PMDF System Manager's Guide


Previous Contents Index


TEST/REWRITE

Test address rewriting specified by a PMDF configuration

Syntax

PMDF TEST/REWRITE [test-address[,...]]

Command Qualifiers Defaults
/ALIAS_FILE=file-spec /ALIAS_FILE=PMDF_ALIAS_FILE
/CHANNEL /CHANNEL
/CHECK_EXPANSIONS /NOCHECK_EXPANSIONS
/CONFIGURATION_FILE=file-spec /CONFIGURATION_FILE=PMDF_CONFIG_FILE
/DATABASE=database-list See text
/DEBUG /NODEBUG
/DELIVERY_RECEIPT See text
/DESTINATION_CHANNEL=channel None
/FILTER /NOFILTER
/FROM=address /FROM=postmaster@localhost
/GREY=setting /GREY=0
/IMAGE_FILE=file-spec /IMAGE_FILE=PMDF_CONFIG_DATA
/LOCAL_ALIAS=value None
/MAPPING_FILE=file-spec /MAPPING_FILE=PMDF_MAPPING_FILE
/OPTION_FILE=file-spec /OPTION_FILE=PMDF_OPTION_FILE
/READ_RECEIPT See text
/REPROCESSING /REPROCESSING
/RESTRICTED=setting /RESTRICTED=0
/SOURCE_CHANNEL=channel /SOURCE_CHANNEL=L

restrictions

None.

prompts

Address: test-address[,...]

Parameters

test-address

Optional parameter specifying one or more addresses to rewrite.

Description

TEST/REWRITE provides a straightforward test facility for examining PMDF's address rewriting and channel mapping process without actually sending any message. Various qualifiers can be used to control whether TEST/REWRITE uses the configuration text files or the compiled configuration (if present), the amount of output produced, and so on.

If one or more test addresses are specified on the command line, TEST/REWRITE applies PMDF address rewriting to those addresses, reports the results, and exits. If no test address is specified TEST/REWRITE will enter a loop, prompting for addresses, rewriting them, and prompting again for more addresses. TEST/REWRITE will exit when a CTRL/Z is entered.

When testing rewriting of a alias corresponding to a mailing list which has an AUTH_ or CANT_ type of named parameter controlling who is authorized to post to the list, or when testing rewriting when SEND_ACCESS or related mapping tables are in effect, note that by default TEST/REWRITE uses as the posting address the return address of the local postmaster as specified by the RETURN_ADDRESS option in the PMDF option file. To specify a different posting address for the rewriting process, use the /FROM qualifier.


Command Qualifiers

/ALIAS_FILE=filename

TEST/REWRITE normally consults the default alias file PMDF_ALIAS_FILE during the rewriting process. The /ALIAS_FILE qualifier specified an alternate file for TEST/REWRITE to use. This qualifier has no effect unless /NOIMAGE_FILE is specified or no compiled configuration exists; use of any compiled configuration precludes reading any sort of alias file.

/CHANNEL (default)

/NOCHANNEL

This qualifier controls whether the utility outputs detailed information, e.g., channel flags, regarding the channel an address matches.

/CHECK_EXPANSIONS

/NOCHECK_EXPANSIONS (default)

This qualifier controls checking of alias address expansion. Normally PMDF considers the expansion of an alias to have been successful if any of the addresses the alias expands to are legal. The /CHECK_EXPANSIONS qualifier causes a much stricter policy to be applied; TEST/REWRITE checks each expanded address in detail and reports a list of any addresses, expanded or otherwise, that fail to rewrite properly. For addresses that match the L channel, PMDF also performs validity checks.

/CONFIGURATION_FILE=filename

TEST/REWRITE normally consults the default configuration file PMDF_CONFIG_FILE during the rewriting process. The /CONFIGURATION_FILE qualifier specifies an alternate file to use in place of the file PMDF_CONFIG_FILE. This qualifier has no effect unless /NOIMAGE_FILE is specified or no compiled configuration exists; use of any compiled configuration will preclude reading any sort of configuration file.

/DEBUG

/NODEBUG (default)

The address rewriting process is capable of producing additional, detailed explanations of what actions are taken and why. The /DEBUG qualifier enables this output; it is disabled by default.

/DATABASE=database-list

TEST/REWRITE normally consults the usual PMDF databases during its operation. This qualifier is used to either disable references to various databases or to redirect the database paths to nonstandard locations. The allowed list items are ALIAS, NOALIAS, PERSONAL_ALIAS, NOPERSONAL_ALIAS, DOMAIN, NODOMAIN, FORWARD, NOFORWARD, GENERAL, NOGENERAL, REVERSE, and NOREVERSE. The list items beginning with NO disable use of the corresponding database. The remaining items require an associated value, which is taken to be the name of that database.

/DELIVERY_RECEIPT

/NODELIVERY_RECEIPT

The /DELIVERY_RECEIPT and /NODELIVERY_RECEIPT qualifiers, which explicitly set the corresponding receipt request flags, can be useful when testing the handling of receipt requests when rewriting forwarded addresses or mailing lists.

/DESTINATION_CHANNEL=channel

The /DESTINATION_CHANNEL qualifier controls what destination or target channel TEST/REWRITE rewrites addresses for. Some address rewriting is destination channel specific; this qualifier allows control of the assumed destination channel.

/FILTER

/NOFILTER (default)

The /FILTER qualifier may be used to have PMDF TEST/REWRITE output any filters (personal mailbox, channel, or system) applying for the address in question.

/FROM=address

/NOFROM

This qualifier controls what envelope From: address is used for access control probes and mailing list access probes. If the /FROM qualifier is omitted, then the address used for access checks is the postmaster return address. Specifying either /FROM=<> or /NOFROM tells the utility to use an empty envelope From: address for access checks.

/GREY=setting

/NOGREY (default)

This qualifier controls the setting of the Grey Book flag. By default, this flag has value 0. When set to 1, /GREY=1, the Grey Book flag will be set on and addresses will be rewritten using the Grey Book format. This flag is used to force rewriting of address in accordance with the JANET (Grey Book) specifications. The most significant effect is that domain specifications appear in reverse order, e.g., edu.claremont.ymir and not ymir.claremont.edu. See Section 2.3.4.83 for further details. Grey Book address formats are not currently used in PMDF, so this qualifier's usefulness is problematic at best.

/IMAGE_FILE[=filename]

/NOIMAGE_FILE

The /IMAGE_FILE qualifier serves two purposes. The first is when /NOIMAGE_FILE is specified; this instructs TEST/REWRITE to ignore any compiled configuration unconditionally and to read configuration information from the various text files instead. When the /IMAGE_FILE qualifier is specified without an optional file name, PMDF TEST/REWRITE will load the compiled configuration from the file PMDF_CONFIG_DATA. If, instead, a file name is specified then TEST/REWRITE will load the compiled configuration from the specified file.

/LOCAL_ALIAS=value

/NOLOCAL_ALIAS (default)

This qualifier controls the setting of an alias for the local host. PMDF supports multiple "identities" for the local host; the local host may have a different identity on each channel. This qualifier may be used to set the local host alias to the specified value; appearances of the local host in rewritten addresses will be replaced by this value.

/MAPPING_FILE[=filename]

/NOMAPPING_FILE

This qualifier instructs TEST/REWRITE to use the specified mapping file rather than the default mapping file named by the PMDF_MAPPING_FILE logical name, usually PMDF_TABLE:mappings. This qualifier has no effect unless /NOIMAGE_FILE was specified or no compiled configuration exists; use of any compiled configuration will preclude reading the mapping file. Use of the /NOMAPPING_FILE qualifier will prevent the PMDF_MAPPING_FILE file from being read in when there is no compiled configuration.

/OPTION_FILE=filename

/NOOPTION_FILE

This qualifier instructs TEST/REWRITE to use the specified option file rather than the default option file PMDF_OPTION_FILE. This qualifier has no effect unless /NOIMAGE_FILE is specified or no compiled configuration exists; use of any compiled configuration will preclude reading any sort of option file. Use of the qualifier /NOOPTION_FILE will prevent the file PMDF_OPTION_FILE from being read in when there is no compiled configuration.

/READ_RECEIPT

/NOREAD_RECEIPT

The /READ_RECEIPT and /NOREAD_RECEIPT qualifiers, which explicitly set the corresponding receipt request flags, can be useful when testing the handling of receipt requests when rewriting forwarded addresses or mailing lists.

/REPROCESSING (default)

/NOREPROCESSING

This qualifier allows the utility to display the contents of a mailing list which uses the [REPROCESS] named parameter in its alias definition.

/RESTRICTED=value

/NORESTRICTED

This qualifier controls the setting of the restricted flag. By default, this flag has value 0. When set to 1, /RESTRICTED=1, the restricted flag will be set on and addresses will be rewritten using the restricted mailbox encoding format recommend by RFC1137. This flag is used to force rewriting of address mailbox names in accordance with the RFC1137 specifications; see Section 2.3.4.57 for further details.

/SOURCE_CHANNEL=channel

The /SOURCE_CHANNEL qualifier controls what source channel to rewrite addresses for. Some address rewriting is source channel specific; TEST/REWRITE normally pretends that the channel source it is rewriting for is the local channel, L.

EXAMPLES

This example shows the typical output generated by TEST/REWRITE. Perhaps the single most important piece of information generated by TEST/REWRITE is the last few lines of the TEST/REWRITE output, (6), which give the channel to which TEST/REWRITE would submit a message with the specified test address and the form in which the test address would be rewritten for that channel. This output is invaluable when debugging configuration problems.

  1. The channel to which, after rewriting as an envelope To: address, the address is mapped.
  2. The flags set for the channel indicated in . These flags are controlled by the channel keywords on the first line of the channel control block for the specified channel. Any unknown keywords---keywords which may have been mistyped---will be interpreted as rightslist identifiers and will appear on the line .
  3. The channel's official host name as specified on the second line of the channel control block for the channel indicated in .
  4. The channel queue name, channel after parameter, and channel daemon name correspond to values specified via the queue, after, and daemon channel keywords, respectively. If no such keyword is present on the channel, then no such line of output will be displayed.
  5. Any items appearing on the first line of the channel block which were not channel keywords are interpreted as rightslist identifiers. Any rightslist identifiers so specified for the channel are listed on this line.
  6. The channel which the address would match as an envelope From: address.
  7. The channel to which a message with the address DAN@EXAMPLE.COM would be queued and the envelope To: address which would be used. Here, the message would be submitted to the TCP/IP channel, tcp_local, using the address DAN@EXAMPLE.COM. Other information appearing here might include an explicit Errors-to: address, which, if present, appears enclosed in square brackets; or notations such as *RR* or *NRR*, indicating whether or not a message is flagged for read receipts, or notations such as *NOTIFY FAILURES*, *NOTIFY DELAYS*, *NOTIFY SUCCESSES* etc., indicating the message's delivery receipt mechanism and flagging.
  8. Notification addresses (reserved for future use).

Error messages

Usually errors reported by PMDF TEST/REWRITE are not actually errors regarding PMDF TEST/REWRITE in particular, but rather are the utility warning of an underlying configuration problem. For instance, "Error in mm_init: ..." sorts of errors; see for a discussion of many such general error messages.


Address list error -- unknown host or domain: 
      

The domain name in the specified address did not rewrite to any PMDF channel. Check that the domain name was correctly spelled. If the domain name was correct, then most likely you need a new (or changed) rewrite rule in the PMDF configuration file to handle that domain name; see


Unknown rightslist identifier ... found on channel ... 
      

You do not have the specified rightslist identifier. Check that it is truly intended to be present as a rightslist identifier, rather than simply being a misspelled channel keyword.


Previous Next Contents Index