E-MailRelay

Classes | Public Types | Static Public Member Functions | List of all members
GSmtp::ServerParser Class Reference

A static class for SMTP command parsing, used by GSmtp::ServerProtocol as a mix-in base. More...

`#include <gsmtpserverparser.h>`

Inheritance diagram for GSmtp::ServerParser:
[legend]

## Classes
struct | AddressCommand
| mail-from or rcpt-to More...
struct | Config
| A configuration structure for GSmtp::ServerParser. More...

## Public Types
using | AddressStyle = GStore::MessageStore::AddressStyle

## Static Public Member Functions
static AddressCommand | parseMailFrom (std::string_view, const Config &)
| Parses a MAIL-FROM command. More...
static AddressCommand | parseRcptTo (std::string_view, const Config &)
| Parses a RCPT-TO command. More...
static std::pair< std::size_t, bool > | parseBdatSize (std::string_view)
| Parses a BDAT command. More...
static std::pair< bool, bool > | parseBdatLast (std::string_view)
| Parses a BDAT LAST command. More...
static std::string | parseHeloPeerName (const std::string &)
| Parses the peer name from an HELO/EHLO command. More...
static std::string | parseVrfy (const std::string &)
| Parses a VRFY command. More...

## Detailed Description

A static class for SMTP command parsing, used by GSmtp::ServerProtocol as a mix-in base.

See also RFC-5321 4.1.2.

Definition at line 40 of file gsmtpserverparser.h.

## Member Typedef Documentation

## ◆ AddressStyle

using GSmtp::ServerParser::AddressStyle = GStore::MessageStore::AddressStyle

Definition at line 56 of file gsmtpserverparser.h.

## Member Function Documentation

## ◆ parseBdatLast()

std::pair< bool, bool > GSmtp::ServerParser::parseBdatLast | ( | std::string_view | bdat_line | ) |
| static

Parses a BDAT LAST command.

Definition at line 48 of file gsmtpserverparser.cpp.

## ◆ parseBdatSize()

std::pair< std::size_t, bool > GSmtp::ServerParser::parseBdatSize | ( | std::string_view | bdat_line | ) |
| static

Parses a BDAT command.

Definition at line 32 of file gsmtpserverparser.cpp.

## ◆ parseHeloPeerName()

std::string GSmtp::ServerParser::parseHeloPeerName | ( | const std::string & | line | ) |
| static

Parses the peer name from an HELO/EHLO command.

Definition at line 292 of file gsmtpserverparser.cpp.

## ◆ parseMailFrom()

GSmtp::ServerParser::AddressCommand GSmtp::ServerParser::parseMailFrom | ( | std::string_view | line,
|  | const Config & | config
| ) |  |
| static

Parses a MAIL-FROM command.

Definition at line 62 of file gsmtpserverparser.cpp.

## ◆ parseRcptTo()

GSmtp::ServerParser::AddressCommand GSmtp::ServerParser::parseRcptTo | ( | std::string_view | line,
|  | const Config & | config
| ) |  |
| static

Parses a RCPT-TO command.

Definition at line 87 of file gsmtpserverparser.cpp.

## ◆ parseVrfy()

std::string GSmtp::ServerParser::parseVrfy | ( | const std::string & | line_in | ) |
| static

Parses a VRFY command.

Definition at line 270 of file gsmtpserverparser.cpp.

The documentation for this class was generated from the following files:

- /tmp/slackdce/slackrepo.HKsbdz/build_emailrelay/emailrelay-2.6/src/gsmtp/gsmtpserverparser.h
- /tmp/slackdce/slackrepo.HKsbdz/build_emailrelay/emailrelay-2.6/src/gsmtp/gsmtpserverparser.cpp