Skip to content

Commit 3d1763c

Browse files
authored
Fix Segment Routing Pad1 TLV definition (#4611)
In RFC 8754, 2.1.1.1, Pad1 is a single byte.
1 parent bdfacb6 commit 3d1763c

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

scapy/layers/inet6.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1047,10 +1047,8 @@ class IPv6ExtHdrSegmentRoutingTLVEgressNode(IPv6ExtHdrSegmentRoutingTLV):
10471047

10481048
class IPv6ExtHdrSegmentRoutingTLVPad1(IPv6ExtHdrSegmentRoutingTLV):
10491049
name = "IPv6 Option Header Segment Routing - Pad1 TLV"
1050-
# RFC8754 sect 2.1.1.1
1051-
fields_desc = [ByteEnumField("type", 0, _segment_routing_header_tlvs),
1052-
FieldLenField("len", None, length_of="padding", fmt="B"),
1053-
StrLenField("padding", b"\x00", length_from=lambda pkt: pkt.len)] # noqa: E501
1050+
# RFC8754 sect 2.1.1.1, Pad1 is a single byte
1051+
fields_desc = [ByteEnumField("type", 0, _segment_routing_header_tlvs)]
10541052

10551053

10561054
class IPv6ExtHdrSegmentRoutingTLVPadN(IPv6ExtHdrSegmentRoutingTLV):

0 commit comments

Comments
 (0)