Skip to main content
Back
IntrusionAWS · Google Cloud · Azure · Kubernetes · SaaS
8 min read

Elementary Data forged release with a credential stealer

Victim
Elementary Data (PyPI package and GHCR image)
When
Apr 24–25, 2026Disclosed Apr 25, 2026
Entry
A script-injection flaw in a GitHub Actions workflow: a pull request comment ran attacker code with the workflow's GITHUB_TOKEN, which forged a commit, a tag and a release and started the project's own release pipeline.

On April 24, 2026 a comment from a two-day-old GitHub account ran attacker code in a workflow of the elementary-data project. The workflow's token forged a commit, a tag and a release and started the project's release pipeline, which published elementary-data 0.23.3 to PyPI at 22:20 UTC and the matching image to GHCR. The release added elementary.pth, a file that runs at every Python start and sends credentials to the attacker; a community member reported it on April 25 and the maintainers removed it at 09:45 UTC.

What happened

External Parties
Community members
Stager host
Attacker domain
Internet
Instance Metadata ServiceAWS role credentials
Project Repository · GitHub Actions
Environments That Installed It
+ PyPI package
+ GHCR image
+ release 0.23.3
PyPI + GHCR
Comment Workflow
GITHUB_TOKEN
Release Workflow
Python Environment
Cloud + Cluster Secrets

Replaying the Elementary Data April 2026 intrusion

  1. 1

    Workflow injection

    Apr 24, 2026, 22:10 UTC

    A comment from a two-day-old account runs attacker code in a workflow that expands comment text into a shell script, with the repository token in scope.

  2. 2

    Forged release

    Apr 24, 2026, 22:10–22:24 UTC

    The workflow token forges an orphan commit, a tag and a release, and the project's own release pipeline publishes it to PyPI and GHCR.

  3. 3

    Install, then harvest

    Apr 24 22:20 UTC – Apr 25 09:45 UTC

    Each environment that installs 0.23.3 or pulls the image runs the payload at every Python start; it reads credential files, asks the metadata service for AWS role credentials and requests secrets from Secrets Manager, Parameter Store and the cluster.

  4. 4

    Archive sent out

    Apr 24 22:20 UTC – Apr 25 09:45 UTC

    The harvester packs its output into trin.tar.gz and posts it to an attacker-controlled domain in one request.

  5. 5

    Found and removed

    Apr 25, 2026, 06:18–09:45 UTC

    A community member opens issue #2205 and the maintainers remove the malicious version at 09:45 UTC and publish 0.23.4.

Impact

elementary-data 0.23.3 and the ghcr.io image tags 0.23.3 and latest carried a credential harvester until the maintainers removed the malicious version at 09:45 UTC on April 25, 2026, about 11 hours after the upload per heise online; when the image was removed is not stated. Each environment that installed the package or pulled the image ran a harvester that read local credential files, asked for AWS role credentials and Secrets Manager and Parameter Store values, and posted an archive to the attacker. StepSecurity reports no victim cloud compromise, and no source gives a count of installs or of affected organizations.

Outcome

Where cloud-provider controls fit

The flaw, the forged release and the registries sit with GitHub and the package index, so no cloud control reaches them. A GitHub setting would have stopped the publish: a protected environment with required reviewers holds the publish job until a reviewer approves it. A read-only default token for the workflow bounds the forgery only where the workflow does not raise its own permissions, which the sources do not state. Once the payload runs, cloud controls bound what it takes: short-lived role credentials that expire, network conditions that refuse a replay from the attacker's network, a hop limit of 1 that keeps containers away from the metadata service, a scoped role for the secret stores. Which Kubernetes Secrets a service account may read is decided by Kubernetes RBAC, which no cloud control sets. An egress allow list on AWS, Google Cloud, Azure or Oracle Cloud, or a NetworkPolicy in the cluster, refuses the POST that sends the archive out only from a workload behind it, and no source says where the payload ran. The harvester still reads what its own host may read: you own pinning versions and digests, a cooling-off period for new releases and the rotation of every credential the environment held.

Could this have been prevented?

In hindsight, not as a whole. 1 control would have refused a step outright, and 19 controls would have limited one. 8 steps have no cloud-provider control. The counts below are control assessments, not attack stages: several can address the same step. The same replay with the controls in place before the incident shows where each phase would have been refused or bounded.

1
Prevented
19
Contained
8
Not covered

How it could have been prevented

The same replay with the controls in place. Green marks where a step is refused, blue where it is bounded, and red where no control reaches it. Open a row to read the control, why it acts, and its caveat.

External Parties
Community members
Stager host
Attacker domain
Internet
Instance Metadata ServiceAWS role credentials
Project Repository · GitHub Actions
Environments That Installed It
+ PyPI package
+ GHCR image
+ release 0.23.3
PyPI + GHCR
Comment Workflow
GITHUB_TOKEN
Release Workflow
Python Environment
Cloud + Cluster Secrets

Replaying the Elementary Data April 2026 intrusion

1 · Workflow injection

2 Not covered

2 · Forged release

1 Prevented1 Contained2 Not covered

3 · Install, then harvest

14 Contained3 Not covered3 on other clouds

4 · Archive sent out

4 Contained1 on other clouds

5 · Found and removed

1 Not covered

Key facts

  • The account that commented was two days old when its comment started the workflow update_pylon_issue.yml at 22:10:14 UTC on April 24, 2026; the injected run lasted 2 hours 46 minutes and ended with status failure, per StepSecurity
  • With the workflow token the attacker created an orphan commit that showed a Verified badge, the tag v0.23.3 and a release marked Latest, then started the legitimate Release package workflow through the GitHub API, per StepSecurity
  • elementary-data 0.23.3 reached PyPI at 22:20:47 UTC and the image tags 0.23.3 and latest were pushed at 22:24 UTC; the only addition was elementary.pth, about 245 KB, which Python runs at every start, per StepSecurity and the maintainers
  • The harvester read SSH keys, git and GitHub credentials, AWS, Google Cloud and Azure credential files, Docker and Kubernetes configuration and environment files, asked the AWS instance metadata service for role credentials, called Secrets Manager and Parameter Store and ran kubectl get secrets across all namespaces; it posted the archive trin.tar.gz in one request, per StepSecurity
  • A community member opened issue #2205 at 06:18 UTC on April 25; the maintainers removed the malicious version at 09:45 UTC and published 0.23.4, while a research note estimates that the exposure ended at about 08:00 UTC and the sources give about 8 to 10 hours or about 11 hours
  • The package had more than 1.1 million monthly downloads, per BleepingComputer citing pypistats.org; no source gives a count of installs, and StepSecurity reports no victim cloud compromise

Sources

Every fact in this breakdown comes from the public reporting below. The replay is a model of that reporting, not a reconstruction of the environment it describes.

  1. 1.
    elementary-data compromised on PyPI and GHCR, forged release pushed via GitHub Actions script injectionStepSecurity · Apr 25, 2026 · ResearchAttack chain, workflow flaw, forged commit and tag, payload behavior and timestamps
  2. 2.
    [Security] Malicious elementary.pth file in release 0.23.3Elementary Data (GitHub issue) · Apr 25, 2026 · Vendor reportPublish and removal times, affected and unaffected products, remediation, user guidance
  3. 3.
    PyPI package with 1.1M monthly downloads hacked to push infostealerBleepingComputer · Apr 27, 2026 · NewsDownload figure as reported, discovery, user guidance
  4. 4.
    elementary-data PyPI Compromise: Cloud Credential Theft via CI/CD HijackCloud Security Alliance · Apr 29, 2026 · ResearchExposure window estimate, weekly download figure, mitigation guidance
  5. 5.
    Script Injection and Data Theft: Python Data Analysis Tool Compromisedheise online · Apr 30, 2026 · NewsTime to removal, the maintainers' credential rotation, upload times, OSV record

The estate in the replay is illustrative and drawn at the level of attack stages; the victim's real environment is not public. Verdicts describe what a control does when it is in place before the incident. They are not an assessment of the victim's security program.

More cloud attack breakdowns

All breakdowns