Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.6.9

Bug #20453 crypt_gpg stops working after gnupg upgrade
Submitted: 2014-11-29 01:26 UTC
From: xelo Assigned: alec
Status: Closed Package: Crypt_GPG (version 1.3.2)
PHP Version: 5.6.3 OS: Archlinux
Roadmaps: 1.6.0b1    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 48 - 1 = ?

 
 [2014-11-29 01:26 UTC] xelo (Dustin Demuth)
Description: ------------ After gnupg upgrade (2.0.26-1 -> 2.1.0-4) digital signatures do not work anymore. The used keys are not protected with a pin/passphrase Expected result: ---------------- data is signed Actual result: -------------- Data is not signed, Script crashes. LOG: Nov 28 20:11:41 smeik nginx[859]: 2014/11/28 20:11:41 [error] 865#0: *13 FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught <table style="border: 1px" cellspacing="0"> Nov 28 20:11:41 smeik nginx[859]: <tr><td colspan="3" style="background: #ff9999"> <b>Crypt_GPG_Exception</b>: Unknown error signing data. Please use the 'debug' option when creating the Crypt_GPG object, and file a bug report at http://pear.php.net/bugs/report.php?package=Crypt_GPG in <b>/usr/share/pear/Crypt/GPG.php</b> on line <b>1019</b></td></tr> Nov 28 20:11:41 smeik nginx[859]: <tr><td colspan="3" style="background-color: #aaaaaa; text-align: center; font-weight: bold;">Exception trace</td></tr> Nov 28 20:11:41 smeik nginx[859]: <tr><td style="text-align: center; background: #cccccc; width:20px; font-weight: bold;">#</td><td style="text-align: center; background: #cccccc; font-weight: bold;">Function</td><td style="text-align: center; background: #cccccc; font-weight: bold;">Location</td></tr> Nov 28 20:11:41 smeik nginx[859]: <tr><td style="text-align: center;">0</td><td>Crypt_GPG->_sign('YTozOntzOjc6Imhl…', false, null, 3, true, false)</td><td>/usr/share/pear/Crypt/GPG.php:1019</td></tr> Nov 28 20:11:41 smeik nginx[859]: <tr><td style="text-align: center;">1</td><td>Crypt_G" while reading response header from upstream, client: 127.0.0.1, server: localhost, request: "GET /application/ HTTP/1.1", upstream: "fastcgi://unix:/run/php-fpm/php-fpm.sock:", host: "localhost" From Debug Mode: Crypt_GPG DEBUG: OPENING SUBPROCESS WITH THE FOLLOWING COMMAND: Crypt_GPG DEBUG: /usr/bin/gpg --status-fd '3' --command-fd '4' --no-secmem-warning --no-tty --no-default-keyring --no-options --always-trust --homedir '/srv/http/keys/application' --version Crypt_GPG DEBUG: BEGIN PROCESSING Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 1 Crypt_GPG DEBUG: GPG error stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG error Crypt_GPG DEBUG: => read 73 bytes Crypt_GPG DEBUG: ERROR: gpg: WARNING: unsafe permissions on homedir '/srv/http/keys/application' Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 3 Crypt_GPG DEBUG: GPG output stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG output Crypt_GPG DEBUG: => read 592 bytes Crypt_GPG DEBUG: GPG error stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG error Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: GPG status stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG status Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 1 Crypt_GPG DEBUG: GPG output stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG output Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: END PROCESSING Crypt_GPG DEBUG: CLOSING SUBPROCESS Crypt_GPG DEBUG: OPENING SUBPROCESS WITH THE FOLLOWING COMMAND: Crypt_GPG DEBUG: /usr/bin/gpg --status-fd '3' --command-fd '4' --no-secmem-warning --no-tty --no-default-keyring --no-options --no-permission-warning --exit-on-status-write-error --trust-model always --with-colons --with-fingerprint --with-fingerprint --fixed-list-mode --homedir '/srv/http/keys/application' --list-secret-keys 'FD0E37311717109EE23745AF81507E398A2521AC' Crypt_GPG DEBUG: BEGIN PROCESSING Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 1 Crypt_GPG DEBUG: GPG output stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG output Crypt_GPG DEBUG: => read 399 bytes Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 3 Crypt_GPG DEBUG: GPG output stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG output Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: GPG error stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG error Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: GPG status stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG status Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: END PROCESSING Crypt_GPG DEBUG: CLOSING SUBPROCESS Crypt_GPG DEBUG: OPENING SUBPROCESS WITH THE FOLLOWING COMMAND: Crypt_GPG DEBUG: /usr/bin/gpg --status-fd '3' --command-fd '4' --no-secmem-warning --no-tty --no-default-keyring --no-options --no-permission-warning --exit-on-status-write-error --trust-model always --with-colons --with-fingerprint --with-fingerprint --fixed-list-mode --homedir '/srv/http/keys/application' --list-public-keys 'FD0E37311717109EE23745AF81507E398A2521AC' Crypt_GPG DEBUG: BEGIN PROCESSING Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 1 Crypt_GPG DEBUG: GPG output stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG output Crypt_GPG DEBUG: => read 426 bytes Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 3 Crypt_GPG DEBUG: GPG output stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG output Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: GPG error stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG error Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: GPG status stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG status Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: END PROCESSING Crypt_GPG DEBUG: CLOSING SUBPROCESS Crypt_GPG DEBUG: OPENING SUBPROCESS WITH THE FOLLOWING COMMAND: Crypt_GPG DEBUG: /usr/bin/gpg --status-fd '3' --command-fd '4' --no-secmem-warning --no-tty --no-default-keyring --no-options --no-permission-warning --exit-on-status-write-error --trust-model always --armor --local-user 'FD0E37311717109EE23745AF81507E398A2521AC' --homedir '/srv/http/keys/application' --detach-sign Crypt_GPG DEBUG: BEGIN PROCESSING Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 1 Crypt_GPG DEBUG: GPG is ready for input Crypt_GPG DEBUG: => about to write 688 bytes to GPG input Crypt_GPG DEBUG: => wrote 688 bytes Crypt_GPG DEBUG: => closing GPG input pipe Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 1 Crypt_GPG DEBUG: GPG status stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG status Crypt_GPG DEBUG: => read 26 bytes Crypt_GPG DEBUG: STATUS: BEGIN_SIGNING H8 Crypt_GPG DEBUG: => closing GPG input pipe Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 1 Crypt_GPG DEBUG: GPG status stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG status Crypt_GPG DEBUG: => read 32 bytes Crypt_GPG DEBUG: STATUS: PINENTRY_LAUNCHED 5093 Crypt_GPG DEBUG: => closing GPG input pipe Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 1 Crypt_GPG DEBUG: GPG error stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG error Crypt_GPG DEBUG: => read 82 bytes Crypt_GPG DEBUG: ERROR: gpg: signing failed: Operation cancelled Crypt_GPG DEBUG: ERROR: gpg: signing failed: Operation cancelled Crypt_GPG DEBUG: => closing GPG input pipe Crypt_GPG DEBUG: selecting streams Crypt_GPG DEBUG: => got 3 Crypt_GPG DEBUG: GPG output stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG output Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: GPG error stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG error Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: GPG status stream ready for reading Crypt_GPG DEBUG: => about to read 8192 bytes from GPG status Crypt_GPG DEBUG: => read 0 bytes Crypt_GPG DEBUG: => closing GPG input pipe Crypt_GPG DEBUG: END PROCESSING Crypt_GPG DEBUG: CLOSING SUBPROCESS Crypt_GPG DEBUG: => subprocess returned an unexpected exit code: 2

Comments

 [2014-11-29 02:49 UTC] gauthierm (Michael Gauthier)
This might be lot of work to fix. Looks like a lot changed in GnuPG 2.1 https://gnupg.org/faq/whats- new-in-2.1.html
 [2016-06-10 06:46 UTC] alec (Aleksander Machniak)
-Status: Open +Status: Feedback
I just noticed that @xelo was using 1.3.2 which did not support GnuPG 2.x at all. So, I'm curious if anyone tried GnuPG 2.1 with Crypt_GPG 1.4.
 [2016-08-13 06:43 UTC] alec (Aleksander Machniak)
GnuPG 2.1 support is work in progress here: https://github.com/pear/Crypt_GPG/pull/27.
 [2016-10-24 12:41 UTC] alec (Aleksander Machniak)
-Status: Feedback +Status: Closed -Assigned To: +Assigned To: alec -Roadmap Versions: +Roadmap Versions: 2.0.0.b1
This bug has been fixed in SVN. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better. Now in git-master