Bug 695992

Summary: Internal hyperlinks lost when converting to pdf and password specified
Product: Ghostscript Reporter: Andrew Maurer <andrew.maurer>
Component: PDF WriterAssignee: Ken Sharp <ken.sharp>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P4    
Version: 9.15   
Hardware: PC   
OS: Windows 7   
Customer: Word Size: ---

Description Andrew Maurer 2015-05-15 13:50:16 UTC
This is a follow up to:
Bug 695162 - Internal hyperlinks lost when converting to pdf
http://bugs.ghostscript.com/show_bug.cgi?id=695162

I first compile Ulrike's example using dvips.exe then gswin64.exe:
\documentclass{book}
\usepackage{hyperref}
\begin{document}
\chapter{Titre}
lala\ref{chp:deux}
\chapter{Titre}\label{chp:deux}
\end{document}

Links work if I don't specify a pdf password in the ghostscript options:
-sDEVICE=pdfwrite -dBATCH -dNOPAUSE -sOutputFile="%bm.pdf" "%bm.ps"

but links don't work if I specify a password:
-sDEVICE=pdfwrite -dBATCH -dNOPAUSE -sUserPassword=pass -sOwnerPassword=pass  -sOutputFile="%bm.pdf" "%bm.ps"

I'm using Ghostscript 9.15 for Windows (64 bit)
Comment 1 Ken Sharp 2015-06-09 02:17:16 UTC
Fixed in commit cb48631e7254e0843a08f075777cbecb43947823