netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next 0/3] virtual netlink device for packet sockets
@ 2013-06-21 17:38 Daniel Borkmann
  2013-06-21 17:38 ` [PATCH net-next 1/3] net: if_arp: add ARPHRD_NETLINK type Daniel Borkmann
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Daniel Borkmann @ 2013-06-21 17:38 UTC (permalink / raw)
  To: davem; +Cc: netdev

This set allows for a virtual netlink device that can be easily used
without modification by tools like tcpdump, Wireshark et al. to debug
and troubleshoot netlink traffic that is exchanged between user and
kernel space. We could even record pcap files for a later analysis.
No code change would be needed on the side of such analyzers, except
adding a simple protocol dissector, for example.

Please have a look at the main description in patch 3. Patch 1 and 2
are just prerequisits for the actual 3rd patch.

I think the device idea is the cleanest solution. We have packet sockets
and they do exactly what we want and expect from them, they have all the
features etc, and user space would not even need to implement code. Thus
adding more and more functionality into af_netlink would be a bigger
surgery and further bloat it up with duplicate code, imho. By taking the
approach with what I'm proposing, we have a clean segregation of
functionality (as: packet sockets vs. netlink sockets), thus keeping it
simple and stupid, and not too complex. 

Thanks !

Daniel Borkmann (3):
  net: if_arp: add ARPHRD_NETLINK type
  net: netlink: add registration/unregistration of virtual tap devices
  packet: nlmon: virtual netlink monitoring device for packet sockets

 drivers/net/Kconfig         |  10 +++
 drivers/net/Makefile        |   1 +
 drivers/net/nlmon.c         | 170 ++++++++++++++++++++++++++++++++++++++++++++
 include/linux/netlink.h     |  10 +++
 include/uapi/linux/if_arp.h |   1 +
 net/netlink/af_netlink.c    | 107 ++++++++++++++++++++++++++++
 6 files changed, 299 insertions(+)
 create mode 100644 drivers/net/nlmon.c

-- 
1.7.11.7

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-06-24 23:39 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-21 17:38 [PATCH net-next 0/3] virtual netlink device for packet sockets Daniel Borkmann
2013-06-21 17:38 ` [PATCH net-next 1/3] net: if_arp: add ARPHRD_NETLINK type Daniel Borkmann
2013-06-21 17:38 ` [PATCH net-next 2/3] net: netlink: virtual tap device management Daniel Borkmann
2013-06-21 17:38 ` [PATCH net-next 3/3] packet: nlmon: virtual netlink monitoring device for packet sockets Daniel Borkmann
2013-06-24 23:39 ` [PATCH net-next 0/3] virtual netlink " David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).