Bug 410020

Summary: Regression: fea2af1d63192226d18910e18627091206a2fcf5 breaks GPG wallets
Product: [Frameworks and Libraries] frameworks-kwallet Reporter: Luca Beltrame <lbeltrame>
Component: generalAssignee: Valentin Rusu <valir>
Status: RESOLVED FIXED    
Severity: major CC: kdelibs-bugs-null, stefan.bruens
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Luca Beltrame 2019-07-20 07:04:37 UTC
SUMMARY

After https://phabricator.kde.org/D21002 landed, GPG wallets are no longer loaded by kwalletd, nor are visible in kwalletmanager. This is despite GPG support being advertised and compiled in. 

Reverting fea2af1d63192226d18910e18627091206a2fcf5 and its follow up commit restores functionality. 

STEPS TO REPRODUCE
1. Start a session, investigate wallets through kwalletmanager

OBSERVED RESULT

No wallets are opened (nor the user is asked for the GPG passphrase if defined) and no wallets are even visible in kwalletmanager.

EXPECTED RESULT

Wallets should be regularly opened through GPG.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: master
KDE Plasma Version: master
KDE Frameworks Version: master
Qt Version: 5.13
Comment 1 Luca Beltrame 2019-07-20 07:27:11 UTC
Git commit ff6b077d9200856dc6e393a04c6b3ae82d9792ed by Luca Beltrame.
Committed on 20/07/2019 at 07:21.
Pushed by lbeltrame into branch 'master'.

Move kwalletd initialization earlier

In the previous code (before removing the kde4 migration agent) it was
started inconditionally, while after the change it was gated behind an
if.

However this does not take into account GPG wallets, which, as far as
I understand from the code, do not produce a password hash.

Moving initialization out of the if restores GPG functionality

Stefan, please check if everything is correct.

CCMAIL: stefan.bruens@rwth-aachen.de

M  +1    -1    src/runtime/kwalletd/main.cpp

https://commits.kde.org/kwallet/ff6b077d9200856dc6e393a04c6b3ae82d9792ed
Comment 2 Stefan BrĂ¼ns 2019-07-20 12:10:11 UTC
Luca, thanks a lot for investigating this. Though I would have preferred going this through Phabricator, the reasoning is really sound, so take this as an LGTM/"Accepted".