Please enable JavaScript to view this site.

A-Shell Reference

Navigation: Subroutines > EMAILX

EMAILX Config File

Scroll Prev Top Next More

Updated June 2023; see History

The EMAILX configuration file is designed to contain those parameters which are most likely to be user-definable yet constant for a given site or application. The file is normally called emailx.cfg, although you specify the name (and location; there is no search path) yourself in the EMAILX statement. The file is a typical text configuration file, and it uses this syntax:

<parameter name> = <value> ; <optional comment>

Note that the config file paramters are case INsensitive.

Parameters

Parameter

Description

ADDBCC

Any number of ADDBCC directives may be specified, each with a single unadorned email address, for example "ADDBCC=eavesdropper@bigbrother.com."

AUTH

SMTP Authentication.

CONNLOCK

The only option is 1 (CONNLOCK=1), which uses a system lock to limit usage to only one SMTP session—i.e. to prevent multiple users from making simultaneous connections to the SMTP server. Typically unnecessary.

DOMAIN

DOMAIN is a strictly optional parameter which specifies the domain to be added to any unqualified address, thus allowing you to abbreviate the addresses, say, for your local company by dropping the @ and everything after it. For example, if DOMAIN=microsabio.com, then if you specify the address "admin" in the to or from fields, it will automatically be expanded to "admin@microsabio.com".

HOST

HOST fulfills the same purpose here as it does in the subroutine parameter list, and is used only if HOST is blank or not specified in the subroutine. This is typically your domain name, and is used to identify your computer or domain to the SMTP server when making the initial connection. Theoretically, the SMTP server may decide to accept or reject you based on whether it recognizes or can resolve this domain name.

LOGFILE

Log file name

LOGLVL

Log level

PASSWORD

Password.

REDIRECT

REDIRECT provides an easy way to temporarily redirect ALL outgoing mail to a specified address for testing purposes. Note that the original To, CC, and BCC addresses will remain in the header, but will all be changed to the redirect address for actual routing purposes. For example: REDIRECT = me@mydomain.com

REPLYTO

REPLYTO is an important parameter often confused with the return address. This is where mail will be sent if the reader clicks the "Reply" button in their email client. It may or may not be the same as the address of the person (or cyber-entity) that actually sent the message. If specified, it inserts a line in the message header reading "Reply-To: " followed by the specified address.

RTNADDR

Return address

SECUREHELLO

Enable/Disable secure EHLO message

SECURE

Type of secure connection.

SERVER

SMTP server name

SIGNATURE

Signature file

USERNAME

USERNAME fulfills the same purpose here as it does in the subroutine parameter list, and is used only if the AUTH parameter is specified, and the USERNAME is blank or not specified in the subroutine.

WAIT

Maximum wait for SMTP response

WAIT2

Similar to WAIT, but units are milliseconds (default=200) rather than seconds, and applies only to packets received after the first response to the HELO/EHLO command. Normally, once the first packet of a response to a command is received, any additional packets are received without delay. But in the case of HELO/EHLO, the server typically responds with an extended list of supported options, sometimes with small delays between them.

 

 

Sample

;EMAILX.SBX configuration file

 

WAIT      = 10                      ; max wait (secs) for SMTP response

SERVER    = localhost               ; SMTP server

SECURE    = STARTTLS                ; use STARTTLS protocol

AUTH      = *                       ; SMTP auth mode (LOGIN or PLAIN)

USERNAME  = yo@micasa.com           ; SMTP login username

PASSWORD  = secret                  ; SMTP login password

HOST      = microsabio.com           ; HELO (sending domain)

DOMAIN    = microsabio.com           ; default domain to add to unqualified addrs

RTNADDR   = ashell@microsabio.com   ; return address (default FROM address)

REPLYTO   = replyto@microsabio.com  ; default Reply-To address

SIGNATURE = EMAILX.SIG              ; signature file (text, amos or native spec)

LOGFILE   = EMAILX.LOG              ; log file name (amos or native)

LOGLVL    = 3                       ;

 

History

2023 June, A-Shell 6.5.1732, EMAILX.SBX(144):  Support multiple ADDBCC parameters

2018 December, A-Shell 6.5.1651, EMAILX.SBX(139):  Add parameters ADDBCC and REDIRECT