Source code for pcapkit.protocols.data.application.ftp
# -*- coding: utf-8 -*-"""data models for FTP protocol"""fromtypingimportTYPE_CHECKINGfrompcapkit.corekit.infoclassimportinfo_finalfrompcapkit.protocols.data.protocolimportProtocolifTYPE_CHECKING:fromtyping_extensionsimportLiteralfrompcapkit.const.ftp.commandimportCommandfrompcapkit.const.ftp.return_codeimportReturnCodefrompcapkit.protocols.application.ftpimportTypeasFTP_Type__all__=['FTP','Request','Response',]
[docs]classFTP(Protocol):"""Data model for FTP protocol."""#: Type.type:'FTP_Type'
[docs]@info_finalclassRequest(FTP):"""Data model for FTP request."""#: Type.type:'Literal[FTP_Type.REQUEST]'#: Command.cmmd:'Command'#: Arguments.args:'str'ifTYPE_CHECKING:def__init__(self,type:'Literal[FTP_Type.REQUEST]',cmmd:'Command',args:'str')->'None':...# pylint: disable=unused-argument,super-init-not-called,multiple-statements,line-too-long,redefined-builtin
[docs]@info_finalclassResponse(FTP):"""Data model for FTP response."""#: Type.type:'Literal[FTP_Type.RESPONSE]'#: Return code.code:'ReturnCode'#: Arguments.args:'str'#: More data flag.more:'bool'ifTYPE_CHECKING:def__init__(self,type:'Literal[FTP_Type.RESPONSE]',code:'ReturnCode',args:'str',more:'bool')->'None':...# pylint: disable=unused-argument,super-init-not-called,multiple-statements,line-too-long,redefined-builtin