2 <HEAD><TITLE>smfi_getsymval
</TITLE></HEAD>
5 $Id: smfi_getsymval.html,v 1.15 2007/03/19 16:49:11 ca Exp $
7 <H1>smfi_getsymval
</H1>
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
>
19 Get the value of a sendmail macro.
22 <!----------- Description ---------->
23 <TR><TH valign=
"top" align=left
>DESCRIPTION
</TH><TD>
24 <TABLE border=
"1" cellspacing=
1 cellpadding=
4>
25 <TR align=
"left" valign=top
>
26 <TH width=
"80">Called When
</TH>
27 <TD>smfi_getsymval may be called from within any of the xxfi_* callbacks. Which macros are defined will depend on when it is called.
</TD>
29 <TR align=
"left" valign=top
>
30 <TH width=
"80">Effects
</TH>
35 <!----------- Arguments ---------->
36 <TR><TH valign=
"top" align=left
>ARGUMENTS
</TH><TD>
37 <TABLE border=
"1" cellspacing=
0>
38 <TR bgcolor=
"#dddddd"><TH>Argument
</TH><TH>Description
</TH></TR>
39 <TR valign=
"top"><TD>ctx
</TD>
40 <TD>The opaque context structure.
42 <TR valign=
"top"><TD>symname
</TD>
43 <TD>The name of a sendmail macro.
44 Single letter macros can optionally be enclosed in braces (
"{" and
"}"),
45 longer macro names must be enclosed in braces, just as in a
46 <TT>sendmail.cf
</TT> file.
47 <A href=
"#notes">See below
</A> for default macros.
52 <!----------- Return values ---------->
54 <TH valign=
"top" align=left
>RETURN VALUES
</TH>
56 <TD>smfi_getsymval returns the value of the given macro as a null-terminated string, or NULL if the macro is not defined.
</TD>
59 <!----------- Notes ---------->
60 <TR align=
"left" valign=top
>
61 <TH><A name=
"notes">NOTES
</A></TH>
63 By default, the following macros are valid in the given contexts:
65 <TABLE border=
"1" cellspacing=
0>
66 <TR bgcolor=
"#dddddd"><TH>Sent With
</TH><TH>Macros
</TH></TR>
67 <TR><TD>xxfi_connect
</TD> <TD>daemon_name, if_name, if_addr, j, _
</TD></TR>
68 <TR><TD>xxfi_helo
</TD> <TD>tls_version, cipher, cipher_bits, cert_subject, cert_issuer
</TD></TR>
69 <TR><TD>xxfi_envfrom
</TD> <TD>i, auth_type, auth_authen, auth_ssf, auth_author,
70 mail_mailer, mail_host, mail_addr
</TD></TR>
71 <TR><TD>xxfi_envrcpt
</TD> <TD>rcpt_mailer, rcpt_host, rcpt_addr
</TD></TR>
73 <TR><TD>xxfi_data
</TD> <TD>(none)
</TD></TR>
74 <TR><TD>xxfi_eoh
</TD> <TD>(none)
</TD></TR>
75 <TR><TD>xxfi_eom
</TD> <TD>msg_id
</TD></TR>
78 All macros stay in effect from the point they are received
79 until the end of the connection for the first two sets,
80 the end of the message for the third (xxfi_envfrom) and last (xxfi_eom),
81 and just for each recipient for xxfi_envrcpt.
83 The macro list can be changed using the confMILTER_MACROS_* options in
85 The scopes of such macros will be determined by when they are set by sendmail.
86 For descriptions of macros' values,
88 "Sendmail Installation and Operation Guide"
89 provided with your sendmail distribution.
98 Copyright (c)
2000,
2002-
2003,
2007 Sendmail, Inc. and its suppliers.
101 By using this file, you agree to the terms and conditions set
102 forth in the LICENSE.