lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:	Fri, 30 Jul 2010 10:05:09 -0400
From:	Jon Smirl <jonsmirl@...il.com>
To:	linux-zigbee-devel <linux-zigbee-devel@...ts.sourceforge.net>,
	Netdev <netdev@...r.kernel.org>
Subject: pcap and ARP hardware type for IEEE 802.15.4

I'm working on pcap support for the native IEEE 802.15.4
implementation in the kernel.
http://sourceforge.net/apps/trac/linux-zigbee/

pcap uses ARPHRD_ to write the DLT value into the pcap file. We need a
new DLT for the internal Linux packets since they have had the two FCS
bytes stripped from the end.

The 802.15.4 implementation has used two different ARPHRD types, one
for the active interface and one for the monitor interface. Has that
been done correctly? Should there be two types?

void ieee802154_monitor_setup(struct net_device *dev)
{
       struct ieee802154_sub_if_data *priv;

       dev->addr_len           = 0;
       dev->features           = NETIF_F_NO_CSUM;
       dev->hard_header_len    = 0;
       dev->needed_tailroom    = 2; /* FCS */
       dev->mtu                = 127;
       dev->tx_queue_len       = 10;
       dev->type               = ARPHRD_IEEE802154_MONITOR;
       dev->flags              = IFF_NOARP | IFF_BROADCAST;
       dev->watchdog_timeo     = 0;

       dev->destructor         = free_netdev;
       dev->netdev_ops         = &ieee802154_monitor_ops;
       dev->ml_priv            = &mac802154_mlme;


void ieee802154_wpan_setup(struct net_device *dev)
{
       struct ieee802154_sub_if_data *priv;

       dev->addr_len           = IEEE802154_ADDR_LEN;
       memset(dev->broadcast, 0xff, IEEE802154_ADDR_LEN);
       dev->features           = NETIF_F_NO_CSUM;
       dev->hard_header_len    = 2 + 1 + 20 + 14;
       dev->header_ops         = &ieee802154_header_ops;
       dev->needed_tailroom    = 2; /* FCS */
       dev->mtu                = 1280;
       dev->tx_queue_len       = 10;
       dev->type               = ARPHRD_IEEE802154;
       dev->flags              = IFF_NOARP | IFF_BROADCAST;
       dev->watchdog_timeo     = 0;

       dev->destructor         = free_netdev;
       dev->netdev_ops         = &ieee802154_wpan_ops;
       dev->ml_priv            = &mac802154_mlme;




-- 
Jon Smirl
jonsmirl@...il.com
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ