Eyeglass Solutions Publication2

CrowdStrike Next-Gen SIEM Zero Trust Log Ingestion and Alerting

Home



 

Overview

Customers using CrowdStrike Next-Gen SIEM can now leverage a native integration that  ingests root cause Cyber Storage events to show as Security events . See Crowdstrike integration landing page 

  1. NOTE:  This documentation is provided "as is" without support for 3rd party software.  The level of support for this integration guide is best effort without any SLA on response time.  No 3rd party product support can be provided by Superna directly.  3rd party components require support contracts

Limitations

  1. None

Solution Overview

Superna Defender Zero Trust API receives webhook alerts from Security Edition and maps all relevant data fields into the CrowdStrike Parsing Standard (CPS). 


Video Demo


Advanced Zero Trust Capabilities

  1. Webhook to native CrowdStrike SIEM ingestion API and log parsing
  2. Superna Security Edition host Containment api integration with CrowdStrike Next-Gen SIEM

Quick Start from Marketplace

  1. Follow this link to the martetplace listing and click Configure to get started. https://falcon.us-2.crowdstrike.com/store-v2/ddb610cacfc349e4a75bac253d7df550
  2.   Create the connecto and parsing instance and generate an API key can skip to section on configuring Eyeglass VM below.

What is CrowdStrike Next-Gen SIEM?

CrowdStrike Falcon® Next-Gen SIEM revolutionizes threat detection, investigation and response by bringing together unmatched security depth and breadth in one unified platform to stop breaches.  The Superna data source is available directly within NExt-GenSIEM Data Onboarding tab.

 


Integration Architecture


Solution Configuration in CrowdStrike Next-Gen SIEM and Defender Zero Trust

Prerequisites

  1. Installed Security Edition
  2. Eyeglass OS appliance version 15.5
    1. cat /etc/os-release
  3. License key for the Zero Trust API 
  4. CrowdStrike Next-Gen SIEM application entitlement


Configuration in CrowdStrike Next-Gen SIEM from the Marketplace

Follow these steps in the Next-Gen SIEM Data Onboarding to install the connector and collect api keys and url to be used with Superna Data Security Edition.

  1. Log in to the CrowdStrike Falcon Console Select Data Onboarding

    1.  Type Superna in the Data Source Search box

  2. Click the connector and fill in the fields 
    1.  
    2. Click Save
  3. Click Generate API key when the window appears
    1. Save the key for use in later steps
  4. Click on Data Sources and click on the new data source and record the API URL
    1.   
    2. Save this url for later steps
  5. done.


Configuration Steps on Eyeglass Virtual Machine

High Level steps

  1. Create python location to run the application on the Eyeglass vm
  2. Create python main application script
  3. Create linux systemd service and set to auto start
  4. Create Zero Trust configuration in Defender
  5. Update the main script to customize with CrowdStrike Next-Gen SIEM  python code
  6. Test the script is running as a service
  7. Create a test event in Defender to validate the alerts appear as indexed parsed events in CrowdStrike Next-Gen SIEM

Configuration Step by Step

Configure the Service start and python integration files
# CrowdStrikeSIEM Integration Deployment Instructions

Login to the Eyeglass VM via SSH as the admin user:
ssh admin@<your-vm-ip>

# Become root
sudo -s
mkdir -p /opt/superna/cgi-bin
chown -R sca:users /opt/superna/cgi-bin
chmod -R u+rwX,g+rwX /opt/superna/cgi-bin

# Switch to the SCA user
sudo -u sca -s
cd /opt/superna/cgi-bin

# Create Python virtual environment for the integration
python3 -m venv venv-crowdstrikesiem
source venv-crowdstrikesiem/bin/activate

# Install required Python packages
pip install flask boto3 requests logging
deactivate

# Create integration script files
touch crowdstrikesiem.py
touch crowdstrikesiem.sh
chmod +x crowdstrikesiem.py
chmod +x crowdstrikesiem.sh

# Create the crowdstrikesiem.sh launch script
nano /opt/superna/cgi-bin/crowdstrikesiem.sh
# Paste the following into the file:
#!/bin/bash
export PATH="/opt/.pyenv/bin:$PATH"
source /opt/superna/cgi-bin/venv-crowdstrikesiem/bin/activate
exec python /opt/superna/cgi-bin/crowdstrikesiem.py

# Make the script executable
chmod +x /opt/superna/cgi-bin/crowdstrikesiem.sh

# Exit back to root
exit
whoami # confirm you are root

# Create the systemd service unit file
nano /etc/systemd/system/crowdstrikesiem.service
# Paste the following into the file:
[Unit]
Description=Webhook listener for Zero Trust API translations and integrations
After=network.target

[Service]
Type=simple
User=sca
Group=users
WorkingDirectory=/opt/superna/cgi-bin
ExecStart=/bin/bash /opt/superna/cgi-bin/crowdstrikesiem.sh
Restart=always
RestartSec=5

[Install]
WantedBy=multi-user.target

# Reload systemd to register the new service
systemctl daemon-reload

# Enable the service to start on boot (do NOT start it yet)
systemctl enable crowdstrikesiem


Configure the python packages and customize the CrowdStrike integration python code
  1. Customize the application code by downloading the python code from this link to download
    1. Open the python template file in a text editor. NOTE: make sure to only replace the values and do not delete any of the commas
    2. Locate this section in the file # Define the endpoint and API token as variables to add your CrowdStrike api token and endpoint for API calls . 
      1.  Add the API URL and API token into this section.
      2.  
  1. nano /opt/superna/cgi-bin/crowdstrikesiem.py
  2. Open the file locally in Windows OS notepad and use control-A or select all the text in the python template
  3. Paste the clipboard into the ssh terminal session with the open nano editor file
  4. save the file
    1. press control+x
    2. Answer yes to save and exit the nano editor 
  5. Start the service and verify it is running
    1. systemctl start CrowdStrikeSIEM 
    2. systemctl status -l CrowdStrikeSIEM 
    3. Verify the service is started successfully and returns "active and running".
  6. If the service does not start do not proceed and double check the steps above are completed. 

Configure Defender Zero Trust Webhooks

  1. The next step creates an Zero Trust Webhook URL.    
    1. Configure Zero Trust endpoint in Ransomware Defender Zero Trust tab.
      1. Recommended Configuration: Only Critical and Major events and only the webhooks that set lockout or delayed lockout.   Customers can customize based on specific requirements. The goal is to send findings versus a list of alarms that do not pinpoint a security incident.

      2. The endpoint url above will use localhost and will send Webhooks to the application service listening on port 5000. URL to use in the configuration
        1. http://localhost:5000/webhook 
        2. Add the Content-Type header with value of application/json as shown above to complete the webhook configuration.
        3. Click save to commit the configuration.
        4. Click save on the main Webhook configuration page
  2. Test the configuration is working following the next section


How the Integration works CrowdStrike Next-Gen SIEM 

  1.  These screenshots show how log messages appear when searching for raw logs and how Detections appear in the Console.
  2. Log message in CPS format
  3. Detections Example
    1.  

How to test the Integration with CrowdStrike Next-Gen SIEM

  1. To test the integration follow these steps
  2. Prerequisites In CrowdStrike Next-Gen SIEM and Eyeglass:
    1. Download this curl command template and open with a text editor.
    2. ssh to the eyeglass vm as the admin user
    3. Copy and Paste the entire cli command text to the ssh prompt to send sample data to the running Zero Trust application.  This will send test data directly to the application to be processed and sent to CrowdStrike Next-Gen SIEM Integration service that is running on the Eyeglass VM.
    4. The output of a successfully processed webhook test will return this text in the ssh terminal
      1. done sending event to CrowdStrike and check for http 200 and success count in response
    5. How to review the process logs from the web application
      1. sudo -s 
      2. journalctl -f -u CrowdStrike 
      3. This allows you to view the logs generated by the application.
      4. To log to a file and review with nano showing only the most recent 250 lines.
      5. journalctl -f -n 250 -u CrowdStrike  > /tmp/ztwebhook.log
      6. nano /tmp/CrowdStrike.log
      7. In the log below the response code from the CrowdStrike Next-Gen SIEM api call should show http 200 status code and successCount 1 to indicate the Finding was successfully created.
      8.   You can also view CrowdStriked.log for specific error messages.
    6. Login to the CrowdStrike Next-Gen SIEM and verify new incident is raised.
  3. Done


CrowdStrike Next-Gen SIEM Zero Trust Log Ingestion and Alerting with Data Security Essentials


Overview

Data Security Essentials saves alerts to the Windows Event log to a custom application log.   This integration will extract the log entries and the json payload contained within them and format as webhook data to send to Crowdstrike endpoint.



Requirements

  1. Follow the integration steps above to configure the logical app.
  2. Install python for Windows on the Data Security Essentials host and allow the installation to add python to the path variable. https://www.python.org/downloads/windows/
    1. NOTE: Ensure it's installed for all users so service accounts have access, by enabling for all users during installation.
  3. The integration code matches event log entries from Custom trigger BOT policies and File management policies
    1. The event log source names are below 
      1. Superna Data Security Essentials BOT Service
      2. Superna Data Security Policy Engine 

Features

  1. Logs for each execution are stored in the path below along with the python code. 
    1.  
  2. Each execution will store the event log record ID and date time and event number of the last processed event in a file called last_processed_record.txt.  This file is read on each execution to continue processing from last record.  The record number is not visible in Event Viewer, the date time and event number can be used to understand where in the log the last processing occurred.
  3. The schedule sync runs every minute and only processes events since the last record and logs all processing as well as event matches in the log file for debugging.
  4. Only events that match the severity filter will be processed for client ip address.   The sample code defaults to Major and Critical severity events all other severities will be ignored. 

Steps to Configure Event Forwarding Integration 

  1. Follow the steps to create the endpoint and install the Superna parser into NextGen SIEM instance before continuing.  The marketplace steps are outlined in this guide above.
  2. Download the integration code from here. (Right click Download)
  3. Modify the python and update the Crowdstrike integration settings highlighted in yellow to match your environment.  Update all the yellow sections highlighted below.
    1. Edit the url in the template integration code downloaded above.
      # CrowdStrike Ingest endpoint and token
      CROWDSTRIKE_ENDPOINT = "https://xxxx.ingest.us-2.crowdstrike.com/services/collector"
      CROWDSTRIKE_API_TOKEN = "yyyyyyyyy"

      # Configuration
      server = 'localhost'
      log_name = 'Data Security Essentials'
      source_names = ['Superna Data Security Essentials BOT Service', 'Superna Data Security Policy Engine']
      trigger_severities = ['MAJOR', 'CRITICAL','WARNING'] # Configure severities that should trigger event forwarding
  4. Copy the Python code into C:\Program Files\Superna\cgi-bin on the Data Security Essentials host and name the file Crowdstrike-dse.py
    1. Create the path from command prompt or GUI makedir 'C:\Program Files\Superna\cgi-bin'
  5. Install python dependencies
    1. MANDATORY Step: Open a command prompt as the service account (hold down shift and right click the command prompt icon) run as  option to login as the service account dse-service.  This is required to install the python packages under the correct user account.
    2. Install the dependencies with this command
      1. pip install pywin32 requests
    3. This command installs the windows API python libraries needed to read the event log.
  6. Test the script can correctly reach your Crowdstrike instance from a dos prompt
    1. cd 'C:\Program Files\Superna\cgi-bin'
    2. python  crowdstrike-ngsiem-dse.py
    3. The output should display event log entries that match  and  will ignore severities that do not match script settings .  It will display the event payload details in json format and will show the data that was sent to the Crowdstrike endpoint.   
    4. NOTE: if no Critical or MAJOR detections occur you can edit the py file to add INFO for testing only.
    5. You can also review this file last_processed_record.txt to see the last date and time within the event log and event id that was last processed.  This file can be deleted to have the script start reading from the oldest windows event log entry.  This can be done for testing puposes.
    6. The above examples shows the output when a client ip address is successfully located and the host containment api returns success.
    7. The example below is logged when event data is processed and inspected for severity and forwarded with key fields parsed and extracted.

  7. Steps to Schedule sync alerts into Crowdstrike Security Incidents 
    1. Open secpol.msc, Local policies
    2. Give the Data security essentials AD service account the  "Logon as a batch job"  OS permission.
    3.   
    4. Create a file 
  8. Right click this link to save to a file. The task scheduler XML file to import into Task Scheduler
    1. You can rename the xml from Servicenow alert sync.xml to Crowdstrike integration.xml. 
    2. NOTE: if the xml will not import to your version of windows, you will need to create the scheduled task manually.
  9. Open Task Scheduler
    1. Run taskschd.msc, right click task schedule library 
    2.   
    3. Import the xml file
    4. You will be prompted with the task definition, you will need to change the service account to match your service account name and domain and re-enter the password to save the task scheduler.  All other settings are configured and match the path and settings used above.  Adjust any parameters that you changed if you did not use all the steps above. 
      1. Edit the name "Crowdstrike Integration"
      2. Click the Actions tab and browse to select the file C:\Program Files\Superna\cgi-bin\crowdstrike-ngsiem-dse.py
      3. Click ok to save 
      4.   
    5. done.



© Superna Inc