Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

smfi_addheader(3n) [hpux man page]

smfi_addheader(3N)														smfi_addheader(3N)

NAME
smfi_addheader() - adds a header to the current sendmail message SYNOPSIS
PARAMETERS
includes the following arguments: ctx Specifies the opaque context structure. headerf Specifies the header name, which is a non-NULL, null- terminated string. headerv Specifies the header value to be added. headerv is a non-NULL, null-terminated string and can be an empty string. DESCRIPTION
adds a header to the current message. can be called only from the function. Notes does not change existing headers of a message. To change the current value of a header, use the routine. A filter that calls the must set the flag in the structure passed to the For the filter, the order in which filters are placed is important. Filters placed later in the sequence will observe the changes already done by the earlier filters. The name and the value of the header are not checked for standards compliance. However, each line of the header must be under 2048 charac- ters. If longer headers are needed, multi-line header must be used. To make a multi-line header, insert a line feed (ASCII 0x0a, or in C) followed by at least one whitespace character, such as, a space (ASCII 0x20) or tab (ASCII 0x09, or in C). The line feed must not be preceded by a carriage return (ASCII 0x0d); the MTA adds this automatically. It is the responsibility of the filter writer to ensure that standards are not violated. RETURN VALUE
returns due to the following reasons: o The headerf or headerv is o Adding headers in the current connection state is invalid. o Memory allocation failure. o Network error o is not set when the routine is called. returns on success. EXAMPLES
Following is an example to add a header: AUTHOR
was developed by the Sendmail Inc. SEE ALSO
smfi_chgheader(3N), smfi_insheader(3N), smfi_addrcpt(3N), smfi_delrcpt(3N), smfi_replacebody(3N). on smfi_addheader(3N)

Check Out this Related Man Page

smfi_setreply(3N)														 smfi_setreply(3N)

NAME
smfi_setreply() - sets the default SMTP error reply code SYNOPSIS
PARAMETERS
ctx Specifies the opaque context structure. rcode Specifies the 3-digit (RFC 821/2821) SMTP reply code as a null-terminated string. rcode cannot be set to NULL value. rcode must be a valid or reply code. xcode Specifies the extended (RFC 1893/2034) reply code. An xcode must conform to RFC 1893/2034. If xcode is set to NULL, an extended code is not used. message Specifies the text part of the SMTP reply. If message is set to NULL, an empty message is used. DESCRIPTION
The routine directly sets the SMTP error reply code for a connection. Only and replies are accepted. uses this code on subsequent error replies from the Milter function. can be called from any function except the function. Notes o Values passed to are not checked for standards compliance. o The message parameter must contain only printable characters; other characters may lead to undefined behavior. For example, CR or LF causes the call to fail, a single (percentage) character can cause the text to be ignored. If a (percentage) character must be used in a string, it must be used as o For more information on reply codes and their meanings, see RFC 821, 2821, 1893, or 2034. o If the reply code (rcode) given is a code but is used for the message, the normal reply is not used. If the reply code (rcode) given is a code but is used for the message, the custom reply is not used. In neither of these two cases, an error is returned to the Milter and silently ignores the reply code. o If the Milter returns and sets the reply code to the SMTP server terminates the SMTP session with a error code. RETURN VALUE
fails and returns if the rcode or xcode argument is invalid or a memory allocation failure occurs; otherwise; returns AUTHOR
The routine was developed by the Sendmail Inc. SEE ALSO
smfi_getsymval(3N), smfi_getpriv(3N), smfi_setreply(3N), smfi_setpriv(3N). on smfi_setreply(3N)
Man Page