scapy.layers.tls.record_tls13
Common TLS 1.3 fields & bindings.
This module covers the record layer, along with the ChangeCipherSpec, Alert and ApplicationData submessages. For the Handshake type, see tls_handshake.py.
See the TLS class documentation for more information.
- class scapy.layers.tls.record_tls13.TLS13(_pkt, /, *, type=23, version=771, len=None, inner=<TLSInnerPlaintext |>, auth_tag=None)[source]
Bases:
_GenericTLSSessionInheritance- aliastypes = [<class 'scapy.layers.tls.record_tls13.TLS13'>, <class 'scapy.layers.tls.session._GenericTLSSessionInheritance'>, <class 'scapy.packet.Packet'>]
- deciphered_len
- do_dissect_payload(s)[source]
Try to dissect the following data as a TLS message. Note that overloading .guess_payload_class() would not be enough, as the TLS session to be used would get lost.
- fields_desc: ClassVar[List[Field[Any, Any] | _FieldContainer]] = [<ByteEnumField (TLS13).type>, <_TLSVersionField (TLS13).version>, <_TLSLengthField (TLS13).len>, <_TLSInnerPlaintextField (TLS13).inner>, <_TLSMACField (TLS13).auth_tag>]
- class scapy.layers.tls.record_tls13.TLSInnerPlaintext(_pkt, /, *, msg=[], type=None, pad=b'')[source]
Bases:
_GenericTLSSessionInheritance- aliastypes = [<class 'scapy.layers.tls.record_tls13.TLSInnerPlaintext'>, <class 'scapy.layers.tls.session._GenericTLSSessionInheritance'>, <class 'scapy.packet.Packet'>]