<html>
<head>
<base href="https://bugs.freedesktop.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - pdfsig: Segfault in ~SignatureHandler / double-free"
href="https://bugs.freedesktop.org/show_bug.cgi?id=97149">97149</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>pdfsig: Segfault in ~SignatureHandler / double-free
</td>
</tr>
<tr>
<th>Product</th>
<td>poppler
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>x86-64 (AMD64)
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux (All)
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>minor
</td>
</tr>
<tr>
<th>Priority</th>
<td>medium
</td>
</tr>
<tr>
<th>Component</th>
<td>utils
</td>
</tr>
<tr>
<th>Assignee</th>
<td>poppler-bugs@lists.freedesktop.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>freedesktop@michael-joost.de
</td>
</tr></table>
<p>
<div>
<pre>pdfsig (from poppler-0.45) results in a segfault on any signed PDF document
(e.g. the BUDGET-2015-BUD.pdf from gpo.gov).
Reason is a double-destroy of a certificate in the destructor of
SignatureHandler.
The segfault only comes to effect if nspr(-4.12) is compiled for DEBUG, which,
sadly, is its default setting. The debug version of nspr causes freed memory to
be filled with a 0xDA pattern, and the second destroy's acccess to this in
nss(-3.25) fails. The release version, without the pattern, is somehow able to
recover from the double-destroy.
Switching between release/debug configs of a component, or any of its
dependencies, should only impact non-functional aspects (such as performance),
but never the functional behavior.
See also:
<a href="https://lists.freedesktop.org/archives/poppler/2016-July/011913.html">https://lists.freedesktop.org/archives/poppler/2016-July/011913.html</a>
(and thread)
<a href="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSPR/NSPR_build_instructions">https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSPR/NSPR_build_instructions</a></pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>