Add smtp starttls support

This commit is contained in:
Bernhard Amann 2014-05-15 09:57:01 -07:00
parent 746c073729
commit 6bc914458b
10 changed files with 94 additions and 12 deletions

View file

@ -49,7 +49,10 @@ export {
path: vector of addr &log &optional;
## Value of the User-Agent header from the client.
user_agent: string &log &optional;
## Indicates that the connection has switched to using TLS
tls: bool &default=F;
## Indicates if the "Received: from" headers should still be
## processed.
process_received_from: bool &default=T;
@ -276,6 +279,12 @@ event connection_state_remove(c: connection) &priority=-5
smtp_message(c);
}
event smtp_starttls(c: connection) &priority=5
{
if ( c?$smtp )
c$smtp$tls = T;
}
function describe(rec: Info): string
{
if ( rec?$mailfrom && rec?$rcptto )