linux/net
Patrick McHardy 77247bbb30 [NETLINK]: Fix module refcounting problems
Use-after-free: the struct proto_ops containing the module pointer
is freed when a socket with pid=0 is released, which besides for kernel
sockets is true for all unbound sockets.

Module refcount leak: when the kernel socket is closed before all user
sockets have been closed the proto_ops struct for this family is
replaced by the generic one and the module refcount can't be dropped.

The second problem can't be solved cleanly using module refcounting in the
generic socket code, so this patch adds explicit refcounting to
netlink_create/netlink_release.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-08-29 16:00:45 -07:00
..
802
8021q
appletalk [TCP]: Move the tcp sock states to net/tcp_states.h 2005-08-29 15:41:54 -07:00
atm
ax25 [TCP]: Move the tcp sock states to net/tcp_states.h 2005-08-29 15:41:54 -07:00
bluetooth [NET]: Store skb->timestamp as offset to a base timestamp 2005-08-29 15:58:24 -07:00
bridge [NET]: Store skb->timestamp as offset to a base timestamp 2005-08-29 15:58:24 -07:00
core [NET]: Store skb->timestamp as offset to a base timestamp 2005-08-29 15:58:24 -07:00
dccp [DCCP]: Fix compiler warnings 2005-08-29 16:00:12 -07:00
decnet [TCP]: Move the tcp sock states to net/tcp_states.h 2005-08-29 15:41:54 -07:00
econet [NET]: Store skb->timestamp as offset to a base timestamp 2005-08-29 15:58:24 -07:00
ethernet
ipv4 [NETLINK]: Remove unused groups member from struct netlink_skb_parms 2005-08-29 16:00:39 -07:00
ipv6 [NETFILTER]: Remove tasklist_lock abuse in ipt{,6}owner 2005-08-29 15:59:07 -07:00
ipx [IPX]: Fix build error in ipx_recvmsg() 2005-08-29 16:00:24 -07:00
irda [TCP]: Move the tcp sock states to net/tcp_states.h 2005-08-29 15:41:54 -07:00
key
lapb
llc [TCP]: Move the tcp sock states to net/tcp_states.h 2005-08-29 15:41:54 -07:00
netfilter [NET]: Store skb->timestamp as offset to a base timestamp 2005-08-29 15:58:24 -07:00
netlink [NETLINK]: Fix module refcounting problems 2005-08-29 16:00:45 -07:00
netrom [TCP]: Move the tcp sock states to net/tcp_states.h 2005-08-29 15:41:54 -07:00
packet [NET]: Store skb->timestamp as offset to a base timestamp 2005-08-29 15:58:24 -07:00
rose [TCP]: Move the tcp sock states to net/tcp_states.h 2005-08-29 15:41:54 -07:00
rxrpc
sched [NET]: Deinline netif_carrier_{on,off}(). 2005-08-29 15:57:08 -07:00
sctp [NET]: Store skb->timestamp as offset to a base timestamp 2005-08-29 15:58:24 -07:00
sunrpc [NET]: Store skb->timestamp as offset to a base timestamp 2005-08-29 15:58:24 -07:00
unix [TCP]: Move the tcp sock states to net/tcp_states.h 2005-08-29 15:41:54 -07:00
wanrouter [TCP]: Move the tcp sock states to net/tcp_states.h 2005-08-29 15:41:54 -07:00
x25 [TCP]: Move the tcp sock states to net/tcp_states.h 2005-08-29 15:41:54 -07:00
xfrm [NETLINK]: Fix missing dst_groups initializations in netlink_broadcast users 2005-08-29 16:00:34 -07:00
compat.c
Kconfig [DCCP]: Initial implementation 2005-08-29 15:49:46 -07:00
Makefile [DCCP]: Initial implementation 2005-08-29 15:49:46 -07:00
nonet.c
socket.c [NET]: Make use of ->private_data in sockfd_lookup 2005-08-29 15:56:38 -07:00
sysctl_net.c
TUNABLE