Email - RoundCube configuration - webmail

This tutorial explains how to configure YetiForce webmail for the use of company emails and free emails.
All the fields of the configuration form will be described.

It is necessary to define:

  1. a list of IMAP servers that users can use to access webmail (Name of IMAP server)
  2. a default SMTP server to use to send emails (Name of SMTP server)

The list of IMAP servers (1) defines which domains can be used for user emails. For example, in addition to the IMAP server of the company domain (eg: imap.thecompanydomain.com), it is possible to allow other domains, such as gmail.com (imap.gmail.com), outlook.com (imap-mail.outlook.com), yahoo.com (imap.mail.yahoo.com) and so on. If the user has got an email address with a domain not included in "Name of IMAP server", the user will not be able to use the YF webmail.
Access to the YF webmail is done in the frontend in "Virtual desk / My mailbox".
The default SMTP server (2) can be configured with global authentication or with simgle authentication:

  • Global authentication
    • Login to SMTP server = <username>
    • Password to SMTP server = <password>
  • Single authentication
    • Login to SMTP server = %u
    • Password to SMTP server = %p

In global authentication case, an account (username / password) must be entered to an specific SMTP server. In this case any user can use this SMTP account to send emails, regardless of which email account they are using. Therefore, any email address can use the default SMTP.
In single authentication, the user can use the default SMTP, if and only if his email address belongs to the same domain as the SMTP server. An example: suppose the default SMTP server is smtp.gmail.com. Only users with email @gmail.com will be able to use the default SMTP. Users with different addresses such as @yahoo.com will need to configure their SMTP server directly in RoundCube / Settings / Identity / SMTP Settings.

Let's go step by step.

Download the RoundCube libraries
The first step to do is to download the RoundCube libraries, that is the YetiForce email management engine.

  1. access the backend (BE) of YetiForce (YF)
  2. go to the page "Standard modules / Modules - Installation"
  3. click on the button at the top right "Download library"
  4. wait a few seconds until the button on the side changes to "Downloaded" (if the library is not downloaded, wait a few hours and try again)

Enable the module "My mailbox"
To check if the "My Mail" module is active:

  1. access the BE of YF
  2. go to the page "Standard modules / Modules - Installation"
  3. search for the "My mailbox" module
  4. if not enabled, check the box alongside

RoundCube configuration

Let's see the configuration field by field.

Name: the name of the configuration. Required field, but useless. In YF 6.0 it will be deleted.
Validate certificate: tick the option if you want to carry out an SSL certificate verification at each access to IMAP. It is recommended not to activate this option to avoid workloads on each operation performed.
Add type and protocol to address: adds the server type (imap) and the protocol (ssl / tls) to the IMAP connection address: usually to be checked, but if the IMAP server does not require type and protocol (i.e. the connection does happens) remove the tick. Unfortunately, the configured IMAP servers must all request the same connection options-path. A mixed situation is not allowed. However, usually, IMAP servers require both type and protocol in the connection address.
Name of IMAP server: List of allowed IMAP server addresses. The address must be entered in the format <protocol>://<domain>, where <protocollo> = ssl or tls; for example, ssl://imap.gmail.com
Port used to connect to IMAP: port on which the IMAP server is listening and accepting connections. The standard IMAP ports are:

  • auth 143
  • ssl 993
  • tls 143

Only one IMAP port can be entered, so all IMAP servers must accept the connection with the same protocol (auth/ssl/tls) and all on the same port (143/993/143). Since only one IMAP port can be specified, a mixed configuration is not allowed, i.e. where an IMAP server uses a port other than the standard one.
Name of SMTP server: default SMTP server address. The address must be entered in the format <protocol>://<domain>, where <protocollo> = ssl or tls; for example, ssl://smtp.gmail.com. This is the default SMTP server used in webmail.
Login to SMTP server ("%u" - login of logged in user): username for authentication to the SMTP server. The ā€œ%u" parameter means that RoundCube uses the webmail authentication username (ie the username for authentication to the IMAP server) as the username for authentication on the default SMTP server.
Password to SMTP server ("%p" - password of logged in user): password for authentication to the SMTP server. The ā€œ%pā€ parameter means that RoundCube uses the webmail authentication password (ie the password for authentication to the IMAP server) as the password for authentication on the default SMTP server.
SMTP port (default 25; 465 for SSL; 587): the port on which the SMTP server is listening and accepting connections. The standard ports for connecting to an SMTP server are:

  • auth 25
  • ssl 465
  • tls 587

Language (RFC 1766 code): en_US, pl_PL: default webmail language. The user can change it in the webmail settings: Settings / Preferences / User interface.
Domain (automatically added to login): domain added to the username (email address) at the webmail login, if the username used does not have a domain (only local-part of the email address).
Logo: logo alternative to RoundCube logo, displayed in the chosen theme (Classic, Larry, YetiForce). In the YetiForce theme, the logo has been removed, so in YetiForce theme it has no influence. If you want to change the logo for the Classic and Larry themes, the logo, in PNG format, must be uploaded to the folders respectively

  • Classic theme: public_html/modules/OSSMail/roundcube/skins/classic/images
  • Larry theme: public_html/modules/OSSMail/roundcube/skins/classic/images

Check IP address of client while giving authorization: RoundCube, during authorization, compares the user's IP address to the one present in the RoundCube authentication authorization cookie.
Spell check module: enables the spell check module as you type.
Level of access to identity: defines how many mail accounts each YF user can manage, and which are the editable parameters:

  • many identities with possibility of editing all parameters: the user can manage multiple email addresses at the same time, being able to change all parameters in RoudCube Settings / Identities
  • many identities with possibility of editing all parameters, but not the email address: the user can manage multiple email addresses at the same time, being able to change all the parameters in RoudCube's Settings / Identities, except the email address
  • one identity with possibility of editing all parameters: the user can use only one email address, being able to change all the parameters in RoudCube's Settings / Identities
  • one identity with possibility of editing all parameters, but not the email address: the user can use only one email address, being able to change all the parameters in RoudCube's Settings / Identities, except the email address
  • one identity with possibility of editing only signature: the user can only use one email address, being able to change only the signature in Settings / Identities of RoudCube

Lifetime of session in minutes: session duration in minutes, after which the user is automatically disconnected from the webmail.

Let's see three different cases:

  1. company email only
  2. only email free
  3. mixed: corporate and free

Configuration with company email only
In this case, assuming that the company domain is thecompanydomain.com, and considering standard configurations for IMAP server and SMTP server, the configuration should be:

  • Add type and protocol to address: yes
  • Name of IMAP server: ssl://imap.thecompanydomain.com
  • Port used to connect to IMAP: 993
  • Name of SMTP server: ssl://smtp.thecompanydomain.com
  • Login to SMTP server: %u
  • Password to SMTP server: %p
  • SMTP port: 465
  • Domain: thecompanydomain.com

Users will be able to access the webmail by specifying only the local-part of the email address: eg 'john.smith' instead of 'john.smith@thecompanydomain.com', since the domain has been specified in the Domain field.
Each user will send with their own account on smtp.thecompanydomain.com
As an alternative, you can set a single, but valid for all, access to SMTP, specifying a username in 'Login to SMTP server' and a password in 'Password to SMTP server'.

Configuration with free email only: Gmail, Yahoo, Outlook, Mail.com and so on
In this case the configuration should be:

  • Add type and protocol to address: yes
  • Name of IMAP server: ssl://imap.gmail.com, ssl://imap.mail.yahoo.com, tls://outlook.office365.com, ssl:// imap.mail.com
  • Port used to connect to IMAP: 993
  • Name of SMTP server: ssl://smtp.gmail.com
  • Login to SMTP server: %u
  • Password to SMTP server: %p
  • SMTP port: 465
  • Domain: <empty>

Only users with GMail emails will be able to send with the default SMTP. Everyone else will need to configure their SMTP in the webmail in the Settings / Identities / SMTP Settings section.
In our example, a user with email other than gmail.com, yahoo.com, office365.com, mail.com will not be able to access the webmail.

Mixed configuration: business email and free email
The configuration should be:

  • Add type and protocol to address: yes
  • Name of IMAP server: ssl://imap.thecompanydomain.com, ssl://imap.gmail.com, ssl://imap.mail.yahoo.com, tls://outlook.office365.com, ssl://imap.mail.com
  • Port used to connect to IMAP: 993
  • Name of SMTP server: ssl://smtp.thecompanydomain.com
  • Login to SMTP server: %u
  • Password to SMTP server: %p
  • SMTP port: 465
  • Domain: thecompanydomain.com

Only users with email @thecompanydomain.com will be able to send emails with the default SMTP and will be able to access the webmail by entering only the local part of the company email address.
All the others, to send, will have to configure their SMTP in the webmail in the Settings / Identities / SMTP Settings section.