NAME

tmda-filter-wrapper - preprocess messages before TMDA filtering


SYNOPSIS

tmda-filter-wrapper path/tmda-filter [arguments]


DESCRIPTION

Wrapper tmda-filter-wrapper is part of the authentication layer of the mail-based voter interface. It reads the message from standard input, adjusts the environment variable SENDER (envelope sender address) if necessary, and passes the message on to tmda-filter (TMDA). TMDA will then challenge the envelope sender address as usual.

This wrapper adjusts SENDER by setting it to the first 'From' or 'Sender' (message sender) address. It thus alters the envelope sender to match the message sender.

An exception is made for an empty envelope SENDER. It is left empty. It indicates a bounce, and TMDA does not attempt to verify bounces (in order to avoid loops).

After altering the SENDER variable (maybe), the remainder of the command line (the call to TMDA) is executed as a separate process, and the message is fed to it on standard input.

Rationale

Votorola needs an authenticated email identity for the human sender. The authentication challenge must therefore be done on the message address as opposed to the envelope address. The envelope address is only intended as a return path for delivery failures and such (RFC 2821).

For example, the sender may be using TMDA too, and may be date-tagging the envelope address. So the envelope address would vary from message to message, making it unsuitable as a sender identifier.

As well, the envelope address is not directly under the sender's control. It is part of the delivery mechanism, outside of the encoded message, and may become altered in the normal course of mail transfer. So again, would be unsuitable as a sender identifier.


CAVEATS

Only tested with qmail. It should work with any mail transfer agent (MTA), but you might have to modify it slightly. Pay particular attention to the environment variable SENDER which it expects from the MTA.