mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #1339] Stopping alias #921
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#921
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 @sknepal on GitHub (Jun 16, 2017).
Original GitHub issue: https://github.com/netblue30/firejail/issues/1339
Hi,
I ran into an issue. I am using firejail to run restricted bash (rbash) for online repl. One of the ways a user can cause problem to others is by setting alias on .bashrc file. For example:
alias python="echo bla". Whenever other users would try to run python now, everyone would see "bla" printed on their screen instead.When I use
--private-home=/home/user/somediroption, this does not take place. The changes to bashrc does not carry over to other user's repl. But when I use--private=/home/user/somedir, this takes place everywhere. Maybe because the modifications are not discarded ?Now the issue is,
--private-homeoption does not start the bash in the home directory. It starts in a directory above it unlike--privateoption which starts in the home directory that was given as input. As I am on a restricted bash, I cannot switch tosomedirwithcd-- its not allowed. I need to switch to the home directory (i.e. somedir) in order to be able to run programs stored there.Any idea how I could achieve it? Are private-home and private options meant to be working differently in the sense where they start (inside the home dir or outside)?
Thank you!
@netblue30 commented on GitHub (Jun 18, 2017):
--private-home=/home/user/somedir will mount /home/user/somedir on top of /home/user. You cannot cd to somedir, because you are already there, although you appear to be in /home/user. Your bash session will end up using /home/user/somedir/.bashrc.