mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #5006] git: ssh push fails when using a yubikey #2852
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#2852
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 @WhyNotHugo on GitHub (Mar 4, 2022).
Original GitHub issue: https://github.com/netblue30/firejail/issues/5006
Description
When using a yubikey-backed ssh key (e.g.:
sk-ssh-ed25519@openssh.com), any git operation (git pull,git push) fails.Removing
/usr/local/bin/sshmakes it work again.Steps to Reproduce
git pushExpected behavior
Should prompt to tap the yubikey and work.
Actual behavior
This is the same message that's displayed with the yubikey is unplugged.
Behavior without a profile
firejail --noprofile /usr/bin/git pullworks fine.Additional context
Only applicable when using a hardware-backed ssh key. I think git's sandbox is too strict for this.
Environment
Checklist
/usr/bin/vlc) "fixes" it).https://github.com/netblue30/firejail/issues/1139)browser-allow-drm yes/browser-disable-u2f noinfirejail.configto allow DRM/U2F in browsers.--profile=PROFILENAMEto set the right profile. (Only relevant for AppImages)Log
Output of
LC_ALL=C firejail /path/to/programOutput of
LC_ALL=C firejail --debug /path/to/program@ghost commented on GitHub (Mar 4, 2022):
Probably caused by the
nou2fin the git profile. Try addingignore nou2fin a git.local (either per-user in ~/.config/firejail or system-wide in /etc/firejail).@WhyNotHugo commented on GitHub (Mar 4, 2022):
That didn't work:
Oddly, removing
sudo rm /usr/local/bin/sshalso serves as a workaround.@WhyNotHugo commented on GitHub (Mar 4, 2022):
Oh, there's no file in
/usr/local/bin/git, even after runningfirecfg.@ghost commented on GitHub (Mar 4, 2022):
You can see the list of applications that are 'automatically' firejailed through firecfg in /etc/firejail/firecfg.config. And as you noticed, git isn't in there, ssh is. That means you will have to create a symlink in /usr/local/bin for git if you want it sandboxed.
By removing /usr/local/bin/ssh you've disabled Firefail from running SSH in a sandbox. Although it makes things work, it's not really a workaround, or at least not a very secure one. If you have some time and feel up to it, I'd suggest (re-)enabling git + ssh firejails, try the git.local again and report back. It might need additional options added or removed, but we can help with that. BTW, Arch Linux repo package of firejail is up to 0.9.68-1, make sure you're fully updated.
@kmk3 commented on GitHub (Mar 4, 2022):
@WhyNotHugo commented on Mar 4:
Does it work with
ignore private-devon ssh.local?If so, the cause is likely the same as:
In which case maybe we could add a comment about it to ssh.profile.