1d0cef73dSGregory Neil Shapiro<HTML> 2d0cef73dSGregory Neil Shapiro<HEAD><TITLE>smfi_chgfrom</TITLE></HEAD> 3d0cef73dSGregory Neil Shapiro<BODY> 4d0cef73dSGregory Neil Shapiro<!-- 5*4313cc83SGregory Neil Shapiro$Id: smfi_chgfrom.html,v 1.4 2013-11-22 20:51:39 ca Exp $ 6d0cef73dSGregory Neil Shapiro--> 7d0cef73dSGregory Neil Shapiro<H1>smfi_chgfrom</H1> 8d0cef73dSGregory Neil Shapiro 9d0cef73dSGregory Neil Shapiro<TABLE border="0" cellspacing=4 cellpadding=4> 10d0cef73dSGregory Neil Shapiro<!---------- Synopsis -----------> 11d0cef73dSGregory Neil Shapiro<TR><TH valign="top" align=left width=100>SYNOPSIS</TH><TD> 12d0cef73dSGregory Neil Shapiro<PRE> 13d0cef73dSGregory Neil Shapiro#include <libmilter/mfapi.h> 14d0cef73dSGregory Neil Shapiroint smfi_chgfrom( 15d0cef73dSGregory Neil Shapiro SMFICTX *ctx, 16d0cef73dSGregory Neil Shapiro const char *mail, 17d0cef73dSGregory Neil Shapiro char *args 18d0cef73dSGregory Neil Shapiro); 19d0cef73dSGregory Neil Shapiro</PRE> 20d0cef73dSGregory Neil ShapiroChange the envelope sender (MAIL From) of the current message. 21d0cef73dSGregory Neil Shapiro</TD></TR> 22d0cef73dSGregory Neil Shapiro 23d0cef73dSGregory Neil Shapiro<!----------- Description ----------> 24d0cef73dSGregory Neil Shapiro<TR><TH valign="top" align=left>DESCRIPTION</TH><TD> 25d0cef73dSGregory Neil Shapiro<TABLE border="1" cellspacing=1 cellpadding=4> 26d0cef73dSGregory Neil Shapiro<TR align="left" valign=top> 27d0cef73dSGregory Neil Shapiro<TH width="80">Called When</TH> 28d0cef73dSGregory Neil Shapiro<TD>Called only from <A href="xxfi_eom.html">xxfi_eom</A>.</TD> 29d0cef73dSGregory Neil Shapiro</TR> 30d0cef73dSGregory Neil Shapiro<TR align="left" valign=top> 31d0cef73dSGregory Neil Shapiro<TH width="80">Effects</TH> 32d0cef73dSGregory Neil Shapiro<TD>Change the envelope sender (MAIL From) of the current message.</TD> 33d0cef73dSGregory Neil Shapiro</TR> 34d0cef73dSGregory Neil Shapiro</TABLE> 35d0cef73dSGregory Neil Shapiro 36d0cef73dSGregory Neil Shapiro<!----------- Arguments ----------> 37d0cef73dSGregory Neil Shapiro<TR><TH valign="top" align=left>ARGUMENTS</TH><TD> 38d0cef73dSGregory Neil Shapiro <TABLE border="1" cellspacing=0> 39d0cef73dSGregory Neil Shapiro <TR bgcolor="#dddddd"><TH>Argument</TH><TH>Description</TH></TR> 40d0cef73dSGregory Neil Shapiro <TR valign="top"><TD>ctx</TD> 41d0cef73dSGregory Neil Shapiro <TD>Opaque context structure. 42d0cef73dSGregory Neil Shapiro </TD></TR> 43d0cef73dSGregory Neil Shapiro <TR valign="top"><TD>mail</TD> 44d0cef73dSGregory Neil Shapiro <TD>The new sender address. 45d0cef73dSGregory Neil Shapiro </TD></TR> 46d0cef73dSGregory Neil Shapiro <TR valign="top"><TD>args</TD> 47d0cef73dSGregory Neil Shapiro <TD>ESMTP arguments. 48d0cef73dSGregory Neil Shapiro </TD></TR> 49d0cef73dSGregory Neil Shapiro </TABLE> 50d0cef73dSGregory Neil Shapiro</TD></TR> 51d0cef73dSGregory Neil Shapiro 52d0cef73dSGregory Neil Shapiro<!----------- Return values ----------> 53d0cef73dSGregory Neil Shapiro<TR> 54d0cef73dSGregory Neil Shapiro<TH valign="top" align=left>RETURN VALUES</TH> 55d0cef73dSGregory Neil Shapiro 56d0cef73dSGregory Neil Shapiro<TD>smfi_chgfrom will fail and return MI_FAILURE if: 57d0cef73dSGregory Neil Shapiro<UL><LI>mail is NULL. 58d0cef73dSGregory Neil Shapiro <LI>Changing the sender in the current connection state is invalid. 59d0cef73dSGregory Neil Shapiro <LI>A network error occurs. 60d0cef73dSGregory Neil Shapiro <LI>SMFIF_CHGFROM was not set when <A href="smfi_register.html">smfi_register</A> was called. 61d0cef73dSGregory Neil Shapiro</UL> 62d0cef73dSGregory Neil ShapiroOtherwise, it will return MI_SUCCESS. 63d0cef73dSGregory Neil Shapiro</TD> 64d0cef73dSGregory Neil Shapiro</TR> 65d0cef73dSGregory Neil Shapiro 66d0cef73dSGregory Neil Shapiro<!----------- Notes ----------> 67d0cef73dSGregory Neil Shapiro<TR align="left" valign=top> 68d0cef73dSGregory Neil Shapiro<TH>NOTES</TH> 69d0cef73dSGregory Neil Shapiro<TD> 70d0cef73dSGregory Neil ShapiroA filter which calls smfi_chgfrom must have set the SMFIF_CHGFROM flag 71d0cef73dSGregory Neil Shapiroin the smfiDesc_str passed to 72d0cef73dSGregory Neil Shapiro<A href="smfi_register.html">smfi_register</A>. 73d0cef73dSGregory Neil Shapiro<BR> 74d0cef73dSGregory Neil ShapiroEven though all ESMTP arguments could be set via this call, 75d0cef73dSGregory Neil Shapiroit does not make sense to do so for many of them, 76d0cef73dSGregory Neil Shapiroe.g., SIZE and BODY. 77d0cef73dSGregory Neil ShapiroSetting those may cause problems, proper care must be taken. 78d0cef73dSGregory Neil ShapiroMoreover, there is no feedback from the MTA to the milter 79d0cef73dSGregory Neil Shapirowhether the call was successful. 80d0cef73dSGregory Neil Shapiro</TD> 81d0cef73dSGregory Neil Shapiro</TR> 82d0cef73dSGregory Neil Shapiro 83d0cef73dSGregory Neil Shapiro</TABLE> 84d0cef73dSGregory Neil Shapiro 85d0cef73dSGregory Neil Shapiro<HR size="1"> 86d0cef73dSGregory Neil Shapiro<FONT size="-1"> 875dd76dd0SGregory Neil ShapiroCopyright (c) 2006 Proofpoint, Inc. and its suppliers. 88d0cef73dSGregory Neil ShapiroAll rights reserved. 89d0cef73dSGregory Neil Shapiro<BR> 90d0cef73dSGregory Neil ShapiroBy using this file, you agree to the terms and conditions set 91d0cef73dSGregory Neil Shapiroforth in the LICENSE. 92d0cef73dSGregory Neil Shapiro</FONT> 93d0cef73dSGregory Neil Shapiro</BODY> 94d0cef73dSGregory Neil Shapiro</HTML> 95