/*++ /* NAME /* cleanup_api 3 /* SUMMARY /* cleanup callable interface, message processing /* SYNOPSIS /* #include "cleanup.h" /* /* CLEANUP_STATE *cleanup_open(src) /* VSTREAM *src; /* /* void cleanup_control(state, flags) /* CLEANUP_STATE *state; /* int flags; /* /* void CLEANUP_RECORD(state, type, buf, len) /* CLEANUP_STATE *state; /* int type; /* char *buf; /* int len; /* /* int cleanup_flush(state) /* CLEANUP_STATE *state; /* /* int cleanup_free(state) /* CLEANUP_STATE *state; /* DESCRIPTION /* This module implements a callable interface to the cleanup service /* for processing one message and for writing it to queue file. /* For a description of the cleanup service, see cleanup(8). /* /* cleanup_open() creates a new queue file and performs other /* per-message initialization. The result is a handle that should be /* given to the cleanup_control(), cleanup_record(), cleanup_flush() /* and cleanup_free() routines. The name of the queue file is in the /* queue_id result structure member. /* /* cleanup_control() processes per-message flags specified by the caller. /* These flags control the handling of data errors, and must be set /* before processing the first message record. /* .IP CLEANUP_FLAG_BOUNCE /* The cleanup server is responsible for returning undeliverable /* mail (too many hops, message too large) to the sender. /* .IP CLEANUP_FLAG_BCC_OK /* It is OK to add automatic BCC recipient addresses. /* .IP CLEANUP_FLAG_FILTER /* Enable header/body filtering. This should be enabled only with mail /* that enters Postfix, not with locally forwarded mail or with bounce /* messages. /* .IP CLEANUP_FLAG_MILTER /* Enable Milter applications. This should be enabled only with mail /* that enters Postfix, not with locally forwarded mail or with bounce /* messages. /* .IP CLEANUP_FLAG_MAP_OK /* Enable canonical and virtual mapping, and address masquerading. /* .PP /* For convenience the CLEANUP_FLAG_MASK_EXTERNAL macro specifies /* the options that are normally needed for mail that enters /* Postfix from outside, and CLEANUP_FLAG_MASK_INTERNAL specifies /* the options that are normally needed for internally generated or /* forwarded mail. /* /* CLEANUP_RECORD() is a macro that processes one message record, /* that copies the result to the queue file, and that maintains a /* little state machine. The last record in a valid message has type /* REC_TYPE_END. In order to find out if a message is corrupted, /* the caller is encouraged to test the CLEANUP_OUT_OK(state) macro. /* The result is false when further message processing is futile. /* In that case, it is safe to call cleanup_flush() immediately. /* /* cleanup_flush() closes a queue file. In case of any errors, /* the file is removed. The result value is non-zero in case of /* problems. In some cases a human-readable text can be found in /* the state->reason member. In all other cases, use cleanup_strerror() /* to translate the result into human-readable text. /* /* cleanup_free() destroys its argument. /* .IP CLEANUP_FLAG_SMTPUTF8 /* Request SMTPUTF8 support when delivering mail. /* .IP CLEANUP_FLAG_AUTOUTF8 /* Autodetection: request SMTPUTF8 support if the message /* contains an UTF8 message header, sender, or recipient. /* .IP CLEANUP_FLAG_REQTLS /* The sender requested REQUIRETLS (RFC 8689) enforcement. /* DIAGNOSTICS /* Problems and transactions are logged to \fBsyslogd\fR(8) /* or \fBpostlogd\fR(8). /* SEE ALSO /* cleanup(8) cleanup service description. /* cleanup_init(8) cleanup callable interface, initialization /* 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 /* /* Wietse Venema /* porcupine.org
/*--*/
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.