惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

L
LangChain Blog
N
Netflix TechBlog - Medium
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
V
V2EX
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
Blog — PlanetScale
Blog — PlanetScale
Microsoft Security Blog
Microsoft Security Blog
D
Docker
WordPress大学
WordPress大学
罗磊的独立博客
J
Java Code Geeks
博客园 - 【当耐特】
博客园 - 司徒正美
雷峰网
雷峰网
H
Help Net Security
酷 壳 – CoolShell
酷 壳 – CoolShell
Last Week in AI
Last Week in AI
宝玉的分享
宝玉的分享
Martin Fowler
Martin Fowler
T
Tailwind CSS Blog
Google DeepMind News
Google DeepMind News
M
MIT News - Artificial intelligence
Recent Announcements
Recent Announcements
B
Blog

Step Security Blog

Securing Vibe Coding and AI Coding Agents: An End-to-End Approach with StepSecurity - StepSecurity Introducing StepSecurity Dev Machine Guard: Protecting Developer Machines from Supply Chain Attacks - StepSecurity Top 2024 Predictions for CI/CD Security - StepSecurity Dev Machine Guard Is Now Open Source: See What's Really Running on Your Developer Machine - StepSecurity Datadog's DevSecOps 2026 Report Validates What We've Been Building - StepSecurity hackerbot-claw: An AI-Powered Bot Actively Exploiting GitHub Actions - Microsoft, DataDog, and CNCF Projects Hit So Far - StepSecurity Cline Supply Chain Attack Detected: cline@2.3.0 Silently Installs OpenClaw - StepSecurity StepSecurity’s Unified Protection Across the SDLC Infrastructure Threat Framework (SITF) - StepSecurity @velora-dex/sdk Compromised on npm: Malicious Version Drops macOS Backdoor via launchctl Persistence - StepSecurity axios Compromised on npm - Malicious Versions Drop Remote Access Trojan - StepSecurity Behind the Scenes: How StepSecurity Detected and Helped Remediate the Largest npm Supply Chain Attack - StepSecurity 10 Layers Deep: How StepSecurity Stops TeamPCP's Trivy Supply Chain Attack on GitHub Actions - StepSecurity Malicious IoliteLabs VSCode Extensions Target Solidity Developers on Windows, macOS, and Linux with Backdoor - StepSecurity TeamPCP Plants WAV Steganography Credential Stealer in telnyx PyPI Package - StepSecurity litellm: Credential Stealer Hidden in PyPI Wheel - StepSecurity Checkmarx KICS GitHub Action Compromised: Malware Injected in All Git Tags - StepSecurity CanisterWorm: How a Self-Propagating npm Worm Is Spreading Backdoors Across the Ecosystem - StepSecurity Trivy Compromised a Second Time - Malicious v0.69.4 Release, aquasecurity/setup-trivy, aquasecurity/trivy-action GitHub Actions Compromised - StepSecurity bittensor-wallet 4.0.2 Compromised on PyPI - Backdoor Exfiltrates Private Keys - StepSecurity Malicious npm Releases Found in Popular React Native Packages - 130K+ Monthly Downloads Compromised - StepSecurity Malicious Polymarket Bot Hides in Hijacked dev-protocol GitHub Org and Steals Wallet Keys - StepSecurity ForceMemo: Hundreds of GitHub Python Repos Compromised via Account Takeover and Force-Push - StepSecurity xygeni-action Compromised: C2 Reverse Shell Backdoor Injected via Tag Poisoning - StepSecurity kubernetes-el Compromised: How a Pwn Request Exploited a Popular Emacs Package - StepSecurity How StepSecurity Caught a Release Storm in Microsoft’s @types Packages - StepSecurity Harden Runner Now Supports Windows and macOS GitHub Actions Runners - StepSecurity 10,000 Open-Source Projects Now Secured by Harden-Runner Community-Tier: A Milestone Three Years in the Making - StepSecurity 20+ Popular NPM Packages Compromised (Chalk, Debug, Strip-ANSI, Color-Convert, Wrap-ANSI...) - StepSecurity 2024 in Review: The Evolution of CI/CD Security & What's Next - StepSecurity How to Use Docker in Actions Runner Controller (ARC) Runners Securely - StepSecurity
lightning: Obfuscated JavaScript Credential Stealer Bundl...
2026-04-30 · via Step Security Blog

On April 30, 2026, a supply chain compromise was identified in the lightning PyPI package — versions 2.6.2 and 2.6.3. The project’s GitHub account shows signs of compromise, with issues reporting the attack closed rapidly by suspicious responses.

This is a developing story.

On import, a daemon thread silently downloads the Bun JavaScript runtime from GitHub and executes router_runtime.js — an 11 MB heavily obfuscated payload. The malware steals tokens, credentials, environment variables, and cloud secrets; abuses the GitHub API to commit exfiltrated data to repositories using the victim’s own credentials; and infects npm package tarballs on the developer’s machine. The project’s GitHub account shows signs of compromise, with issues reporting the attack closed rapidly by suspicious responses.

We analyzed both wheels. The last clean release is 2.6.1, published January 30, 2026. Full payload analysis is ongoing and this post will be updated as additional details become available.

Background: What Is lightning?

The lightning package (Lightning AI, formerly PyTorch Lightning) is one of the most widely used deep learning frameworks in the Python ecosystem. It provides a high-level interface for training PyTorch models and is a common dependency in research environments, MLOps pipelines, and production AI systems, receiving hundreds of thousands of daily downloads. Environments running lightning routinely hold GPU cluster credentials, cloud IAM tokens, Hugging Face API keys, Weights & Biases tokens, and other high-value secrets tied to model training infrastructure — making it a high-value target for a credential-stealing campaign.

The Entry Point: Hidden _runtime Directory

Both compromised wheels bundle a hidden _runtime/ directory containing two files:

  • _runtime/start.py — downloads the Bun JavaScript runtime binary from GitHub
  • _runtime/router_runtime.js — an 11 MB heavily obfuscated JavaScript payload

The attack fires the moment the package is imported, via a daemon thread with suppressed stdout and stderr. No user action beyond installation is required. The thread runs silently in the background while the victim’s process continues normally with no errors or visible output.

The Shai-Hulud pattern: Downloading an external runtime at execution time to run a large obfuscated payload is a hallmark of the Shai-Hulud supply chain attack family, first documented in the November 2025 npm compromise that affected 780+ packages. Because the credential-stealing logic lives entirely in an obfuscated JS file fetched at runtime, static analysis of the Python wheel alone cannot reveal the payload’s capabilities.

Payload Capabilities

Static analysis of router_runtime.js reveals 703+ references to process and environment variables, 463+ references to tokens and authentication material, and 336+ references to repositories. The payload’s confirmed capabilities include:

  • Credential theft: tokens, API keys, authentication material, environment variables, and cloud secrets
  • GitHub API abuse: commits encoded stolen data to repositories using the victim’s own GitHub credentials
  • npm tarball poisoning: injects malicious code into npm package tarballs on the developer’s machine, enabling the attack to spread to downstream npm consumers

GitHub Account Compromise

The Lightning AI GitHub repository shows indicators of account compromise coinciding with the malicious releases. Issue #21689, which surfaced the attack, was rapidly closed with suspicious responses. This pattern is consistent with the attacker holding both PyPI publishing credentials and a GitHub token — a token-based takeover rather than a direct build-system compromise.

How StepSecurity Helps

Harden-Runner detects this attack at the process layer. Attacks in this family use a Python child process to scan /proc for the GitHub Actions Runner.Worker process and dump its readable memory via /proc/{pid}/mem, extracting secrets held in the runner’s address space. Harden-Runner’s process monitor flags this unauthorized memory access as a suspicious process event.

References