icmp.py 400 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14
from pyroute2.protocols import msg


class icmpmsg(msg):
    fields = [('type', 'uint8'),
              ('code', 'uint8'),
              ('csum', 'be32')]


class icmp_router_adv(icmpmsg):
    fields = icmpmsg.fields + [('addrs_num', 'uint8'),
                               ('alen', 'uint8'),
                               ('lifetime', 'be32'),
                               ('addrs', 'routers')]