ArcSight FlexConnector Developer's Guide Flex Conn Dev Config
User Manual:
Open the PDF directly: View PDF
.
Page Count: 241
HPE Security ArcSight Connectors
FlexConnector
Developer's Guide
October 17, 2017
Developer's Guide
Legal Notices
Warranty
The only warranties for Hewlett Packard Enterprise products and services are set forth in the express warranty statements
accompanying such products and services. Nothing herein should be construed as constituting an additional warranty.
Hewlett Packard Enterprise shall not be liable for technical or editorial errors or omissions contained herein.
The information contained herein is subject to change without notice.
The network information used in the examples in this document (including IP addresses and hostnames) is for illustration
purposes only.
HPE Security ArcSight products are highly flexible and function as you configure them. The accessibility, integrity, and
confidentiality of your data is your responsibility. Implement a comprehensive security strategy and follow good security
practices.
This document is confidential.
Restricted Rights Legend
Confidential computer software. Valid license from Hewlett Packard Enterprise required for possession, use or copying.
Consistent with FAR 12.211 and 12.212, Commercial Computer Software, Computer Software Documentation, and Technical
Data for Commercial Items are licensed to the U.S. Government under vendor's standard commercial license.
Copyright Notice
© Copyright 2016, 2017 Hewlett Packard Enterprise Development, LP
Follow this link to see a complete statement of copyrights and acknowledgements:
https://community.saas.hpe.com/t5/Discussions/Third-Party-Copyright-Notices-and-License-Terms/td-p/1589228
Support
Contact Information
Phone
A list of phone numbers is available on the HPE Security ArcSight Technical Support
Page: https://softwaresupport.hpe.com/documents/10180/14684/esp-support-
contact-list
Support Web Site
https://softwaresupport.hpe.com
Protect 724 Community
https://community.saas.hpe.com/t5/ArcSight/ct-p/arcsight
HPE Connectors
Page 2 of 241
Developer's Guide
Revision History
Date
Description
10/17/2017
l
Updated "Set Global Parameters" section to include encryption parameters.
l
Updated information for downloading SQL Server JDBC drivers.
l
l
l
05/15/2017
l
02/15/2017
l
l
In Appendix E: ArcSight Built-in Event Field Mappings, the ArcSight Mappings
fields have been changed to camel case.
Only non-blocking I/O is available for syslog connectors; therefore, the
tcpmaxidletime, tcpsetsocketlinger, and tcppeeerclosedchecktimeout parameters
are no longer relevant and have been removed from the Advanced Parameters
appendix.
As flexString fields are for the use of customers, examples have been updated to
show deviceCustomString or deviceCustomNumber fields rather than flexString
fields.
Added a notice about ODBC connections not being supported after release 7.2.1 to
the "ArcSight FlexConnector ID-Based Database", "ArcSight FlexConnector Multiple
Database", and "ArcSight FlexConnector Scanner Database" sections.
Added JSON to the list of available extra processors. See "Extra Processors".
Clarified the configuration file names and locations for vulnerabilities, open ports,
and URIs for scanner FlexConnectors for normal text reports. See "Getting
Vulnerabilities for Scanned Hosts", "Getting Open Ports on Scanned Hosts", and
"Getting OS and Applications (URIs) on Scanned Hosts".
11/30/2016
l
08/30/2016
l
Reorganized and expanded content for increased usability.
l
Updated the "Configure the JDBC Driver and Windows Authentication” section.
l
06/30/2016
HPE Connectors
l
Updated installation procedure for setting preferred IP address mode. Updated
FlexConnector information for IPv6-aware parsers.
In "Advanced Parameters", updated information regarding preservestate
parameters.
Added parameters to “Parameters Common to all SmartConnectors”.
Page 3 of 241
Developer's Guide
Date
Description
05/16/2016
l
l
03/31/2016
l
l
l
l
l
02/15/2016
HPE Connectors
Updates and clarifications in the “Log Rotation Types” section. Added a section on
the unparsed events detection feature: “Unparsed Events Detection”.
In "Advanced Parameters", clarified the descriptions of several advanced
parameters.
Added advanced parameters to customize connector behavior as Chapter 5.
In "Advanced Parameters", noted that for Syslog connectors, the
persistenceinterval parameter must be a positive integer to enable persistence.
In "Advanced Parameters", noted that the rawlogfolder and usefilequeue
parameters cannot be applied to Syslog Pipe/File Connector.
Added configuration properties for JSON Folder Follower FlexConnector.
Noted that only one question mark is supported for time-based database
FlexConnector queries.
l
Removed agents[x].maxfilesize parameter.
l
End of life for FlexConnector SNMP (install the SmartConnector for SNMP Unified).
l
Added the new feature to detect and log unparsed events.
l
Updated the time format for __parseMutableTimeStamp function.
l
Updated the wildcard parameter default value to use *.
Page 4 of 241
Developer's Guide
Contents
Chapter 1: Overview
13
FlexConnector Development
IPv6-Aware Parsers
Event Fields
Operations
Developer Considerations
Folder Structure
Key Files
13
14
14
14
15
15
16
FlexConnector Management
ArcSight Connector Appliance
ArcSight Management Center
16
16
17
Chapter 2: Choose a FlexConnector Type
19
FlexConnector Types
19
Event Data Format Examples
Log File FlexConnector
ID-Based Database FlexConnector
JSON Folder Follower FlexConnector
Multiple Database FlexConnector
Regex FlexConnectors (Variable-Format File FlexConnectors)
Scanner FlexConnector
SNMP FlexConnector
Syslog FlexConnector
Time-Based Database FlexConnector
XML File FlexConnector
21
22
22
22
23
24
24
25
27
27
28
Chapter 3: Install and Configure the FlexConnector
FlexConnector Installation
Install Core Software
Set Global Parameters (Optional)
Select Connector and Add Parameter Information
ArcSight FlexConnector File
ArcSight FlexConnector ID-Based Database
ArcSight FlexConnector JSON Folder Follower
HPE Connectors
30
30
30
31
32
33
34
36
Page 5 of 241
Developer's Guide
ArcSight FlexConnector Multiple Database
ArcSight FlexConnector Multiple Folder File
ArcSight FlexConnector Regex File
ArcSight FlexConnector Regex Folder File
ArcSight FlexConnector REST
ArcSight FlexConnector Scanner Database
ArcSight FlexConnector Scanner Text Reports
ArcSight FlexConnector Scanner XML Reports
ArcSight FlexConnector XML File
ArcSight FlexConnector Simple Network Management Protocol (SNMP Unified)
ArcSight FlexConnector Syslog
Select a Destination
Complete Installation and Configuration
Additional Configuration for Database Connectors
Install SQL Server JDBC Driver
Install MySQL Driver
Add a JDBC Driver to the Connector Appliance/ArcSight Management Center
Configure the JDBC Driver and Windows Authentication
Oracle 8i Support
Troubleshooting Duplicate Events
Example 1: ID-based Database Connectors Only
Example 2: ID-based and Time-based Connectors
Example 3: Complex Main Query with a Join
37
40
41
42
43
44
47
49
50
51
52
53
53
54
54
56
57
57
58
59
59
60
60
Chapter 4: Create a Configuration File
62
Parser File Locations and Names
62
Example Parser File
63
Parser File Structure
Token Declarations
Token Types
Event Mapping
RequestUrl Event Field
Operations Table
Severity Mapping
Examples
Extra Processors
Key-Value Parsers
64
65
66
66
66
67
68
68
69
71
FlexConnector Creation Wizard for Delimited Log Files
72
HPE Connectors
Page 6 of 241
Developer's Guide
Regex Tool for Regex FlexConnectors
75
Start the FlexConnector
78
Chapter 5: Configuration File Examples
79
Configuration Properties for a Log File FlexConnector
79
Configuration Properties for all Regex FlexConnectors
80
Configuration Properties for a Time-based Database FlexConnector
Version
Query
Timestamp
UniqueID
81
81
82
83
83
Configuration Properties for an ID-based Database FlexConnector
Version
MaxID
Query
ID
UniqueID
Query Limit
83
84
84
84
85
85
85
Configuration Properties for an SNMP Connector
85
Configuration Properties for an XML FlexConnector
Namespace
Hop Nodes
Trigger Nodes
Token Mappings
Examples of Token Mappings
Extra Events
87
88
88
88
89
89
90
Configuration Properties for a JSON Folder Follower FlexConnector
Trigger Node
Token Location and Mappings
JSON Parsers for Complex Event Schemas
Working with Hierarchical Schemas
Representing a JSON Array with a Key Element
Representing a Token Value in URI Format
Sample JSON Array
90
92
92
92
92
94
95
96
Configuration Properties for Scanner FlexConnectors
Scanner FlexConnectors for Normal Text or XML Scan Reports
How Scanner FlexConnectors Parse Scan Reports
96
96
97
HPE Connectors
Page 7 of 241
Developer's Guide
Parser Files for Normal Text Reports
Getting a List of Hosts
Ignore or Include Line
Regular Expression and Token Mappings
Use IP
Invalid Vulnerabilities
Extra Events
Getting Vulnerabilities for Scanned Hosts
Token Mappings
Event Mappings
Severity Mappings
Ignore or Include Line
Getting Open Ports on Scanned Hosts
Token Mappings
Event Mappings
Ignore or Include Line
Getting OS and Applications (URIs) on Scanned Hosts
Token Mappings
Event Mappings
Ignore or Include Line
Configuration Files for XML Reports
Getting a List of Hosts
Token Mappings
Use IP
Invalid Vulnerabilities
Extra Events
Getting Vulnerabilities for Scanned Hosts
Token Mappings
Event Mappings
Severity Mappings
Getting Open Ports on Scanned Hosts
Token Mappings
Event Mappings
Getting OS and Applications (URIs) on Scanned Hosts
Token Mappings
Event Mappings
Scanner FlexConnectors for Database Scan Reports
Getting the Version of the Database
Version
Getting the List of Scan Jobs
HPE Connectors
97
98
99
99
100
100
100
101
102
102
103
103
104
105
105
105
106
106
107
107
107
107
108
108
108
109
109
111
111
112
112
114
114
114
115
115
116
116
116
117
Page 8 of 241
Developer's Guide
Scan Job
Use IP
Invalid Vulnerabilities
Extra Queries
Vulnerability Query
Open Ports Query
Getting OS and Applications (URIs) on Scanned Hosts
Getting Scanned Hosts (Host Query)
117
117
117
118
118
121
122
122
Chapter 6: Advanced Features
124
Regular Expressions
Multi-line Parsing
124
126
Sub-Messages
Default Sub-message
Extra Mappings
Conditional Mappings
Using Conditional Mapping in Sub-messages
Additional Data Mapping
Using the Get Additional Data Names Command
Using the Map Additional Data Name… Command
Using the Unmap Additional Data Name… Command
Using the Get Status Command
130
135
136
138
140
141
141
143
143
144
Log Rotation Types
Name Following Log Rotation
Daily Rotation
Index Rotation
Parameters for Daily and Index Rotation
Using rotationschemeparams for Daily Log File Rotation
Using rotationschemeparams for Index Log File Rotation
Using wildcard for Daily and Index Log File Rotation (File Folder Follower Only)
Using wildcard for Date Rotation
Using wildcard for Index Rotation
144
145
145
145
145
146
147
148
148
148
Log Internal Events for File-Reading FlexConnectors
149
Unparsed Events Detection
Supported Parser Types
Unparsed Events Detection Criteria
Comment Expressions
Parsing Expressions
149
150
150
152
153
HPE Connectors
Page 9 of 241
Developer's Guide
Token Expressions
Mapping Expressions
Extra-Processor Expressions
Criteria for Unparsed Events
Unparsed Events Output File
Chapter 7: Map Files
154
154
155
155
158
160
What Are Map Files?
160
Map File Examples
Multiple "Getters" and "Setters"
Using the “No Getter” Trick
160
161
162
Map File Details
Controlling Map File Operation
Basic Map Files
AgentInfoAdder1 Map Files
Categorizer Map Files
Extra Processor Map Files
162
162
163
164
164
165
Using Ranges in Map Files
165
Using Regular Expressions in Map Files
166
Using Parser-Like Expressions in Map Files
More About Parser-Like Expressions Syntax
Operations Containing Commas
Backslashes in Expressions Versus in Parsers
167
168
168
168
Real World Examples
Adding Country Names to Events
Getting Domain Name from Hostname
169
169
169
Appendix A: ArcSight Operations
171
Appendix B: ArcSight Built-in Tokens
186
Appendix C: ArcSight Built-in Token Types
187
Appendix D: Date and Time Format Symbols
188
Appendix E: ArcSight Built-in Event Field Mappings
189
HPE Connectors
Page 10 of 241
Developer's Guide
Appendix F: Configuring a Connector for ArcSight ESM Domain Field Sets
195
Appendix G: Advanced Parameters
198
Parameters Common to all SmartConnectors
199
CEF Syslog Parameters
201
File Connector Parameters
203
File Folder Follower Parameters
205
Syslog Parameters
Syslog Daemon Parameters
Event Parsing (Sub-agents) Parameters
Event Reception Parameters
Raw Log Parameters
Event Queue Parameters
Event Processing Parameters
Syslog Pipe Parameters
Syslog File Parameters
Syslog NG Daemon Parameters
Raw Syslog Daemon Parameters
ArcSight CEF Encrypted Syslog (UDP) Parameters
TippingPoint SMS Syslog Extended Parameters
209
210
210
211
213
214
215
216
216
218
218
219
219
Appendix H: FlexConnectors and Categorization
Categorization
HTTP Status Code Categorization Example
Firewall Example
220
220
220
222
Appendix I: Developing a Syslog FlexConnector
224
Appendix J: Developing an XML FlexConnector
226
XML FlexConnector Development
226
XML Tools
226
XML Concepts for FlexConnector Development
General XML Concepts
XML FlexConnector Concepts
Namespace
Hop Nodes
227
227
228
228
228
HPE Connectors
Page 11 of 241
Developer's Guide
Trigger Nodes
Token Mappings
Extra Events
Examples of Token Mappings
229
229
229
230
Prepare to Write the Parser - Identify Namespace, Nodes, and Tokens
Find the Trigger Node - the Most Important Step
Decide if You Need a Namespace
Identify Hop Nodes
Identify Tokens
230
231
231
232
232
Create the XML FlexConnector Parser
Parser Development - First Several Lines
Parser Development Continued - Tokens
Parser Development Continued - Mappings
Categorization
Copy the Parser Into the Folder
233
233
234
234
235
235
Install the FlexConnector
236
Appendix K: Frequently Asked Questions
237
Send Documentation Feedback
241
HPE Connectors
Page 12 of 241
Chapter 1: Overview
HPE Security ArcSight provides a range of device-specific SmartConnectors with which to gather
security event information. The connectors send normalized security events to the specified destination
for storage and further processing. For information about the possible destination types, see the
ArcSight SmartConnector User Guide.
FlexConnectors are custom connectors you define to gather security events from log files, databases,
and other software and devices. FlexConnectors let you create custom connectors that can read and
parse information from third-party devices and map that information to ArcSight’s event schema.
FlexConnector Development
This guide describes these basic steps for creating a FlexConnector:
l
l
l
l
l
Deciding the type of FlexConnector to develop based on the source data to be collected. (See
“Choose a FlexConnector Type".)
Providing a log file. For database connectors, this includes developing a query for pulling events.
Installing and configuring one of the FlexConnector types. For SNMP, you install the SNMP Unified
connector; for syslog, you install the Syslog Daemon connector. (See “Install and Configure the
FlexConnector".)
Creating your properties file (parser) and mapping events to ArcSight fields. (See “Create a
Configuration File”.)
Creating the categorization.csv file and assigning appropriate categories. (See “FlexConnectors
and Categorization".)
This guide also describes related topics, such as:
l
Log Rotation Types
l
Unparsed Events Detection
l
Advanced Parameters that can be used to tune the collection process
l
Map Files
l
ArcSight Operations
l
FlexConnectors and Categorization
l
Configuring a Connector for ArcSight ESM Domain Field Sets
HPE Connectors
Page 13 of 241
Developer's Guide
Chapter 1: Overview
IPv6-Aware Parsers
With only a few exceptions, ArcSight connectors fully support both IPv6 and IPv4 addresses for
receiving and processing events. Before support for IPv6 addresses was added, an extra mapping for
setting Device Custom fields to IPv6 addresses was required for mapping IPv6 addresses.
Note: Older FlexConnectors and parsers will continue to use the Device Custom IPv6 Address
fields for IPv6 addresses.
Event Fields
To support IPv6-aware parsers, the following ArcSight event fields can accept both IPv4 and IPv6
addresses. See "ArcSight Built-in Event Field Mappings" for details on the following event fields.
l
Destination Address
l
Destination Translated Address
l
Device Address
l
Device Translated Address
l
Source Address
l
Source Translated Address
The Bytes In and Bytes Out event field parameters have been changed to type Long.
For an IPv6-aware parser, the Device Custom IPv6 Address 1, 2, and 3 fields can contain either IPv4 or
IPv6 addresses. However, these fields should rarely be used. If they are, the corresponding labels should
be set to an appropriate value.
Operations
To support IPv6-aware parsers, the behavior of the following operations has changed. See "ArcSight
Operations" for details.
l
__byteArrayToIPAddress (new parameter)
l
__byteArrayToIPv6
l
__getIPv4AddressEmbeddedInIPv6Address
l
__hexStringToAddress
l
__hexStringToIPV6Address
l
__oneOfAddress
l
__oneOfHostName
l
__stringToIPv6Address
HPE Connectors
Page 14 of 241
Developer's Guide
Chapter 1: Overview
Developer Considerations
l
l
l
l
l
l
l
For an IPv6-aware parser, the main parser and all of the extra processors for the connector should be
marked with the property ipv6.aware=true.
Mixed ranges are not supported (that is, where one end of the range is an IPv4 address and the
other is an IPv6 address).
Because the standard IP address fields (such as Device Address, Source Address, Destination
Address, and so on) support both IPv4 and IPv6 addresses, the Device Custom IPv6 Address fields
are almost never needed in an IPv6-aware parser. These mappings should be redirected to the
standard address fields. If there are any addresses which do not fall into any of the normal device,
source, or destination categories, then the Device Custom IPv6 Address fields can be used, but that
would be a very rare case.
Do not use the __stringToIPv6Address or __byteArrayToIPv6 operations as they are not relevant in
IPv6-aware parsers.
Rename the __byteArrayToIPv6 operation to the new generic __byteArrayToIPAddress operation in
the parser.
The __oneOfAddress operation returns the first non-null IP address whether IPv4 or IPv6, when that
operation is used in an IPv6-aware parser.
The Bytes In and Bytes Out event fields are now type Long.
Folder Structure
The following table lists the connector folder structure after connector installation and configuration,
and describes the contents of each folder.
Directory
Description
$ARCSIGHT_HOME\current\bin
Executables and scripts; for example, runagentsetup.bat .
$ARCSIGHT_HOME\current\config\agent
Default and base configurations; for example,
agent.defaults.properties .
$ARCSIGHT_HOME\current\logs
Generated logs; for example agent.log .
$ARCSIGHT_HOME\current\user\agent
Connector property files and destination-specific configurations;
for example, agent.properties .
$ARCSIGHT_HOME\current\user\agent\agentdata
Queue, cache, and persistence files.
$ARCSIGHT_
HOME\current\user\agent\acp\categorizer\current
Categorizaton files (ArcSight Content), which provide additional
meaning to events.
$ARCSIGHT_HOME\current\user\agent\flexagent
Custom parsers that are developed for the FlexConnector.
$ARCSIGHT_HOME\current\user\agent\map
Mapping files that can be used to set fields in the Security Event
object; for example, map.0.properties .
HPE Connectors
Page 15 of 241
Developer's Guide
Chapter 1: Overview
Key Files
During connector installation and configuration, several key files are created. The following table
describes these files, their locations, and their purpose.
File Name
Path
Description
agent.log
$ARCSIGHT_HOME\current
\logs
Generated log that contains information on the running of the
connector; search for ERROR to see any errors that occurred
during the running of the connector. The most current log is
agent.log , but there can be older logs in the folder as well,
such as agent.log.1 or agent.log.2 .
agent.properties
$ARCSIGHT_HOME\current
\user\agent
Contains configuration parameters and values, created from
the values entered during connector configuration.
agent.default.
properties
$ARCSIGHT_HOME\current\
config\agent
Contains default framework parameters; for example, contains
the syntax for enabling debugging and increasing the
agent.log file size and agent log count. Do not modify
agent.default.properties as it is overwritten when the
connector is upgraded. Make any property changes in
agent.properties .
FlexConnector Management
There are currently two ways to manage SmartConnectors: through ArcSight Management Center (also
referred to as "ArcMC") and through ArcSight Connector Appliance. Eventually, ArcSight Management
Center will replace ArcSight Connector Appliance.
ArcSight Connector Appliance
The ArcSight Connector Appliance is a hardware solution that incorporates a number of onboard
ArcSight SmartConnectors and a web-based user interface that provides centralized management for
SmartConnectors across a potentially large number of hosts.
FlexConnectors can generally be managed by a Connector Appliance and can be hosted on the
appliance if they are compatible with a Linux platform. The Connector Appliance ships with several
prototype FlexConnectors, including the following:
l
ArcSight FlexConnector File
l
ArcSight FlexConnector ID-Based DB
l
ArcSight FlexConnector Multiple DB
l
ArcSight FlexConnector Regex File
HPE Connectors
Page 16 of 241
Developer's Guide
Chapter 1: Overview
l
ArcSight FlexConnector Regex Folder File
l
ArcSight FlexConnector Simple Network Management Protocol (SNMP Unified)
l
ArcSight FlexConnector Time-Based DB
l
ArcSight FlexConnector XML File
For detailed information and instructions for using the Connector Appliance, see the ArcSight
Connector Appliance Administrator’s Guide.
ArcSight Management Center
ArcSight Management Center includes all of the functions of ArcSight Connector Appliances, and also
the ability to manage and monitor an additional range of ArcSight products, such as Connector
Appliances, Loggers, and other ArcSight Management Centers, as illustrated in the following figure.
ArcSight Management Center uses the concept of nodes to manage various entities. A node is a
networked ArcSight product that can be centrally managed using ArcSight Management Center. Each
node is associated with a single networked host that has been assigned either a hostname, an IP
address, or both.
A single host can include multiple nodes. For example, a single Connector Appliance (with a single IP
address or hostname) could have multiple containers, each of which could be a separate node. In
addition, a node can be in a parent or child relationship with other modes.
You can perform any of the following node management tasks:
l
View managed nodes by location, host, or node type
l
Add, view, edit, and delete locations for hosts
HPE Connectors
Page 17 of 241
Developer's Guide
Chapter 1: Overview
l
Add nodes from a host, import hosts from a .csv file, view and delete hosts, view all hosts in a
location, move hosts to different locations, and scan hosts for new connectors or containers
See the ArcSight Management Center Administrator’s Guide for details.
HPE Connectors
Page 18 of 241
Chapter 2: Choose a FlexConnector Type
The FlexConnector type you choose should be based on the format of the security event data.
Examples of data formats for different FlexConnector types are provided in “Event Data Format
Examples”.
FlexConnector Types
The available FlexConnector types are listed in the following table; selection criteria is included.
FlexConnector Type
Description
File
Choose this type if the event data is in log files that use a fixed, delimited format. In this
case, each line in the text file represents a unique event, and each line contains the same
number of fields, in the same order. Fixed-format log files can be delimited by commas,
tabs, or another character, such as a pipe (‘|’).
All file-reader FlexConnectors can process GZIP and ZIP files. Other compression formats
are not supported. Compressed files are processed in batch mode only. The connectors
read the file from the beginning to the end and then stop monitoring the file. See " Log
File FlexConnector" and "ArcSight FlexConnector File".
ID-Based Database
Choose ID-Based Database or Time-Based Database for devices that write security event
information to a database. Each row represents a single event, and the number and
meaning of the columns are fixed. If you use unique IDs to read events from a database,
choose ID-Based Database.
Knowledge of SQL is a prerequisite for coding database FlexConnectors. See " ID-Based
Database FlexConnector" and "ArcSight FlexConnector ID-Based Database".
JSON Folder Follower
Choose this type for devices that write event information to JSON files. Event information
in these files is presented in standard JSON format. This type recursively reads events
from JSON-based files in a folder. See "JSON Folder Follower FlexConnector" and "ArcSight
FlexConnector JSON Folder Follower".
Multiple Database
Choose this type to retrieve information from multiple databases that use the same query
or retrieve different set of events using different queries from the same database.
Knowledge of SQL is a prerequisite for coding database FlexConnectors. See "Multiple
Database FlexConnector" and "ArcSight FlexConnector Multiple Database".
Multiple Folder File
HPE Connectors
Choose this type for devices that write log files to multiple folders. This connector type
can read events in real time or in batch mode. See "Multiple Database FlexConnector" and
"ArcSight FlexConnector Multiple Folder File".
Page 19 of 241
Developer's Guide
Chapter 2: Choose a FlexConnector Type
FlexConnector Type
Description
Regex File
Choose this type if the source log files have one event per line, but the format of each line
varies based on the type of event information. In this case, each line shares a common
section (for example, the date and hostname), but the number and content of the other
fields on the line varies.
The regular expression-based FlexConnectors require a familiarity with Java-compatible
regular expressions. See "Regex FlexConnectors (Variable-Format File FlexConnectors)"
and "ArcSight FlexConnector Regex File".
Regex Folder File
File and Regex File FlexConnectors read events in real time, one line at a time, from a log
file. However, some devices may not write to log files in real time. To read such events, use
a Regex Folder Follower FlexConnector. This connector processes all log files in a specified
folder.
The regular expression-based FlexConnectors require a familiarity with Java-compatible
regular expressions. See "Regex FlexConnectors (Variable-Format File FlexConnectors)"
and "ArcSight FlexConnector Regex Folder File".
REST
The REST FlexConnector uses REST API endpoints, JSON parser, and OAuth2
authentication to collect security events from cloud vendors (such as Salesforce or Google
Apps). See "ArcSight FlexConnector REST". For detailed information about this
FlexConnector, see the ArcSight REST FlexConnector Developer’s Guide for details.
Scanner DB
Scanner Text Reports
Scanner XML Reports
Choose a Scanner FlexConnector type to import the results of a scan from a scanner
device and forward the data to ESM so that ESM can model an organization’s assets, open
ports, operating systems, applications, and vulnerabilities. The connector imports periodic
scans to ESM, which uses this information for event prioritization, reporting, and
correlation.
Database:
A database contains results for multiple scans where each scan is identified by a job
identifier (ID). The scan results are organized in multiple tables that are linked by job IDs
or other IDs. SQL query-based parsers are used to extract relevant information from the
scan results.
Knowledge of SQL is a prerequisite for coding database FlexConnectors. See "Scanner
FlexConnector" and "ArcSight FlexConnector Scanner Database".
HPE Connectors
Page 20 of 241
Developer's Guide
Chapter 2: Choose a FlexConnector Type
FlexConnector Type
Description
Text Reports:
A normal text report contains results for a single scan with each line in the report
containing a piece of information about a host. Regular expression based parsers are used
to extract relevant information from the report.
The regular expression-based FlexConnectors require a familiarity with Java-compatible
regular expressions. See "Scanner FlexConnector" and "ArcSight FlexConnector Scanner
Text Reports".
XML Reports:
An XML report contains results for a single scan with scan results organized in the form of
nested XML elements. XQuery/XPath-based parsers are used to extract relevant
information from the report.
The XML FlexConnector require a familiarity with XML, XPath, and XQuery. See "Scanner
FlexConnector" and "ArcSight FlexConnector Scanner XML Reports".
Time-Based Database
Choose ID-Based Database or Time-Based Database for devices that write security event
information to a database. Each row represents a single event, and the number and
meaning of the columns are fixed. One column represents the event timestamp and can
be used to order the rows. To read events from database table rows, choose Time-Based
DB.
Knowledge of SQL is a prerequisite for coding database FlexConnectors. See "Time-Based
Database FlexConnector" and "ArcSight FlexConnector Time-Based DB".
XML File
Choose this type for devices that write event information to XML files. Event information
in these files is presented in standard XML format, using namespaces, elements,
attributes, text, and cdata. This connector type recursively reads events from XML-based
files in a folder.
The XML FlexConnectors require a familiarity with XML, XPath, and XQuery.
See "XML File FlexConnector" and "ArcSight FlexConnector XML File". See "Developing an
XML FlexConnector" for a description of the development of an example of an XML
FlexConnector.
SNMP Unified
For SNMP devices, choose the SmartConnector for SNMP Unified. See the SmartConnector
configuration guide for installation and configuration information. See "SNMP
FlexConnector" and "ArcSight FlexConnector Simple Network Management Protocol
(SNMP Unified)".
Syslog
For reading events from syslog messages, choose the SmartConnector for Syslog Daemon
and define a Syslog FlexConnector sub-connector to parse syslog packets of interest. See
"Syslog FlexConnector" and "ArcSight FlexConnector Syslog".
Event Data Format Examples
You choose a FlexConnector type based on the format of the event data. The following examples
illustrate the kind of source data expected by the various FlexConnector types.
HPE Connectors
Page 21 of 241
Developer's Guide
Chapter 2: Choose a FlexConnector Type
Log File FlexConnector
The following is an example of a fixed-format, delimited log file. In this example, there are three events;
each has the same format composed of six tokens separated by a comma.
01/01/2016-11:33:00,1.1.1.1,52123,2.2.2.2,80,Invalid URL
01/01/2016-12:43:00,3.3.3.3,49123,2.2.2.2,80,Buffer Overflow Attempt
01/01/2016-13:53:00,4.4.4.4,35123,2.2.2.2,80,Web Cgi Access
ID-Based Database FlexConnector
Two rows of a security event table in a database might look like this. This example describes two events:
one with ID 123456 and another with ID 123457.
EventId
Incident
Time
Signature
SourceIP
Destination
IP
Priority
Protocol
123456
09/01/16
12:56:00
Port Scan
9.10.11.12
13.14.15.16
1
TCP
123457
09/01/16
12:54:00
ICMP Failure
1.2.3.4
5.6.7.8
3
ICMP
JSON Folder Follower FlexConnector
An JSON file with event information might look like this:
{
"chunk_size":100,
"entries":[{
"source":null,
"created_by":{
"type":"user",
"id":"175265599",
"name":"Mary Jane",
"login":"mary.jane@abc.com"
},
"created_at":"1324497497",
"event_id":"13254621",
"event_type":"FAILED_LOGIN",
"ip_address":"192.168.233.76",
"type":"event",
"session_id":null
HPE Connectors
Page 22 of 241
Developer's Guide
Chapter 2: Choose a FlexConnector Type
},
{
"source":null,
"created_by":{
"type":"user",
"id":"175265599",
"name":"Mary Jane",
"login":"mary.jane@abc.com"
},
"created_at":"1324497544",
"event_id":"13254633",
"event_type":"FAILED_LOGIN",
"ip_address":"192.168.233.76",
"type":"event",
"session_id":null
},
{
"source":null,
"created_by":{
"type":"user",
"id":"175265599",
"name":"Mary Jane",
"login":"mary.jane@abc.com"
},
"created_at":"1324497614",
"event_id":"13254649",
"event_type":"LOGIN",
"ip_address":"192.168.233.76",
"type":"event",
"session_id":null
}
]
}
Multiple Database FlexConnector
The Multi-Database FlexConnector reads events from more than one database or multiple event types
from different tables in the same database. For data format examples, see "ID-Based Database
FlexConnector" and "Time-Based Database FlexConnector".
HPE Connectors
Page 23 of 241
Developer's Guide
Chapter 2: Choose a FlexConnector Type
Regex FlexConnectors (Variable-Format File
FlexConnectors)
FlexConnectors , capable of processing variable-format log files, include Regex Log File, Regex Folder
Follower and Regex Multiple Folder Follower. Variable-format log files might look like this:
Aug 21 15:28:49 beach sshd[24939]: Failed password for rajiv from
192.168.10.27 port 33654 ssh2
Aug 21 15:28:51 beach sshd[24939]: Accepted password for rajiv from
192.168.10.27 port 33654 ssh2
Aug 21 15:28:51 beach PAM_unix[24948]: (ssh) session opened for user rajiv by
(uid=525)
Aug 21 15:28:53 beach PAM_unix[24948]: (ssh) session closed for user rajiv
Aug 22 00:13:23 beach sshd[6305]: Did not receive IDentification string from
192.168.10.28
Scanner FlexConnector
The following is an example scan report:
HPE Connectors
Page 24 of 241
Developer's Guide
Chapter 2: Choose a FlexConnector Type
SNMP FlexConnector
SNMP traps contain variables (varbinds) that must be mapped to the ArcSight Database Schema. The
SmartConnector for SNMP Unified supports SNMP traps in versions 1, 2, and 3. The following example
is the output of an SNMP connector when it receives a trap (in this case, generated by SecureNet Pro)
for which it is not yet configured:
[Wed May 21 11:11:17 PDT 2016] [INFO ] Unable to process trap (not
configured) :
Received SNMPv1 trap
Port : 162
Generating Agent : 10.0.112.104
Sending Agent : 10.0.112.104
Time Stamp : 412257333
Enterprise OID : 1.3.6.1.4.1.8678.1.1.2
Trap Type : 1
Var Binds:14
VarBind #0
0.0.0.0.0.0.0.0.412257333.0
StringValue: 439228089
TimeStamp: 0
Value: 439228089
VarBind #1
0.0.0.0.0.0.0.0.412257333.0
StringValue: 439228089
TimeStamp: 0
Type: ASN_INTEGER | ASN_INTEGER32
Value: 439228089
VarBind #2
0.0.0.0.0.0.0.0.412257333.0
StringValue: [] - TCP Connection from 10.0.112.132
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@29e357
VarBind #3
0.0.0.0.0.0.0.0.412257333.0
StringValue: TCP Session Logging
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@ca470
VarBind #4
0.0.0.0.0.0.0.0.412257333.0
HPE Connectors
Page 25 of 241
Developer's Guide
Chapter 2: Choose a FlexConnector Type
StringValue: Miscellaneous
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@7fc686
VarBind #5
0.0.0.0.0.0.0.0.412257333.0
StringValue: TCP (Stream)
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@42bece
VarBind #6
0.0.0.0.0.0.0.0.412257333.0
StringValue: 1
TimeStamp: 0
Type: ASN_INTEGER | ASN_INTEGER32
Value: 1
VarBind #7
0.0.0.0.0.0.0.0.412257333.0
StringValue: 05/21/2003 10:58:26
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@7cfa52
VarBind #8
0.0.0.0.0.0.0.0.412257333.0
StringValue: 00:b0:d0:61:6c:6e
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@161dff
VarBind #9
0.0.0.0.0.0.0.0.412257333.0
StringValue: 00:00:d1:ee:c4:2e
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@b81e3
VarBind #10
0.0.0.0.0.0.0.0.412257333.0
StringValue: 10.0.112.132
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@7c6e42
VarBind #11
0.0.0.0.0.0.0.0.412257333.0
HPE Connectors
Page 26 of 241
Developer's Guide
Chapter 2: Choose a FlexConnector Type
StringValue: 10.0.111.26
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@2af0b3
VarBind #12
0.0.0.0.0.0.0.0.412257333.0
StringValue: 60901
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@2082e2
VarBind #13
0.0.0.0.0.0.0.0.412257333.0
StringValue: 64288
TimeStamp: 0
Type: ASN_OCTSTR
Value: [B@70c85e
Syslog FlexConnector
A security appliance might send syslog messages with the following format:
Myapplication: Intruder Detected from 1.1.1.1 to 2.2.2.2 High
In this case, Myapplication is the name of the security appliance, Intruder Detected is the name
of the event, 1.1.1.1 and 2.2.2.2 are the source and target addresses and High refers to the
severity of the event. This message is not delimited; however, you can identify that this message comes
from the security appliance by the prefix Myapplication. Regular expressions are a simple mechanism
to identify and tokenize the message, so the format of a FlexConnector Syslog configuration file is
similar to the FlexConnector Regex Log-file. The only difference is that the detected time and sending
host will automatically be set by the syslog daemon and only additional mappings need to be specified.
Time-Based Database FlexConnector
Two rows of a security event table in a database might look like this. This example describes two events:
one at 12:56 and another at 12:54.
EventId
Incident
Time
Signature
SourceIP
Destination
IP
Priority
Protocol
CCC-DDD
09/01/16
12:56:00
Port Scan
9.10.11.12
13.14.15.16
1
TCP
AAA-BBB
09/01/16
12:54:00
ICMP Failure
1.2.3.4
5.6.7.8
3
ICMP
HPE Connectors
Page 27 of 241
Developer's Guide
Chapter 2: Choose a FlexConnector Type
XML File FlexConnector
An XML file with event information looks like this:
HPE Connectors
Page 28 of 241
Developer's Guide
Chapter 2: Choose a FlexConnector Type