Skip to content

Commit fb3cc3b

Browse files
committed
Full draft with tabs
1 parent cb02d39 commit fb3cc3b

File tree

1 file changed

+64
-13
lines changed

1 file changed

+64
-13
lines changed

articles/sentinel/connect-cef-agent.md

Lines changed: 64 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -50,30 +50,81 @@ Continue to [STEP 2: Configure your security solution to forward CEF messages](c
5050

5151
The following is a command-by-command description of the actions of the deployment script.
5252

53-
**Downloading and installing the Log Analytics agent:**
53+
Choose a syslog daemon to see the appropriate description.
5454

55-
1. Downloads the installation script for the Log Analytics (OMS) Linux agent<br>`wget https://raw.githubusercontent.com/Microsoft/OMS-Agent-for-Linux/master/installer/scripts/onboard_agent.sh`
55+
# [rsyslog daemon](#tab/rsyslog)
5656

57-
1. Installs the Log Analytics agent<br>`sh onboard_agent.sh -w [workspaceID] -s [Primary Key] -d opinsights.azure.com`
57+
1. **Downloading and installing the Log Analytics agent:**
5858

59-
**Configuring the Syslog daemon:**
59+
- Downloads the installation script for the Log Analytics (OMS) Linux agent<br>
60+
`wget https://raw.githubusercontent.com/Microsoft/OMS-Agent-for-Linux/master/installer/scripts/onboard_agent.sh`
6061

61-
# [rsyslog daemon](#tab/rsyslog)
62+
- Installs the Log Analytics agent<br>
63+
`sh onboard_agent.sh -w [workspaceID] -s [Primary Key] -d opinsights.azure.com`
64+
65+
1. **Configuring the Syslog daemon:**
66+
67+
1. Opens port 514 for TCP communication using the syslog configuration file `/etc/rsyslog.conf`.
68+
69+
1. Configures the daemon to forward CEF messages to the Log Analytics agent on TCP port 25226, by inserting a special configuration file `security-config-omsagent.conf` into the syslog daemon directory `/etc/rsyslog.d/`.
70+
71+
Contents of the `security-config-omsagent.conf` file:
72+
73+
:rawmsg, regex, "CEF\|ASA" ~
74+
*.* @@127.0.0.1:25226
75+
76+
1. **Restarting the Syslog daemon**
6277

63-
Content for rsyslog...
78+
`service rsyslog restart`
6479

80+
1. **Setting the Log Analytics agent configuration to listen on port 25226 and forward CEF messages to Azure Sentinel**
81+
82+
1. Downloads the configuration from the Log Analytics agent GitHub repository<br>
83+
`wget -o /etc/opt/microsoft/omsagent/[workspaceID]/conf/omsagent.d/security_events.conf https://raw.githubusercontent.com/microsoft/OMS-Agent-for-Linux/master/installer/conf/omsagent.d/security_events.conf`
84+
85+
86+
1. Restarts the Log Analytics agent<br>
87+
`/opt/microsoft/omsagent/bin/service_control restart [workspaceID]`
6588

6689
# [syslog-ng daemon](#tab/syslogng)
6790

68-
Content for syslog-ng...
91+
1. **Downloading and installing the Log Analytics agent:**
92+
93+
- Downloads the installation script for the Log Analytics (OMS) Linux agent<br>`wget https://raw.githubusercontent.com/Microsoft/OMS-Agent-for-Linux/master/installer/scripts/onboard_agent.sh`
94+
95+
- Installs the Log Analytics agent<br>`sh onboard_agent.sh -w [workspaceID] -s [Primary Key] -d opinsights.azure.com`
96+
97+
1. **Configuring the Syslog daemon:**
98+
99+
1. Opens port 514 for TCP communication using the syslog configuration file `/etc/syslog-ng/syslog-ng.conf`.
100+
101+
1. Configures the daemon to forward CEF messages to the Log Analytics agent on TCP port 25226, by inserting a special configuration file `security-config-omsagent.conf` into the syslog daemon directory `/etc/syslog-ng/conf.d/`.
102+
103+
Contents of the `security-config-omsagent.conf` file:
104+
105+
filter f_oms_filter {match(\"CEF\|ASA\" ) ;};
106+
destination oms_destination {tcp(\"127.0.0.1\" port("25226"));};
107+
log {source(s_src);filter(f_oms_filter);destination(oms_destination);};
108+
109+
1. **Restarting the Syslog daemon**
110+
111+
`service syslog-ng restart`
112+
113+
1. **Setting the Log Analytics agent configuration to listen on port 25226 and forward CEF messages to Azure Sentinel**
114+
115+
1. Downloads the configuration from the Log Analytics agent GitHub repository<br>
116+
`wget -o /etc/opt/microsoft/omsagent/[workspaceID]/conf/omsagent.d/security_events.conf https://raw.githubusercontent.com/microsoft/OMS-Agent-for-Linux/master/installer/conf/omsagent.d/security_events.conf`
117+
118+
119+
1. Restarts the Log Analytics agent<br>
120+
`/opt/microsoft/omsagent/bin/service_control restart [workspaceID]`
121+
122+
123+
124+
125+
69126

70-
---
71127

72-
|Action |rsyslog daemon |syslog-ng daemon |
73-
|--------------|------------------|-------------------|
74-
|Open port 514 for TCP communication<br>using syslog configuration file|`/etc/rsyslog.conf`|`/etc/syslog-ng/syslog-ng.conf`|
75-
|Configure the daemon to forward CEF messages<br>to the Log Analytics agent on localhost, on TCP port 25226, by inserting a special omsagent configuration file into the syslog daemon directory|`/etc/rsyslog.d/security-config-omsagent.conf`|`/etc/syslog-ng/conf.d/security-config-omsagent.conf`|
76-
|File contents:|`:rawmsg, regex, "CEF\|ASA" ~`<br>`*.* @@127.0.0.1:25226`|`filter f_oms_filter {match(\"CEF\|ASA\" ) ;};`<br>`destination oms_destination {tcp(\"127.0.0.1\" port("25226"));};`<br>`log {source(s_src);filter(f_oms_filter);destination(oms_destination);};`|
77128

78129

79130

0 commit comments

Comments
 (0)