scapy.layers.tftp
TFTP (Trivial File Transfer Protocol).
- class scapy.layers.tftp.TFTP(*args: Any, **kargs: Any)[source]
Bases:
scapy.packet.Packet
- aliastypes
- class scapy.layers.tftp.TFTP_ACK(*args: Any, **kargs: Any)[source]
Bases:
scapy.packet.Packet
- aliastypes
- class scapy.layers.tftp.TFTP_DATA(*args: Any, **kargs: Any)[source]
Bases:
scapy.packet.Packet
- aliastypes
- class scapy.layers.tftp.TFTP_ERROR(*args: Any, **kargs: Any)[source]
Bases:
scapy.packet.Packet
- 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 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | ERRORCODE | ERRORMSG | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Fig. TFTP_ERROR
TFTP_ERROR fields errorcode
0
errormsg
b''
- class scapy.layers.tftp.TFTP_OACK(*args: Any, **kargs: Any)[source]
Bases:
scapy.packet.Packet
- aliastypes
- fields_desc
- payload_guess
Possible sublayers:
TFTP_Options
- class scapy.layers.tftp.TFTP_Option(*args: Any, **kargs: Any)[source]
Bases:
scapy.packet.Packet
- 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 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | ONAME | VALUE | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Fig. TFTP_Option
TFTP_Option fields oname
b''
value
b''
- class scapy.layers.tftp.TFTP_Options(*args: Any, **kargs: Any)[source]
Bases:
scapy.packet.Packet
- aliastypes
- class scapy.layers.tftp.TFTP_RRQ(*args: Any, **kargs: Any)[source]
Bases:
scapy.packet.Packet
- 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 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | FILENAME | MODE | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Fig. TFTP_RRQ
TFTP_RRQ fields filename
b''
mode
b'octet'
- payload_guess
Possible sublayers:
TFTP_Options
- class scapy.layers.tftp.TFTP_RRQ_server(*args, **kargs)[source]
Bases:
scapy.automaton.Automaton
- actions = {'data_remaining': [], 'file_in_store': [], 'file_not_found': [<function TFTP_RRQ_server.send_error>], 'no_more_data': [], 'receive_rrq': [], 'received_ack': [], 'timeout_waiting_ack': []}
- conditions = {'END': [], 'RECEIVED_ACK': [<function TFTP_RRQ_server.no_more_data>, <function TFTP_RRQ_server.data_remaining>], 'RECEIVED_RRQ': [<function TFTP_RRQ_server.file_in_store>, <function TFTP_RRQ_server.file_not_found>], 'SEND_FILE': [], 'WAIT_RRQ': []}
- initial_states = [<function ATMT.state.<locals>.deco.<locals>.state_wrapper>]
- ioevents = {'END': [], 'RECEIVED_ACK': [], 'RECEIVED_RRQ': [], 'SEND_FILE': [], 'WAIT_RRQ': []}
- ionames = []
- iosupersockets = []
- parse_args(store=None, joker=None, dir=None, ip=None, sport=None, serve_one=False, **kargs)[source]
- recv_conditions = {'END': [], 'RECEIVED_ACK': [], 'RECEIVED_RRQ': [], 'SEND_FILE': [<function TFTP_RRQ_server.received_ack>], 'WAIT_RRQ': [<function TFTP_RRQ_server.receive_rrq>]}
- state = None
- states = {'END': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'RECEIVED_ACK': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'RECEIVED_RRQ': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'SEND_FILE': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'WAIT_RRQ': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>}
- stop_states = []
- timeout = {'END': [(None, None)], 'RECEIVED_ACK': [(None, None)], 'RECEIVED_RRQ': [(None, None)], 'SEND_FILE': [(3, <function TFTP_RRQ_server.timeout_waiting_ack>), (None, None)], 'WAIT_RRQ': [(None, None)]}
- class scapy.layers.tftp.TFTP_WRQ(*args: Any, **kargs: Any)[source]
Bases:
scapy.packet.Packet
- 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 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | FILENAME | MODE | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Fig. TFTP_WRQ
TFTP_WRQ fields filename
b''
mode
b'octet'
- payload_guess
Possible sublayers:
TFTP_Options
- class scapy.layers.tftp.TFTP_WRQ_server(*args, **kargs)[source]
Bases:
scapy.automaton.Automaton
- actions = {'receive_WRQ': [<function TFTP_WRQ_server.ack_WRQ>], 'receive_data': [<function TFTP_WRQ_server.ack_data>], 'resend_ack': []}
- conditions = {'BEGIN': [], 'DATA': [], 'END': [], 'WAIT_DATA': []}
- initial_states = [<function ATMT.state.<locals>.deco.<locals>.state_wrapper>]
- ioevents = {'BEGIN': [], 'DATA': [], 'END': [], 'WAIT_DATA': []}
- ionames = []
- iosupersockets = []
- recv_conditions = {'BEGIN': [<function TFTP_WRQ_server.receive_WRQ>], 'DATA': [], 'END': [], 'WAIT_DATA': [<function TFTP_WRQ_server.receive_data>]}
- state = None
- states = {'BEGIN': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'DATA': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'END': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'WAIT_DATA': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>}
- stop_states = []
- timeout = {'BEGIN': [(None, None)], 'DATA': [(None, None)], 'END': [(None, None)], 'WAIT_DATA': [(1, <function TFTP_WRQ_server.resend_ack>), (None, None)]}
- class scapy.layers.tftp.TFTP_read(*args, **kargs)[source]
Bases:
scapy.automaton.Automaton
- actions = {'receive_data': [<function TFTP_read.send_ack>], 'receive_error': [], 'timeout_waiting': [<function TFTP_read.retransmit_last_packet>]}
- conditions = {'BEGIN': [], 'END': [], 'ERROR': [], 'RECEIVING': [], 'WAITING': []}
- initial_states = [<function ATMT.state.<locals>.deco.<locals>.state_wrapper>]
- ioevents = {'BEGIN': [], 'END': [], 'ERROR': [], 'RECEIVING': [], 'WAITING': []}
- ionames = []
- iosupersockets = []
- recv_conditions = {'BEGIN': [], 'END': [], 'ERROR': [], 'RECEIVING': [], 'WAITING': [<function TFTP_read.receive_data>, <function TFTP_read.receive_error>]}
- state = None
- states = {'BEGIN': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'END': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'ERROR': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'RECEIVING': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'WAITING': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>}
- stop_states = []
- timeout = {'BEGIN': [(None, None)], 'END': [(None, None)], 'ERROR': [(None, None)], 'RECEIVING': [(None, None)], 'WAITING': [(3, <function TFTP_read.timeout_waiting>), (None, None)]}
- class scapy.layers.tftp.TFTP_write(*args, **kargs)[source]
Bases:
scapy.automaton.Automaton
- actions = {'received_ack': [], 'received_error': [], 'timeout_waiting': [<function TFTP_write.retransmit_last_packet>]}
- conditions = {'BEGIN': [], 'END': [], 'ERROR': [], 'SEND_DATA': [], 'WAITING_ACK': []}
- initial_states = [<function ATMT.state.<locals>.deco.<locals>.state_wrapper>]
- ioevents = {'BEGIN': [], 'END': [], 'ERROR': [], 'SEND_DATA': [], 'WAITING_ACK': []}
- ionames = []
- iosupersockets = []
- recv_conditions = {'BEGIN': [], 'END': [], 'ERROR': [], 'SEND_DATA': [], 'WAITING_ACK': [<function TFTP_write.received_ack>, <function TFTP_write.received_error>]}
- state = None
- states = {'BEGIN': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'END': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'ERROR': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'SEND_DATA': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>, 'WAITING_ACK': <function ATMT.state.<locals>.deco.<locals>.state_wrapper>}
- stop_states = []
- timeout = {'BEGIN': [(None, None)], 'END': [(None, None)], 'ERROR': [(None, None)], 'SEND_DATA': [(None, None)], 'WAITING_ACK': [(3, <function TFTP_write.timeout_waiting>), (None, None)]}