Home OSINT News Signals
CYBER

Malicious Rust Crates and AI Bot Exploit CI/CD Pipelines to Steal Developer Secrets

🕓 2 min read

Cybersecurity researchers have uncovered a sophisticated supply chain attack targeting the Rust ecosystem, involving five malicious crates published to the official crates.io repository. These packages, masquerading as legitimate time-related utilities, were designed to stealthily exfiltrate sensitive `.env` file data from developer environments to attacker-controlled infrastructure. According to analysis by security firm Socket, the crates impersonated the legitimate timeapi.io service and were published between late February and early March 2026. Investigators assess this to be the work of a single threat actor, based on consistent exfiltration techniques and the use of a similar lookalike domain, `timeapis[.]io`, for data staging.

The malicious crates, named `chrono_utilities`, `time_converter`, `local_time_sync`, `epoch_toolkit`, and `chrono_anchor`, were advertised as tools for calibrating local time without relying on the Network Time Protocol (NTP). However, their core functionality was credential and secret theft. "Although the crates pose as local time utilities, their core behavior is credential and secret theft," explained security researcher Kirill Boychenko. "They attempt to collect sensitive data from developer environments, most notably .env files, and exfiltrate it to threat actor-controlled infrastructure." While four of the packages employed relatively straightforward exfiltration methods, `chrono_anchor` implemented advanced obfuscation and operational security measures to evade detection.

The `chrono_anchor` crate specifically embedded its malicious logic within a file named `guard.rs`, which was invoked from a seemingly benign "optional sync" helper function. This design choice aimed to avoid raising suspicions during code review. Unlike typical malware that establishes persistence on a host, this crate was engineered to trigger its exfiltration routine each time a developer's Continuous Integration (CI) workflow executed the malicious code. This approach leverages the automated nature of CI/CD pipelines, ensuring repeated data theft during build processes. The targeting of `.env` files is strategic, as these files commonly store critical secrets like API keys, database credentials, cloud service tokens, and registry access keys, providing attackers a pathway to compromise downstream services and infrastructure.

In a related and evolving threat, researchers have also identified the exploitation of AI-powered coding assistants, like GitHub Copilot, to infiltrate CI/CD pipelines. Attackers are crafting malicious code snippets or documentation that, when suggested or incorporated by an AI bot into a codebase, can lead to secret leakage or remote code execution. This method represents a novel attack vector where the trust in AI-generated code is weaponized. The combination of malicious packages and AI bot exploitation highlights a growing focus on the software supply chain and the automation infrastructure that supports modern development. While the identified Rust crates have been removed from crates.io, developers who may have inadvertently installed them must audit their projects, rotate all exposed secrets, and scrutinize dependencies, especially those related to time or system utilities. Organizations are advised to implement robust software composition analysis (SCA), enforce strict CI/CD pipeline security controls, and educate developers on the risks associated with AI coding assistants.

Telegram X LinkedIn
Back to News