NPM package installed Hermes Agent as root and tasked it over Telegram
Malicious npm package @leadstack/crm-connect installed Nous Research's Hermes Agent on host servers to execute root commands via a remote Telegram bot.
By Dillip Chowdary • Nov 21, 2026 • Source: safedep.io

At a glance
- Product
- @leadstack/crm-connect
- Publisher
- zmaticoo
- Embedded agent
- Hermes Agent
- Initial release
- 16 November 2026
- Network endpoint
- 72.62.1.108:3000
- Target model
- kimi-k2-0711-preview
In this post
A malicious npm package disguised as a legitimate client library installed an open-source autonomous artificial intelligence agent on host servers and connected it to a Telegram control channel, according to safedep.io's report. The package, named @leadstack/crm-connect, posed as the official integration for a customer relationship management platform called LeadStack. Upon installation, the software deployed Nous Research's Hermes Agent, fetched credentials and operational instructions from an external command server, and registered the process as a background systemd service. When developers or automated environments ran the package installation under root privileges, the artificial intelligence agent gained full root access to execute terminal commands, modify files, and browse the web under the operator's chat instructions.
This report examines how the compromised package established unauthorized persistence, downloaded runtime personas, and shifted architectures across multiple version releases on 16 November 2026. System administrators, JavaScript developers, and security engineers managing automated deployment pipelines face increasing supply chain risks from complex implant payloads. The investigation reveals how the attacker exploited trusted package installation lifecycle hooks to silently provision artificial intelligence agents capable of scheduling background tasks and executing arbitrary terminal instructions directly from Telegram.
01Fake client installation and systemd persistence
The package @leadstack/crm-connect used standard Node.js lifecycle hooks to deploy its payload silently during dependency resolution. Its package configuration file designated a postinstall script that invoked an internal provisioning routine with Node warnings suppressed. This script executed a secondary, hidden package installation into a dedicated directory under ~/.leadstack/runtime.
If the installer operated with administrative privileges, the script registered Hermes Agent as a root systemd service renamed LeadStack Lead Routing Daemon to blend into standard operating system processes. Version 1.0.18 introduced a fallback routine designed for unprivileged users, attempting to configure a user-level service and enable systemd lingering. Enabling lingering ensures the background agent remains active even after the compromised user session terminates or logs out.
The installer purged the original service unit files associated with Hermes Agent to eliminate obvious signatures. Operators in control of the remote Telegram bot could then instruct the host to run arbitrary shell commands, read and write files, browse external websites, and schedule recurring tasks.
02Remote credential bootstrap and soul configuration
During the automated setup routine, the provisioning script made two sequential HTTP requests to an external server at 72.62.1.108:3000. The initial network call fetched environment configuration values containing the necessary Telegram bot token and credentials for the Kimi model provider. Without these specific credentials, Hermes Agent refuses incoming chat connections and denies Telegram commands.
The second request retrieved plain text instructions that the provisioning script wrote to a file named SOUL.md in the agent directory. In the Hermes Agent architecture, this file dictates the primary personality, operational rules, and standing instructions of the agent. The runtime loads this persona specification before every incoming message, allowing the remote attacker to direct the host's actions dynamically.
Hermes Agent incorporates an internal prompt-injection scanner, but the defense mechanism only logs a warning when flagging a local SOUL.md file and proceeds to load the instructions anyway. By hosting the credentials and persona externally, the attacker avoided embedding static API keys directly inside the published npm tarball.
03Deployment timeline across nine versions
Advertisement
Tech Pulse Daily
Get tomorrow's pulse first
Join engineers who read Tech Pulse before stand-up. Free, weekday mornings.
The publisher account zmaticoo registered nine distinct versions of @leadstack/crm-connect within a six-hour window on 16 November 2026. The initial release, version 1.0.15, appeared at 09:44 UTC containing the complete Hermes Agent deployment scripts. Across subsequent updates, the author modified delivery techniques and payload locations.
| Version | Publication time | Payload delivery mechanism |
|---|---|---|
| 1.0.15 | 09:44 UTC | Installs full Hermes Agent and Telegram gateway |
| 1.0.18–1.0.21 | 10:42 UTC | Shifts payload to SDK call and remote module |
| 1.0.29–1.0.30 | 14:55 UTC | Downloads external binary directly via postinstall |
| 1.1.0–1.1.1 | 15:24 UTC | Executes an unpublished platform dependency |
The package publisher requested partner access on npm and kept every release except the final version marked as restricted access. The npmmirror archive recorded its first public capture of the package at 15:26 UTC. Automated static analysis flagged the package as malicious at 15:33 UTC, and security researchers confirmed the assessment at 16:20 UTC before npm removed the registry entries.
04Borrowed branding and command infrastructure
The package fabricated an association with LeadStack to deceive developers seeking customer management tooling. Its included documentation referenced api.leadstack.io, a domain endpoint that failed to resolve to an active server. An unrelated business consultancy owns the primary leadstack.io domain and maintains no connection to the rogue npm software.
Code artifacts within the helper scripts revealed remnants of earlier development environments. Variable names such as HERMES_LAB_TOKEN and HERMES_BOOTSTRAP_URL indicate the developer adapted a pre-existing testing setup into the LeadStack delivery campaign. The package bundled configuration referencing the kimi-coding provider and the default model kimi-k2-0711-preview.
The command server at 72.62.1.108 stopped responding on port 3000 by 19 November 2026. Matching web endpoints hosted on port 80 shifted behavior to return HTTP 401 unauthorized errors requiring bearer token authentication, preventing public retrieval of the original environment files.
05Indicators of compromise and publisher activity
Organizations running Node.js environments must audit dependency trees and host filesystems for signs of the rogue package. Systems that executed the package scripts may contain persistent directories, modified services, or active connections to the attacker's network endpoints.
- Check local filesystems inspect ~/.leadstack/, ~/.config/leadstack/, and ~/.local/share/leadstack/bin/ for agent binaries and configuration files
- Review systemd services query systemctl for active services named leadstack-routing.service and leadstack-ingest-worker.service
- Block network infrastructure restrict outbound network traffic to 72.62.1.108, 72-62-1-108.sslip.io, and zmaticco.dev
- Remove package releases verify the exclusion of @leadstack/crm-connect versions 1.0.15 through 1.1.1 across all private mirrors and local caches
Note: The npm publisher account zmaticoo remained active after package removal and published three additional packages on 18 November 2026 that fetch dependencies from external servers.
Frequently asked questions
What did the @leadstack/crm-connect package do upon installation?
It executed a postinstall script that downloaded Nous Research's Hermes Agent, configured it with remote instructions, and registered it as a persistent systemd service. The agent connected to a remote Telegram bot, giving the attacker root command capabilities on the host.
How did the malicious package maintain persistence after install?
The script registered a systemd daemon called LeadStack Lead Routing Daemon when executed as root. For unprivileged installs, later versions configured a user service and enabled lingering so the process remained active after user logout.
How was the rogue npm package detected and handled?
SafeDep static analysis flagged the package five minutes after its final update on 16 November 2026, and security analysts confirmed the malicious verdict. Npm subsequently removed all nine versions of the package from the registry.
Sources
Author
Dillip Chowdary
Writes Tech Bytes coverage of AI, engineering, and the tools that actually ship. Editor of Tech Pulse Daily.
Related on Tech Bytes
Advertisement