Generic Transport Options

Transports are modules that carry out the delivery of messages, the only option required for a transport is driver which defines which transport is being configured.

Environment for Running Transports

Transports run in subprocesses of the main Exim delivery process, before running a transport's code Exim sets a specific uid and gid for the subprocess. It also sets the durrent directory for the process, this can be relevant before running appendfile to write to a users mail box. Normally Exim switches uid and gid to the user to ensure that deliveries are done as the "user", so that access to files is controlled by the operating systems. The router can sometimes supply the uid and gid but the transport can override these values.

setting gid

   driver = appendfile
   file = /var/spool/mail/$local_part
   group = mail

Note: You can also supply a group list if you so wish

You can specify current and home directories thus overriding the values from the router, if the home_directory option is not set then it is taken from these options: transport_home_directory, check_user_local, router_home_directory

overriding files example group_delivery:
   driver = appendfile
   file = /var/spool/mail/$local_part
   group = mail

Debugging Transports

The debug_print option works just the router option, when the debug ption is turned then the string value of debug_print is expanded and added to the debugging output when the transport is run.

debugging example remote_smtp:
   driver = smtp
   debug_print = self_hostname = $self_hostname

Transport Message Options

Normally, the transport delivers the whole message, but occasionally you may only want to send the only the head or only the body, which can be achieved using the options headers_only and body_only.

You can also reject a message if it is over a certain size using the option message_size_limit, the default is to apply no limit.

You can add or remove headers lines if you wish, other options are:

Message option example headers_add = Subject: new subject (was $h_subject:)
headers_remove = Subject

You can override the router option local_part_prefix, where the prefix is removed by setting the transport option rcpt_include_affixes to true.

Change the Return Path

You can change the return-path (another name for the senders address) in a envelope, this is replace the current return-path. You can refer to the existing return-path by using the variable $return-path. The main use of this option is for implementing Variable Envelope Return Path (VERP) for messages from mailing lists. This handles mail that may have been forwarded to a an address has been cancelled, etc. The header could contain details from where the message was original sent from and the routes it has taken thus highlighting a security risk. I suject to head off to the Exim web site to get more details on this option.

Transport Filters

The transport filter can make extensive changes to the message, by using the option transport_filter. Three process then will be used to deliver the message, a message writer process, transport filter process and a final delivery process, all three will be run in parallel and and used like a pipe. A default timeout of 5 minutes but can be override by using the option transport_filter_timeout.

*** diagram needed ***

Transport filter example transport_filter = /opt/exim/scripts/ $host $host_address $sender_address $pipe_address