mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #2062] keepassxc: single-instance option does not work (private-tmp) #1390
Labels
No labels
LTS merge
LTS merge
bug
bug
converted-to-discussion
doc-todo
documentation
duplicate
enhancement
file-transfer
firecfg
firejail-in-firejail
firetools
graphics
help wanted
information_old
installation
invalid
modif
moved
needinfo
networking
notabug
notourbug
old-version
overlayfs
packaging
profile-request
pull-request
question
question_old
removal
runtime-permissions
sandbox-ipc
security
stale
wiki
wiki
wontfix
wordpress
workaround
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/firejail#1390
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @t4777sd on GitHub (Jul 24, 2018).
Original GitHub issue: https://github.com/netblue30/firejail/issues/2062
The private-tmp feature breaks the keep in single-instance option of keepass. It writes to that directory a lock file / socket. And, since it is private, a new instance cannot read it and thus launches. It would be nice to fix the profile to not do this so features remain the same.
Until that is done is there is a way to fix this in keepassxc.local without editing the original profile?
@SkewedZeppelin commented on GitHub (Jul 24, 2018):
You can use
ignore private-tmp@chiraag-nataraj commented on GitHub (Jul 29, 2018):
@t4777sd Does it write to specific directory within
/tmp? If so, we can whitelist that specific directory instead of usingprivate-tmp.@chiraag-nataraj commented on GitHub (Jul 29, 2018):
Or if we used
mkfileto touch those files, could we then whitelist those specific files? It would be nice to keep the isolating properties ofprivate-tmp.@t4777sd commented on GitHub (Jul 29, 2018):
It writes to the following
/tmp/keepassxc-[user].lock
/tmp/keepassxc-[user].socket
Replace [user] by the current user so if that is dan it would be keepassxc-dan.lock
@chiraag-nataraj commented on GitHub (Jul 29, 2018):
Hmm, if we implement variables
${USER}and${UID}(which was suggested on an issue somewhere...), then we could do aor something similar (although I'm not sure how keepassxc would react if the files existed but nothing was listening...)
@t4777sd commented on GitHub (Jul 30, 2018):
I tested it with those files pre-created and re-opened it and it caused no issues for keepass. So, I guess the only thing left is the ${USER} ability
@chiraag-nataraj commented on GitHub (Jul 30, 2018):
Cool. I think we should be able to do that.
@chiraag-nataraj commented on GitHub (Jul 30, 2018):
Side question: @t4777sd, did you use mkfifo for the socket? We may need to bring in an option
mkfifoifkeepassxccan't deal with a regular file atkeepassxc-${USER}.socket(to be fair, it might be good to have anyway).@chiraag-nataraj commented on GitHub (Jul 30, 2018):
@netblue30 I was looking at the code, and this variable already exists internally as I understand it (
cfg.username). But I'm not sure exactly where the variable substitution should take place. I assume it would be somewhere infs_whitelist.c...?@chiraag-nataraj commented on GitHub (Jul 30, 2018):
Or...in
util.c?@Vincent43 commented on GitHub (Aug 18, 2018):
Does KeePassXC honor
TMPDIR? If yes, you may simply addenv TMPDIR=/home/user/.cacheto its profile. That would be much simpler than adding new code.@chiraag-nataraj commented on GitHub (Aug 19, 2018):
Yes, it does (just tested). I suppose that solves this issue then (maybe we should add it to the profile?).
@chiraag-nataraj commented on GitHub (Aug 19, 2018):
@t4777sd Can you verify that the new profile fixes this issue?
@SkewedZeppelin commented on GitHub (Aug 22, 2018):
@chiraag-nataraj I had some weird issues with
f9aeac080adoes
5ee6ed83bbwork for you?@chiraag-nataraj commented on GitHub (Aug 22, 2018):
@SkewedZeppelin Lemme try (I don't actually use
keepassxclol, but I'll try it for this 😂)@chiraag-nataraj commented on GitHub (Aug 22, 2018):
HAHAHAHAHAHA...hahahahahaha...ha. Oh god, this is too good. I think the fix for #942 breaks your fix. The sandbox name is changed to
keepassxc-1and it doesn't join the existing one.@chiraag-nataraj commented on GitHub (Aug 22, 2018):
But also,
join-or-startshould attach to the existing one if it's specified, shouldn't it?@chiraag-nataraj commented on GitHub (Aug 22, 2018):
Or maybe it's because I have
hidepidenabled...lemme see.@Vincent43 commented on GitHub (Aug 22, 2018):
@chiraag-nataraj yes, sorry I forgot that. We have
join-or-starton several profiles so it's weird this one doesn't work.@chiraag-nataraj commented on GitHub (Aug 22, 2018):
No, it's because of
hidepid, sincejoin-or-startjoins by looking for the pid.@chiraag-nataraj commented on GitHub (Aug 22, 2018):
So yes, @SkewedZeppelin, this is fixed now :) @t4777sd I'm going to close this now, but feel free to re-open if the profile in master doesn't work for you.