Skip to content

Commit

Permalink
interfaces/seccomp/template.go: allow copy_file_range
Browse files Browse the repository at this point in the history
This was recently introduced as an optimization to Go 1.15, and so apps that
start compiling may start to try and use it.

Note that as of this commit, Go 1.15 does not fall back, and so apps that use
this will fail outright, but there is work upstream in Go to fix this so that
apps that get denied usage of copy_file_range with an EPERM will fallback to
potentially slower implementations.

See golang/go#40893 and
https://go-review.googlesource.com/c/go/+/249257/ for more details on the Go
issue and the fallback implementation.

Signed-off-by: Ian Johnson <[email protected]>
  • Loading branch information
anonymouse64 committed Nov 25, 2020
1 parent d65f9fa commit 7717d17
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions interfaces/seccomp/template.go
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,10 @@ readdir
readlink
readlinkat
# the file descriptors used here will already be mediated by apparmor, so it's
# safe to not filter syscall args here
copy_file_range
# allow reading from sockets
recv
recvfrom
Expand Down

0 comments on commit 7717d17

Please sign in to comment.