Managing Domains
Note
Domains can be managed via the API as well.
Adding a Domain
Domains can be added by either importing them using a YAML file, via the API
or by adding them using the Add domain form.
To add a domain by import refer to Import domains in to an organization. To add a domain via the API refer to the API documentation.
To add a domain using the Add domain form,
- Mouse over or Click 
Domains - Click 
Add a domain - Enter the domain details
 - Click the 
Add domainButton 
Updating a Domain
- Click 
Domains - Select the domain > Click 
Editunder actions - Update the details you want to change
 - Click the 
Update DomainButton 
Deleting a Domain
- Click 
Domains - Select the domain > Click the 
Domain name - Click 
Delete domain - Click the 
Delete DomainButton 
Exporting Domains
Domains can be exported to YAML, To export domains.
- Click 
Domains - Click 
Export Domains - Click 
Download the yaml file - Save the YAML file to your computer
 
Domain Settings
Each domain has a range of additional settings that you can configure. These include Delivery Servers, User Delivery Servers, SmartHosts, Authentication Settings, Alias Domains, DKIM, Signatures
Delivery Servers
Delivery servers are the actual mail servers hosting the email accounts where messages processed by Baruwa need to be delivered.
Multiple servers per domain are supported and they can be configured to either
load balance or fail over.
In load balance mode mail is sent to the group of servers in a round robin
manner while in fail over mail is sent to the first in the list and only to
the others if the first is not available.
Adding a delivery server
- Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
Add delivery server - Enter server IP address or Hostname in the 
Server addressfield - Select the protocol in the 
Protocoldrop down - Change the port in the 
Portfield if your mail server does not use port 25 - Ensure the 
Enabledcheckbox is checked - Click the 
Add serverbutton 
Editing a delivery server
- Click 
Domains - Select the domain > Click the 
Domain name - Scroll to the bottom
 - Select the 
delivery server> ClickEdit - Make changes
 - Click the 
Update serverbutton 
Deleting a delivery server
- Click 
Domains - Select the domain > Click the 
Domain name - Scroll to the bottom under 
Delivery Servers - Select the 
delivery server> ClickDelete - Click the 
Delete serverbutton 
User Delivery Servers
User Delivery servers are used to support split delivery of mail for users on a per user basis.
Multiple servers per domain are supported. The User Delivery servers are added to the domain to make them available for assignment to users within the domain.
Adding a User delivery server
- Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
Add User Delivery Server - Enter server IP address or Hostname in the 
Server addressfield - Select the protocol in the 
Protocoldrop down - Change the port in the 
Portfield if your mail server does not use port 25 - Ensure the 
Enabledcheckbox is checked - Click the 
Add serverbutton 
Editing a User delivery server
- Click 
Domains - Select the domain > Click the 
Domain name - Scroll to the bottom
 - Select the 
User delivery server> ClickEdit - Make changes
 - Click the 
Update serverbutton 
Deleting a User delivery server
- Click 
Domains - Select the domain > Click the 
Domain name - Scroll to the bottom under 
User Delivery Servers - Select the 
delivery server> ClickDelete - Click the 
Delete serverbutton 
SmartHosts
SmartHosts are used to route outbound email via a SmartHost as opposed to routing it via the DNS based lookup of the MX record.
Multiple SmartHosts per domain are supported.
Adding a SmartHost
- Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
Add SmartHosts - Enter server IP address or Hostname in the 
Server addressfield - Change the port in the 
Portfield if your mail server does not use port 25 - Enter a description of the SmartHost
 - Enter the 
SMTP-AUTH usernameandSMTP-AUTH passwordandRetype Passwordif usingSMTP-AUTH. - Ensure the 
Require TLScheckbox is checked if usingSMTP-AUTHor service uses TLS. - Ensure the 
Enabledcheckbox is checked - Click the 
Add SmartHostbutton 
Editing a SmartHost
- Click 
Domains - Select the domain > Click the 
Domain name - Scroll to the bottom
 - Select the 
SmartHost> ClickEdit - Make changes
 - Click the 
Update SmartHostbutton 
Deleting a SmartHost
- Click 
Domains - Select the domain > Click the 
Domain name - Scroll to the bottom under 
SmartHosts - Select the 
SmartHost> ClickDelete - Click the 
Delete SmartHostbutton 
Authentication Settings
Authentication settings allow users within a domain be be authenticated to an external authentication system.
Administrative accounts can not be configured to use external authentication.
This can be used for centralized user management and to allow users to use existing authentication credentials instead of creating duplicate accounts on the Baruwa system.
The supported external authentication mechanisms include:
AD/LDAPSMTPPOP3IMAPRADIUSSAML2
The following mechanisms are planned but have not been implemented yet:
OAUTH
The AD/LDAP mechanism allows for the user details in the directory to be automatically updated to the Baruwa account created for them. These details include:
First nameLast namePrimary Email AddressAlias Email Addresses
Adding Authentication Settings
- Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
Add Authentication settings - Enter server IP address or Hostname in the 
Server addressfield - Select the Authentication protocol in the 
Protocoldrop down - Enter the port in the 
Portfield - Ensure the 
Enabledcheckbox is checked - Check the 
Split addresscheckbox if the username does not contain the domain part - Enter a username map template if your usernames require translation e.g
Webmincreates usernames likedomainowner.usernamethe template would bedomainowner.%(user)sFor available variables see Username map template variables - Click the 
Addbutton 
The AD/LDAP, SAML2 and RADIUS mechanisms require additional settings
which can be added by Adding AD/LDAP Authentication additional settings, Adding SAML2 Authentication additional settings
and Adding RADIUS Authentication additional settings.
Username map template variables
Username map templates allow you to map Baruwa logins to complex user naming
schemes such as those used by web hosting control panels for virtual accounts.
The following variables are available to your username map template:
%(user)s- replaced by user part of the login%(domain)s- replaced by the domain part of the login
Adding AD/LDAP Authentication additional settings
AD/LDAP authentication requires the following additional setting.
Base DN- The LDAP Directory Base DNUsername attribute- The username attribute, defaults touidEmail attribute- The email attribute, defaults tomailBind DN- The BIND DN if Directory does not allow anonymous bindsBind password- The BIND passwordUse TLS- Use a TLS connectionSearch for UserDN- Find the UserDN then Bind to thatAuth Search Filter- Filter used to find the UserDN, LDAP Search Filter Variables are supportedAuth Search Scope- Search Scope, defaults tosubtreeEmail Search Filter- Filter used to find email addresses, LDAP Search Filter Variables are supportedEmail Search Scope- Search Scope, defaults tosubtree
To Add AD/LDAP Authentication additional settings:
- Click 
Domains - Select the domain > Click the 
Domain name - Scroll to the bottom under 
Authentication Servers - Select the LDAP 
Authentication server> ClickSettings - Enter the required settings
 - Click the 
Save settingsbutton 
LDAP Search Filter Variables
The following variables are available for use in your LDAP search filters.
%n- login (user@domain)%u- user (user part of the login)%d- domain (domain part of the login)%D- domainDN (domain DN)
| Variable | Auth Search Filter | Email Search Filter | 
|---|---|---|
%n | 
Available | Not Available | 
%u | 
Available | Available | 
%d | 
Available | Available | 
%D | 
Available | Not Available | 
Adding RADIUS Authentication additional settings
The RADIUS protocol requires a shared secret between the client and the server, the additional settings allows you to configure this.
To Add RADIUS Authentication additional settings:
- Click 
Domains - Select the domain > Click the 
Domain name - Scroll to the bottom under 
Authentication Servers - Select the RADIUS 
Authentication server> ClickSettings - Enter the shared secret in the 
Radius secretfield - Click the 
Save settingsbutton 
Adding SAML2 Authentication additional settings
The SAML2 protocol requires the following additional settings.
IDP entityIDThis is the SAML entityIDIDP Sign-in page URLThis is the SSO login end pointIDP Sign-out page URLThis is the SLO logout end pointIDP certificateThis is the IDP’s certificate
To Add SAML2 Authentication additional settings:
- Click 
Domains - Select the domain > Click the 
Domain name - Scroll to the bottom under 
Authentication Servers - Select the SAML2 
Authentication server> ClickSettings - Enter the required settings
 - Click the 
Save settingsbutton 
The metadata for the domain’s SP endpoint is available at the url:
https://<baruwa-hostname>/a/metadata/<domain-name>
You can configure your IDP to provide the following attributes which will be used to update the users local Baruwa profile.
urn:oid:0.9.2342.19200300.100.1.3: Email aliasesurn:oid:2.5.4.4: Surnameurn:oid:2.5.4.42: Given Name
The NameID provided by the IDP should be the users email address.
The current Baruwa implementation supports the following bindings.
SP to IDP-HTTP Redirect BindingIDP to SP-HTTP Redirect Binding, HTTP POST Binding
Alias Domains
Some organisations have email addressed to the same account using different domain names, Alias domains allow users access to all their messages regardless of the domain name under a single login.
By adding an alias to a domain name, Baruwa will accept and process email for that domain
alias as well. This simplifies configuration in cases where an organisation owns multiple
domains for example example.com, example.net and example.org. You can add
example.com as a domain and then add the others as domain aliases of example.com.
Adding an Alias Domain
- Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
Add Alias Domain - Enter Alias domain name in the 
Domain alias namefield - Ensure the 
Enabledcheckbox is checked - Click the 
Addbutton 
DKIM
DomainKeys Identified Mail (DKIM) is a method for associating a domain name to an email message, thereby allowing a person, role, or organization to claim some responsibility for the message. The association is set up by means of a digital signature which can be validated by recipients. Wikipidia
Baruwa allows you to manage the digital signatures within the interfaces and signs any outbound messages for which DKIM is enabled.
Generate DKIM Keys
To generate DKIM keys for a domain,
- Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
DKIM>Generate DKIM keys - Select 
DNS recordand add to you DNS zone 
Enable DKIM signing
- Make sure your have followed the steps in Generate DKIM Keys
 - Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
DKIM>Enable/Disable DKIM signing - Ensure the 
Enabledcheckbox is checked - Click the 
Submitbutton 
Regenerate DKIM keys
- Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
DKIM>Regenerate DKIM keys - Select 
DNS recordand update your DNS zone 
Signatures
Baruwa can manage email signatures / disclaimers that are added to messages that are sent outbound through it. Both HTML and Text signatures are supported. HTML signatures can contain a single embedded image.
Adding Signatures/Disclaimers
- Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
Signatures>Add signature - Select 
Signature typefrom the drop down - Enter signature content
 - Ensure the 
Enabledcheckbox is checked - Click the 
Add signaturebutton 
Importing Accounts
Accounts can be imported into a domain using a YAML file.
- Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
Import accounts - Browse for the YAML file by clicking 
Browsenext to theYAML filefield - Click the 
ImportButton 
Exporting Accounts
Accounts can be exported from a domain to a YAML file.
- Click 
Domains - Select the domain > Click the actions 
Manage settingsicon - Click 
Export accounts - Click 
Download the YAML file - Save the file to your computer
 
Rulesets
Note
Domain specific rule sets are not implemented yet.
Searching for Domains
If you have a large number of domains you can search for a domain by name.
- Click 
Domains - Enter the Domains name in the search box
 - Click the 
SearchButton 
Bulk domain management
To enable, disable or delete multiple domains:
- Click 
Domains - Use the checkbox to select the domains
 - Select 
enableordisableordeleteat the top - Click the 
Submitbutton