Bug 467620

Summary: Cannot open encrypted USB drive from systray
Product: [I don't know] kde Reporter: David <david.cortes.rivera>
Component: generalAssignee: Unassigned bugs mailing-list <unassigned-bugs>
Status: RESOLVED DOWNSTREAM    
Severity: normal CC: nate
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description David 2023-03-20 18:32:53 UTC
SUMMARY
If I create a luks-encrypted volume on an external USB drive with the KDE partition manager, then plug it into the same computer that created it, and try to mount and open it with the systray pop-up, the drive will fail to mount without any error message.

STEPS TO REPRODUCE
1. Connect some external USB drive to the computer.
2. Format it with as ext4 on an encrypted luks volume using the KDE partition manager.
3. Unplug the disk.
4. Plug it again.
5. In the pop-up asking what to do with it, select 'Mount and Open'.
6. Put the correct password.

OBSERVED RESULT
Fails to mount. No error message is given.

EXPECTED RESULT
Should decrypt and mount it successfully.

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Nate Graham 2023-04-04 21:39:07 UTC
I have the exact same use case and it's been working for me for years.

Does it work if you try to mount it in Dolphin, or from Partition Manager?
Comment 2 David 2023-04-05 16:03:06 UTC
(In reply to Nate Graham from comment #1)
> I have the exact same use case and it's been working for me for years.
> 
> Does it work if you try to mount it in Dolphin, or from Partition Manager?

Did some research about it and turns out it's a situation of KDE software not polling for the right permissions for some actions. It mounts and decrypts correctly through other non-KDE software.

I found I think a reddit post (lost the bookmark unfortunately) with some commands to try or some text file to edit (don't remember exactly what it was, tried a couple solutions before finding out one that worked) adding permissions for my user for mounting encrypted devices (mounting unencrypted devices works fine, and the encrypted partition here doesn't require sudo privileges to access).

Afterwards, mounting it works correctly from the system tray icon.
Comment 3 Nate Graham 2023-04-05 17:52:47 UTC
It sounds very much like this is a distro setup issue. Please do report it to your distro.
Comment 4 David 2023-04-05 17:53:57 UTC
(In reply to Nate Graham from comment #3)
> It sounds very much like this is a distro setup issue. Please do report it
> to your distro.

But other non-KDE software can mount it without having to add these permissions manually.
Comment 5 Nate Graham 2023-04-05 18:28:11 UTC
Software stacks can works differently from one another.

If you can pinpoint exactly what change needs to be made, we may be able to investigate whether it's something that could be improved on the KDE side. Still, it's your distro's job to perform this kind of integration work, regardless of what special requirements KDE apps may have here.