Skip to content
Sign inGet started
All posts

Talon Studio on Splunk: detections as code, shipped as one app

A lot of detection teams run on Splunk. Talon Studio keeps every detection in Git and ships a workspace to Splunk Enterprise or Splunk Cloud Platform as a single app, then watches how each rule behaves once it's live: whether it runs, what it costs, and whether it ever fires.

By Talon Labs4 min read

  • Talon Studio
  • Splunk
  • Detection engineering

Splunk Enterprise and Splunk Cloud Platform are where a lot of detection engineering still happens, and where a lot of it gets hard to manage. Saved searches are edited in the UI by several people, nobody is sure which version is live, and a rule can stop running for weeks before anyone notices.

Talon Studio treats Splunk the way it treats every SIEM it supports: Git is the source of truth, the SIEM runs what Git says, and Studio checks afterwards that it really does.

As everywhere else, Talon Studio does not ingest your data. Splunk indexes the events. Studio reads Splunk's field catalogue, sourcetypes, saved searches and scheduler history over the REST API, and writes only its own app.

One app per workspace

Every detection is a YAML file in the workspace's Git repository, with its Sigma rule and, where it has one, its own SPL. Only what is committed to main ships, and drafts stay drafts.

Studio builds the whole workspace into one Splunk app, talon_studio, as a single commit. The app holds one savedsearches.conf stanza per detection (Talon - <technique> - <name>), the macros and lookups those searches use (kept in Forge → Macros & Lookups), a manifest and a dashboard. A detection with no SPL of its own is converted from its Sigma rule when the app is built, and the YAML is never rewritten.

The app installs on Splunk Cloud Platform through ACS, or on Splunk Enterprise over REST or SSH. Reinstalling replaces the app, so a detection removed or deprecated in Git is gone from Splunk on the next deploy, and a REST install also removes old copies of Talon searches that earlier versions left in the Search app, so nothing fires twice. A commit or merged change request on main can rebuild and deploy the app on its own.

How it looks in Splunk

A detection with a risk model becomes a Splunk Enterprise Security correlation search, with its ATT&CK and analytic story annotations, risk-based alerting and a notable at the detection's severity. Hunting and baseline detections add risk but raise no notable. A detection without a risk model is a plain scheduled alert, listed under Activity → Triggered Alerts with its severity, so a match is visible even without Enterprise Security.

Talon SOC reads Splunk's fired alerts, with or without Enterprise Security, and can also take each match as it fires through a webhook. Throttling lives in the YAML too: x_splunk.throttle_period and x_splunk.throttle_fields fire a rule once per period for each distinct field value, and a change request shows hits and alerts after throttling.

Before a rule ships

The library holds the public Splunk Security Content alongside Sigma and the other SIEMs' rule sets, and Deploy next ranks the library rules worth deploying in this workspace: ones that cover ATT&CK techniques nothing covers yet, that the actors on the threat profile use, and that Splunk has the data to run, each with its reasons.

Forge Library on a Splunk workspace: rules Splunk has the data to run, and Deploy next

From there:

  • Estimate runs a rule's search over the last 7 days and says how many alerts it would have raised, before anything is saved. A change request's estimate runs only read-only searches.
  • Golden events run on Splunk itself, without reading your data, as a self-test that a rule fires on the events it's meant to catch. A pass is a self-test, not validation.
  • Query cost warnings flag index=*, leading wildcards, join, search * and similar patterns. They're advice and never block.
  • Pilot. pilot: true in the YAML deploys a rule on real data with no notable, no risk event and no SOC webhook. Its results show in Monitor, and Promote opens a change request that removes the flag, so going live goes through review.
  • Threat Scenarios chain existing detections into one risk-incident search, which raises a single notable when one risk object builds up risk across every stage inside a time window.

After it's live

Rule health reads Splunk's scheduler history for every rule, Talon's and the ones that were there before, and grades each one.

Rule health on a Splunk workspace: each installed rule graded, with the signals that brought it down

  • Stopped running. A rule whose scheduled runs are skipped or failing is flagged, and Re-run missed windows dispatches the saved search as of each skipped run's scheduled time, over the last 7 days, with its alerts on.
  • Slow search and high volume. A rule whose slowest run takes over half its schedule, that averages five minutes or more, or that returns more than 100 results a day becomes a triage item.
  • Never fires. A rule that hasn't matched in its window is marked, so a silent rule doesn't look like a quiet network.
  • A value stops arriving. When a value a detection matches on, such as EventCode=4625, drops to none while its source keeps sending, the sync flags it.

Vantage follows the data to Splunk too, including Splunk's own props.conf and transforms.conf and their field aliases, so a coverage question includes how a field got its name.

What we checked, and what we haven't

Splunk is tested live on every Talon Studio pull request: CI starts a real Splunk Enterprise container, deploys a workspace's app, checks the searches are installed and running, updates them and rolls them back. A red run blocks the release.

The gaps, stated plainly. That container is Splunk Enterprise without Enterprise Security, so we haven't yet confirmed that Enterprise Security's Content Management lists the correlation searches from the talon_studio app; that needs a real Enterprise Security 8 install. The CI run also doesn't cover installing through ACS on a Splunk Cloud Platform stack.

Connecting Splunk is covered in SIEM Connections in the Talon Studio docs.

Splunk, Splunk> and Turn Data Into Doing are trademarks or registered trademarks of Splunk LLC in the United States and other countries. Talon Labs is not affiliated with or endorsed by Splunk.

IN THIS POST

Talon StudioSelf-hosted detection engineering
Get your free Community keyOne Talon Labs account holds your Talon Studio key

READ NEXT

Anything here you want to pick apart, or try on your own infrastructure? The next post arrives on the RSS feed.

Talk to us