The images in this article were generated with artificial intelligence. How we publish
The discovery of the automated campaign called "Megalodon," which in a few hours introduced thousands of malicious commitments into GitHub's public repositories, brings to the fore a reality that many developers have feared for years: the software supply chain is a powerful and attractive attack vector for actors seeking credentials, tokens and mass secrets.
What happened and why it matters: The attackers took advantage of disposable accounts and forged authors to add workflows in .github / workflows containing obfussed payloads and designed to run on CI / CD runners. Once activated, these workflows search and exfilter CI environment variables, cloud credentials, SSH keys, OIDC tokens and other secrets to a command and control server. The risk is not just the one-time theft: when executed within the continuous integration environment they can pivote and sow malicious code in more projects, creating a multiplier effect that turns a single intrusion into an epidemic of interdependent commitments.

Strategic and operational implications: This type of operation shows that safety can no longer be limited to protecting servers and workstations: pipelines, tokens, deploy keys and Action permit policies are now primary objectives. A CI credential with broad privileges or a publication token can be enough for the attacker to spread a commitment to dozens or hundreds of projects. In addition, when a campaign combines mass automation with more stealth variants that are activated under manual or specific triggers (workflow _ dispatch), the scope and selectivity increase: there are massive "mapping" attacks and targeted attacks to exfilter what is really interested.
Immediate actions for maintenance and development equipment: if you administer repositories or packages, immediately check the .github / workflows folder for files added or modified by unknown accounts, especially those with ospused payloads (e.g., base64 chains that are decoded when running). Revoque tokens of publication and deploy keys committed, enable the expiry of tokens and generate new credentials with minimum permits. Check the performance logs of Actions to detect unexpected executions and, where possible, disable workflows from unverified forks or contributions until the inventory is clean.
Recommended medium-term technical and policy measures: implement the principle of less privilege in tokens and cloud roles, prefer temporary and OIDC-based credentials rather than permanent PATs, and limit which actions and who can execute them from external repositories. Using external secret managers and not embed secrets in the repository or workflow variables reduces the exposure surface. To guide these practices, official documentation on the management of secrets in GitHub Actions is a good starting point: GitHub Actions Encrypled Secrets and it is also appropriate to review how the automatic token permissions are handled: GITHUB _ TOKEN permissions.
What should change the records and platforms: The incidents showed that the publication mechanisms and management of tokens require more rigid controls: default tokens expiry, enhanced 2FA verification for critical operations and options to force publication from verified channels. NPM and other registrations have already made similar decisions about tokens with high privileges; projects must review and, if necessary, rotate their credentials following the guidelines of the registry itself: Npm access tokens guide.

Prevention and organizational resilience: In addition to technical controls, organizations need to prepare for detection and response: establish playbooks to revoke committed credentials, communicate with the affected project community and automate regular repository scans in search of unauthorized workflows. The adoption of practices such as package integrity verification, commitment signatures and subscription to unit security alerts helps to detect early propagations.
Wider context and lessons learned: Megalodon and related campaigns confirm a trend: attackers combine automation, social engineering and abuse of legitimate infrastructure to maximize impact and complicate detection. This forces you to reimagine software security as a collective effort involving maintainers, platforms, registrations and consumers. The solution is not a single patch, but a continuous process improvement, minimum default controls and a rapid and coordinated response when a failure occurs.
The final recommendation for any developer or project manager is clear: today to audit your pipelines and credentials, to rotate and impose expiry on tokens, to tighten permissions and to document a response plan. The threat will not disappear, but with proper controls the possibility of a simple malicious commit becoming a large-scale secret escape vector is drastically reduced.
Related
More news on the same subject.

Campaign at Hugging Face Spaces and GitHub uses game traps to steal passwords and sessions
A massive campaign has used Hugging Face Spaces pages and GitHub repositories to attract players with supposed traps and bots and push them to install malware that steals browse...

Canada detects NEXCOL intrusion and suspension of export permits
The Canadian government confirmed that its online system to manage permits for the export of military material and strategic goods, known as NEXCOL, suffered an intrusion detect...

CertiK shows Weight2Shell: identical weights, different outputs by inference environment
CertiK security researchers have demonstrated a technique - called Weight2Shell in their report - that allows two instances of the same artificial intelligence model, carrying i...

RabbitMQ: critical failure in the management interface exposes tokens OAuth2; patches 4.4.1 / 4.3.8
A critical vulnerability in RabbitMQ allows an attacker who has access to the management interface to get tokens OAuth2 signed by the identity provider without credentials and t...

Critical Vulnerability in Erlang / OTP client TLS allows MITM without certificate (CVE-2026-124286)
A critical vulnerability to the client implementation of TLS within Erlang / Open Telecom Platform (OTP) allows a malicious server to complete a TLS 1.2 handshake without presen...

pCloud Pass: cyber attack exposes emails from few users; undecipher encrypted vaults
This week pCloud Pass, the password manager integrated into the Swiss pCloud service, confirmed that it was the target of a "cyber attack" after several users reported early log...

SOCRadar identifies WeaveLotus / RedOps campaign in intrusions to Thailand and the Philippines
SOCRadar has published an analysis that attributes a series of intrusions to military, government and legislative institutions in South-East Asia to a set of tools and activitie...