|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object SK.gnome.dwarf.GenericService SK.gnome.dwarf.ParametersService SK.gnome.dwarf.mail.smtp.SMTPParameters
Provides the SMTP-related parameters.
An instance of this class may be added to the SMTPServer
to provide
a set of the SMTP-related runtime parameters. The parameters are by default available
to the server and all its nested services.
Each parameter is represented by a protected field with its setter and getter methods, which can be used to access the parameter from the outside world.
Note that some of the parameters are read-only while others may be modified in runtime either via the server console, or programatically.
Field Summary | |
protected SK.gnome.dwarf.tcpip.InetHostSet |
authClients
List of clients which must always authenticate for any SMTP command. |
protected java.lang.String[] |
authMethods
The actually available authentication methods. |
protected SK.gnome.dwarf.tcpip.InetHostSet |
authRelayClients
List of clients for which the SMTP relaying is enabled if they authenticate themselves first. |
protected java.lang.String[] |
autoRunNodes
List of nodes which will be automatically processed each time a message arrives to the queue. |
protected boolean |
caseSensitiveMailbox
Whether the local user names should be regarded case-sensitive. |
protected int |
clientTimeout
Client inactivity timeout. |
protected java.lang.String |
defaultRelay
Default SMTP relay which will be used to route the outgoing messages. |
protected int |
deferredDeliveryTimeout
After this time in hours a message will be considered undeliverable if it is targeted for a deferred node. |
protected java.lang.String[] |
deferredNodes
List of nodes which are deffered by default. |
protected int |
deliveryInterval
Interval in seconds of the particular delivery attempts for a single message. |
protected int |
deliveryTimeout
After this time in hours a message will be considered undeliverable. |
protected int |
deliveryWarningTimeout
After this time in hours a DSN warning will be issued for an undelivered message if the failure reason is regarded as temporary. |
protected java.lang.String[] |
etrnNodes
List of nodes for which the ETRN command is enabled. |
protected java.lang.String[] |
extensions
The actually available SMTP extensions. |
protected java.lang.String |
hostName
The host name of the server. |
protected boolean |
identifyUser
Whether the local user existence will be tested using the system authentication facility. |
protected boolean |
insecureLoginDisabled
Whether to allow the transfer of cleartext passwords via insecure connections. |
protected int |
loginDelay
The delay after a failed login. |
protected int |
maxMessageSize
Maximum allowed size of a single message in bytes. |
protected int |
maxRecipients
Maximum allowed number of recipients in a single message. |
protected SK.gnome.dwarf.tcpip.InetHostSet |
noAuthClients
List of clients which will be rejected even if they are implied by authClients . |
protected SK.gnome.dwarf.tcpip.InetHostSet |
noAuthRelayClients
List of clients for which the SMTP relaying will be rejected even if they are implied by authRelayClients . |
protected boolean |
notifyIfRemoteDSN
Whether the DSN notifications will be created for failed delivery attempts even if the remote SMTP host reports that it supports DSN, too. |
protected boolean |
notifyPostmaster
Whether the DSN notifications will be sent to the postmaster address, too. |
protected java.lang.String[] |
rejectFrom
List of sender addresses which will always be rejected. |
protected java.lang.String[] |
rejectTo
List of recipient addresses which will always be rejected. |
protected SK.gnome.dwarf.tcpip.InetHostSet |
relayClients
List of clients for which the SMTP relaying is enabled. |
protected boolean |
sendServerInfo
Enables or disables exposing of the server name and version to the client. |
protected int |
serverTimeout
Remote server inactivity timeout. |
Fields inherited from class SK.gnome.dwarf.GenericService |
initParameters, parent |
Fields inherited from interface SK.gnome.dwarf.Service |
INITIALIZED, LOG_DEBUG, LOG_ERROR, LOG_FATAL, LOG_INFO, LOG_TRACE, LOG_WARN, LOG_XFER, SHUTDOWN, STARTED, STOPPED |
Constructor Summary | |
SMTPParameters(java.lang.String name)
Creates a new SMTPParameters. |
Method Summary | |
boolean |
containsAuthMethod(java.lang.String method)
|
boolean |
containsAutoRunNode(java.lang.String node)
|
boolean |
containsDeferredNode(java.lang.String node)
|
boolean |
containsEtrnNode(java.lang.String node)
|
boolean |
containsExtension(java.lang.String extension)
|
boolean |
containsRejectFrom(java.lang.String addr)
|
boolean |
containsRejectTo(java.lang.String addr)
|
java.lang.String[] |
getAllAuthMethods()
|
java.lang.String[] |
getAllExtensions()
|
SK.gnome.dwarf.tcpip.InetHostSet |
getAuthClients()
|
java.lang.String[] |
getAuthMethods()
|
SK.gnome.dwarf.tcpip.InetHostSet |
getAuthRelayClients()
|
java.lang.String[] |
getAutoRunNodes()
|
boolean |
getCaseSensitiveMailbox()
|
int |
getClientTimeout()
|
java.lang.String |
getDefaultRelay()
|
int |
getDeferredDeliveryTimeout()
|
int |
getDeliveryInterval()
|
int |
getDeliveryTimeout()
|
int |
getDeliveryWarningTimeout()
|
java.lang.String[] |
getExtensions()
|
java.net.InetAddress |
getHostAddress()
|
java.lang.String |
getHostName()
|
boolean |
getIdentifyUser()
|
boolean |
getInsecureLoginDisabled()
|
int |
getLoginDelay()
|
int |
getMaxMessageSize()
|
int |
getMaxRecipients()
|
SK.gnome.dwarf.tcpip.InetHostSet |
getNoAuthClients()
|
SK.gnome.dwarf.tcpip.InetHostSet |
getNoAuthRelayClients()
|
boolean |
getNotifyIfRemoteDSN()
|
boolean |
getNotifyPostmaster()
|
java.lang.String |
getPostmasterAddress()
|
SK.gnome.dwarf.tcpip.InetHostSet |
getRelayClients()
|
boolean |
getSendServerInfo()
|
int |
getServerTimeout()
|
void |
init(SK.gnome.dwarf.Server parent)
Initialized the service. |
void |
setAuthClients(SK.gnome.dwarf.tcpip.InetHostSet hosts)
|
void |
setAuthMethods(java.lang.String[] methods)
|
void |
setAuthRelayClients(SK.gnome.dwarf.tcpip.InetHostSet hosts)
|
void |
setAutoRunNodes(java.lang.String[] nodes)
|
void |
setCaseSensitiveMailbox(boolean enable)
|
void |
setClientTimeout(int timeout)
|
void |
setDefaultRelay(java.lang.String addr)
|
void |
setDeferredDeliveryTimeout(int timeout)
|
void |
setDeferredNodes(java.lang.String[] nodes)
|
void |
setDeliveryInterval(int interval)
|
void |
setDeliveryTimeout(int timeout)
|
void |
setDeliveryWarningTimeout(int timeout)
|
void |
setEtrnNodes(java.lang.String[] nodes)
|
void |
setExtensions(java.lang.String[] extensions)
|
void |
setHostName(java.lang.String name)
|
void |
setIdentifyUser(boolean enable)
|
void |
setInsecureLoginDisabled(boolean enable)
|
void |
setLoginDelay(int delay)
|
void |
setMaxMessageSize(int size)
|
void |
setMaxRecipients(int max)
|
void |
setNoAuthClients(SK.gnome.dwarf.tcpip.InetHostSet hosts)
|
void |
setNoAuthRelayClients(SK.gnome.dwarf.tcpip.InetHostSet hosts)
|
void |
setNotifyIfRemoteDSN(boolean enable)
|
void |
setNotifyPostmaster(boolean enable)
|
void |
setRejectFrom(java.lang.String[] addrs)
|
void |
setRejectTo(java.lang.String[] addrs)
|
void |
setRelayClients(SK.gnome.dwarf.tcpip.InetHostSet hosts)
|
void |
setSendServerInfo(boolean enable)
|
void |
setServerTimeout(int timeout)
|
Methods inherited from class SK.gnome.dwarf.ParametersService |
readOnly, report |
Methods inherited from class SK.gnome.dwarf.GenericService |
getAuthenticator, getAuthFacility, getFullName, getInitParameter, getInitParameterNames, getLogFacility, getLogger, getName, getParameters, getPrincipal, getShutdownTimeout, getState, log, log, login, logout, setAuthFacility, setInitParameters, setLogFacility, shutdown, start, stop, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected java.lang.String hostName
It must be a resolvable name of the host which the server is running on.
This parameter is read-only.
Default value: the local host name, if available
protected java.lang.String defaultRelay
If null the server will do the mail routing by itself.
protected SK.gnome.dwarf.tcpip.InetHostSet relayClients
Default value: all hosts from the local network
protected SK.gnome.dwarf.tcpip.InetHostSet authClients
protected SK.gnome.dwarf.tcpip.InetHostSet noAuthClients
authClients
.
protected SK.gnome.dwarf.tcpip.InetHostSet authRelayClients
protected SK.gnome.dwarf.tcpip.InetHostSet noAuthRelayClients
authRelayClients
.
protected java.lang.String[] rejectFrom
The sender address is obtained from the SMTP envelope, not from the message header.
Default value: {}
protected java.lang.String[] rejectTo
The recipient address is obtained from the SMTP envelope, not from the message headers.
Default value: {}
protected boolean notifyPostmaster
Default value: true
protected boolean notifyIfRemoteDSN
This may cause that the DSN messages will be generated by both the sending and receiving server if the message delivery fails for any reason, but it guarantees that the error message will be created in any case.
Default value: false
protected int clientTimeout
Specifies the client inactivity timeout in seconds. After this time the server will automatically close the idle connection.
Default value: 600
protected int serverTimeout
Specifies the server inactivity timeout in seconds. After this time the client will automatically close the connection.
Default value: 600
protected boolean sendServerInfo
This parameter is read-only.
Default value: false
protected int maxRecipients
Default value: 100
protected int maxMessageSize
This parameter is read-only.
Default value: 2 MB
protected java.lang.String[] extensions
This parameter is read-only.
Default value: AUTH, DSN, SIZE, STARTTLS
protected java.lang.String[] authMethods
This parameter is read-only.
Default value: LOGIN, PLAIN
protected boolean insecureLoginDisabled
If enabled the server will not allow to authenticate via a method which uses cleartext passwords unless the session is secured by an encryption mechanism. The LOGIN command and the AUTHENTICATE command with LOGIN or PLAIN methods are examples of such prohibited means.
Default value: false
protected int loginDelay
This value in seconds specifies how long will server wait for accepting another login request in the same session after a failed one. This feature may prevent some sort of attacks against the server.
Default value: 5
protected java.lang.String[] etrnNodes
This parameter is read-only.
Default value: {}
protected java.lang.String[] deferredNodes
A deferred node is never processed on a regular queue scan. Instead, it must be run by issuing a special console command, or remotelly via the ETRN protocol extension, if enabled.
This parameter is read-only.
Default value: {}
protected java.lang.String[] autoRunNodes
This parameter is read-only.
Default value: {}
protected int deliveryInterval
This parameter is read-only.
Default value: 300
protected int deliveryTimeout
This parameter is read-only.
Default value: 120
protected int deferredDeliveryTimeout
This parameter is read-only.
Default value: 336
protected int deliveryWarningTimeout
This parameter is read-only.
Default value: 4
protected boolean caseSensitiveMailbox
It is highly recommended to keep this feature disabled.
This parameter is read-only.
Default value: false
protected boolean identifyUser
If this parameter is enabled, the existence of a local user will be tested by using the identification feature provided by the Dwarf-based login modules. If your login module does not provide this feature, or it is not based on the Dwarf framework, or the underlying authentication mechanism is completely different, you will have to set this parameter to false. In that case, the server will test the local user presence by simply checking whether a mail store exists for that user. That means you will have to create a mail store for each local user prior to delivering any mail message to the mailbox.
This parameter is read-only.
Default value: false
Constructor Detail |
public SMTPParameters(java.lang.String name)
Method Detail |
public void init(SK.gnome.dwarf.Server parent) throws SK.gnome.dwarf.ServiceException
SK.gnome.dwarf.ServiceException
public java.lang.String[] getAllExtensions()
public java.lang.String[] getAllAuthMethods()
public java.lang.String getHostName()
public java.net.InetAddress getHostAddress()
public void setHostName(java.lang.String name)
public java.lang.String getPostmasterAddress()
public java.lang.String getDefaultRelay()
public void setDefaultRelay(java.lang.String addr)
public SK.gnome.dwarf.tcpip.InetHostSet getRelayClients()
public void setRelayClients(SK.gnome.dwarf.tcpip.InetHostSet hosts)
public SK.gnome.dwarf.tcpip.InetHostSet getAuthClients()
public void setAuthClients(SK.gnome.dwarf.tcpip.InetHostSet hosts)
public SK.gnome.dwarf.tcpip.InetHostSet getNoAuthClients()
public void setNoAuthClients(SK.gnome.dwarf.tcpip.InetHostSet hosts)
public SK.gnome.dwarf.tcpip.InetHostSet getAuthRelayClients()
public void setAuthRelayClients(SK.gnome.dwarf.tcpip.InetHostSet hosts)
public SK.gnome.dwarf.tcpip.InetHostSet getNoAuthRelayClients()
public void setNoAuthRelayClients(SK.gnome.dwarf.tcpip.InetHostSet hosts)
public boolean containsRejectFrom(java.lang.String addr)
public void setRejectFrom(java.lang.String[] addrs)
public boolean containsRejectTo(java.lang.String addr)
public void setRejectTo(java.lang.String[] addrs)
public boolean getNotifyPostmaster()
public void setNotifyPostmaster(boolean enable)
public boolean getNotifyIfRemoteDSN()
public void setNotifyIfRemoteDSN(boolean enable)
public void setClientTimeout(int timeout)
public int getClientTimeout()
public void setServerTimeout(int timeout)
public int getServerTimeout()
public boolean getSendServerInfo()
public void setSendServerInfo(boolean enable)
public int getMaxRecipients()
public void setMaxRecipients(int max)
public int getMaxMessageSize()
public void setMaxMessageSize(int size)
public java.lang.String[] getExtensions()
public boolean containsExtension(java.lang.String extension)
public void setExtensions(java.lang.String[] extensions)
public java.lang.String[] getAuthMethods()
public boolean containsAuthMethod(java.lang.String method)
public void setAuthMethods(java.lang.String[] methods)
public void setInsecureLoginDisabled(boolean enable)
public boolean getInsecureLoginDisabled()
public int getLoginDelay()
public void setLoginDelay(int delay)
public boolean containsEtrnNode(java.lang.String node)
public void setEtrnNodes(java.lang.String[] nodes)
public boolean containsDeferredNode(java.lang.String node)
public void setDeferredNodes(java.lang.String[] nodes)
public java.lang.String[] getAutoRunNodes()
public boolean containsAutoRunNode(java.lang.String node)
public void setAutoRunNodes(java.lang.String[] nodes)
public void setDeliveryInterval(int interval)
public int getDeliveryInterval()
public void setDeliveryTimeout(int timeout)
public int getDeliveryTimeout()
public void setDeferredDeliveryTimeout(int timeout)
public int getDeferredDeliveryTimeout()
public void setDeliveryWarningTimeout(int timeout)
public int getDeliveryWarningTimeout()
public boolean getCaseSensitiveMailbox()
public void setCaseSensitiveMailbox(boolean enable)
public boolean getIdentifyUser()
public void setIdentifyUser(boolean enable)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |