mirror of
https://bitbucket.org/jsuto/piler.git
synced 2024-11-08 00:21:59 +01:00
Added SMTP HELP command to piler-smtp
Signed-off-by: Janos SUTO <sj@acts.hu>
This commit is contained in:
parent
a1d81a0281
commit
5d70881463
@ -31,6 +31,11 @@ void process_smtp_command(struct smtp_session *session, char *buf, struct config
|
||||
return;
|
||||
}
|
||||
|
||||
if(strncasecmp(buf, SMTP_CMD_HELP, strlen(SMTP_CMD_HELP)) == 0){
|
||||
send_smtp_response(session, SMTP_RESP_221_PILER_SMTP_OK);
|
||||
return;
|
||||
}
|
||||
|
||||
if(strncasecmp(buf, SMTP_CMD_MAIL_FROM, strlen(SMTP_CMD_MAIL_FROM)) == 0){
|
||||
process_command_mail_from(session, buf);
|
||||
return;
|
||||
|
@ -18,6 +18,7 @@
|
||||
|
||||
#define SMTP_CMD_HELO "HELO"
|
||||
#define SMTP_CMD_EHLO "EHLO"
|
||||
#define SMTP_CMD_HELP "HELP"
|
||||
#define SMTP_CMD_MAIL_FROM "MAIL FROM:"
|
||||
#define SMTP_CMD_RCPT_TO "RCPT TO:"
|
||||
#define SMTP_CMD_DATA "DATA"
|
||||
@ -32,6 +33,7 @@
|
||||
|
||||
// SMTP responses
|
||||
|
||||
#define SMTP_RESP_221_PILER_SMTP_OK "221 piler-smtp is OK\r\n"
|
||||
#define SMTP_RESP_220_BANNER "220 %s ESMTP\r\n"
|
||||
#define SMTP_RESP_220_READY_TO_START_TLS "220 Ready to start TLS\r\n"
|
||||
#define SMTP_RESP_221_GOODBYE "221 %s Goodbye\r\n"
|
||||
|
Loading…
Reference in New Issue
Block a user