Change the logo
To change the logo in the notifications:-
Open
shared/email_templates/style/default.yml. -
Uncomment the configuration about logo, choose either via embedded File or via URL:
File (preferred)
PNG Logo is uploaded to xorlab.default.ymlURL
Logo is referenced via a URL.default.yml - In case of URL, click Publish and finish. The template configuration becomes active within about one minute.
-
In case of File, add a new folder called
sharedundershared/email_templates. -
Create a new file inside
shared/email_templates/sharedand name itlogo.txt(as configured above). - Enter the logo Base64 encoded into this file. For Base64 encoding, you can use e.g. Base64.guru or CyberChef.
- Click Publish. The template configuration becomes active within about one minute.
Change the colors
In the same Branding & Colors section of thedefault.yml file, you can change the colors used in the mail notification templates to match your company’s brand identity.
- Click the
stylefolder to expand it and click thedefault.ymlfile. - The second part in the section titled Branding & Colors is marked as
#colors:. - Using the Ctrl+Slash (Cmd+Slash on macOS) keyboard shortcut, uncomment the
colorsline and the required lines that follow. Enter new values for color properties that can be changed:error,alert,warning,ok,neutral—the color of the text label for the findings (aka the “kicker”, e.g.,ALERT,WARN,GREEN LIGHTorUNDECIDED)background—self-explanatory: the color of the backgroundlightanddark—reserved (unused)infosubscript(message info: from, date, etc.)
- Click Publish. The template configuration becomes active within about one minute.
Change the font
- Click the
stylefolder to expand it and click thedefault.ymlfile. - Go to the section titled Typography.
- Using the Ctrl+Slash (Cmd+Slash on macOS) keyboard shortcut, uncomment the
fontline and the required lines that follow. Enter new values for font properties that can be changed:size—if you want to specify a new sizefamily—if you want to use another font familycolor—for specifying a new font color
Change the footer information
All company information appearing as an email footer is configurable in thedefault.yml file located in the info folder.
- Click the
infofolder to expand it and click thedefault.ymlfile. - Using the Ctrl+Slash (Cmd+Slash on macOS) keyboard shortcut, uncomment the required lines. Enter new values for company info properties that can be changed:
name—your company namedetails—additional info, e.g., the department name such as"Security Operations Center"email—contact email addressurl—the URL address for a Self-Service Quarantine link in notification mails, e.g.,"https://customer.activeguard.cloud"provider—the name of the service provider
Localization
In order to support localization for a particular language (lang) of a given country (COUNTRY), follow the steps below:
- Click the
localefolder to expand it and click thedefault.ymlfile. - In the right pane, select and copy the whole content of the file.
- Use the context menu for the
localefolder to add a new file. - Enter the name for the file in the dialog box that appears. Use the convention of
default_lang_COUNTRY.yml, e.g.,default_pt_BR.ymlfor the Brazilian Portuguese version of a file. Click Create. - Scroll down to the file you have just created, click it, and in the right pane paste the content of the previously copied content of the
default.ymlfile. For each template entry in the new localization file, replace the default text with its translation. Click Publish. The new localization file becomes active within about one minute.
Change the default language
The default language for notifications is defined in thedefault.yml file located in the config folder.
- Click the
configfolder to expand it and click thedefault.ymlfile. - You will see only one entry:
defaultLocale. Set it to your country code (currently, onlyENandDEvalues are supported). - Click Publish. The new default language becomes active within about one minute.
Using language headers
If you want to use another language in notifications for a particular report email, set thex-ag-locale email header in the report email to the locale desired for the template (this header must be set in the “outer” email that carries the reported email as attachment). For example, if you want to set the template for Swiss German, set the value to de-CH. For this reported email, xorlab Security Platform will then use the default_de_CH.yml instead of the default.yml template to pick the translation.
To read the language from a custom header, for example my-custom-language-header instead of x-ag-locale, you would need to edit activeguard/core/active_guard.yml the following way:
emailReporting setting is in active_guard.yml and requires an MTA restart; see How to Activate the Configuration.
Managing Templates
Disable a template
- In the main
shared/email_templatesfolder, click a.ymlfile for the notification template you want to disable. - In the right pane, go to the
categorykeyword and change its value fromANALYST_FEEDBACKtoDEFAULT. - Repeat these actions for every unwanted template and click Publish. The template configuration becomes active within about one minute.
Create a new template
To create a new email notification titledNOTIFICATION_NAME for the default tenant:
- Use the context menu for the
email_templatesfolder to create a new file inside of it. - Enter
NOTIFICATION_NAME.ymlas the name for the file in the dialog box that appears. Click Create. - Scroll down to the file you just created, click it, and in the right pane paste the following content:
- Enter values that match the template usage—please refer to the Template configuration section.
- Go to the
localefolder and, in each localization file of thedefaulttenant, add a new entry for the newNOTIFICATION_NAMEtemplate using the YAML structure given below. For example, to localize the email notification into US English, add the following lines todefault.yml: - Click Publish. The new template becomes active within about one minute.
Untranslated sectionsAny template sections that are not translated will be rendered as empty in the final email notification.
Template configuration
The table below lists template parameters and their allowed values:Using variables in templates
It is possible to use some variables in notification templates so that notifications contain more details about the email messages they refer to. The table below lists all available variables. In order to use them, type$email.<variable_name>, e.g., $email.subject or $email.senderAddress, where you want the desired value to appear in the notification email.
contextFieldsThe
contextFields variable is an exception in the usage. Since it’s a map, you have to use the following pattern: $email.contextFields.get("<indicator>"), e.g., $email.contextFields.get("dce.indicator.shortened").Multi-Tenancy
Everything on this page edits thedefault files, which apply to all tenants.
To give a single tenant its own logo, colors, texts or footer, assign it an emailTemplateStyle in guarded_tenants.yml and create the matching files next to the default ones, instead of editing default itself. The customization steps are the same as above.
Customize Tenant Notifications
Step-by-step guide for per-tenant text, style, logo and footer.