MCPcopy Index your code
hub / github.com/secdev/scapy / ifaddrmsg

Class ifaddrmsg

scapy/arch/linux/rtnetlink.py:484–507  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

482
483
484class ifaddrmsg(Packet):
485 fields_desc = [
486 ByteEnumField("ifa_family", 0, socket.AddressFamily),
487 ByteField("ifa_prefixlen", 0),
488 FlagsField(
489 "ifa_flags",
490 0,
491 -8,
492 {
493 0x01: "IFA_F_SECONDARY",
494 0x02: "IFA_F_NODAD",
495 0x04: "IFA_F_OPTIMISTIC",
496 0x08: "IFA_F_DADFAILED",
497 0x10: "IFA_F_HOMEADDRESS",
498 0x20: "IFA_F_DEPRECATED",
499 0x40: "IFA_F_TENTATIVE",
500 0x80: "IFA_F_PERMANENT",
501 },
502 ),
503 ByteField("ifa_scope", 0),
504 Field("ifa_index", 0, fmt="=L"),
505 # Pay
506 PacketListField("data", [], ifaddrmsg_rtattr),
507 ]
508
509
510bind_layers(rtmsghdr, ifaddrmsg, nlmsg_type=20)

Callers 1

_get_ipsFunction · 0.85

Calls 5

ByteEnumFieldClass · 0.90
ByteFieldClass · 0.90
FlagsFieldClass · 0.90
FieldClass · 0.90
PacketListFieldClass · 0.90

Tested by

no test coverage detected