''-f'' '''

-f

Set sender's address All versions

The -f command-line switch[10] causes sendmail to take the address of the sender from the command line rather than from the envelope or message header. The -f switch is used by UUCP software and by mailing list software. The form of the -f switch is:

[10] The -r command-line switch is a synonym for this -f switch, but the -r is deprecated and should not be used.

-faddr
-f addr

Space between the -f and the addr is optional. If addr is missing, sendmail prints the following error message and ignores the -f switch:

sendmail: option requires an argument -- f

Multiple -f switches cause sendmail to print the following error message and exit:

More than one "from" person

The behavior of this switch varies depending on the version of sendmail you are running.

Prior to V8 the uid of the user specifying the -f switch must match one of the usernames given in the T configuration command. If they do not match, sendmail silently ignores the option and determines the sender's address in the usual ways.

From V8.1 through V8.6 the T configuration command was eliminated. If the -f or -r switch was used, and if the p (privacy) option was given authwarnings, sendmail included an X-Authentication-Warning: header in the mail message. That header warned that the identity of the sender had changed.

Beginning with V8.7 sendmail, the T was reintroduced, but in a different form (Section 10.8.1). First sendmail checks to see whether the user specified by the -f is the same as the login name of the user running sendmail, as would be the case for mh(1). If they are the same, sendmail silently accepts the address. If they differ, sendmail looks to see whether the login name of the user running sendmail is in the class $=t. If it is, sendmail silently accepts the address. If not, sendmail checks to see if authwarnings is set for the PrivacyOptions option (PrivacyOptions). If it is, the following warning is logged and included in the outgoing message:

X-Authentication-Warning: login set sender to new name using -f 

An example of one use for the -f switch can be seen in the previous section covering the -F switch.



    Part I: Build and Install
    Part II: Administration
    Part III: The Configuration File