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>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 30 Jan 2008 15:49:26 -0500
From:	"chas williams - CONTRACTOR" <chas@....nrl.navy.mil>
To:	"Chung-Chi Lo" <linolo@...il.com>
cc:	netdev@...r.kernel.org, davem@...emloft.net
Subject: Re: [PATCH net-2.6.25 4/7][ATM]: [br2864] routed support

In message <3f696b20801282342q43537963ueb8fb9cf3389ac03@...l.gmail.com>,"Chung-
Chi Lo" writes:
>> +       } else { /* vc-mux */
>> +               if (brdev->payload == p_routed) {
>
>add line
>
>			skb->protocol = __constant_htons(ETH_P_IP);
>
>here just like LLC did?
>
>> +                       skb_reset_network_header(skb);
>> +                       skb->pkt_type = PACKET_HOST;

yes, that is missing but it needs to be a little more complicated than
that i think.  you need to examine the first byte to see if its an
ipv4 or ipv6 datagram.  something like:

			struct iphdr *iph = skb_network_header(skb);

                        skb_reset_network_header(skb);
			iph = skb_network_header(skb);
			if (iph->version == 4)
				skb->protocol = __constant_htons(ETH_P_IP);
			else if (iph->version == 6)
				skb->protocol = __constant_htons(ETH_P_IPV6);
			else
				/* drop the packet */
                        skb->pkt_type = PACKET_HOST;

how does that look?

>+       } else {
>+               skb_push(skb, 2);
>+               if (brdev->payload == p_bridged)
>+                       memset(skb->data, 0, 2);
>+       }
>
>Here should be
>
>	} else {
>		if (brdev->payload == p_bridged) {
>			skb_push(skb, 2);
>			memset(skb->data, 0, 2);
>		}
>	}
>
>Because VCMUX and routed mode doesn't need two bytes in header.

yeah, another oversight.  your fix is correct. i bet you have guessed
that we dont use vc multiplexing.
--
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