Help needed to fix FilterActionEncryptTest::shouldEncrypt(PGP*) unit tests

Sandro Knauß sknauss at kde.org
Tue Aug 17 18:17:06 BST 2021


Hey,

What I used for all tests inside messagelib is  in gpg-agent.conf
faked-system-time 20130110T154812

this makes sure, that keys do not expire ;)
see messagelib/messagecore/autotests/gnupg_home for maybe more settings, that 
may help.

Also what helps a lot is to create a GPGHOME at your own, by coping 
src/filter/autotests/gpghome into a temp dir and than 
export GNUPGHOME = <path>

and than use gpg --list-keys and gpg --list-secrect-keys etc. to understand 
why those keys can't be used. As this give you a direct output, that is more 
"user friendly".

regards,

hefee



On Dienstag, 17. August 2021 00:01:04 CEST Friedrich W. H. Kossebau wrote:
> Thanks for the quick reply, Ingo. Tried your suggestion (see below, but no
> luck).
> 
> Am Montag, 16. August 2021, 23:21:29 CEST schrieb Ingo Klöcker:
> > Without having looked at this I'm making a wild guess that it's caused by
> > current gpg refusing signatures made with SHA1. This happened for some
> > tests in gpgme. To fix this one needs to add "allow-weak-key-signatures"
> > to the gpg.conf of the test environment resp. add a gpg.conf with this
> > option to src/filter/autotests/gpghome.
> > 
> > Again, that's just a wild guess. I may be completely wrong. Maybe we will
> > have to have a closer look at it.
> 
> Added a file src/filter/autotests/gpghome/gpg.conf, with the line
> allow-weak-key-signatures
> also made sure by debug logging it gets deployed to the temporary GNUPGHOME
> working dir with all the other files by GPGHelper,
> but test keeps failing with same error :(
> 
> Cheers
> Friedrich






More information about the kde-pim mailing list