Actions Defined

The following actions are available from the Execute actions and rules drop-down lists available in the PureMessage Manager's Policy Constructor.

Note: As of PureMessage 5.2.1, some actions allow you to specify Japanese characters. See the version 5.2.1 section of the Release History for details.

Accept the message

Deliver the message to its envelope recipients.

Add banner

Add a custom banner to the body or header of a message. If the message contains both an HTML and a plain text part, the banner is added to both (unless Ignore these content-types is used). If the message contains multiple text parts, the banner will be added to the first one.

Add header

Add a header to the message. Specify the name of the header, then the value the header should contain.

Use template variables to specify the value(s) to display in the message header.

Add recipient(s)

Adds a CC (carbon copy) recipient to the message, as opposed to "Redirect the message" (which replaces the envelope recipients) and "Forward to" (which adds a blind carbon copy recipient).

Apply BATV watermark

When applied to outgoing messages, this action adds a Bounce Address Tag Validation (BATV) identifier to each message, allowing PureMessage to distinguish legitimate bounce messages from backscatter spam messages.

This action should be configured in the "Mail from internal hosts" section of the PureMessage policy, in conjunction with the "Message is a bounce" test in the "Mail from external hosts" section.

See also the "Message is a bounce" description in the Message Characteristics section of the Policy Tab documentation. For more information about BATV, see the Knowledgebase on the Sophos website.

Archive message to a file (Extended Policy Model)

A copy of the message is stored in "mbox" format (compatible with many mail readers) in the specified directory and filename.

Change the envelope from address

Replaces the message's Envelope From address with the address that you specify.

Clean the message of any viruses

Tells the virus engine to clean the virus from the message. If cleaning fails, the message is quarantined, and a message is sent to the recipient based on the specified Failure Template File.

Collect attachment statistics in message log

Writes an entry in the message log that includes:

Copy the message to quarantine

Store a copy of the message in the quarantine. This command does not affect the delivery of the message. If called multiple times, multiple copies of the message are stored in the quarantine. The copy stored in the quarantine incorporates any changes made to the message as a result of actions that have occurred to that point.

Custom policy mark

Mark the message with a key-value pair. This action should only be used for custom policy reports. For more information, see "Viewing and Managing Reports" in the Admimistrative Groups section of the Adminstrator's Reference. The message will accumulate marks as it is processed that are written to the message log. These marks can be used to generate custom statistical reports.

Delete header

Delete the specified header.

Deliver immediately for

Allows the message to be exempted from further processing for the specified recipients. The "envelope to" address is compared against the list or individual addresses specified in the Arguments dialog box. For example, to exempt a user's email from being checked for spam, create a Deliver immediately for action before the spam rule.

The message will be queued for delivery and delivered when the pmx-queue program is run (pmx-queue is configured as a scheduled job).

Discard the message

Tells the mail transfer agent to discard the message.

Drop attachment

Discard the attachment, but deliver the message. This action can only be used with tests that check message attachment characteristics. If the message has multiple attachments, the attachment associated with the test will be dropped.

Forward to

Forward message (via a blind carbon copy) to the specified addresses. This action writes a copy of the message to the outgoing queue, which is then delivered.

Log the message with key/value pair

Mark the message with a key-value pair. The message will accumulate "marks" as it is processed that are written to the message log when the message stops processing. These marks can be used to generate Policy Mark Hits reports, which show a count of keywords and keys from the message log.

Log the message with keyword

Mark the message with given key. The message will accumulate "marks" as it is processed that are written to the message log when the message stops processing. These marks can be used to generate Policy Mark Hits reports, which show a count of keywords and keys from the message log. The keyword string can consist of alphanumeric characters and underscores, up to a maximum of 64 characters.

Map recipients

Maps the envelope recipients against the specified address map. The envelope recipients are looked up in the address map; if they match a source address, they are replaced with the destination address defined in the address map.

Note that address maps can be configured with an empty Map To value, which has the result of deleting the message.

Notify

Send a notification email to the sender or recipients of a message. The following fields can be configured for notifications:

Quarantine the message

Copy the message to the quarantine; do not deliver the message to the intended recipient(s).

Redirect the message

Replaces all the envelope recipient addresses with the specified address.

Reject the message

Tells the mail transfer agent to reject the message.

Rename attachment

Rename an attachment. The replacement string can use the %%ATTACHMENT_NAME%% template variable to provide the original filename in the replacement name (for example, %%ATTACHMENT_NAME%%.warning)

Replace header

Replace the value of the specified header with the specified value. See the Add header action for a list of template variables that can be used for the value. If the header does not exist, this action will add it.

Replace message part

Replace an attachment, or the whole body of the message, with custom text or a file. If used in the same rule as an attachment test, the matching attachment(s) will be replaced. If it is used outside of this context, the entire body of the message will be replaced.

The following template variables can be used in the file or string.

Route message

Route the message to a specified server or to multiple servers, usually for the purpose of archiving or encrypting. Enter the IP address(es) or fully qualified hostname(s) of the server(s) to which the message should be routed. For example, you may want make a copy of each message sent to the customer service department and archive it on a separate server.

Important: When using the "Route message" action, make sure that the relay you specify here is not also a mail server that is delivering mail via the same server that performed the routing action. This would cause PureMessage to route mail in a continuous loop instead of delivering it.
Note:

If, when upgrading to the latest version of PureMessage, an error message is displayed regarding the smtp_generic_maps setting in /opt/pmx/postfix/etc/main.cf, complete the following steps:

  1. Because policy routing only works with "pcre" maps, ensure that the smtp_generic_maps setting is of the type pcre. For example:

    smtp_generic_maps=pcre:PathToMapFile
  2. In the pcre map file, add the following regular expression on a separate line at the end of the file:
    /(.*)%(.*)@.*/  $1@$2
  3. As the root user, in /opt/pmx/postfix/etc, run make.

These steps may also be necessary if you are using an external Postfix installation. Follow the same instructions, making adjustments for the different file locations.

Set a template variable

Initialize a template variable with a shell command. This action will execute the shell command and put the output in a template variable that can be used in subsequent tests and actions. Use the %%MESSAGE_FILE%% template in the shell command to determine the filename of a file containing a message.

Sign message with DKIM header

DomainKeys Identified Mail (DKIM) is an authentication framework used to sign and validate a message, based on the domain of its sender. This action signs outgoing messages with a unique DKIM signature. To configure PureMessage to detect and verify DKIM signatures for incoming messages, see Verify message DKIM header in the "Message Characteristics" section.

In order for this action to take effect, you must configure /opt/pmx/etc/dkim.conf. This configuration file contains the required signing options, and the location of the private key that is used to create the DKIM signature. If you want multiple PureMessage servers in the same domain to share one signature for the delivery of mail, you must also add the location of the private key to the DomainKeys-Identified-Mail publication. For configuration instructions, see the dkim.conf man page, and "Managing Publications " in the Server Groups Tab section of the Manager Reference .

DKIM signatures depend on access to a private key. This must also be configured in order for the action to take affect. For general information, see www.dkim.org.

The action appends a signature to messages, and, therefore, should only be applied to rules in the "Mail from internal hosts" section of the PureMessage policy.

Stop processing

When you add this action to a rule, it prevents processing of subsequent rules if that rule is hit. If you create a new rule by clicking add rule or Add Alternative, the Stop processing action is added by default.

Tempfail the message

Signal the MTA to return SMTP error code 421 (service not available).

Write an entry to pmx_log

Log a message to the PureMessage log file (as specified by the 'log_to' parameter in the pmx.conf configuration file).

Write test data to message log

This action is used for policy tests. When tests are run, this action writes a marker to the message log, and uses that marker to track the test message's progress through the policy filter. This action must be defined in the policy in order to run policy tests.

Related concepts
Template Variables
Regular Expression Primer
Message Characteristics
Managing Publications
Related tasks
Creating Lists or Maps
Related information
pmx-policy
pmx-queue
dkim.conf
www.dkim.org