summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/vfs/anonfs.go
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2020-04-29 03:17:56 +0000
committergVisor bot <gvisor-bot@google.com>2020-04-29 03:17:56 +0000
commit633d413b30734e629996821342b81d4e67e0cb22 (patch)
tree2def7c27594dc8721649b86df5a9b9e856fbfe47 /pkg/sentry/vfs/anonfs.go
parentb11d270c40b190c6aef7396d0e5f0941d123a345 (diff)
parentce19497c1c0829af6ba56f0cc68e3a4cb33cf1c8 (diff)
Merge release-20200413.0-18-gce19497 (automated)
Diffstat (limited to 'pkg/sentry/vfs/anonfs.go')
-rwxr-xr-xpkg/sentry/vfs/anonfs.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/pkg/sentry/vfs/anonfs.go b/pkg/sentry/vfs/anonfs.go
index b1a998590..981bd8caa 100755
--- a/pkg/sentry/vfs/anonfs.go
+++ b/pkg/sentry/vfs/anonfs.go
@@ -241,6 +241,9 @@ func (fs *anonFilesystem) BoundEndpointAt(ctx context.Context, rp *ResolvingPath
if !rp.Final() {
return nil, syserror.ENOTDIR
}
+ if err := GenericCheckPermissions(rp.Credentials(), MayWrite, anonFileMode, anonFileUID, anonFileGID); err != nil {
+ return nil, err
+ }
return nil, syserror.ECONNREFUSED
}