security_socket_getpeername(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ¦‹ security_socket_getpeername(9) πŸ¦‹

bestie, this page is from the Kernel API Manual, and it’s serving security_socket_getpeername(9) realness. it’s the hook that checks if reading the peer’s addr is allowed, and it’s lowkey important. no cap.

✨ NAME ✨

security_socket_getpeername β€” check if reading the peer’s addr is allowed.

πŸŽ€ SYNOPSIS πŸŽ€

int security_socket_getpeername (struct socket *sock );

πŸ’– ARGUMENTS πŸ’–

  • sock β€” socket. that’s the argument, bestie. it’s literally just the socket.

🌸 DESCRIPTION 🌸

okay so this hook checks permission before the remote address (name) of a socket object is read. it’s giving β€œmay i please look at the peer’s addr?” energy. that’s the whole description, and it ate.

⭐ RETURN ⭐

Returns 0 if permission is granted. if it’s allowed, you get 0 β€” that’s the return vibe, periodt.

πŸ”₯ SEE ALSO πŸ”₯

bestie, this SEE ALSO section is the entire security friend group. i’m not skipping a single one, fr fr:

mwah πŸ’‹ this cutie came from source/version ./security, dated October 2026, and it’s still security_socket_getpeername(9). periodt. 🫢

πŸ“¦ where this page comes from