Created initial SMTP handlers.
This commit is contained in:
1 parent
1751d431c9
commit
caa8dd7d90
11 files changed
+608
-12
No files matched your search
@@ -0,0 +1,25 @@
|
||||
//---------------------------------------------------------------------------
|
||||
// MAIL command request handling.
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
else if(command(input) == "MAIL") {
|
||||
|
||||
sender = cleanEMail(input.substr(5));
|
||||
|
||||
//-------------------------------------------------------------
|
||||
// Verify that the senders domain name resolves to an address
|
||||
// with an MX record. If not and there is a bounce then we
|
||||
// will not be able to return the bounce message so it is
|
||||
// probably a spammer anyway.
|
||||
//-------------------------------------------------------------
|
||||
|
||||
if(verifyDomainMX(domainOnly(sender))) {
|
||||
|
||||
cout << "250 OK" << CRLF;
|
||||
log.message("Response: 250 OK.");
|
||||
recipientList = "";
|
||||
state = "MAIL";
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user