Configuring Quarantine Digests for Java System Messaging Server (JSMS)

If Java System Messaging Server (JSMS) is your mail transfer agent, you must perform the following steps before end users can receive quarantine digests. This procedure configures a "pipe channel" through which digest requests are processed. The procedure assumes that JSMS and PureMessage are installed on the same server and that JSMS is used in conjunction with LDAP. Portions of this procedure may vary, depending on the nature of your installation.

Note: All commands must be run as either the root or IMTA user.

To configure quarantine digests for JSMS:

  1. Add a mail user named pmx-auto-approve to the LDAP directory that JSMS uses to perform mail user lookups.
  2. Create a symlink to the pmx-qdigest-approve program.

    The path differs depending on which version of JSMS you are using. For example:

    Version 5.2:

    cd <JSMS_Install_Dir>/imta/programs
    ln -s /opt/pmx/bin/pmx-qdigest-approve

    Version 6:

    cd <JSMS_Install_Dir>/data/site-programs
    ln -s /opt/pmx/bin/pmx-qdigest-approve
  3. Register the program with the MTA by running the following command:
    imsimta program -a -m pmxapprove -p pmx-qdigest-approve -e pmx
  4. Create a text file called entrymod in the /tmp directory. Note that the distinguished name for your pmx-auto-approve user must follow the same format as other distinguished names in your LDAP system. Add the following lines to the text file:
    dn: uid=pmx-auto-approve, ou=people, o=internet, dc=Domain_Name, dc=com\
    changetype: modify
    edit: maildeliveryoption
    maildeliveryoption: program
    -
    add: mailprogramdeliveryinfo
    mailprogramdeliveryinfo: pmxapprove
  5. Run the following command to modify LDAP:
    ldapmodify -D 'cn=Directory Manager' -f /tmp/entrymods
  6. Run the ldapsearch command to confirm that the entry has been modified:
    ldapsearch -b 'dc=Domain_Name, dc=com' -D 'cn=Directory Manager' uid=pmx-auto-approve

    If the modification was successful, a result that includes the following lines is displayed:

    dn: uid=pmx-auto-approve, ou=people, o=internet, dc=Domain_Name, dc=com
    ...
    mailDeliveryOption: program
    mailProgramDeliveryInfo: pmxapprove
  7. If you are using "Dirsync" (the default for JSMS 5.2) instead of "Direct LDAP", run the following command to ensure that the changes are synchronized with the database:
    imsimta dirsync -F
  8. This step is only necessary if JSMS was installed by a user other than the IMTA user. Create a file <JSMS_Install_Dir>/config/pipe_option. Ensure that the file is readable by the IMTA user (specified in <JSMS_Install_Dir>/config/imta_tailor). Specify the following entry to indicate the temporary working directory to use when running commands via the pipe channel.
    SHELL_TMPDIR=/tmp
  9. To test how JSMS rewrites the recipient address, run:
    imsimta test -rewrite pmx-auto-approve@Domain_Name.com

    Output similar to the following indicates correct configuration:

    Expanded address: 
      pmx-auto-approve@Domain_Name.com
    Submitted address list:
      pipe
         pmx-auto-approve%pmxapprove@pipe-daemon\
         (orig pmx-auto-approve@Domain_Name.com,\
         inter pmx-auto-approve@Domain_Name.com,\
         host pipe-daemon) *NOTIFY-FAILURES*\
         *NOTIFY-DELAYS*
  10. Sometimes, JSMS is not able to deal with digest requests when a server name is appended to the domain name. If necessary, create aliases by editing the "aliases" file.

    Version 5.2:

    <JSMS_Install_Dir>/imta/config/aliases

    Version 6:

    <JSMS_Install_Dir>/config/aliases

    Add the following line to the "aliases" file:

    pmx-auto-approve@Server_Name.Domain_Name.com: pmx-auto-approve@Domain_Name.com
  11. Run the following command to make the alias(es) take effect: ./imsimta refresh