Category:Email

From Gr88erWiki

Email Accounts

Here we can define the domains for which we want to set up email accounts later on.

To create a new email domain, click on the Add new Domain button. This will lead you to the Mail Domain form with the tab Domain.

Domain

This form contains the following fields:

  • Server: If more than one server is available, you can select the server on which the email domain will be located. It is possible that the email domain is located on another server than the web site domain.
  • Client: Here you select the client that owns the email domain.
  • Domain: Type in the email domain, e.g. example.com (this would lead to email addresses such as user@example.com). It is also possible to fill in subdomains, e.g. sub.example.com, which would result in email addresses such as user@sub.example.com.
  • Spamfilter: Here you can specify if you want to enable the spam filter for this domain, and if so, what spam filter level to use: Non-Paying, Uncensored, Wants all spam, Wants viruses, Normal, Trigger happy, Permissive. The settings for each of these levels are defined under Email > Spamfilter > Policy.
  • Active: This defines whether this email domain is active or not.

DomainKeys Identified Mail (DKIM)

Dkim is a method to digitally sign emails. It is used to validate the origin of an email and a commonly used method to prevent spam. The Email is signed with the private key and the public key is made available in DNS so that a receiving mail server can verify that the email was sent by an authorized mail system. The actual signing of emails is done by the amavis daemon which is also responsible for spam filtering and virus scans in the mail server setup. Click on the [DomainKeys Identified Mail (DKIM)] button in the mail domain form to show the DKIM settings.

  • Enable Dkim: Check this option to enable the DKIM function for all addresses of this domain.
  • DKIM Selector: You can have multiple DKIM key instances, the DKIM selector is the name of the currently used key instance. Most users should leave this at default.
  • DKIM Private-key: This field contains the private key that is used to sign emails. You can either paste an existing key here or press on the Generate DKIM Private-key button to create a new key.
  • DNS-Record: This field shows the DNS-Record that needs to be added to the DNS zone of the domain. When the DNS-zone is managed, then this record will get added automatically, you can see it in the DNS zone record list in the DNS module.
Domain Alias

With domain aliases, you can map one email domain to another one. Let's assume you have created the email domains example.com and yourseconddomain.com, and have also created the email accounts user1@example.com and user2@example.com. Now you want to use the exact same mailboxes for yourseconddomain.com as well, i.e., user1@example.com and user1@yourseconddomain.com as well as user2@example.com and user2@yourseconddomain.com should be identical mailboxes. This can be achieved by mapping yourseconddomain.com to example.com - it can be imagined as a kind of symlink from yourseconddomain.com to example.com.

To create a new domain alias, click on the Add new Domain alias button. This will lead you to the Domain Alias form with the tab Domain Alias.

This form has the following fields:

  • Source: This is the domain that you want to map to another email domain. In our above example, this would be yourseconddomain.com.
  • Destination: This is the email domain that the source domain should be mapped to. In our above example, this would be example.com.
Email Mailbox

This is where we create/modify/delete email accounts.

To create a new email account, click on the Add new Mailbox button. This will lead you to the Mailbox form with the tabs Mailbox, Autoresponder, Mail Filter, Custom Rules, and Backup.

Tabs:  Mailbox · Autoresponder · Mail Filter
Email Alias

An email alias is the same as a domain alias, except that it is used to map an email address to another email address instead of mapping a whole email domain to another email domain.

To create a new email alias, click on the Add new Email alias button. This will lead you to the Email Alias form with the tab Email Alias.

This form has the following fields:

  • Email: This specification is split up in two fields, Alias and Domain. The alias contains the part in front of the @ sign (the "local-part") - it should be an alias that doesn't already exist for this domain -, and in the Domain drop-down menu, you select the email domain. For example, if you want to create the email alias info@example.com, you'd fill in info in the Alias field and select example.com from the Domain drop-down menu.

The local-part of an e-mail address may be up to 64 characters long and the domain name may have a maximum of 255 characters. However, the maximum length of a forward or reverse path length of 256 characters restricts the entire e-mail address to be no more than 254 characters. Some mail protocols, such as X.400, may require larger objects, however. The SMTP specification recommends that software implementations impose no limits on the lengths of such objects.

The local-part of the e-mail address may use any of these ASCII characters:

  • Uppercase and lowercase English letters (a-z, A-Z)
  • Digits 0 to 9
  • Characters ! # $ % & ' * + - / = ? ^ _ ` { | } ~
  • Character . (dot, period, full stop) provided that it is not the first or last character, and provided also that it does not appear two or more times consecutively (e.g. John..Doe@example.com).

Additionally, quoted-strings (e.g. "John Doe"@example.com) are permitted, thus allowing characters that would otherwise be prohibited, however, they do not appear in common practice. RFC 5321 also warns that "a host that expects to receive mail SHOULD avoid defining mailboxes where the Local-part requires (or uses) the Quoted-string form".

The local-part is case sensitive, so "jsmith@example.com" and "JSmith@example.com" may be delivered to different people. This practice is discouraged by RFC 5321. However, only the authoritative mail servers for a domain may make that decision (if you have set up your server according to one of the "Perfect Server" tutorials from HowtoForge.com, then the local part is not case sensitive). The only exception is for a local-part value of "postmaster" which is case insensitive and should be forwarded to the server's administrator.

Within the rules set out in the RFCs, organizations are free to restrict the forms their own e-mail addresses take however they wish, e.g. many organizations do not use certain characters, e.g. space, ?, and ^, and most organizations treat uppercase and lowercase letters as equivalent. Hotmail, for example, only allows the creation of e-mail addresses using alphanumerics, dot (.), underscore (_) and hyphen (-).

Systems that send mail, of course, must be capable of handling outgoing mail for all addresses. Contrary to the relevant standards, some defective systems treat certain legitimate addresses as invalid and fail to handle mail to these addresses. Hotmail, for example, incorrectly refuses to send mail to any address containing any of the following legitimate characters: ! # $ % * / ? ^ ` { | } ~

  • Destination: Select the email account that you want to map this email alias to. If you want to map info@example.com to john.doe@example.com, you'd select john.doe@example.com here. The destination email address is also the SMTP/POP3/IMAP username for the email account.
  • Active: This defines whether this email alias is active or not.
  • Send as: Enable this option to allow the user that is logged in with the target mailbox by SMTP to use this alias address as the sender address.
  • Enable Greylisting: Enable the greylisting function for this alias. Greylisting is a method to prevent SPAM by delaying incoming emails when you receive the first email of an unknown sender. Please see here for a detailed explanation: https://en.wikipedia.org/wiki/Greylisting
Email Forward

With this feature, you can make the mail system automatically forward emails for an email address to one or more other email accounts. For example, you can use this function to define an email address for a group of people, e.g. danceclass@mydancestudio.com, and forward emails to that address to all members of the dance class, like dancer1@firstdomain.com, dancer2@someotherdomain.com, dancer3@yetanotherdomain.com, etc.

To create a new email forward, click on the Add new Email forward button. This will lead you to the Email Forward form with the tab Email Forward.

The form has the following fields:

  • Email: This specification is split up in two fields, Alias and Domain. Alias contains the part in front of the @ sign (the "local-part") - it should be an alias that doesn't already exist for this domain -, and in the Domain drop-down menu, you select the email domain. For example, if you want to create an email forward for the email address danceclass@mydancestudio.com, you'd fill in danceclass in the Alias field and select mydancestudio.com from the Domain drop-down menu.

The local-part of an e-mail address may be up to 64 characters long and the domain name may have a maximum of 255 characters. However, the maximum length of a forward or reverse path length of 256 characters restricts the entire e-mail address to be no more than 254 characters. Some mail protocols, such as X.400, may require larger objects, however. The SMTP specification recommends that software implementations impose no limits on the lengths of such objects.

The local-part of the e-mail address may use any of these ASCII characters:

  • Uppercase and lowercase English letters (a-z, A-Z)
  • Digits 0 to 9
  • Characters ! # $ % & ' * + - / = ? ^ _ ` { | } ~
  • Character . (dot, period, full stop) provided that it is not the first or last character, and provided also that

it does not appear two or more times consecutively (e.g. John..Doe@example.com).

Additionally, quoted-strings (e.g. "John Doe"@example.com) is permitted, thus allowing characters that would otherwise be prohibited, however, they do not appear in common practice. RFC 5321 also warns that "a host that expects to receive mail SHOULD avoid defining mailboxes where the Local-part requires (or uses) the Quoted-string form".

The local-part is case sensitive, so "jsmith@example.com" and "JSmith@example.com" may be delivered to different people. This practice is discouraged by RFC 5321. However, only the authoritative mail servers for a domain may make that decision (if you have set up your server according to one of the "Perfect Server" tutorials from HowtoForge.com, then the local part is not case sensitive). The only exception is for a local-part value of "postmaster" which is case insensitive and should be forwarded to the server's administrator.

Within the rules set out in the RFCs, organizations are free to restrict the forms their own e-mail addresses take however they wish, e.g. many organizations do not use certain characters, e.g. space, ?, and ^, and most organizations treat uppercase and lowercase letters as equivalent. Hotmail, for example, only allows the creation of e-mail addresses using alphanumerics, dot (.), underscore (_) and hyphen (-).

Systems that send mail, of course, must be capable of handling outgoing mail for all addresses. Contrary to the relevant standards, some defective systems treat certain legitimate addresses as invalid and fail to handle mail to these addresses. Hotmail, for example, incorrectly refuses to send mail to any address containing any of the following legitimate characters: ! # $ % * / ? ^ ` { | } ~

  • Destination Email: Fill in one or more email addresses (one email address per line) that the email should be forwarded to.
  • Active: This defines whether this email forward is active or not.
  • Send as: Enable this option to allow the user that is logged in with the target mailbox by SMTP to use this alias address as the sender address.
  • Enable Greylisting: Enable the greylisting function for this alias. Greylisting is a method to prevent SPAM by delaying incoming emails when you receive the first email of an unknown sender. Please see here for a detailed explanation: https://en.wikipedia.org/wiki/Greylisting
Email Catchall

If you want all emails that are addressed to non-existing mailboxes of a domain to arrive in an existing email box of this domain, you can create a catchAll for this email account. Example: You have configured the email address info@example.com. Someone sends an email to abc@example.com which does not exist. If info@example.com is a catchAll email address the email arrives here. If there is no catchAll email address for this domain the sender of the mail to abc@example.com gets back an error message ("error: no such user here"). Please note: Per domain there can be only one catchAll email address.

To create a new email catchAll, click on the Add new Catchall button. This will lead you to the Email Catchall form with the tab Email Catchall.

The form has the following fields:

  • Source: Select the domain for which you want to create a catchAll.
  • Destination: Select the catchAll email account - i.e., the email account that should receive all emails to non-existing email addresses of this domain.
  • Active: This defines whether this email catchAll is active or not.
Email Routing

With the email routing feature, you can define what server mail for a given domain will be forwarded to and by what transport. (This feature is based on Postfix' transport_maps.) This makes it possible to route emails for one domain to a totally different server.

Please note that you have created one or more Relay Recipients (Email > Global Filters > Relay Recipients) for each route that you create so that the system knows it should accept the emails before routing them to another server.

To create a new email route, click on the Add new transport button. This will lead you to the Email Routing form with the tab Email transport.

Email transport

This form has the following fields:

  • Server: If more than one server is available, you can select the server on which the email transport will be located. You should select the server that handles emails for the domain that you want to route to another server (i.e., the server that the domain's MX record points to).
  • Domain: Type in the email domain or email address that you want to route to another server. You can also use an asterisk (*) as a wildcard. You can have just one routing rule per domain (an error message will be shown if you try to add a second rule with the exact same domain), however, if you use an asterisk there can be more than just one routing rule that applies to a domain.
  • Type: Select the transport type (in almost all cases you should use SMTP). Refers to an entry from /etc/postfix/master.cf, so make sure that what you select here exists in /etc/postfix/master.cf.
    • smtp: The Internet standard for transferring email. It uses TCP/IP port 25 and allows for file attachments. You can use the Destination field to specify the destination host. When no Destination is specified, the domain name from the Domain field is used instead.
    • uucp: A UNIX protocol and set of programs most often used to copy files across serial connections and telephone lines. UUCP was often used to transfer email and Usenet news over phone lines when direct Internet connectivity was scarce in small and medium-sized companies. You can use the Destination field to specify the UUCP destination host. When no Destination is specified, the domain name from the Domain field is used instead.
    • slow: This transport has to be defined in your /etc/postfix/master.cf before you can select it. Depending on how your slow transport looks, you might or might not have to specify a Destination.
    • error: The special error transport causes all mail to be rejected. You can use the Destination field to specify an error message such as mail for *.example.com is not deliverable (optional).
    • custom: If you specify a custom transport in /etc/postfix/master.cf, you can use it for your email routing. Depending on how your custom transport looks, you might or might not have to specify a Destination.
    • null: If you select this transport type, all emails will be deleted. You can leave the Destination field empty.
  • No MX lookup: This defines whether Postfix will perform an MX lookup for the destination host or not (see the explanation of the next field, Destination).
  • Destination: The destination host for delivery of messages. The host is used only with inet transports such as SMTP and LMTP. Postfix treats the hostname like any destination domain. It performs an MX lookup to determine where to deliver messages. If there are no MX records, Postfix delivers to the A record IP address. If you know that Postfix should deliver directly to the IP in the A record for the specified host, you can have Postfix skip the check for MX records by checking the No MX lookup checkbox. If you use an IP address, it is required that you check the No MX lookup checkbox. When no Destination is specified, the domain name from the Domain field is used instead. IF you use the error transport, you can specify an error message such as mail for *.example.com is not deliverable here (optional).
  • Sort by: Postfix will process all routing rules from top to bottom and use the first one that applies and will stop then. If you have multiple routing rules that might match a certain situation, you can define the order with this field. A higher number means a higher priority, i.e., if you have two rules that apply, and the first has a priority of 8 and the second a priority of 5, then the first rule will be used by Postfix.
  • Active: This defines whether this email transport is active or not.

Please note that you have created one or more Relay Recipients (Email > Global Filters > Relay Recipients) for each route that you create so that the system knows it should accept the emails before routing them to another server.

Mailing List

To create a new mailing list, click on the Add new record button. This will lead you to the Mailing List form with the tab Mailing List.

Mailing List

The form has the following fields:

  • Client: Select the client that owns the mailing list.
  • Domain: Select the domain to which the mailing list belongs. This is also the list's web interface host name. For example, if you select example.com here, and the list name is testlist, the administration interface for testlist will be at http://example.com/cgi-bin/mailman/admin/testlist, and the web page for users of the mailing list will be at http://example.com/cgi-bin/mailman/listinfo/testlist.
  • Listname: Specify the name of the list. Note that list names are forced to lowercase.
  • Email: Specify the email address of the list administrator. The list administrator will receive an email with all important details about the new mailing list after it was created (see below).
  • Password: Please specify the admin password for the mailing list (or use the Generate Password link).
  • Repeat Password: Confirm your password.

After the list has been created, the list administrator will receive an email with all important details about the new mailing list, for example as follows:

The mailing list `testlist' has just been created for you. The following is some basic information about your mailing list.

Your mailing list password is:

234567890

You need this password to configure your mailing list. You also need it to handle administrative requests, such as approving mail if you choose to run a moderated list.

You can configure your mailing list at the following web page

http://example.com/cgi-bin/mailman/admin/testlist

The web page for users of your mailing list is

http://example.com/cgi-bin/mailman/listinfo/testlist

You can even customize these web pages from the list configuration page. However, you do need to know HTML to be able to do this. There is also an email-based interface for users (not administrators) of your list; you can get info about using it by sending a message with just the word `help' as subject or in the body, to:

testlist-request@example.com

To unsubscribe a user: from the mailing list 'listinfo' web page, click on or enter the user's email address as if you were that user. Where that user would put in their password to unsubscribe, put in your admin password. You can also use your password to change member's options, including digestification, delivery disabling, etc.

Please address all questions to mailman-owner@example.com.

Spamfilter

Whitelist

The whitelist allows you to "whitelist" email sender addresses, i.e., emails from such addresses will never be tagged as spam.

To create a new whitelist, click on the Add Whitelist record button. This will lead you to the Spamfilter Whitelist form with the tab Whitelist.

The form has the following fields:

  • User: Here you can select the recipient email account or even the whole recipient domain for which this whitelist record will be valid - this whitelist record will not be used for other recipient email accounts or domains.
  • Email: Specify the email address whose emails should be whitelisted. You can even whitelist a whole domain by leaving out the local part of the email address - i.e., if you want to whitelist emails from the domain example.com, type @example.com in this field.
  • Priority: If multiple whitelist/blacklist records apply, this field specifies which rule to use first (10 = highest priority, 1 = lowest priority). For example, if you blacklist @example.com with a priority of 5, you could whitelist user@example.com with a priority of 6 so that user@example.com's mails get through while @example.com is blacklisted.
  • Active: This defines whether this whitelist record is active or not.
Blacklist

The blacklist allows you to "blacklist" email sender addresses, i.e., emails from such addresses will always be tagged as spam.

To create a new blacklist, click on the Add Blacklist record button. This will lead you to the Spamfilter blacklist form with the tab Blacklist.

The form has the following fields:

  • User: Here you can select the recipient email account or even the whole recipient domain for which this blacklist record will be valid - this blacklist record will not be used for other recipient email accounts or domains.
  • Email: Specify the email address whose emails should be blacklisted. You can even blacklist a whole domain by leaving out the local part of the email address - i.e., if you want to blacklist emails from the domain example.com, type @example.com in this field.
  • Priority: If multiple whitelist/blacklist records apply, this field specifies which rule to use first (10 = highest priority, 1 = lowest priority). For example, if you blacklist @example.com with a priority of 5, you could whitelist user@example.com with a priority of 6 so that user@example.com's mails get through while @example.com is blacklisted.
  • Active: This defines whether this blacklist record is active or not.

Spamfilter users

This form has the following fields:

  • Server: If more than one server is available, you can select the server on which the record will be located.
  • Priority: If multiple records apply, this field specifies which rule to use first (10 = highest priority, 1 = lowest priority). For example, if you have a record for a whole domain with the priority 5 and a record for a specific email account (from the same domain) with the priority 10, Then the record with priority 10 will override the record with priority 5.
  • Policy: Here you can specify the spam filter level to use: Non-Paying, Uncensored, Wants all spam, Wants viruses, Normal, Trigger happy, Permissive. The settings for each of these levels are defined under Email > Spamfilter > Policy.
  • Email (Pattern): Fill in the email address (e.g. user@example.com) or the domain (with the @ in front, e.g. @example.com), to which the rule should apply.
  • Name: Specify a name for the rule. You can use the email address or domain, but you can as well fill in something else, such as Rule1 etc. This is just for you so that you can distinguish the rules.
  • Local: This specifies if this record is active (Yes) or not (No).
User / Domain

The records that you find here are created automatically when you create a new email domain or email account (not, when you create a domain alias or an email alias), i.e., for all items that have a Spamfilter drop-down menu. These settings tell amavisd when it should scan emails for spam. You can modify these settings here, however, this is usually not necessary. You can also create new records which makes sense for email transports (see Email Routing), domain aliases, and email aliases.

If you create a record for email transport, this allows the system to scan emails even if those emails will be forwarded to another server. Normally, such mails would not be scanned. For domain aliases, there's no automatic record here, and because the record for the target domain doesn't apply to the domain alias, you should create a record if you want emails targetted at the domain alias to be scanned for spam as well.

For email aliases, there's no automatic record here either, and the record for the target email account doesn't apply to the email alias. If there's a record here for the domain of the email alias, then this record applies for the email alias - if there's no record for the domain either, then there's no spam scanning for the email alias at all. If you want spam-scanning settings for the email alias that differ from the domain record or if there's no domain record at all, you can create a record for the email alias here.

What I wrote about the domain aliases and email aliases is true because spam scanning takes place before addresses are rewritten. So if you have the email account user@example.com with spam scanning enabled and the email alias for this mailbox alias@example.com, spam scanning would take place before alias@example.com is rewritten to user@example.com, and because there's no record for alias@example.com, no spam scanning takes place for alias@example.com, while mails for user@example.com are scanned. You can change this behavior by commenting out or removing the line

receive_override_options = no_address_mappings

from /etc/postfix/main.cf (don't forget to restart Postfix) - in this case, address rewriting takes place before spam scanning, which means you don't need extra rules for aliases because the records for the main domain/main email account apply.

To create a new record, click on the Add Spamfilter User button. This will lead you to the Spamfilter users form with the tab Users.

Policy

Here you can modify existing spam levels (Non-Paying, Uncensored, Wants all spam, Wants viruses, Normal, Trigger happy, Permissive) and create new levels, if needed.

To create a new policy, click on the Add Policy record button. This will lead you to the Spamfilter policy form with the tabs Policy, Quarantine, Tag-Level

Tabs:  Policy · Quarantine · Tag-Level

Fetchmail

This feature can be used to retrieve emails from a remote POP3 or IMAP account and put them into a local mailbox. Although this feature is called "Fetchmail" here, Gr88er uses getmail instead of fetchmail under the hood.

To create a new Fetchmail account, click on the Add new Account button. This will lead you to the Get Email form with the tab Get Email.

Fetchmail

Get Email

This form has the following fields:

  • Type: Select the protocol to use to retrieve emails from the remote account (POP3, IMAP, POP3SSL, IMAPSSL).
  • Pop3/Imap Server: Specify the hostname of the remote mail server, e.g. mail.example.com.
  • Username: Specify the username of the remote email account.
  • Password: Specify the user's password.
  • Delete emails after retrieval: Select if you want emails to be automatically deleted on the remote host after they have been retrieved.
  • Retrieve all emails (incl. read mails): By default, only new emails will be retrieved from the remote server. If you check this box, read emails will be retrieved as well.
  • Destination: Select the destination mailbox for the retrieved emails.
  • Active: This defines whether this Fetchmail account is active or not.

Statistics

The Statistics section is a bit special in that there's nothing that you can configure here. This section just displays statistics for your email accounts.

Mailbox quota

Under Mailbox quota you can see used space (in KB) for your email accounts. This feature is available only if you use Dovecot; the mailbox quota report is not available if you use Courier.

Mailbox traffic

Under Mailbox traffic you can see traffic statistics (in MB) for your email accounts for the current month, the month before, the current year, and the year before. Please note that this traffic covers only incoming traffic, not outgoing emails. Traffic statistics are available only if you use Courier; traffic cannot be counted if you use Dovecot.

These statistics are updated once per night.

Backup Stats

Under Backup stats you can see the backup interval, number of backup copies and used space (in MB) for your email account backups.

These statistics are updated once per night.

Pages in category "Email"

The following 4 pages are in this category, out of 4 total.