Bug 404051

Summary: On deleting a folder asks to delete the two folders after the folder as well
Product: [Applications] kwalletmanager Reporter: Martin Steigerwald <Martin>
Component: generalAssignee: Valentin Rusu <valir>
Status: CONFIRMED ---    
Severity: grave CC: nate
Priority: HI    
Version First Reported In: 18.04   
Target Milestone: ---   
Platform: Debian unstable   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Works for me in 18.12.2

Description Martin Steigerwald 2019-02-07 09:18:12 UTC
Unfortunately Debian has only 18.04.1 of KWalletManager. But the bug may still be there and as it may cause serious data loss, I report it nonetheless. Can someone with 18.12 of KWalletManager verify it? The KWallet parts in KDE Frameworks are at 5.54.0.


SUMMARY
When I delete a folder from kdewallet like "kmail" for ancient account passwords (I bet it would happen with another wallet as well), it asks two times to also delete the folders after this folder, with deleting as the default action triggerable by hitting enter. This easily triggers severe data loss, thus the "grave" severity.




STEPS TO REPRODUCE
1. Delete a folder from "kdewallet" wallet or I bet any other wallet.

OBSERVED RESULT
1. It asks for confirmation. 

2. I confirm, it deletes the folder and then…

3. immediately asks to delete the next category.

4a) If I say no it asks again, if I say no then, it keeps quiet.

4b) If I say yes *or* just hit enter, then it deletes the next folder and asks whether I like to delete the folder after that as well.

So when I hit enter three times, it just deletes the original folder and two more folder after that *including* all stored secrets in it.



EXPECTED RESULT
It asks for confirmation for deleting the original folder I selected. If I confirm, it deletes the folder and *is done*. If I say no, it does not delete the folder and *is done*.

Also deleting better would not be the default action that the user can trigger with hitting enter.



SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Debian Unstable
KDE Plasma Version: 5.14.5
KDE Frameworks Version: 5.54
KDE Applications Version: Unfortunately a mixture of 18.04, 18.08 and 18.12. For kwalletmanager it is 18.04.1
Qt Version: 5.11.3


ADDITIONAL INFORMATION
I informed Debian Qt/KDE team about outdated KWalletmanager version. It may be too late for Buster at this point in time to include a newer version.
Comment 1 Nate Graham 2019-02-07 18:03:07 UTC
Created attachment 117913 [details]
Works for me in 18.12.2

Cannot reproduce in 18.12.2. See attached screen recording.
Comment 2 Martin Steigerwald 2019-02-07 21:00:53 UTC
Thank you very much Nate for testing.

Now it worked here as well here as well for several folders.

But then I closed it and reopened it and I was able to reproduce the original behavior.

Ah, I think I have found a pattern here. Please try this:

1. Open KWalletManager. Select to delete a folder. Say "no" (no need to actually delete a folder).

2. Close the window of KWalletManager.

3. Open it again. Select to delete a folder. Say "no". Confirmation dialog appears for the folder after it, say "no" here, too.

4. Close the window of KWalletManager.

5. Open it again. Select to delete a folder. Now asks for confirmation to delete the folder you selected and the two folders after it. Say "no" all three times.

I continued it a bit and I was able to have it ask me five times for five subsequent folders. I do not know off-hand how to screen record this. I hope you can reproduce it. Well even better it would be that the bug is not in 18.12.2 of course. But if its there, I hope you can reproduce it.
Comment 3 Nate Graham 2019-02-10 22:29:28 UTC
Yikes, can confirm now with those new steps to reproduce. :(