mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #2301] File transfer fails on large files #1532
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#1532
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 @laniakea64 on GitHub (Dec 18, 2018).
Original GitHub issue: https://github.com/netblue30/firejail/issues/2301
Xubuntu 18.04 64-bit
firejail self build from
9eca281abbSteps to reproduce
check free space available in
/runwithdf -Th, and create or find a file larger than that (On my system I used a 2 GB file)run
firejail --noprofile --overlay-tmpfsTry to get the large file from (1) using
firejail --get=<pid> path/to/the/fileExpected results
At (3), file should be copied from the overlay-tmpfs to the working directory
Actual results
At (3) it sits for a short time, then exits with status 1 without anything seeming to happen. I think it's related to the file being bigger than free space in
/runbecause of this -9eca281abb/src/firejail/ls.c (L316-L345)And indeed, a file does appear at
/run/firejail/tmpget-...while thefirejail --get=...command is running.@chiraag-nataraj commented on GitHub (Feb 7, 2019):
@laniakea64 I presume this is still a problem?
@laniakea64 commented on GitHub (Feb 7, 2019):
Yes, this still happens in self build from
2323a45ca7@rusty-snake commented on GitHub (Aug 26, 2019):
@laniakea64 fixed by
ccd0152? (#2820)@laniakea64 commented on GitHub (Aug 26, 2019):
I'm unable to fully test this in self build from
580e49badabecause joining the sandbox doesn't seem to actually get me in the overlay-tmpfs -run
firejail --overlay-tmpfs --noprofile, note the parent pidin the sandbox:
firejail --join=<pid>(replacing<pid>with the parent pid)When joined to the sandbox, run:
And the file created in (2) is not there in the second terminal, it's only there in the first terminal.
Edit: It's not just not getting me in the sandbox's overlay-tmpfs. It's completely ignoring that aspect of the sandbox. In the second terminal, running
And a file called
AAAAAappears in the real~/Downloads, despite the sandbox being--overlay-tmpfs! 😱Actually, looks like
--get=might not be affected by this, so maybe I can do a partial test? I setfile-copy-limit 4096infirejail.config, then tried to transfer a 2 GB file. Transfer failed, same as before. Transfer of the 5-bytetest.txtfile mentioned in this comment seems to work.@laniakea64 commented on GitHub (Sep 18, 2019):
The regression reported in https://github.com/netblue30/firejail/issues/2301#issuecomment-524923730 is still there in self build from
0ecbe8631c. Should I be filing it as a separate issue?@laniakea64 commented on GitHub (Oct 9, 2019):
Since I didn't get a reply to this, I assume you rather it just be discussed here, even though it's not the same as the original issue.
The regression reported in https://github.com/netblue30/firejail/issues/2301#issuecomment-524923730 is still there in self build from
b35c000fee. So I did a git bisect, and it pointed to3e662f793das the culprit.@smitsohu commented on GitHub (Oct 10, 2019):
@laniakea64 Thanks a lot! I'll try to figure out what's going wrong.
@laniakea64 commented on GitHub (Oct 18, 2019):
https://github.com/netblue30/firejail/issues/2301#issuecomment-524923730 seems fixed in self build from
61bfaa6927. Thanks @smitsohu !Back to the original issue: to finally properly answer @rusty-snake comment https://github.com/netblue30/firejail/issues/2301#issuecomment-524762431 - increasing
file-copy-limitin/etc/firejail/firejail.configdoes not help here.@atrent commented on GitHub (May 8, 2020):
I had to copy large videos generated by Zoom... and I had not edited the limit in config beforehand, so I needed to solve the problem before turning off the program (thus losing tmp files).
I solved by copying files from the inside of the firejail sandbox, e.g. using Midnight Commander:
$ firejail --join= mc
and then copying files using a "Shell Link" (i.e., FISH file transfer) to the host.
(instead of 'firejail --get= ...')
@smitsohu commented on GitHub (Sep 2, 2020):
Should be fixed in
ccd01529adand27c136dcf4. Also there will be acatoption in 0.9.64 which can be used with shell redirection on files of arbitrary size.Thanks for reporting the bug.
@laniakea64 commented on GitHub (Sep 3, 2020):
I'm unable to check it because build from
6ac40a5979fails:@rusty-snake commented on GitHub (Sep 3, 2020):
I know build is failing ATM. Checkout
4762cf6855for now.@laniakea64 commented on GitHub (Sep 3, 2020):
Sorry, this is still not fixed in self build from
4762cf6855.--cat=+ shell redirection does seem to work though.Can this issue be reopened? Or is the answer to just use
--cat=for large files?Thanks 🙂
@smitsohu commented on GitHub (Sep 3, 2020):
Reopening! Sorry @laniakea64 I confused this with a different issue.
Maybe someone comes up with a better idea, but for now it seems that's going to be the answer.
I guess we could just reimplement the current
--getusing--catunder the hood.