SANS C Carroll Performing INSM With Open-Source Tools
SANS C Carroll Performing INSM With Open-Source Tools
SANS C Carroll Performing INSM With Open-Source Tools
Accepted: 03/29/2024
Abstract
Security vendors have made many advances in internal network security monitoring
(INSM) in recent years. Numerous vendors have developed specialized platforms that
provide industrial control system (ICS) security teams with detailed network visibility.
However, the cost of these platforms is prohibitive to smaller electric distribution
providers and cooperatives. This scenario leaves these smaller but critical systems
vulnerable to cybersecurity threats. While IT teams regularly monitor security, ICS
systems have lagged in adopting centralized security monitoring. However, ICS security
teams could safely leverage many well-established open-source tools in their
environment to provide essential network security monitoring and asset visibility.
This research will demonstrate how INSM monitoring could be performed by ICS
security teams using a single monitoring platform with multiple open-source tools,
including Zabbix, OpenSearch, and Suricata, and deployed in Docker containers. These
services provide asset inventory, intrusion detection, and server health monitoring with
minimal hardware requirements. This research proves that while essential monitoring is
possible, it is critical to understand the network protocols and device limitations to build
a comprehensive monitoring strategy.
Performing Internal Network Security Monitoring with Open-Source Tools 2
1. Introduction
In January 2023, the Federal Energy Regulatory Commission (FERC) issued
Order No. 887. This order directed the North American Reliability Corporation (NERC)
to expand the scope of required network monitoring beyond the electronic security
perimeter (ESP) and into the local area network (LAN) or internal network security
monitoring (INSM) (North American Reliability Corporation, 2024). While this
requirement will initially apply only to high-impact and medium-impact systems with
external routable connectivity (ERC), many low-impact and medium-impact systems will
evaluate their ability to implement similar controls. Larger entities, such as those the
requirement initially applies to, can budget for specialized monitoring systems such as
Dragos, Nozomi, or Microsoft Defender for IoT. However, these solutions will likely be
cost-prohibitive for smaller entities such as electric cooperatives and distribution
providers. Consequently, they will continue to operate with little or no network
monitoring in their critical infrastructure.
The lack of asset and network visibility in some of the most critical infrastructure
in the United States is troubling. While network monitoring is commonplace in IT
systems, the electric power sector has lagged significantly in implementing any internal
asset monitoring due in part to the lack of standardization in the environments (Sanchez,
2022). Rather than relying on regulation to force these smaller entities to enact INSM via
compliance or continuing to react after an impact on their system, it could be beneficial to
leverage existing open-source packages that one can deploy as a single monitoring sensor
into the network for this task. This research aims to build a functional, easily deployable
INSM system utilizing existing open-source tools to provide basic network traffic
inspection and asset inventory monitoring. As Jason Christopher mentions in his recent
white paper, while IT enterprise networks have focused heavily on network and asset
visibility but have not typically extended into the ICS networks, this information is
critical in the ability to defend a system and to respond in the case of an incident
(Christopher, 2023). The combination of open-source tools will comprise a platform to
provide a basic network intrusion detection system (IDS) and asset monitoring to
facilitate visibility into LAN assets and traffic.
2. Research Method
For the research, the INSM platform will be configured to monitor lab devices
and test scenarios will be performed to validate the system's baseline and security
monitoring. The primary focus of the testing will be on field devices such as relays and
meters. These device types typically lack security monitoring because they do not
provide typical monitoring interfaces. The research will endeavor to validate the
effectiveness of the monitoring solution and describe novel methods of critical data
retrieval and monitoring.
Each of these devices presents various interfaces for interaction with the user.
This experiment utilizes several interfaces representing a typical substation environment;
details are provided in Table 2.1.
SEL-3555 REST API The SEL RTAC is a multifunctional platform that can act as a
remote terminal unit (RTU), logic processor, and protocol
converter (Schweitzer Engineering Laboratories, 2024). It is a
very flexible platform that supports many protocols and offers
numerous interfaces. The experiment will utilize the built-in
REST API.
SEL
1 SEL-3355 2
INSM Platform 1
Caldera Virtual Server
Mirror Port
1 2 3 4 5 9 11
RUGGEDCOM SWITCH
SEL
SEL
SEL-735 SEL
SEL-751 SEL-3360 1
Engineering
1 1 Workstation
SEL
RTAC
Meter Feeeder 1
Relay
Automation Controller
2.2.1. Applications
The two primary applications that make up the INSM monitoring stack are Zabbix
and Suricata. Zabbix is an open-source, all-in-one monitoring solution advertised as
capable of monitoring anything (Zabbix, 2024). Zabbix provides baseline server health
information, centralized asset information, and essential network monitoring for this use
case. The Zabbix images used for this experiment are pulled directly from the Docker
hub using the official Zabbix images (Zabbix, 2024). Zabbix is ideal for this solution
because it provides a wide range of interface compatibility required for the diverse
systems under test.
Several other applications are required to support the base functionality of Zabbix
and Suricata. The complete list of applications is detailed in Table 2.2.
OpenSearch opensearch:1.0.1 OpenSearch and the OpenSearch dashboard are derived from
Elasticsearch and Kibana but are open-source (OpenSearch
Project, 2024). OpenSearch is the search engine daemon.
Fluent Bit fluent-bit The fluent-bit container is a lightweight log processor that
sends data to OpenSearch (Fluentd project, 2024). Log
directories to ship to OpenSearch are mounted as volumes in
the fluent-bit container.
Zabbix Web Zabbix-web- This application provides the frontend web interface for
Interface nginx- Zabbix servers that use MySQL backend; the web interface is
mysql:alpine-6.4- built on Nginx (Zabbix, 2024).
latest
Zabbix Agent Zabbix- The Zabbix agent is installed on a target to monitor (Zabbix,
agent:alpine-6.4- 2024). In this experiment, the agent is deployed as a container
latest to monitor the Zabbix server instance and installed locally on
the EWS.
Zabbix Server Zabbix-server- This is the primary Zabbix process; this image is built on
MySQL:alpine- Alpine Linux with support for the MySQL backend (Zabbix,
6.4-latest 2024).
3. Test Scenarios
The following test scenarios will test the basic system functionalities and identify
limitations. The asset monitoring section will focus on the ability to retrieve critical
operational data and enrichment of that data. The attack simulation portion will focus on
the platform's ability to identify basic attack patterns based on MITRE ATT&CK and
prevalent threat groups. The test will also identify any specific tuning or modifications to
the platform components required for successful detections.
built-in TELNET agent for performing simple checks; however, this method would not
work for this application because the TELNET server needs to provide a login prompt.
The SEL relay and meter used in the test do not provide a prompt; when a client
successfully connects to the server, the client is presented with a blank screen, as shown
below.
Because the built-in Zabbix TELNET agent would not work for this application,
two options remain to move this data into Zabbix. The first is to use the "External
Checks" item to allow the Zabbix server to call an external script to spawn a TELNET
session and issue the ID command to send the data back to the Zabbix server. The second
option is to run the command elsewhere, such as on the Docker server itself, and have it
use the “Zabbix-sender” to send the data to the “Zabbix-trapper” for ingest into the
platform. Both methods were experimented with, but the second method was ultimately
successful. Data is imported into Zabbix using the bash script on the server, and the
“expect” command is combined with a regular expression to automate the data retrieval
and package the data in the format required by Zabbix.
This script will run as a Cron job on the server and then send the data to Zabbix.
The screenshot below demonstrates the successful import of data into Zabbix.
Using this method, anything accessible from the TELNET interface of the
connected devices can be retrieved and viewed within the Zabbix container.
It should be noted that the SALARM word bit can indicate several events; it is not
explicit, meaning that an invalid password will trigger the same event that a setting
change will. However, as seen in Figure 3.6 below, a default SER is also logged for
settings changes for this relay model.
The next step is to move this data into the monitoring platform. One potential
method is to retrieve this data as a log file and have Zabbix monitor it. The other option is
to bring this data directly into OpenSearch as SYSLOG. To test this, a simple Python
script was created to access this device from a read-only telnet session and convert the
SER to SYSLOG. With this method, the SERs are automatically retrieved and indexed
into our OpenSearch instance.
For this test, the administrator configures the Zabbix server to use the built-in
HTTP agent to perform an API query asking for the device "Id" information. The
response from this request will be JSON formatted and include information such as the
device serial number, BIOS version, and feature set. To do this, a web interface on the
host is specified for the Zabbix server to query.
It can now be verified that Zabbix is successfully receiving the RTAC asset data.
Zabbix provides a built-in SNMP agent used in the experiment to monitor the lab
switch by configuring the SNMP agent in the RUGGEDCOM host and the SNMP item in
the Zabbix server.
Since many ICS devices use unencrypted protocols for management, it is possible
to easily create a few custom rules that alert specific network behavior. For instance, the
SEL-735 meter and SEL-751A relay have two access levels and corresponding access
groups for this use case. The access group "acc" provides interactive read access, and the
access group "2ac" provides access to make device setting changes. From a network or
security monitoring perspective, it is critical that attempted "2ac" access and
authenticated "2ac" should be logged. Because the devices use TELNET as their network
protocol for interactive access, writing Suricata rules to alert them to this is trivial.
As demonstrated in Figure 3.16, when the user attempts to elevate to "2ac," they
enter that into the terminal, and when they are successful, they receive a banner stating,
"Level 2." Suricata can capture this activity by creating a few custom rules to alert people
about this attempted and eventual successful access.
alert tcp any 23 -> any any (msg: "PRIVILEGED ACCESS TO IED"; content:
"Level 2"; nocase; sid:1000001; rev:1;)
alert tcp any any -> any 23 (msg:"2AC ATTEMPTED"; content:"2ac"; nocase;
sid:1000002; rev:1;)
The first rule will alert when the "Level 2" banner is returned from the TELNET server,
and the second rule will alert when the "2ac" command is sent to the server. The
successful alerts in OpenSearch are shown below.
Alerts can be further expanded by creating a ruleset based on the known traffic
patterns in the network. For instance, because it is known that a device should only be
using a specific port and protocol for communication, it is logical that the platform
should generate an alert for any deviation from that pattern. In Suricata, accomplishing
this baseline alerting involves creating a list of variables representing the network's host
profile and alerting any deviation. For the following tests, Suricata is configured with
some basic rules to support this approach.
alert ip 192.168.0.53 any -> ![192.168.0.54, 192.168.0.56] ![23, 502] (msg: "Alert
on non-Telnet and non-Modbus traffic from RTU"; sid:1000003; rev:1;)
Caldera ran several tests successfully. However, as shown in Figure 3.19 below,
Suricata generated no alerts about this activity.
However, the alert is immediately triggered when Caldera performs the attack again
using the modified ruleset.
This platform can further alert on lateral movement by leveraging the SYSLOG records
while the Python SER to SYSLOG converter monitors SER data and sends it to
OpenSearch.
This attack used the EWS to enumerate the network using built-in Windows tools
and attempted to download and run Mimikatz to dump credentials. As shown in the
figures below, Caldera invoked a command to download the tool from Git Hub.
As with previous tests, the network traffic is visible and recorded on the sensor;
but, as with the first scenario, the standard Suricata ruleset did not trigger an alert, but the
traffic allow-listing approach did. However, Windows Defender detected the malicious
activity.
This further illustrates that when implementing INSM, one must consider all
monitoring cases; leveraging one monitoring technique is insufficient.
As expected, the field devices are the most difficult to obtain data from; however,
monitoring them from a network standpoint is significantly more straightforward due to
the limited data flow and network protocols supported. The one less-than-ideal
component is the TELNET interface; pulling this data directly from Zabbix is preferred
rather than running a script outside the platform and sending it in via traps. The current
TELNET agent implementation is a known drawback in the platform, and there is an
open feature request for this ability (Franquesa, 2023). The following tables contain the
summarized results of the testing.
Asset Monitoring
Device Default INSM Test Result Notes
Monitoring Component Pass/Fail/
Capability Partial
None Zabbix Server Zabbix was Partial This is listed
Active able to as partial due
Checks retrieve to the limited
critical amount of
device asset
information information
through the that can be
Relay use of retrieved.
and custom
Meters scripts.
None Zabbix Server Zabbix can Pass
Active retrieve both
Checks asset data
and
configuration
monitoring
Controll data through
ers and the built-in
RTUs API
SNMP Zabbix SNMP Zabbix can Pass
pull critical
asset and
Network device health
Switche data using
s SNMP
Agent-Based Zabbix Agent The Zabbix Pass
Monitoring agent can
provide
Servers complete
platform
visibility for
servers.
Table 3.1: Asset Monitoring Analysis
Security Monitoring
Device Default INSM Test Result Notes
Monitoring Component Pass/Fail
Capability /Partial
SER stored SER to Zabbix was Partial The Suricata can
locally SYSLOG able to monitor some
custom script retrieve ICS protocols,
and IDS critical and the
device monitoring can be
information enriched by
through the developing
use of custom scripts.
custom
scripts.
SYSLOG
and IDS
Relay logs sent to
and OpenSearc
Meters h
SYSLOG SYSLOG and SYSLOG Pass IDS was most
Suricata IDS and IDS effective when
Control logs sent to configured with
lers and OpenSearc custom rulesets.
RTUs h
SYSLOG SYSLOG and SYSLOG Pass IDS was most
Networ Suricata IDS and IDS effective when
k logs sent to configured with
Switch OpenSearc custom rulesets.
es h
Windows SYSLOG and SYSLOG Pass IDS was most
Event Logs Suricata IDS and IDS effective when
logs sent to configured with
OpenSearc custom rulesets.
Servers h
Table 3.2: Security Monitoring Analysis
of usability. However, because most industrial devices used for testing do not support
agents, the platform is limited in what it can retrieve. Nevertheless, by creating templates
that correspond on a per-device level, administrators could normalize the data retrieved
through active checks to make that more accessible for the user. Secondly, the inability to
use the TELNET without a standard response interface was unfortunate, and although a
workaround was found, it still needs to be improved from a monitoring standpoint.
Lastly, CIP-007 R1 specifies that all ports, protocols, and services be identified
per asset and evidence provided (North American Electric Reliability Corporation, 2024).
Typically, the compliance team would record evidence using either an NMAP scan or
Netstat output, but it would be beneficial to audit this persistently. Zabbix can monitor an
individual TCP port and discover devices based on TCP sweep; however, it does not
record all open ports found. Administrators could accomplish this by using the built-in
network discovery tool in the RTAC and then querying the API for that data. However,
pulling that information directly from Zabbix by having Zabbix spawn an NMAP scan
and retrieve the data would be cleaner.
5. Conclusion
Although security improvements in recent years have been made, a gap exists in
network visibility and asset management for many ICS systems. This gap is most notable
in comparatively smaller organizations with limited budgets. With all the open-source
tools available focusing on IT systems, this research intended to understand how some of
these open-source software solutions could be tailored to the needs of ICS. While the
experiment was ultimately successful in retrieving device information and essential
network monitoring, it also highlighted the amount of effort required in even a minimal
lab environment, given the heterogeneous nature of the devices, and further emphasized
the value proposition posed by ICS-focused vendor platforms.
This work should encourage ICS security practitioners to reevaluate the available
toolsets and that perhaps tools previously considered as "IT only" may benefit ICS
environments. It is possible to achieve visibility into the ICS system using open-source
tools; however, it may take some customization to achieve the level of visibility required.
References
Christopher, J. (2023, June 22). Breaking IT/OT Silos with ICS/OT Visibilty. Retrieved
visibility/
opensearch.org: https://opensearch.org/docs/latest/data-prepper/
docker. (2024, 02 18). Use containers to Build, Share, and Run your applications.
https://www.dragos.com/threat/electrum/
https://www.dragos.com/threat/kostovite/
https://www.dragos.com/threat/talonite/
https://hub.docker.com/r/fluent/fluent-bit
https://support.zabbix.com/browse/ZBXNEXT-5837
https://github.com/jasonish/docker-suricata
https://caldera.mitre.org/
https://hub.docker.com/_/mysql
https://www.nerc.com/pa/Stand/Reliability%20Standards/CIP-007-6.pdf
https://www.nerc.com/pa/Stand/Pages/Project-2023-03-INSM.aspx
https://hub.docker.com/r/opensearchproject/opensearch
hub.docker.com: https://hub.docker.com/r/opensearchproject/opensearch-
dashboards
Sanchez, M. (2022, 09 28). Network Security Monitoring for BES Cyber Systems.
news/community-voices/network-security-monitoring-bes-cyber-systems
https://selinc.com/products/751A/docs/
https://selinc.com/products/RTAC/
selinc.com: https://selinc.com/products/3355/
selinc.com: https://selinc.com/products/3360/
selinc.com: https://selinc.com/products/735/
selinc.com: https://selinc.com/products/751/
https://support.industry.siemens.com/cs/products/6gk6021-0as2.-..../ruggedcom-
rsg2100?pid=303165&mlfb=6GK6021-0AS2.-....&mfn=ps&lc=en-WW
https://www.zabbix.com/network_monitoring
https://hub.docker.com/u/zabbix
https://www.zabbix.com/server_monitoring
https://hub.docker.com/r/zabbix/zabbix-agent
https://hub.docker.com/r/zabbix/zabbix-server-mysql
https://hub.docker.com/r/zabbix/zabbix-web-nginx-mysql