GitHub Activity from Credential Scanner User Agent

Last updated 2 months ago on 2026-09-22
Created 2 months ago on 2026-09-22

About

Identifies GitHub audit activity from a user agent associated with credential-scanning and secret-harvesting tooling such as TruffleHog or Nord Stream. These tools walk repository contents and API routes to locate hardcoded secrets, tokens, deploy keys, and other credentials. Legitimate users rarely drive GitHub API traffic with these user agents, so a match is a strong signal that an adversary or an unsanctioned scan is mining the organization for exposed credentials, frequently as a precursor to credential access and data collection from code repositories.
Tags
Domain: CloudDomain: SaaSPlatform: GitHubUse Case: Threat DetectionTactic: CollectionTactic: Credential AccessTactic: DiscoveryData Source: GithubData Source: GitHub Audit LogsRule Type: ES|QLLanguage: esql
Severity
medium
Risk Score
47
MITRE ATT&CK™

Discovery (TA0007)(external, opens in a new tab or window)

Credential Access (TA0006)(external, opens in a new tab or window)

Collection (TA0009)(external, opens in a new tab or window)

False Positive Examples
Authorized secret-scanning jobs that identify as TruffleHog in CI. Restrict exceptions to known automation identities and repositories.
License
Elastic License v2(external, opens in a new tab or window)

Definition

Integration Pack
Prebuilt Security Detection Rules
Related Integrations

github(external, opens in a new tab or window)

Query
text code block:
from logs-github.audit-* metadata _id, _index, _version | where event.module == "github" and data_stream.dataset == "github.audit" and ( TO_LOWER(github.user_agent) LIKE "*trufflehog*" or TO_LOWER(github.user_agent) LIKE "*nord-stream*" or TO_LOWER(github.user_agent) LIKE "*nordstream*" ) | keep _id, _index, _version, @timestamp, event.action, user.name, github.org, github.repo, github.route, github.actor_ip, github.hashed_token, github.programmatic_access_type, github.user_agent

Install detection rules in Elastic Security

Detect GitHub Activity from Credential Scanner User Agent in the Elastic Security detection engine by installing this rule into your Elastic Stack.

To setup this rule, check out the installation guide for Prebuilt Security Detection Rules(external, opens in a new tab or window).