scapy.contrib.spbm module

Example SPB Frame Creation

Note the outer Dot1Q Ethertype marking (0x88e7)

backboneEther = Ether(dst=‘00:bb:00:00:90:00’, src=‘00:bb:00:00:40:00’, type=0x8100) # noqa: E501 backboneDot1Q = Dot1Q(vlan=4051,type=0x88e7) backboneServiceID = SPBM(prio=1,isid=20011) customerEther = Ether(dst=‘00:1b:4f:5e:ca:00’,src=‘00:00:00:00:00:01’,type=0x8100) # noqa: E501 customerDot1Q = Dot1Q(prio=1,vlan=11,type=0x0800) customerIP = IP(src=‘10.100.11.10’,dst=‘10.100.12.10’,id=0x0629,len=106) # noqa: E501 customerUDP = UDP(sport=1024,dport=1025,chksum=0,len=86)

spb_example = backboneEther/backboneDot1Q/backboneServiceID/customerEther/customerDot1Q/customerIP/customerUDP/”Payload” # noqa: E501

class scapy.contrib.spbm.SPBM

Bases: scapy.packet.Packet

aliastypes = [<class 'scapy.contrib.spbm.SPBM'>, <class 'scapy.packet.Packet'>]
fields_desc = [<Field (SPBM).prio>, <Field (SPBM).dei>, <Field (SPBM).nca>, <Field (SPBM).res1>, <Field (SPBM).res2>, <Field (SPBM).isid>]
mysummary()

DEV: can be overloaded to return a string that summarizes the layer. Only one mysummary() is used in a whole packet summary: the one of the upper layer, # noqa: E501 except if a mysummary() also returns (as a couple) a list of layers whose # noqa: E501 mysummary() must be called if they are present.

payload_guess = [({}, <class 'scapy.layers.l2.Ether'>)]