This post includes instructions for configuring Splunk Universal Forwarder for ingesting Teleport Audit Logs into your Splunk Enterprise Server.
On the server where you are running the Teleport Auth role, do the following.
Note: The below is specific to Ubuntu and may differ slightly for your operating system.
- Download the Splunk Forwarder for your distro. The downloads page is located here.
- After downloading the universal forwarder, install the packge.
dpkg -i splunkforwarder...
- Enable the forwarder to start at boot. There’s a handy command that will install an init script. For more options (i.e. to use systemd), see this documentation.
cd /opt/splunkforwarder/bin && ./splunk enable boot-start
- Add a forward server.
./splunk add forward-server \<splunk-enterprise-host\>:9997 -auth \<username\>:\<password\>
- Add a monitor.
./splunk add monitor /var/lib/teleport/log/events.log -auth \<username\>:\<password\>
- Restart the universal forwarder.
- Log in to Teleport to generate a few events.
- Verify you are receiving events on the Splunk Enterprise Server.
The Splunk Enterprise Server enables line merge functionality by default. To prevent Splunk from merging lines, you should disable this feature on your Splunk Enterprise Server for Teleport audit events.
On your Splunk Enterprise server, create a props file (typically in /opt/splunk/etc/system/local/props.conf) with the following contents:
[host::\<teleport server name\>] KV_MODE = json SHOULD_LINEMERGE = false