google / google/gvisor

fsgofer UDS connect may fail due to longer-than-app path

Open
#1,003 3 comments 0 reactions 1 assignee Claimed by @ayushr2 View on GitHub
area: compatibility area: filesystem no-auto-close priority: p3 type: bug
Dominant language
Go
Stars
19.3k
Forks
2k
Avg merge
3d 5h
Merged PRs (30d)
264

Description

Gofer attach points are not 1:1 with app locations. e.g., you may bind mount /foo/bar/baz to /baz. When the app calls connect(/baz/sock), fsgofer will connect(/foo/bar/baz/sock). If len(/foo/bar/baz/sock) > [UnixPathMax](https://github.com/google/gvisor/blob/master/pkg/abi/linux/socket.go#L262) (108), then the connect will fail (unexpectedly for the app).

This is technically possible with regular files too, but (1) PATH_MAX is much larger, and (2) such files couldn't even exist in the first place.

Related #235.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.