3837a84eec
The patch teaches packet library to truncate padding octets. Change packet_base.parser() to return (header, next_type, rest_of_packet) The protocol class that knows its payload length should rest_of_packet where padding octets at the last of packet is truncated. As bonus, - fix ipv6 parser as ipv6 header doesn't have options. It seems copy-and-paste from ipv4 - improve ipv4, tcp a bit Cc: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Cc: Shaun Crampton <Shaun.Crampton@metaswitch.com> Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> |
||
---|---|---|
.. | ||
__init__.py | ||
arp.py | ||
dhcp.py | ||
ethernet.py | ||
icmp.py | ||
icmpv6.py | ||
ipv4.py | ||
ipv6.py | ||
lldp.py | ||
mpls.py | ||
packet_base.py | ||
packet_utils.py | ||
packet.py | ||
tcp.py | ||
udp.py | ||
vlan.py | ||
vrrp.py |