Basic Messaging Services for Windows NT and Windows 2000




Version 1-0-1b





MailEnable is a powerful, scalable and cost-effective mail solution for Microsoft Windows NT 4, 2000, XP or greater. MailEnable is designed to provide a mail system based on simplicity, reliability and scalability rather than excessive and often unused functionality.

MailEnable also provides an environment that is very extensible and promotes development through COM Libraries, DLLs and configuration files. Its componentized architecture promotes customization and development, making it a perfect solution if you need to integrate with existing systems.

MailEnable facilitates mail system hosting and can be used by ISPs looking for a cheap/free messaging solution on the Windows platform.

With no client access licenses, free core components, and quick implementation, this is the ideal message solution, whether you are catering for 5 users or 50 thousand.

The purpose of this document is to outline the core components of MailEnable and to provide an overview of its architecture.


The following diagram outlines the core services and connectors that form the basis of MailEnable. This diagram illustrates how the Mail Transfer Agent moves messages between different connectors. The Mail Transfer Agent monitors connector inbound and outbound messages queues, reading in messages and mapping them to other connectors using an address map.

The WWW Service and POP3 Service access the Postoffice Repository (which is usually a shared or replicated file service) and allow users to access and interface with their mailboxes.

From the above diagram, it is simple to see that MailEnable is comprised of Connectors, Agents, Services and Providers.

Mail Transfer Agent

(Windows NT Service)


These are defined in the following table:




Connectors facilitate moving mail between systems or subsystems (whether they be local or remote)


Agents run perform specific management or operating functions for MailEnable itself. An example of an Agent is the Mail Transfer Agent. Its function is to move messages between connectors.


Services expose MailEnable functionality to external agents or programs. An example of a service is the POP3 service. This service allows mail clients to access mail from their postoffice.


Providers are used by Connectors, Agents and Services to allow them to read their configurations. An example of a provider is the Address Map provider. This provider reads the address map that is used to determine mail routing between connectors.

Note: MailEnable Standard does not include webmail or enterprise provisioning.

Each of these system components is described in detail under the following respective headings.


Mail connectors allow mail to be received and sent by Mail Enable. Typically a mail connector allows MailEnable to send a receive mail messages to external systems. MailEnable comes with SMTP, Postoffice and List Connectors.

In some cases mail connectors can relay mail by immediately queuing it for relay. MailEnable’s SMTP Connector is an example of such a connector.

An internal MailEnable address is made of two core parts. Firstly, there is the Connector Descriptor and secondly there is the addressing detail. The exact syntax is shown below:


[Connector Acronym: Connector Address Details]


Mail Enable Internal Address



The location of mailbox (MAILBOX) on postoffice (POSTOFFICE) using the SF Connector (Postoffice Connector)


The SMTP Address of a User at the prescribed domain using the SMTP Connector


The location of list mailbox (LISTNAME) on postoffice (POSTOFFICE) using the LS Connector (List Connector).

When a mail connector receives mail, it resolves the addressed recipients to an internal address format. Some of these recipients will be local, and others will be relayed to non-local users. The connector will produce a command file containing all resolved recipients and a message file containing the actual data. This information is stored in the Connectors Spooling directory.

A Mail Transfer agent is used to take information from the spooling directory and either delivers it to local postoffice mailboxes or queues it for relay to a remote host. We will explain how Mail Transfer Agents are configured later in this document.

3.1 SMTP Connector

The SMTP Connector is responsible for both receiving and delivering mail via the SMTP protocol. This connector is made up of two agents, the inbound agent and the outbound agent. The inbound agent is responsible for accepting messages from mail clients and remote SMTP hosts. The outbound agent is responsible for dispatching any queued mail messages to remote SMTP hosts.

An overview of the SMTP Connector is provided in the sequence diagram to the right.

3.1.1 Inbound Agent

The SMTP Inbound Agent listens on a nominated port (usually port 25) for inbound SMTP mail requests. Once a connection attempt in detected it spawns a new conversation to carry out the mail delivery transaction.

The end result of a successful inbound transaction is a message placed in the SMTP Inbound directory. This message has two parts. Firstly it has the actual message contents, and secondly it has a matching configuration file containing the internally resolved and externally relayed recipients.

This message then waits for a mail transfer agent to deliver the spooling message to the local and relayed users specified in the configuration file.

3.1.2 Outbound Agent

The outbound agent polls an outbound message queue for unsent messages. When it finds an unsent message it spawns a delivery conversation thread. This conversation thread interprets the message command file and attempts to deliver the message to the specified recipients. The outbound agent expects that a message command file relates to a single delivery domain. It is the responsibility of the Mail Transfer agent to ensure this.

If a message cannot be delivered to a recipient, it is requeued for up to 10 times. The message will be reset every 3 hours and the mail agent will continue to attempt message delivery for up-to 3 days. If the message is older than 3 days, the message is returned to the sender. For each unsuccessful batch of delivery attempts (usually 10) the originator of the message is notified that the message delivery has been delayed.

3.2 Postoffice (SF) Connector

The Postoffice Connector is responsible for receiving and delivering mail to Postoffices. When a message arrives to the Postoffice Connector, we need to determine whether it is targeted to a group or a mailbox.

If the message is addressed to a group, we need to expand the group and feed the message back into the postoffice connectors outbound message queue for further processing.

(The MTA will pick the message up and route it back to the Postoffice Connector as necessary).

If the message is destined for a mailbox, the Postoffice Connector needs to determine if there are any rules that need to be applied to the message. For example, the mailbox owner may have nominated that messages be forwarded to another address.

The Mail Transfer Agent (MTA) is responsible for the internal of routing of messages between connectors.

3.2.1 Groups

Groups are implemented by having a file that lists the names of any groups that are registered on the system. Mail items within groups are defined using internal address formats.

Internal Address formats are defined as follows:

[Address Type Qualifier:Address Specifiers]

As a result, a group file could contain internal users as well as external users. So the contents of a group configuration file could look something like this:

Internal Address Format



Local Postoffice Mailbox User


External SMTP User


Local Postoffice Group

So, once we detect a group e-mail address in an incoming message, we need to look it up to determine who the recipients are. The steps for working this out are as follows:

We open the DomainMap file under the postoffices directory and determine if we are hosting the domain. If we are then we need to determine if the address is for a user or a group. We do this by opening the group map file under the postoffice.
If the SMTPAddress of the group is located in this file then we need to get the name of the groupfile that contains the addresses.
We open this file and read each line in the file determining whether the address is a local or external address. We will the buffer of recipients with this information.
3.3 List Server Connector

MailEnable contains a list server that enables people to subscribe and unsubscribe to mailing lists. A list is an online discussion group or information mailout, where emails are sent out to all the members. People are able to post to the list, and the server will duplicate their email and send it out to all the members.

Unmoderated lists allow messages to be posted straight away instead of going via the moderator, who can stop the message from being posted.

The following diagram outlines the implementation of MailEnable’s List Server Connector.

When a message arrives in the List Server Connector’s Outbound Queue (typically via the MTA), its message command file is opened.

The system uses the address of the list to determine whether the list is moderated. If the list is moderated and the message is coming from the moderator, it is preprocessed (headers and footers added) and sent to all the recipients in the corresponding list-member file.

Otherwise, the list is routed to the moderator

4.1 Mail Transfer Agent

The Mail Transfer Agent (MTA) is a Windows Service responsible for:

Receiving Inbound Messages from Mail Connectors
Delivering Mail to Local Mailboxes
Queuing Mail for Relay to other Mail Connectors (Including themselves, as in SMTP Relay)

The example below outlines the typical contents of a queued command message:





4.1.1 Address Resolution

Each message for the MTA contains the Sender and the recipients of the message. The MTA looks at the recipients of each message and resolves them to messages to translated addresses. It then prepares a message for each connector containing only the recipients that have been mapped to the connector.

When a message is picked up by the MTA and it cannot be resolved to a connector it is placed in the Bad Mail directory and a Non Delivery Report (NDR) is sent to the sender.

The following sequence is applied by the MTA:

1. MTA needs to check for all the exact matches first, and we prepare a message for each recipient and each connector.
2. If it cannot exact match, we will need to check for a generic handler, ie relay to connector. We need to be able to allow a message to be relayed to the connector itself.

For example, an entry in the address map as [SMTP:*] [SMTP:*] will relay a message through the MTA from SMTP gateway to SMTP gateway for the domain name “”. Likewise, [SMTP:*] [SF:ACTIVEMEDIA/ADMIN] will send all mail from one domain to a nominated mailbox.

This means that we need to check every item in the list until we find a mask that matches our address.

3. If the message could not be resolved and the message there is no default mail handler, the message is placed in the bad-mail directory. The MTA will send a return path message to the originator as it is bad-mailed.
4.1.2 Transfer Events

When mail is picked up or dispatched by the mail transfer agent, specific events can fire to facilitate the processing of messages as they are moved between connectors. For example, the MTA may wish to check a message for viruses as it is moved between connectors.

Lets assume that a message is arriving through the SMTP connector for delivery to the local postoffice. In this scenario, the MTA attempts to pick up the mail message and deliver it to the appropriate connector. The MTA can optionally execute a program either when it attempts to pick up the message from a connector, or when it attempts to deliver the message to a new connector. It should also be noted that specific connectors may also be configured to perform the same function, although, in most cases, it is best if it is handled by the MTA (because it is simpler to configure an instance of the MTA rather than a potential array of MailEnable connectors).


Mail Enable is available with two mail services. These are the POP3 Service and the Web Mail Service.

5.1 POP3 Service

The POP3 Service allows mail users to access their mailbox and download messages from the servers Inbox to their local storage.

5.2 WebMail Service

Mail Enable Professional edition provides access to web mail services. Web Mail is not available with the Standard edition at this point in time.


Providers are used to control MailEnable configuration settings. Providers are used to configure MailEnable to store details in Tab Delimited file, Databases, etc. The default provider that comes with MailEnable Standard is the TAB Delimited Provider. This section outlines the configuration settings for Mail Enable Tab Delimited configuration providers, beyond those made available in the supplied administration application.

There are three primary configuration providers. These are outlined in the following table:

Provider Name


Postoffice Configuration Provider

Storage of Postoffice and Mailbox Configuration Data

SMTP Configuration Provider

Domain and Connector Configuration Data

Address Map Configuration Provider

Storage of Addresses Mapping Data

Authentication Configuration Provider

Authentication of user credentials and permissions

List Server Configuration Provider

List Names, Addresses, Members, etc.

Directory Provider

Allows a list of addresses to be defined for use by MailEnable applications.

6.1 Tab Delimited Configuration Provider

This table lists all the Tab Delimited Provider configuration files and their function.




IPAddress Access Authorization File


This file contains a list of masks that defines who can use the SMTP gateway for the nominated right defined in this file.

IPAddress Deny Authorization File


This file contains a list of masks that defines who cannot use the SMTP gateway for the nominated right defined in this file

Postoffice Groups File


This file is used to define the SMTP Addresses of any groups and point to a file for each that lists the members.

Group Membership File


This file keeps a list of all the members in a group.

Domain File


This file is used to map an SMTP Domain to a local Postoffice and to store all details for a nominated SMTP Domain. It also allows mail to be redirected or forwarded to an array of hosts. This is used in preference to DNS Resolution

Address Mapping File


This file is used to map an SMTP Address to a local Account on the specified postoffice.

Authorization File


This file is used to store the user is and passwords for accessing the system and mailboxes

Mailbox File


This file is used to store the details for a postoffice mailbox. It also allows mail to be be redirected from an internally formatted address. Eg: [SMTP:sss@sss.sss.sss] or [SF:POSTOFFICE/MAILBOX]

SMTP Connector Configuration Files

File Name





TargetDomainName, BannedDomainName, Status, Account



AddressMask,Status,SMTPAccess, Right, Account



AddressMask,Status,SMTPAccess, Right, Account



DomainName, Status, RedirectionStatus, RedirectionHosts, Account

Postoffice Connector Configuration Files

File Name





Name,Status, Account



Mailbox, Status, Size, RedirectStatus, RedirectAddress



RecipientAddress, GroupName




Authentication Provider Configuration Files

File Name





UserName, Status, Password, Account, Rights, Description

Address Map Provider Configuration Files

File Name





SourceAddress, DestinationAddress, Scope, Account


For more information please visit the MailEnable web site: ( ).

Alternatively, you can email us at . To assist us, we would ask that you use the MailEnable Diagnostics to take a snapshot of your configuration and send us either the whole file, or those sections that supplement your query. The MailEnable Diagnostic utility is installed under the MailEnable program group. It is also available for download from the MailEnable web site.