SMTP Constant Enumerations¶
Added in version 1.10.0.
SMTP Command¶
Generated from pcapkit.vendor.smtp.command.Command.
- class pcapkit.const.smtp.command.Command(*values)[source]¶
Bases:
EnumRegistry,aenum.StrEnum[Command] SMTP Command
- EHLO = 'EHLO'¶
Extended HELLO [RFC 5321 Section 4.1.1.1]
- HELO = 'HELO'¶
HELLO [RFC 5321 Section 4.1.1.1]
- MAIL = 'MAIL'¶
MAIL [RFC 5321 Section 4.1.1.2]
- RCPT = 'RCPT'¶
RECIPIENT [RFC 5321 Section 4.1.1.3]
- DATA = 'DATA'¶
DATA [RFC 5321 Section 4.1.1.4]
- RSET = 'RSET'¶
RESET [RFC 5321 Section 4.1.1.5]
- VRFY = 'VRFY'¶
VERIFY [RFC 5321 Section 4.1.1.6]
- EXPN = 'EXPN'¶
EXPAND [RFC 5321 Section 4.1.1.7]
- HELP = 'HELP'¶
HELP [RFC 5321 Section 4.1.1.8]
- NOOP = 'NOOP'¶
NOOP [RFC 5321 Section 4.1.1.9]
- QUIT = 'QUIT'¶
QUIT [RFC 5321 Section 4.1.1.10]
- classmethod get(key, default=NO_DEFAULT)[source]¶
Resolve
keyto a member, folding astrto upper case.Command verbs are not case-sensitive (RFC 5321 Section 2.4), and each member is named, and valued, its verb in upper case.
- Parameters:
- Return type:
- Returns:
The member
keynames or carries.- Raises:
EnumKeyError – If
keynames no member and there is no usabledefault.EnumValueError – If
keyis not astrand there is no usabledefault.
- classmethod _validate_value(value)[source]¶
Reject
valueunless it is astr, as_missing_()does.- Parameters:
value (
Any) – Value about to be looked up or minted.- Raises:
EnumValueError – If
valueis not astr.
- classmethod _missing_(value)[source]¶
Lookup function used when value is not found.
- Parameters:
value (
str) – Value to get enum item, matched case-insensitively against the member names (RFC 5321 Section 2.4). A verb no member names resolves to an unregistered member named after it in upper case and valued as given (#860).- Return type:
SMTP Reply Code¶
Generated from pcapkit.vendor.smtp.reply_code.ReplyCode.
- class pcapkit.const.smtp.reply_code.ReplyCode(*values)[source]¶
Bases:
EnumRegistry,aenum.IntEnum[ReplyCode] SMTP Reply Code
- CODE_211 = 211¶
System status, or system help reply [RFC 5321 Section 4.2.3]
- CODE_214 = 214¶
Help message [RFC 5321 Section 4.2.3]
- CODE_220 = 220¶
<domain> Service ready [RFC 5321 Section 4.2.3]
- CODE_221 = 221¶
<domain> Service closing transmission channel [RFC 5321 Section 4.2.3]
- CODE_250 = 250¶
Requested mail action okay, completed [RFC 5321 Section 4.2.3]
- CODE_251 = 251¶
User not local; will forward to <forward-path> [RFC 5321 Section 4.2.3]
- CODE_252 = 252¶
Cannot VRFY user, but will accept message and attempt delivery [RFC 5321 Section 4.2.3]
- CODE_354 = 354¶
Start mail input; end with <CRLF>.<CRLF> [RFC 5321 Section 4.2.3]
- CODE_421 = 421¶
<domain> Service not available, closing transmission channel [RFC 5321 Section 4.2.3]
- CODE_450 = 450¶
Requested mail action not taken: mailbox unavailable [RFC 5321 Section 4.2.3]
- CODE_451 = 451¶
Requested action aborted: local error in processing [RFC 5321 Section 4.2.3]
- CODE_452 = 452¶
Requested action not taken: insufficient system storage [RFC 5321 Section 4.2.3]
- CODE_455 = 455¶
Server unable to accommodate parameters [RFC 5321 Section 4.2.3]
- CODE_500 = 500¶
Syntax error, command unrecognized [RFC 5321 Section 4.2.3]
- CODE_501 = 501¶
Syntax error in parameters or arguments [RFC 5321 Section 4.2.3]
- CODE_502 = 502¶
Command not implemented [RFC 5321 Section 4.2.3]
- CODE_503 = 503¶
Bad sequence of commands [RFC 5321 Section 4.2.3]
- CODE_504 = 504¶
Command parameter not implemented [RFC 5321 Section 4.2.3]
- CODE_530 = 530¶
Authentication required [RFC 4954 Section 6][RFC 6409 Section 4.3]
- CODE_550 = 550¶
Requested action not taken: mailbox unavailable [RFC 5321 Section 4.2.3]
- CODE_551 = 551¶
User not local; please try <forward-path> [RFC 5321 Section 4.2.3]
- CODE_552 = 552¶
Requested mail action aborted: exceeded storage allocation [RFC 5321 Section 4.2.3]
- CODE_553 = 553¶
Requested action not taken: mailbox name not allowed [RFC 5321 Section 4.2.3]
- CODE_554 = 554¶
Transaction failed [RFC 5321 Section 4.2.3]
- CODE_555 = 555¶
MAIL FROM/RCPT TO parameters not recognized or not implemented [RFC 5321 Section 4.2.3]
- classmethod _validate_value(value)[source]¶
Reject
valueunless it passes the range check_missing_()makes.Overrides
_validate_value()with that check and the message it raises, soregister()refuses exactly the valuesget()refuses, in the same words (#1816).- Parameters:
value (
Any) – Value about to be looked up or minted.- Raises:
EnumValueError – If
valuefails that check. AValueError, so anexcept ValueErrorcaller is unaffected.
Footnotes