acrn-kernel/net/x25
Hyunwoo Kim 22312eeab3 net/x25: Fix to not accept on connected socket
[ Upstream commit f2b0b5210f ]

When listen() and accept() are called on an x25 socket
that connect() succeeds, accept() succeeds immediately.
This is because x25_connect() queues the skb to
sk->sk_receive_queue, and x25_accept() dequeues it.

This creates a child socket with the sk of the parent
x25 socket, which can cause confusion.

Fix x25_listen() to return -EINVAL if the socket has
already been successfully connect()ed to avoid this issue.

Signed-off-by: Hyunwoo Kim <v4bel@theori.io>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-02-09 11:28:13 +01:00
..
Kconfig
Makefile
af_x25.c net/x25: Fix to not accept on connected socket 2023-02-09 11:28:13 +01:00
sysctl_net_x25.c
x25_dev.c net/x25: Fix skb leak in x25_lapb_receive_frame() 2022-11-15 20:22:19 -08:00
x25_facilities.c
x25_forward.c
x25_in.c
x25_link.c
x25_out.c
x25_proc.c x25: remove redundant pointer dev 2022-05-10 11:59:22 +02:00
x25_route.c
x25_subr.c
x25_timer.c