Managing Custom Alert Templates
search cancel

Managing Custom Alert Templates

book

Article ID: 289324

calendar_today

Updated On:

Products

Carbon Black App Control (formerly Cb Protection)

Issue/Introduction

Steps to create and remove custom Alert Templates.

Environment

  • App Control Server: All Supported Versions

Resolution

Note: This article is a "Best Effort" to provide the ability to create custom Templates. The methods described here are not officially supported.

 

Creating New Templates:

  1. Log in to the application server as the Carbon Black Service Account.
    • Failure to log in as the Service Account will prevent importing the necessary files.
  2. Browse to the AlertTemplates directory in the Server install directory, example:
    C:\Program Files\Bit9\Parity Server\Reporter\AlertTemplates
  3. Make copies of the relevant files for the Alert or Response Template(s), outside the Server directory (example: C:\Temp\CustomAlert\):
    • Template for Alert.hdr
    • Template for Alert.html
    • Template for Alert.txt
  4. Customize the copied Template files as needed (example: adjust phrasing, add additional Tags, etcetera)
  5. Use an administrative command prompt to switch into the Parity Server\Reporter directory:
    cd "C:\Program Files\Bit9\Parity Server\Reporter\"
  6. Add the new Custom Template to the database with a unique Name and specify the folder, header, html and text files, example:
    ParityReporter.exe add_template /name="Name of New Alert" /folder="C:\Temp\CustomAlert" /header="C:\Temp\CustomAlert\CustomHeader.hdr" /html="C:\Temp\CustomAlert\CustomBody.html" /text="C:\Temp\CustomAlert\CustomBody.txt"
  7. Verify the new Template is available in the Console > Tools > Alerts > Add Alert > Mail Template.

Removing Existing Templates:

  1. Verify the Template Name from the Console > Tools > Alerts > relevant Alert > Mail Template.
  2. Log in to the application server as the Carbon Black Service Account.
  3. Issue the following commands in an administrative command prompt:
    cd "C:\Program Files\Bit9\Parity Server\Reporter\"
    ParityReporter.exe remove_template /name="Name of Alert"

Available Template Tags: (Per Alert Type)

Tag NameAlert Type Tag Can Be Used WithTag Value
{$server_name}All AlertsComputer name where Server is installed
{$alert_id}All AlertsAlert identifier
{$alerts_triggered_id}All AlertsTriggered alert instance identifier
{$priority}All AlertsPriority of the Alert itself
{$priority_color}All AlertsAlert priority color (for HTML)
{$alert_type}All AlertsAlert type name
{$alert_name}All AlertsAlert name
{$alert_message}All AlertsAlert message
{$created_by}All AlertsDate when alert was created
{$triggered_date}All AlertsDate when alert was triggered
{$triggered_summary}All AlertsSummary of triggered alert
{$tagline}All AlertsTagline used for branding purposes through database (shepherdConfigs param tagline)
{$host_id}Computer related alertsHost database identifier (used optionally for host detail links)
{$host_name}Elevated privilege alertHost name of computer that triggered the alert
{$hash}File related alertsHash of file that triggered the alert
{$file_name}File related alertsFile name of file that triggered the alert
{$antibody_id}File related alertsFile database identifier (used for file detail links)
{$file_state}File related alertsFile state of the file that triggered the alert
{$cert_it}Certificate alertsCertificate id that triggered the alert
{$cert_subject}Certificate alertsCertificate subject that triggered the alert
{$publisher}Certificate alertsCertificate publisher that triggered the alert
<Sha256>Event and Approval Request alertsSHA256 hash of the file that triggered the alert
<Md5>Event and Approval Request alertsMD5 hash of the file that triggered the alert
<Sha1>Event and Approval Request alertsSHA1 hash of the file that triggered the alert
<FileName>Event and Approval Request alertsFile name of the file that triggered the alert
<HostName>Event and Approval Request alertsHost name of the computer which triggered the alert
<UserName>Event and Approval Request alertsUser name that triggered the alert
<RootSha256>Event and Approval Request alertsSHA256 hash of the installer of the file that triggered the alert
<AntibodyId>Event and Approval Request alertsDatabase identifier of the file that triggered the alert
<HostId>Event and Approval Request alertsDatabase identifier of the computer that triggered the alert
<EventRuleName>Event alertsEvent rule that triggered the alert (if event rule is used)
<EventRuleDescription>Event alertsEvent rule description that triggered the alert (if event rule is used as criteria)
<EventSubtype>Event alertsEvent subtype that triggered the alert (if event is used as criteria)
<EventDescription>Event alertsEvent description that triggered the alert (if event is used as criteria)
<ApprovalRequestPriority>Approval Request alertsApproval request priority as submitted by the user
<ApprovalRequestReason>Approval Request alertsApproval request reason as submitted by the user
{$approval_filename}Approval ResponseApproval response file name
{$approval_resolution}Approval ResponseApproval response resolution as submitted by the administrator
{$approval_response}Approval ResponseApproval response comments as submitted by the administrator
{$approval_request_reason}Approval ResponseApproval request reason as submitted by the user
{$approval_requestor}Approval ResponseApproval requester
{$approval_request_date}Approval ResponseApproval request date
{$indicator_id}System health alertsHealth indicator id that triggered the alert

Additional Information

  • Each Template consists of 3 files: Header, HTML Body, and Text Body.
  • A new Template with the same name will overwrite an existing Template.