Skip to content

Socket restrict sopasscred sopasssec to unix and netlink #2719

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

Snorch
Copy link
Member

@Snorch Snorch commented Aug 19, 2025

This is to follow mainstream kernel change from commit [1]. Else we have all our socket related zdtm tests failing.

7d8d93fdde50b ("net: Restrict SO_PASS{CRED,PIDFD,SEC} to AF_{UNIX,NETLINK,BLUETOOTH}.") [1]

Fixes: #2718
Signed-off-by: Pavel Tikhomirov [email protected]

Snorch added 2 commits August 19, 2025 11:58
This is to follow mainstream kernel change from commit [1]. Else we have
all our socket related zdtm tests failing.

7d8d93fdde50b ("net: Restrict SO_PASS{CRED,PIDFD,SEC} to AF_{UNIX,NETLINK,BLUETOOTH}.") [1]

Fixes: checkpoint-restore#2718
Signed-off-by: Pavel Tikhomirov <[email protected]>
Due to commit [1] it's now impossible to get/set those options on
regular sockets.

While on it, let's fix error handling by closing sockets on all error paths.

7d8d93fdde50b ("net: Restrict SO_PASS{CRED,PIDFD,SEC} to AF_{UNIX,NETLINK,BLUETOOTH}.") [1]

Signed-off-by: Pavel Tikhomirov <[email protected]>
@rst0git
Copy link
Member

rst0git commented Aug 19, 2025

@Snorch Is this the same problem fixed in #2711?

@Snorch
Copy link
Member Author

Snorch commented Aug 19, 2025

@Snorch Is this the same problem fixed in #2711?

Yes, I even tried to search for "SO_PASS" and didn't find anything (probably just somehow I overlooked it), so I made a fix, oops...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

problem with getsockopt: Error (criu/sockets.c:640): sockets: Can't get 1:16(34) opt: Operation not supported"
2 participants