MCPcopy Create free account
hub / github.com/secdev/scapy / ZigbeeAppDataPayloadStub

Class ZigbeeAppDataPayloadStub

scapy/layers/zigbee.py:929–949  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

927
928
929class ZigbeeAppDataPayloadStub(Packet):
930 name = "Zigbee Application Layer Data Payload for Inter-PAN Transmission"
931 fields_desc = [
932 FlagsField("frame_control", 0, 4, ['reserved1', 'security', 'ack_req', 'extended_hdr']), # noqa: E501
933 BitEnumField("delivery_mode", 0, 2, {0: 'unicast', 2: 'broadcast', 3: 'group'}), # noqa: E501
934 BitField("frametype", 3, 2), # value 0b11 (3) is a reserved frame type
935 # Group Address present only when delivery mode field has a value of 0b11 (group delivery mode) # noqa: E501
936 ConditionalField(
937 XLEShortField("group_addr", 0x0), # 16-bit identifier of the group
938 lambda pkt: pkt.getfieldval("delivery_mode") == 0b11
939 ),
940 # Cluster identifier
941 XLEShortField("cluster", 0x0000),
942 # Profile identifier
943 EnumField("profile", 0, _aps_profile_identifiers, fmt="<H"),
944 # ZigBee Payload
945 ConditionalField(
946 StrField("data", ""),
947 lambda pkt: pkt.frametype == 3
948 ),
949 ]
950
951
952# Zigbee Device Profile #

Callers

nothing calls this directly

Calls 8

FlagsFieldClass · 0.90
BitEnumFieldClass · 0.90
BitFieldClass · 0.90
ConditionalFieldClass · 0.90
XLEShortFieldClass · 0.90
EnumFieldClass · 0.90
StrFieldClass · 0.90
getfieldvalMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…