scapy.contrib.rpl

RPL

RFC 6550 - Routing Protocol for Low-Power and Lossy Networks (RPL) draft-ietf-roll-efficient-npdao-17 - Efficient Route Invalidation

RPL Options : Pad1 PadN TIO RIO PIO Tgt TgtDesc DODAGConfig DAGMC ...

RPL Msgs : DIS DIO DAO DAOACK DCO DCOACK

ICMPv6 : type 155 RPL

class scapy.contrib.rpl.RPLDAO(_pkt, /, *, RPLInstanceID=50, K=0, D=0, flags=0, reserved=0, daoseq=1, dodagid=None)[源代码]

基类:_RPLGuessMsgType, _RPLGuessOption

Control Message: Destination Advertisement Object (DAO)

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| RPLINSTANCEID |K|D|   FLAGS   |    RESERVED   |     DAOSEQ    |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                            DODAGID                            |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                           Fig. RPLDAO                            
RPLDAO fields

RPLInstanceID

ByteField

50

K

BitField (1 bit)

0

D

BitField (1 bit)

0

flags

BitField (6 bits)

0

reserved

ByteField

0

daoseq

ByteField

1

dodagid

IP6Field (Cond)

None

class scapy.contrib.rpl.RPLDAOACK(_pkt, /, *, RPLInstanceID=50, D=0, reserved=0, daoseq=1, status=0, dodagid=None)[源代码]

基类:_RPLGuessMsgType, _RPLGuessOption

Control Message: Destination Advertisement Object Acknowledgement (DAOACK)

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| RPLINSTANCEID |D|   RESERVED  |     DAOSEQ    |     STATUS    |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                            DODAGID                            |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                          Fig. RPLDAOACK                          
RPLDAOACK fields

RPLInstanceID

ByteField

50

D

BitField (1 bit)

0

reserved

BitField (7 bits)

0

daoseq

ByteField

1

status

ByteField

0

dodagid

IP6Field (Cond)

None

class scapy.contrib.rpl.RPLDCO(_pkt, /, *, RPLInstanceID=50, K=0, D=0, flags=0, status=0, dcoseq=1, dodagid=None)[源代码]

基类:_RPLGuessMsgType, _RPLGuessOption

Control Message: Destination Cleanup Object (DCO)

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| RPLINSTANCEID |K|D|   FLAGS   |     STATUS    |     DCOSEQ    |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                            DODAGID                            |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                           Fig. RPLDCO                            
RPLDCO fields

RPLInstanceID

ByteField

50

K

BitField (1 bit)

0

D

BitField (1 bit)

0

flags

BitField (6 bits)

0

status

ByteField

0

dcoseq

ByteField

1

dodagid

IP6Field (Cond)

None

class scapy.contrib.rpl.RPLDCOACK(_pkt, /, *, RPLInstanceID=50, D=0, flags=0, dcoseq=1, status=0, dodagid=None)[源代码]

基类:_RPLGuessMsgType, _RPLGuessOption

Control Message: Destination Cleanup Object Acknowledgement (DCOACK)

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| RPLINSTANCEID |D|    FLAGS    |     DCOSEQ    |     STATUS    |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                            DODAGID                            |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                          Fig. RPLDCOACK                          
RPLDCOACK fields

RPLInstanceID

ByteField

50

D

BitField (1 bit)

0

flags

BitField (7 bits)

0

dcoseq

ByteField

1

status

ByteField

0

dodagid

IP6Field (Cond)

None

class scapy.contrib.rpl.RPLDIO(_pkt, /, *, RPLInstanceID=50, ver=0, rank=1, G=1, unused1=0, mop=1, prf=0, dtsn=240, flags=0, reserved=0, dodagid='::1')[源代码]

基类:_RPLGuessMsgType, _RPLGuessOption

Control Message: DODAG Information Object (DIO)

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| RPLINSTANCEID |      VER      |              RANK             |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|G|U| MOP | PRF |      DTSN     |     FLAGS     |    RESERVED   |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                            DODAGID                            |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                           Fig. RPLDIO                            
RPLDIO fields

RPLInstanceID

ByteField

50

ver

ByteField

0

rank

ShortField

1

G

BitField (1 bit)

1

unused1

BitField (1 bit)

0

mop

BitEnumField

1

prf

BitField (3 bits)

0

dtsn

ByteField

240

flags

ByteField

0

reserved

ByteField

0

dodagid

IP6Field

'::1'

class scapy.contrib.rpl.RPLDIS(_pkt, /, *, flags=0, reserved=0)[源代码]

基类:_RPLGuessMsgType, _RPLGuessOption

Control Message: DODAG Information Solicitation (DIS)

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     FLAGS     |    RESERVED   |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                           Fig. RPLDIS                            
RPLDIS fields

flags

ByteField

0

reserved

ByteField

0

class scapy.contrib.rpl.RPLOptDODAGConfig(_pkt, /, *, otype=4, len=14, flags=0, A=0, PCS=0, DIOIntDoubl=20, DIOIntMin=3, DIORedun=10, MaxRankIncrease=0, MinRankIncrease=256, OCP=1, reserved=0, DefLifetime=255, LifetimeUnit=65535)[源代码]

基类:_RPLGuessOption

Control Option: DODAG Configuration

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     OTYPE     |      LEN      | FLAGS |A| PCS |  DIOINTDOUBL  |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|   DIOINTMIN   |    DIOREDUN   |        MAXRANKINCREASE        |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|        MINRANKINCREASE        |              OCP              |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|    RESERVED   |  DEFLIFETIME  |          LIFETIMEUNIT         |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                      Fig. RPLOptDODAGConfig                      
RPLOptDODAGConfig fields

otype

ByteEnumField

4

len

ByteField

14

flags

BitField (4 bits)

0

A

BitField (1 bit)

0

PCS

BitField (3 bits)

0

DIOIntDoubl

ByteField

20

DIOIntMin

ByteField

3

DIORedun

ByteField

10

MaxRankIncrease

ShortField

0

MinRankIncrease

ShortField

256

OCP

ShortField

1

reserved

ByteField

0

DefLifetime

ByteField

255

LifetimeUnit

ShortField

65535

class scapy.contrib.rpl.RPLOptPIO(_pkt, /, *, otype=8, len=30, plen=64, L=0, A=0, R=0, reserved1=0, validlifetime=4294967295, preflifetime=4294967295, reserved2=0, prefix='::1')[源代码]

基类:_RPLGuessOption

Control Option: Prefix Information Option (PIO)

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     OTYPE     |      LEN      |      PLEN     |L|A|R|RESERVED1|
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                         VALIDLIFETIME                         |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                          PREFLIFETIME                         |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                           RESERVED2                           |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                             PREFIX                            |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                          Fig. RPLOptPIO                          
RPLOptPIO fields

otype

ByteEnumField

8

len

ByteField

30

plen

ByteField

64

L

BitField (1 bit)

0

A

BitField (1 bit)

0

R

BitField (1 bit)

0

reserved1

BitField (5 bits)

0

validlifetime

IntField

4294967295

preflifetime

IntField

4294967295

reserved2

IntField

0

prefix

IP6Field

'::1'

class scapy.contrib.rpl.RPLOptPad1(_pkt, /, *, otype=0)[源代码]

基类:_RPLGuessOption

Control Option: Pad 1 byte

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     OTYPE     |
+-+-+-+-+-+-+-+-+

                         Fig. RPLOptPad1                          
RPLOptPad1 fields

otype

ByteEnumField

0

class scapy.contrib.rpl.RPLOptPadN(_pkt, /, *, otype=1, optlen=None, optdata=b'')[源代码]

基类:_RPLGuessOption

Control Option: Pad N bytes

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     OTYPE     |     OPTLEN    |            OPTDATA            |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                         Fig. RPLOptPadN                          
RPLOptPadN fields

otype

ByteEnumField

1

optlen

FieldLenField

None

optdata

StrLenField

b''

class scapy.contrib.rpl.RPLOptRIO(_pkt, /, *, otype=3, len=None, plen=None, res1=0, prf=0, res2=0, rtlifetime=4294967295, prefix=None)[源代码]

基类:_RPLGuessOption

Control Option: Routing Information Option (RIO)

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     OTYPE     |      LEN      |      PLEN     | RES1|PRF| RES2|
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                           RTLIFETIME                          |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                             PREFIX                            |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                          Fig. RPLOptRIO                          
RPLOptRIO fields

otype

ByteEnumField

3

len

FieldLenField

None

plen

ByteField

None

res1

BitField (3 bits)

0

prf

BitEnumField

0

res2

BitField (3 bits)

0

rtlifetime

IntField

4294967295

prefix

_IP6PrefixField

None

class scapy.contrib.rpl.RPLOptSolInfo(_pkt, /, *, otype=7, len=19, RPLInstanceID=0, V=0, I=0, D=0, flags=0, dodagid='::1', ver=0)[源代码]

基类:_RPLGuessOption

Control Option: Solicited Information

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     OTYPE     |      LEN      | RPLINSTANCEID |V|I|D|  FLAGS  |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                            DODAGID                            |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|      VER      |
+-+-+-+-+-+-+-+-+

                        Fig. RPLOptSolInfo                        
RPLOptSolInfo fields

otype

ByteEnumField

7

len

ByteField

19

RPLInstanceID

ByteField

0

V

BitField (1 bit)

0

I

BitField (1 bit)

0

D

BitField (1 bit)

0

flags

BitField (5 bits)

0

dodagid

IP6Field

'::1'

ver

ByteField

0

class scapy.contrib.rpl.RPLOptTIO(_pkt, /, *, otype=6, len=None, E=0, flags=0, pathcontrol=0, pathseq=0, pathlifetime=255, parentaddr=None)[源代码]

基类:_RPLGuessOption

Control Option: Transit Information Option (TIO)

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     OTYPE     |      LEN      |E|    FLAGS    |  PATHCONTROL  |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|    PATHSEQ    |  PATHLIFETIME |           PARENTADDR          |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+                               +
|                                                               |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+                               +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                          Fig. RPLOptTIO                          
RPLOptTIO fields

otype

ByteEnumField

6

len

FieldLenField

None

E

BitField (1 bit)

0

flags

BitField (7 bits)

0

pathcontrol

ByteField

0

pathseq

ByteField

0

pathlifetime

ByteField

255

parentaddr

_IP6PrefixField

None

class scapy.contrib.rpl.RPLOptTgt(_pkt, /, *, otype=5, len=None, flags=0, plen=0, prefix=None)[源代码]

基类:_RPLGuessOption

Control Option: RPL Target

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     OTYPE     |      LEN      |     FLAGS     |      PLEN     |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                             PREFIX                            |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+                                                               +
|                                                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                          Fig. RPLOptTgt                          
RPLOptTgt fields

otype

ByteEnumField

5

len

FieldLenField

None

flags

ByteField

0

plen

ByteField

0

prefix

_IP6PrefixField

None

class scapy.contrib.rpl.RPLOptTgtDesc(_pkt, /, *, otype=9, len=4, descriptor=0)[源代码]

基类:_RPLGuessOption

Control Option: RPL Target Descriptor

aliastypes
fields_desc
Display RFC-like schema
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     OTYPE     |      LEN      |           DESCRIPTOR          |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

                        Fig. RPLOptTgtDesc                        
RPLOptTgtDesc fields

otype

ByteEnumField

9

len

ByteField

4

descriptor

IntField

0