Star64_linux/net
Eric W. Biederman 3fbc290540 netlink: Make the sending netlink socket availabe in NETLINK_CB
The sending socket of an skb is already available by it's port id
in the NETLINK_CB.  If you want to know more like to examine the
credentials on the sending socket you have to look up the sending
socket by it's port id and all of the needed functions and data
structures are static inside of af_netlink.c.  So do the simple
thing and pass the sending socket to the receivers in the NETLINK_CB.

I intend to use this to get the user namespace of the sending socket
in inet_diag so that I can report uids in the context of the process
who opened the socket, the same way I report uids in the contect
of the process who opens files.

Acked-by: David S. Miller <davem@davemloft.net>
Acked-by: Serge Hallyn <serge.hallyn@canonical.com>
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
2012-08-14 21:49:49 -07:00
..
9p
802
8021q
appletalk userns: Print out socket uids in a user namespace aware fashion. 2012-08-14 21:48:06 -07:00
atm
ax25 userns: Convert net/ax25 to use kuid_t where appropriate 2012-08-14 21:49:42 -07:00
batman-adv
bluetooth
bridge
caif netvm: prevent a stream-specific deadlock 2012-07-31 18:42:47 -07:00
can
ceph libceph: fix crypto key null deref, memory leak 2012-08-02 09:19:20 -07:00
core userns: Convert sock_i_uid to return a kuid_t 2012-08-14 21:47:34 -07:00
dcb
dccp
decnet ipv4: Restore old dst_free() behavior. 2012-07-31 14:41:38 -07:00
dns_resolver
dsa
ethernet
ieee802154
ipv4 userns: Use kgids for sysctl_ping_group_range 2012-08-14 21:49:10 -07:00
ipv6 net ip6 flowlabel: Make owner a union of struct pid * and kuid_t 2012-08-14 21:49:25 -07:00
ipx userns: Print out socket uids in a user namespace aware fashion. 2012-08-14 21:48:06 -07:00
irda
iucv
key userns: Print out socket uids in a user namespace aware fashion. 2012-08-14 21:48:06 -07:00
l2tp
lapb
llc userns: Print out socket uids in a user namespace aware fashion. 2012-08-14 21:48:06 -07:00
mac80211
mac802154
netfilter
netlabel
netlink netlink: Make the sending netlink socket availabe in NETLINK_CB 2012-08-14 21:49:49 -07:00
netrom
nfc
openvswitch
packet userns: Print out socket uids in a user namespace aware fashion. 2012-08-14 21:48:06 -07:00
phonet userns: Print out socket uids in a user namespace aware fashion. 2012-08-14 21:48:06 -07:00
rds
rfkill
rose
rxrpc
sched
sctp userns: Print out socket uids in a user namespace aware fashion. 2012-08-14 21:48:06 -07:00
sunrpc Merge branch 'akpm' (Andrew's patch-bomb) 2012-07-31 19:25:39 -07:00
tipc
unix Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2012-08-01 10:26:23 -07:00
wanrouter
wimax
wireless
x25
xfrm
compat.c
Kconfig
Makefile
nonet.c
socket.c
sysctl_net.c