scapy.contrib.ltp module

Copyright 2012, The MITRE Corporation:

                          NOTICE
This software/technical data was produced for the U.S. Government
under Prime Contract No. NASA-03001 and JPL Contract No. 1295026
  and is subject to FAR 52.227-14 (6/87) Rights in Data General,
    and Article GP-51, Rights in Data  General, respectively.
   This software is publicly released under MITRE case #12-3054
class scapy.contrib.ltp.LTP

Bases: scapy.packet.Packet

aliastypes = [<class 'scapy.contrib.ltp.LTP'>, <class 'scapy.packet.Packet'>]
fields_desc = [<Field (LTP).version>, <Field (LTP).flags>, <Field (LTP).SessionOriginator>, <Field (LTP).SessionNumber>, <Field (LTP).HeaderExtensionCount>, <Field (LTP).TrailerExtensionCount>, <Field (LTP).HeaderExtensions>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <scapy.fields.ConditionalField object>, <Field (LTP).TrailerExtensions>]
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.

class scapy.contrib.ltp.LTPReceptionClaim

Bases: scapy.packet.Packet

aliastypes = [<class 'scapy.contrib.ltp.LTPReceptionClaim'>, <class 'scapy.packet.Packet'>]
default_payload_class(pay)

DEV: Returns the default payload class if nothing has been found by the guess_payload_class() method.

Parameters:payload (str) – the layer’s payload
Returns:the default payload class define inside the configuration file
fields_desc = [<Field (LTPReceptionClaim).ReceptionClaimOffset>, <Field (LTPReceptionClaim).ReceptionClaimLength>]
class scapy.contrib.ltp.LTPex

Bases: scapy.packet.Packet

aliastypes = [<class 'scapy.contrib.ltp.LTPex'>, <class 'scapy.packet.Packet'>]
default_payload_class(pay)

DEV: Returns the default payload class if nothing has been found by the guess_payload_class() method.

Parameters:payload (str) – the layer’s payload
Returns:the default payload class define inside the configuration file
fields_desc = [<Field (LTPex).ExTag>, <Field (LTPex).ExLength>, <Field (LTPex).ExData>]
scapy.contrib.ltp.ltp_bind_payload(cls, lambd)

Bind payload class to the LTP packets.

Parameters:
  • cls – the class to bind
  • lambd – lambda that will be called to check whether or not the cls should be used ex: lambda pkt: …