Technical data

Configuring and Managing SMTP
17.7 Managing SMTP Send-From-File (SFF)
17.7.1 SFF Security Measures
The ability to create messages with arbitrary headers could be used to spoof
message headers. To limit this, the SFF mechanism includes the following
security measures:
Allows you to define the TCPIP$SMTP_SFF_REQUIRES_PRIV logical. If the
logical is defined as 1, the process must have either BYPASS, SYSPRV, or
OPER privilege set in order to use SFF.
To help you track messages, SFF adds a Received: header to the headers you
supply. This tells you the origin of an attempted spoofed message.
You can invoke SFF from an application or from DCL, as described in the
following sections.
17.7.2 Invoking SFF from an Application
TCPIP$SMTP_MAILSHR.EXE contains a routine called TCPIP$SMTP_SEND_
FROM_FILE. This routine is declared as follows:
unsigned int TCPIP$SMTP_SEND_FROM_FILE(infile_name, logfd, log_level)
char *infile_name;
FILE *logfd;
int log_level;
The parameters for this routine are:
infile_name
Specifies the name of the text file that contains the RFC 822 mail message.
logfd
Specifies the file to which to log diagnostic messages. This file must be opened
by the caller before calling this routine. If no log file is specified, output goes
to SYS$OUTPUT. This parameter is optional.
log_level
Specifies the level of diagnostics to use: either 1 (on) or 0 (off). The default is
0 (no logging). This parameter is optional.
To call the routine, link with TCPIP$SMTP_MAILSHR.EXE/SHARE.
17.7.3 Invoking SFF from DCL
The SMTP_SFF command allows you to invoke SFF. To define SMTP_SFF as a
foreign command so that you can use it from DCL, enter the following command:
$ SMTP_SFF:==$TCPIP$SYSTEM:TCPIP$SMTP_SFF.EXE
This command takes UNIX style parameters and passes them to SFF.
The command format is:
SMTP_SFF infile_name [-log logfile_name] [-loglevel log_level]
The parameters to this command are:
infile_name
Specifies the name of text input file containing the SMTP mail to send.
logfile_name
Specifies the name of the log file for diagnostic messages. The default is
SYS$OUTPUT. This parameter is optional.
Configuring and Managing SMTP 17–27