Closed danielmitterdorfer closed 6 years ago
rpm 4.12 is getting mainstream... It is even in Debian. We should really go forward with a patch for the next version.
I created a pull request for this : https://github.com/mojohaus/rpm-maven-plugin/pull/78
fixed by #78
Problem Description
We have spotted Jenkins build failures when signing RPM packages on systems with gpg-agent 2.1+ (i.e. Fedora 22 and Fedora 23). Here is the relevant part of the build output:
(for all details, please see the build logs).
If I run this command manually on Fedora 22:
I can see an ncurses-based password prompt. gpg provides a helper program called pinentry to change the appearance of the password prompt but only ncurses, QT and GTK are supported. So with pinentry it is not possible to get the old password prompt.
However, we can add two config options:
gpg-agent.conf:
gpg.conf:
Now we're at least able to get the password prompt again. However,
RPMSigner
expects the output "Pass phrase is good." which is not shown anymore in newer gpg-agent versions (in gpg-agent version 2.1+, the invokingrpm
command exits either with exit code 0 on success or a non-zero exit code if the password was incorrect).Environment information
Tested with
rpm-maven-plugin
version 2.1.3 and 2.1.5.I think it boils down to modifying the expect script in
RPMSigner
but I don't see an easy option to support multiple versions of gpg. Another option seems to be to usegpg-preset-passphrase
to set the passphrase ingpg-agent
before it is used.