2 <HEAD><TITLE>xxfi_body</TITLE></HEAD>
5 $Id: xxfi_body.html,v 1.17 2007/03/26 20:12:46 ca Exp $
9 <TABLE border="0" cellspacing=4 cellpadding=4>
10 <!---------- Synopsis ----------->
11 <TR><TH valign="top" align=left width=100>SYNOPSIS</TH><TD>
13 #include <libmilter/mfapi.h>
14 sfsistat (*xxfi_body)(
20 Handle a piece of a message's body.
23 <!----------- Description ---------->
24 <TR><TH valign="top" align=left>DESCRIPTION</TH><TD>
25 <TABLE border="1" cellspacing=1 cellpadding=4>
26 <TR align="left" valign=top>
27 <TH width="80">Called When</TH>
28 <TD>xxfi_body is called zero or more times between xxfi_eoh and xxfi_eom.</TD>
30 <TR align="left" valign=top>
31 <TH>Default Behavior</TH>
32 <TD>Do nothing; return SMFIS_CONTINUE.</TD>
36 <!----------- Arguments ---------->
37 <TR><TH valign="top" align=left>ARGUMENTS</TH><TD>
38 <TABLE border="1" cellspacing=0>
39 <TR bgcolor="#dddddd"><TH>Argument</TH><TH>Description</TH></TR>
40 <TR valign="top"><TD>ctx</TD>
41 <TD>Opaque context structure.
43 <TR valign="top"><TD>bodyp</TD>
44 <TD>Pointer to the start of this block of body data. bodyp is not valid outside this call to xxfi_body.
46 <TR valign="top"><TD>len</TD>
47 <TD>The amount of data pointed to by bodyp.
52 <!----------- Notes ---------->
54 <TH valign="top" align=left>NOTES</TH>
57 <LI>bodyp points to a sequence of bytes.
58 It is <EM>not</EM> a C string (a sequence of characters that is terminated by '\0').
59 Therefore, do not use the usual C string functions like <CODE>strlen(3)</CODE>
61 Moreover, the byte sequence may contain '\0' characters inside the block.
62 Hence even if a trailing '\0' is added, C string functions may still fail
64 <LI>Since message bodies can be very large, defining xxfi_body can
65 significantly impact filter performance.
66 <LI>End-of-lines are represented as received from SMTP (normally CR/LF).
67 <LI>Later filters will see body changes made by earlier ones.
68 <LI>Message bodies may be sent in multiple chunks, with one call to
71 <A HREF="api.html#SMFIS_SKIP">SMFIS_SKIP</A>
72 if a milter has received sufficiently many
73 body chunks to make a decision,
74 but still wants to invoke
75 message modification functions that are only allowed to be called from
76 <A HREF="xxfi_eom.html">xxfi_eom()</A>.
77 Note: the milter <EM>must</EM>
78 <A HREF="xxfi_negotiate.html">negotiate</A>
79 this behavior with the MTA, i.e., it must check whether
81 <A HREF="xxfi_negotiate.html#SMFIP_SKIP"><CODE>SMFIP_SKIP</CODE></A>
82 is available and if so, the milter must request it.
90 Copyright (c) 2000-2003, 2007 Sendmail, Inc. and its suppliers.
93 By using this file, you agree to the terms and conditions set