[PATCH net] net/x25: inherit the listening socket's security label on accept

Paul Moore paul at paul-moore.com
Tue Nov 24 17:34:38 UTC 2026


On Tue, Nov 24, 2026 at 12:19 PM Wong Steve <shyckless at gmail.com> wrote:
> > the x25_make_new() function is called by
> > x25_rx_call_request(), which as far as I can tell is on pretty
> > analogous to an accept() operation, is that correct?
>
> Yes. x25_rx_call_request() runs in the receive path
> (x25_lapb_receive_frame() -> x25_receive_data()) when a Call Request
> arrives for a listening socket. It is the X.25 counterpart of TCP
> creating the child socket for an incoming connection:
>
> - x25_find_listener() finds the listening socket,
> - x25_make_new() creates the new socket and copies the listener's
>   settings,
> - the new socket is queued on the listener's receive queue, and
> - x25_accept() later takes it off the queue and grafts it onto the
>   socket that accept() returns.

Great, thanks.

Reviewed-by: Paul Moore <paul at paul-moore.com>

-- 
paul-moore.com



More information about the Linux-security-module-archive mailing list