Skip to content

Splunk SIEM Deployment Guide

github-actions[bot] edited this page Nov 15, 2026 · 1 revision

๐ŸŽฏ Purpose

Splunk SIEM deployment guide - covering installation, index configuration, Universal Forwarder deployment, SPL search queries, dashboards, and detection rule development for Splunk Free (500MB/day) and Enterprise.

โš™๏ธ Function

Covers: Splunk indexer/search head installation, Universal Forwarder setup for Windows/Linux, index and sourcetype configuration, SPL query writing (stats, eval, transaction, lookup), Splunk Security Essentials app, saved searches, alerts, and BOSS of the SOC training data.

๐Ÿ† Goal

Deploy Splunk as a SIEM for security monitoring, with Universal Forwarders on endpoints feeding centralized log analysis and SPL-based detection rules.

๐Ÿ“‹ When to Use

  • Setting up Splunk for a homelab SOC or security training environment
  • Writing SPL queries to hunt for specific attacker behaviors
  • Building Splunk dashboards for security operations
  • Preparing for Splunk Power User or SIEM analyst certification

Splunk is a powerful commercial platform for log aggregation, search, and security analytics. While enterprise licensing can be costly, Splunk offers a Free tier (500 MB/day indexing) and Enterprise Trial (60 days, full features) that are perfect for homelabs, training, and small deployments.

This guide covers deploying Splunk Enterprise, configuring inputs, installing the Universal Forwarder on endpoints, and setting up security monitoring.


๐ŸŽฏ Splunk Editions Comparison

Feature Splunk Free Enterprise Trial Enterprise
Daily Index Volume 500 MB Unlimited Licensed
Duration Perpetual 60 days Licensed
Alerting โŒ โœ… โœ…
User Authentication โŒ โœ… โœ…
Clustering โŒ โœ… โœ…
Apps/Add-ons Limited โœ… โœ…
Support Community Trial Licensed

Tip: For a homelab SIEM, the Free tier is often sufficient. Start with the Enterprise Trial to explore all features, then convert to Free if you don't need alerting.


๐Ÿ“‹ Prerequisites

Server Requirements

Component Minimum Recommended
OS Ubuntu 20.04/22.04, RHEL 8/9 Ubuntu 22.04 LTS
RAM 4 GB 8 GB+
CPU 2 vCPUs 4 vCPUs
Storage 50 GB 200 GB+ SSD

Network Requirements

Port Purpose
8000 Splunk Web UI
8089 Splunk Management/REST API
9997 Forwarder receiving (indexer)
8088 HTTP Event Collector (HEC)
514 Syslog (if configured)

Account Requirements

Create a free Splunk account at splunk.com to download software.


๐Ÿ› ๏ธ Part 1: Server Preparation

Step 1.1: Update System

sudo apt update && sudo apt upgrade -y

Step 1.2: Configure System Limits

Splunk requires increased file descriptor limits:

# Add limits for splunk user
cat << 'EOF' | sudo tee -a /etc/security/limits.conf
splunk soft nofile 65535
splunk hard nofile 65535
splunk soft nproc 20480
splunk hard nproc 20480
EOF

# Disable THP (Transparent Huge Pages)
echo 'never' | sudo tee /sys/kernel/mm/transparent_hugepage/enabled
echo 'never' | sudo tee /sys/kernel/mm/transparent_hugepage/defrag

# Make THP change persistent
cat << 'EOF' | sudo tee /etc/rc.local
#!/bin/bash
echo 'never' > /sys/kernel/mm/transparent_hugepage/enabled
echo 'never' > /sys/kernel/mm/transparent_hugepage/defrag
exit 0
EOF
sudo chmod +x /etc/rc.local

Step 1.3: Create Splunk User

# Create dedicated user
sudo useradd -m -s /bin/bash splunk

# Create installation directory
sudo mkdir -p /opt/splunk
sudo chown splunk:splunk /opt/splunk

๐Ÿš€ Part 2: Splunk Enterprise Installation

Method 1: Manual Installation (Recommended)

Step 2.1: Download Splunk

  1. Go to splunk.com/download
  2. Select Linux โ†’ .deb (for Ubuntu) or .rpm (for RHEL)
  3. Download the package

Or via wget - do not hardcode a version number. Splunk removes old release binaries from its CDN once superseded, so a pinned URL like .../releases/9.2.0/... 404s within a release cycle or two (confirmed: this exact URL is dead). Get the current link from splunk.com/download/splunk-enterprise.html (right-click the download button to copy it), then:

cd /tmp
wget -O splunk.deb "<PASTE-DIRECT-DOWNLOAD-URL-FROM-SPLUNK-WEBSITE>"

Step 2.2: Install Splunk

Debian/Ubuntu:

sudo dpkg -i /tmp/splunk-*.deb

RHEL/CentOS:

sudo rpm -i /tmp/splunk-*.rpm

Step 2.3: Set Ownership

sudo chown -R splunk:splunk /opt/splunk

Step 2.4: Initial Start and Configuration

# Start Splunk and accept license
sudo -u splunk /opt/splunk/bin/splunk start --accept-license

# You'll be prompted to create admin credentials
# Username: admin
# Password: <your-strong-password>

Step 2.5: Enable Boot Start

# Enable systemd service
sudo /opt/splunk/bin/splunk enable boot-start -user splunk -systemd-managed 1

# Verify service
sudo systemctl status Splunkd

Method 2: Docker Installation

Isolated localhost-only lab example (not a production template). Before running Docker Compose, select and review a supported, explicit Splunk Docker image tag from the official Splunk Docker images; do not rely on an implicit latest update. Put SPLUNK_TAG=YOUR_VERIFIED_TAG in a private .env file, replacing the placeholder with the actual supported tag after checking release notes. Generate a separate unique SPLUNK_PASSWORD (at least eight characters) without writing it to terminal history:

(umask 077; python3 -c "import secrets; print('SPLUNK_PASSWORD=' + secrets.token_urlsafe(24))" > .env)
# Add SPLUNK_TAG=<verified image tag> to .env, then protect and never commit it.
chmod 600 .env

Compose refuses to start if either required value is missing. This local example cannot be used for remote forwarders or browsers without a separate, reviewed TLS/network configuration.

Create docker-compose.yml:

version: '3.8'

services:
  splunk:
    image: splunk/splunk:${SPLUNK_TAG:?Set vetted SPLUNK_TAG in .env}
    container_name: splunk
    environment:
      - SPLUNK_START_ARGS=--accept-license
      - SPLUNK_PASSWORD=${SPLUNK_PASSWORD:?Set SPLUNK_PASSWORD in .env}
      - SPLUNK_LICENSE_URI=Free
    ports:
      # Loopback-only educational lab. No remote clients, management or ingest
      # can reach these published ports until separately designed and approved.
      - "127.0.0.1:8000:8000"
      - "127.0.0.1:8089:8089"
      - "127.0.0.1:9997:9997"
      - "127.0.0.1:8088:8088"
      - "127.0.0.1:514:514/udp"
    volumes:
      - splunk-var:/opt/splunk/var
      - splunk-etc:/opt/splunk/etc
    restart: unless-stopped

volumes:
  splunk-var:
  splunk-etc:

Start the container:

docker compose up -d
docker compose logs -f

Step 2.6: Access Splunk Web

On the Docker host only, open http://127.0.0.1:8000 for this isolated lab. Because plaintext HTTP is used here, do not put credentials on an untrusted network, forward the port to the internet, or use this URL remotely. For remote management, enable supported Splunk Web TLS with a trusted certificate and use a restricted management path (for example, a reviewed VPN or SSH tunnel). See Splunk Web HTTPS configuration and Docker Compose port binding behavior.

This demonstration binds all listed host ports to loopback. If you need real forwarders, syslog or HEC clients, design separate limited ingress with source-IP restrictions, TLS, explicit credentials and data-retention controls before changing any bind addresses.


๐Ÿ”ฅ Part 3: Firewall Configuration

Default: no inbound rules are needed for the localhost-only Docker example. Do not apply blanket allow rules to TCP 8000/8089/9997/8088 or UDP 514. Publishing Docker ports on all interfaces can bypass assumptions about host firewalls.

For an approved non-lab deployment, create a narrowly scoped ingress plan and validate it with a separate authorized client. On a host with UFW, a scoped forwarder rule can look like this only after substituting an actual approved source:

# Example documentation address: replace 192.0.2.20 with an approved forwarder IP.
# Apply only after changing the Docker binding and enabling supported TLS.
sudo ufw allow from 192.0.2.20 to any port 9997 proto tcp comment "Approved Splunk forwarder"
sudo ufw status numbered

For firewalld, use an appropriate source-restricted zone or rich rule instead of broad --add-port on the public zone. Splunk Web (8000) and management (8089) should normally stay on a restricted administration path; HEC (8088) requires authenticated HTTPS and explicit clients, and syslog (514) needs its own trusted-source and encryption plan. Do not assume firewall changes alone override Docker-published port behavior.


๐Ÿ“ฅ Part 4: Configure Data Inputs

Step 4.1: Enable Receiving (for Forwarders)

  1. Navigate to Settings โ†’ Forwarding and receiving
  2. Click Configure receiving
  3. Click New Receiving Port
  4. Enter port: 9997
  5. Click Save

Or via CLI:

# Use interactive authentication; avoid placing passwords in shell arguments/history.
sudo -u splunk /opt/splunk/bin/splunk enable listen 9997

Step 4.2: Configure Syslog Input

Via Web UI:

  1. Navigate to Settings โ†’ Data inputs
  2. Click UDP โ†’ New Local UDP
  3. Port: 514
  4. Source type: syslog
  5. Index: main (or create a dedicated index)
  6. Click Next โ†’ Review โ†’ Submit

Via inputs.conf:

Create /opt/splunk/etc/system/local/inputs.conf:

[udp://514]
connection_host = dns
sourcetype = syslog
index = main

[tcp://514]
connection_host = dns
sourcetype = syslog
index = main

Restart Splunk:

sudo systemctl restart Splunkd

Step 4.3: Enable HTTP Event Collector (HEC)

HEC allows applications to send data via HTTP/HTTPS.

  1. Navigate to Settings โ†’ Data inputs
  2. Click HTTP Event Collector
  3. Click Global Settings
  4. Set All Tokens to Enabled
  5. Click Save
  6. Click New Token
  7. Name: default-hec-token
  8. Click Next โ†’ Select indexes โ†’ Review โ†’ Submit
  9. Copy the generated token

๐Ÿ“Š Part 5: Create Indexes

Organize your data with dedicated indexes.

Via Web UI

  1. Navigate to Settings โ†’ Indexes
  2. Click New Index
  3. Configure:
    • Index Name: windows
    • Max Size: 50 GB
    • Retention: 30 days
  4. Click Save

Create these recommended indexes:

Index Name Purpose
windows Windows Event Logs
linux Linux system logs
network Firewall, switch, router logs
sysmon Sysmon events
dns DNS query logs
web Web server access logs

Via CLI

sudo -u splunk /opt/splunk/bin/splunk add index windows -maxDataSize auto_high_volume -auth admin:YourPassword
sudo -u splunk /opt/splunk/bin/splunk add index linux -auth admin:YourPassword
sudo -u splunk /opt/splunk/bin/splunk add index network -auth admin:YourPassword
sudo -u splunk /opt/splunk/bin/splunk add index sysmon -auth admin:YourPassword

๐Ÿ–ฅ๏ธ Part 6: Windows Universal Forwarder Deployment

The Splunk Universal Forwarder (UF) is a lightweight agent that ships logs to Splunk.

Step 6.1: Download Universal Forwarder

Download from splunk.com/download/universal-forwarder

Or via PowerShell - again, get the current URL from the download page rather than hardcoding a version (this exact 9.2.0 URL is already dead):

# Download (check website for current version)
$url = "https://www.splunk.com/en_us/download/universal-forwarder.html"
Invoke-WebRequest -Uri $url -OutFile "$env:TEMP\splunkforwarder.msi"

Step 6.2: Install with Configuration

Interactive Installation:

Start-Process msiexec.exe -ArgumentList "/i $env:TEMP\splunkforwarder.msi AGREETOLICENSE=Yes /quiet" -Wait

Silent Installation with Pre-configuration:

# Prompt for the forwarder admin password (not echoed, not stored in the script)
$env:SPLUNK_FWD_PASSWORD = [System.Net.NetworkCredential]::new('', (Read-Host -AsSecureString 'Forwarder admin password')).Password
# Install with deployment server or direct indexer configuration
$msiArgs = @(
    "/i"
    "$env:TEMP\splunkforwarder.msi"
    "AGREETOLICENSE=Yes"
    "RECEIVING_INDEXER=<SPLUNK-SERVER-IP>:9997"
    "SPLUNKUSERNAME=admin"
    "SPLUNKPASSWORD=$env:SPLUNK_FWD_PASSWORD"   # set just before running; never hard-code
    "WINEVENTLOG_SEC_ENABLE=1"
    "WINEVENTLOG_SYS_ENABLE=1"
    "WINEVENTLOG_APP_ENABLE=1"
    "/quiet"
)
Start-Process msiexec.exe -ArgumentList $msiArgs -Wait
Remove-Item Env:SPLUNK_FWD_PASSWORD

Step 6.3: Configure Inputs

Create C:\Program Files\SplunkUniversalForwarder\etc\system\local\inputs.conf:

# ==================== Windows Event Logs ====================

[WinEventLog://Security]
disabled = 0
index = windows
sourcetype = WinEventLog:Security

[WinEventLog://System]
disabled = 0
index = windows
sourcetype = WinEventLog:System

[WinEventLog://Application]
disabled = 0
index = windows
sourcetype = WinEventLog:Application

# ==================== Sysmon Events ====================

[WinEventLog://Microsoft-Windows-Sysmon/Operational]
disabled = 0
index = sysmon
sourcetype = XmlWinEventLog:Microsoft-Windows-Sysmon/Operational
renderXml = true

# ==================== PowerShell Logging ====================

[WinEventLog://Microsoft-Windows-PowerShell/Operational]
disabled = 0
index = windows
sourcetype = WinEventLog:PowerShell

[WinEventLog://Windows PowerShell]
disabled = 0
index = windows
sourcetype = WinEventLog:PowerShell

# ==================== Windows Defender ====================

[WinEventLog://Microsoft-Windows-Windows Defender/Operational]
disabled = 0
index = windows
sourcetype = WinEventLog:Defender

Step 6.4: Configure Outputs

Create C:\Program Files\SplunkUniversalForwarder\etc\system\local\outputs.conf:

[tcpout]
defaultGroup = splunk-indexers

[tcpout:splunk-indexers]
server = <SPLUNK-SERVER-IP>:9997

[tcpout-server://<SPLUNK-SERVER-IP>:9997]

Step 6.5: Restart Forwarder

# Restart service
Restart-Service SplunkForwarder

# Verify status
Get-Service SplunkForwarder

๐Ÿง Part 7: Linux Universal Forwarder Deployment

Step 7.1: Download and Install

Get the current package URL from splunk.com/download/universal-forwarder - the 9.2.0 URLs previously here are dead (Splunk purges old release binaries).

Debian/Ubuntu:

# Download (check website for current version)
wget -O /tmp/splunkforwarder.deb "<PASTE-DIRECT-DOWNLOAD-URL-FROM-SPLUNK-WEBSITE>"

# Install
sudo dpkg -i /tmp/splunkforwarder.deb

RHEL/CentOS:

wget -O /tmp/splunkforwarder.rpm "<PASTE-DIRECT-DOWNLOAD-URL-FROM-SPLUNK-WEBSITE>"

sudo rpm -i /tmp/splunkforwarder.rpm

Step 7.2: Configure Forwarder

# Accept license and set credentials
sudo /opt/splunkforwarder/bin/splunk start --accept-license

# Add forward server
sudo /opt/splunkforwarder/bin/splunk add forward-server <SPLUNK-SERVER-IP>:9997 -auth admin:YourPassword

# Add monitored files
sudo /opt/splunkforwarder/bin/splunk add monitor /var/log/syslog -index linux -sourcetype syslog
sudo /opt/splunkforwarder/bin/splunk add monitor /var/log/auth.log -index linux -sourcetype linux_secure
sudo /opt/splunkforwarder/bin/splunk add monitor /var/log/audit/audit.log -index linux -sourcetype linux_audit

Step 7.3: Configure via Files

Create /opt/splunkforwarder/etc/system/local/inputs.conf:

[monitor:///var/log/syslog]
disabled = false
index = linux
sourcetype = syslog

[monitor:///var/log/auth.log]
disabled = false
index = linux
sourcetype = linux_secure

[monitor:///var/log/secure]
disabled = false
index = linux
sourcetype = linux_secure

[monitor:///var/log/audit/audit.log]
disabled = false
index = linux
sourcetype = linux_audit

[monitor:///var/log/messages]
disabled = false
index = linux
sourcetype = syslog

Create /opt/splunkforwarder/etc/system/local/outputs.conf:

[tcpout]
defaultGroup = splunk-indexers

[tcpout:splunk-indexers]
server = <SPLUNK-SERVER-IP>:9997

Step 7.4: Enable Boot Start

sudo /opt/splunkforwarder/bin/splunk enable boot-start -user splunk
sudo systemctl start SplunkForwarder
sudo systemctl status SplunkForwarder

๐Ÿ”Ž Part 8: Essential Splunk Apps

Install Apps from Splunkbase

  1. Navigate to Apps โ†’ Find More Apps
  2. Search for the app
  3. Click Install
  4. Enter your Splunk.com credentials

Recommended Security Apps

App Purpose Link
Splunk Security Essentials Pre-built security detections Splunkbase
Sysmon Add-on Parse Sysmon events Splunkbase
Windows Add-on Parse Windows events Splunkbase
Linux Add-on Parse Linux events Splunkbase
MITRE ATT&CK App Map detections to ATT&CK Splunkbase
SA-Investigator Investigation workspace Splunkbase

Install via CLI

# Download app from Splunkbase, then:
sudo -u splunk /opt/splunk/bin/splunk install app /path/to/app.tgz -auth admin:YourPassword
sudo systemctl restart Splunkd

๐Ÿ“Š Part 9: Splunk Search (SPL) Basics

Search Processing Language (SPL)

Basic Search Structure

index=<index> sourcetype=<sourcetype> <search_terms>
| <command1>
| <command2>
| <command3>

Time Modifiers

earliest=-24h latest=now
earliest=-7d@d latest=@d
earliest=01/01/2024:00:00:00 latest=01/31/2024:23:59:59

Security-Focused Searches

Failed Windows Logins

index=windows sourcetype="WinEventLog:Security" EventCode=4625
| stats count by Account_Name, Source_Network_Address
| sort -count
| head 20

Successful Logins from Unusual Locations

index=windows sourcetype="WinEventLog:Security" EventCode=4624 Logon_Type=10
| stats count by Account_Name, Source_Network_Address
| sort -count

Sysmon Process Creation

index=sysmon EventCode=1
| table _time, Computer, User, Image, CommandLine, ParentImage
| sort -_time

Encoded PowerShell Detection

index=sysmon EventCode=1 Image="*powershell.exe"
| where match(CommandLine, "(?i)(-enc|-encodedcommand|frombase64string)")
| table _time, Computer, User, CommandLine

Network Connections to External IPs

index=sysmon EventCode=3 
| where NOT cidrmatch("10.0.0.0/8", DestinationIp) AND NOT cidrmatch("192.168.0.0/16", DestinationIp) AND NOT cidrmatch("172.16.0.0/12", DestinationIp)
| stats count by Image, DestinationIp, DestinationPort
| sort -count

LSASS Access (Credential Dumping)

index=sysmon EventCode=10 TargetImage="*lsass.exe"
| table _time, Computer, SourceImage, SourceUser, GrantedAccess

New Service Installation

index=windows sourcetype="WinEventLog:System" EventCode=7045
| table _time, ComputerName, Service_Name, Service_File_Name, Service_Type

Registry Run Key Modifications

index=sysmon EventCode=13 TargetObject="*CurrentVersion\\Run*"
| table _time, Computer, User, Image, TargetObject, Details

Dashboard Searches

Top Talkers by Event Count

index=* earliest=-24h
| stats count by host
| sort -count
| head 10

Events Over Time

index=windows earliest=-7d
| timechart span=1h count by EventCode

Authentication Summary

index=windows sourcetype="WinEventLog:Security" (EventCode=4624 OR EventCode=4625)
| eval Status=if(EventCode=4624, "Success", "Failure")
| stats count by Status, Account_Name
| sort -count

๐Ÿšจ Part 10: Alerting (Enterprise Only)

Create a Basic Alert

  1. Run a search that returns results you want to alert on
  2. Click Save As โ†’ Alert
  3. Configure:
    • Title: Multiple Failed Logins
    • Permissions: Private or Shared in App
    • Alert type: Scheduled or Real-time
    • Trigger condition: Number of Results > 5
    • Trigger Actions: Email, Webhook, Run Script

Example Alert: Brute Force Detection

Search:

index=windows sourcetype="WinEventLog:Security" EventCode=4625
| stats count by Account_Name, Source_Network_Address
| where count > 10

Schedule: Every 15 minutes

Trigger: When number of results > 0

Example Alert: Suspicious Process

Search:

index=sysmon EventCode=1
| where match(Image, "(?i)(mimikatz|procdump|psexec|cobalt)")
| table _time, Computer, User, Image, CommandLine

Schedule: Real-time

Trigger: When number of results > 0


๐Ÿ”„ Part 11: Data Retention Management

Configure Index Retention

Edit /opt/splunk/etc/system/local/indexes.conf:

[windows]
homePath = $SPLUNK_DB/windows/db
coldPath = $SPLUNK_DB/windows/colddb
thawedPath = $SPLUNK_DB/windows/thaweddb
maxDataSize = auto_high_volume
maxTotalDataSizeMB = 50000
frozenTimePeriodInSecs = 2592000  # 30 days

[linux]
homePath = $SPLUNK_DB/linux/db
coldPath = $SPLUNK_DB/linux/colddb
thawedPath = $SPLUNK_DB/linux/thaweddb
maxTotalDataSizeMB = 20000
frozenTimePeriodInSecs = 2592000  # 30 days

[sysmon]
homePath = $SPLUNK_DB/sysmon/db
coldPath = $SPLUNK_DB/sysmon/colddb
thawedPath = $SPLUNK_DB/sysmon/thaweddb
maxTotalDataSizeMB = 100000
frozenTimePeriodInSecs = 7776000  # 90 days

Monitor Index Usage

| dbinspect index=* 
| stats sum(sizeOnDiskMB) as "Size (MB)" by index
| sort -"Size (MB)"

โ— Part 12: Troubleshooting

Splunk Won't Start

Check logs:

tail -f /opt/splunk/var/log/splunk/splunkd.log

Common issues:

Error Solution
Splunk has not been started Run /opt/splunk/bin/splunk start
License violation Check license usage, reduce indexing
Port already in use Change ports in web.conf/server.conf
Insufficient disk space Free space or adjust retention

Forwarder Not Sending Data

Check forwarder status:

# Linux
/opt/splunkforwarder/bin/splunk list forward-server

# Windows
& "C:\Program Files\SplunkUniversalForwarder\bin\splunk.exe" list forward-server

Test connectivity:

# From forwarder to indexer
nc -zv <SPLUNK-IP> 9997
telnet <SPLUNK-IP> 9997

Check forwarder logs:

# Linux
tail -f /opt/splunkforwarder/var/log/splunk/splunkd.log

# Windows
Get-Content "C:\Program Files\SplunkUniversalForwarder\var\log\splunk\splunkd.log" -Tail 50

No Data in Search

  1. Verify time range: Adjust the time picker
  2. Check index: Ensure you're searching the correct index
  3. Verify data input: Settings โ†’ Data inputs โ†’ check status
  4. Check forwarder: Run | metadata type=hosts to see reporting hosts

License Exceeded (Free Tier)

# Check daily indexing volume
index=_internal source=*license_usage.log type=Usage
| timechart span=1d sum(b) as bytes
| eval GB=round(bytes/1024/1024/1024, 2)

Solutions:

  • Filter unnecessary events at the forwarder level
  • Reduce log verbosity on sources
  • Upgrade to Enterprise Trial/License

๐Ÿ›ก๏ธ Part 13: Security Hardening

Change Default Ports

Edit /opt/splunk/etc/system/local/web.conf:

[settings]
httpport = 8443
enableSplunkWebSSL = true

Enable SSL

# Generate self-signed certificate
sudo -u splunk /opt/splunk/bin/splunk createssl server-cert -d /opt/splunk/etc/auth

# Or use your own certificates

Configure Authentication

LDAP Integration:

  1. Navigate to Settings โ†’ Authentication Methods
  2. Select LDAP
  3. Configure LDAP server settings
  4. Map LDAP groups to Splunk roles

SAML Integration:

  1. Navigate to Settings โ†’ Authentication Methods
  2. Select SAML
  3. Upload IdP metadata
  4. Configure attribute mapping

Audit Logging

Enable audit logging in /opt/splunk/etc/system/local/audit.conf:

[auditTrail]
privateKey = $SPLUNK_HOME/etc/auth/audit/private.pem
publicKey = $SPLUNK_HOME/etc/auth/audit/public.pem

๐Ÿ“š Part 14: Additional Resources

Documentation

Community & Training

Detection Content


๐Ÿ—‚๏ธ Quick Reference

Service Commands

OS Start Stop Restart Status
Linux (Splunk) systemctl start Splunkd systemctl stop Splunkd systemctl restart Splunkd systemctl status Splunkd
Linux (Forwarder) systemctl start SplunkForwarder systemctl stop SplunkForwarder systemctl restart SplunkForwarder systemctl status SplunkForwarder
Windows (Forwarder) Start-Service SplunkForwarder Stop-Service SplunkForwarder Restart-Service SplunkForwarder Get-Service SplunkForwarder

CLI Commands

Command Purpose
splunk start Start Splunk
splunk stop Stop Splunk
splunk restart Restart Splunk
splunk status Check status
splunk add monitor <path> Add file monitoring
splunk add forward-server <ip:port> Add forward server
splunk list forward-server List forward servers
splunk btool inputs list Debug inputs configuration

File Locations

Component Path
Splunk Home /opt/splunk/
Forwarder Home /opt/splunkforwarder/ (Linux) or C:\Program Files\SplunkUniversalForwarder\ (Windows)
Local Config $SPLUNK_HOME/etc/system/local/
Apps $SPLUNK_HOME/etc/apps/
Logs $SPLUNK_HOME/var/log/splunk/
Data $SPLUNK_HOME/var/lib/splunk/

Common SPL Commands

Command Purpose Example
stats Calculate statistics stats count by host
table Format output as table table _time, host, message
sort Sort results sort -count (descending)
head Return first N results head 10
timechart Time-based chart timechart span=1h count
where Filter with expressions where count > 10
eval Create/modify fields eval GB=bytes/1024/1024/1024
rex Extract with regex rex field=message "user=(?<user>\w+)"
dedup Remove duplicates dedup host, user
transaction Group related events transaction host maxspan=5m

Part of the Incident Response & Log Aggregation Branch

Related Files


๐Ÿ“„ Source: IncidentResponse/SIEM/splunk.md | โœ๏ธ Suggest an edit | โฌ…๏ธ Back to Incident Response

Clone this wiki locally