/*++ /* NAME /* smtp_session 3 /* SUMMARY /* SMTP_SESSION structure management /* SYNOPSIS /* #include "smtp.h" /* /* SMTP_SESSION *smtp_session_alloc(stream, iter, start, flags) /* VSTREAM *stream; /* SMTP_ITERATOR *iter; /* time_t start; /* int flags; /* /* void smtp_session_free(session) /* SMTP_SESSION *session; /* /* int smtp_session_passivate(session, dest_prop, endp_prop) /* SMTP_SESSION *session; /* VSTRING *dest_prop; /* VSTRING *endp_prop; /* /* SMTP_SESSION *smtp_session_activate(fd, iter, dest_prop, endp_prop) /* int fd; /* SMTP_ITERATOR *iter; /* VSTRING *dest_prop; /* VSTRING *endp_prop; /* DESCRIPTION /* smtp_session_alloc() allocates memory for an SMTP_SESSION structure /* and initializes it with the given stream and destination, host name /* and address information. The host name and address strings are /* copied. The port is in network byte order. /* /* smtp_session_free() destroys an SMTP_SESSION structure and its /* members, making memory available for reuse. It will handle the /* case of a null stream and will assume it was given a different /* purpose. /* /* smtp_session_passivate() flattens an SMTP session (including /* TLS context) so that it can be cached. The SMTP_SESSION /* structure is destroyed. /* /* smtp_session_activate() inflates a flattened SMTP session /* so that it can be used. The input property arguments are /* modified. /* /* Arguments: /* .IP stream /* A full-duplex stream. /* .IP iter /* The literal next-hop or fall-back destination including /* the optional [] and including the :port or :service; /* the name of the remote host; /* the printable address of the remote host; /* the remote port in network byte order. /* .IP start /* The time when this connection was opened. /* .IP flags /* Zero or more of the following: /* .RS /* .IP SMTP_MISC_FLAG_CONN_LOAD /* Enable re-use of cached SMTP or LMTP connections. /* .IP SMTP_MISC_FLAG_CONN_STORE /* Enable saving of cached SMTP or LMTP connections. /* .RE /* SMTP_MISC_FLAG_CONN_MASK corresponds with both _LOAD and _STORE. /* .IP dest_prop /* Destination specific session properties: the server is the /* best MX host for the current logical destination, the dest, /* host, and addr properties. When dest_prop is non-empty, it /* overrides the iterator dest, host, and addr properties. It /* is the caller's responsibility to save the current nexthop /* with SMTP_ITER_SAVE_DEST() and to restore it afterwards /* with SMTP_ITER_RESTORE_DEST() before trying alternatives. /* .IP endp_prop /* Endpoint specific session properties: all the features /* advertised by the remote server. /* LICENSE /* .ad /* .fi /* The Secure Mailer license must be distributed with this software. /* AUTHOR(S) /* Wietse Venema /* IBM T.J. Watson Research /* P.O. Box 704 /* Yorktown Heights, NY 10598, USA /* /* Wietse Venema /* Google, Inc. /* 111 8th Avenue /* New York, NY 10011, USA /* /* Viktor Dukhovni
/*--*/
/* smtp_session_activate - re-activate a passivated SMTP_SESSION object */
SMTP_SESSION *smtp_session_activate(int fd, SMTP_ITERATOR *iter,
VSTRING *dest_prop,
VSTRING *endp_prop)
{ constchar *myname = "smtp_session_activate";
VSTREAM *mp;
SMTP_SESSION *session; int endp_features; /* server features */ int dest_features; /* server features */ long expire_time; /* session re-use expiration time */ int reuse_count; /* # times reused */
#if USE_TLS if (tls_context)
tls_log_summary(TLS_ROLE_CLIENT, TLS_USAGE_USED,
session->tls_context); #endif
return (session);
}
Messung V0.5 in Prozent
¤ Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.0.12Bemerkung:
(vorverarbeitet am 2026-08-08)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.