LIVE · cybersecurity feed
Live wire
npmmedium

The security signal log tailing can't see: tracking npm cooldown removals with Elastic Agent

Elastic has developed a new detection engineering method to track the removal of the `min-release-age` setting from `.npmrc` files on developer workstations. This setting, available since npm version 11.10, is designed to prevent the installation of recently published package versions, mitigating supply chain attacks such as Compromise Software Dependencies and Development Tools (T1195.001).

ZeroDay News ·

Source: Elastic Security Labs

Elastic has developed a new detection engineering method to track the removal of the `min-release-age` setting from `.npmrc` files on developer workstations. This setting, available since npm version 11.10, is designed to prevent the installation of recently published package versions, mitigating supply chain attacks such as Compromise Software Dependencies and Development Tools (T1195.001).

The `min-release-age` setting specifies a number of days, and npm will ignore any package version published more recently than that duration. While enterprise-level CI/CD pipelines often have their own supply chain guardrails, developer workstations represent a common gap where a compromised package could be installed. Elastic enforces this setting by using Jamf to write `min-release-age=7` to user-level and machine-global `.npmrc` files daily.

The challenge lies in detecting when this setting is removed, as traditional log-tailing inputs only trigger on file appends, not content removal or file deletion. To address this, Elastic built a Common Expression Language (CEL) integration within Elastic Agent. This integration snapshots all `.npmrc` files every six hours. If the `min-release-age` setting is absent from a subsequent snapshot, the pipeline marks it as `cooldown.absent = true`. This allows Elastic to identify hosts where the setting has been removed during the window before Jamf re-applies it.

The target `.npmrc` files are small, typically 10 to 50 bytes, and contain the `min-release-age` setting along with sensitive data like private registry authentication tokens. Any monitoring solution must filter out these tokens before data leaves the host.

Elastic initially attempted to use the Custom Logs Filestream integration, which wraps Filebeat's modern filestream input. This approach involved configuring path globs for user-level and system-global `.npmrc` files on macOS, and an ingest pipeline to extract the `min-release-age` value while dropping other lines to prevent sensitive data exfiltration.

However, three issues arose with the filestream approach. First, Filebeat's default `fingerprint` file identity strategy, which hashes the first 1024 bytes, caused small `.npmrc` files to be held back from ingestion. Switching to `native` file identity (inode plus device) resolved this, as it has no size floor. Second, the `clean_inactive` setting, necessary for periodic re-emission of config files, required `ignore_older` to also be set, which is unsuitable for static configuration files. Consequently, `clean_inactive` was disabled.

The third and most significant limitation was that filestream emits events only on appends. When `min-release-age` was removed from an `.npmrc` file, filestream recognized a modification, but the allowlist filter dropped all resulting lines, preventing the removal signal from reaching Elasticsearch. This structural limitation led to the adoption of the CEL snapshot approach.

It was also noted that machines often report multiple npm versions due to Node Version Manager (nvm) installations, each with its own npm binary. While `npm config set min-release-age 7` writes to the user-level `.npmrc` that all npm installations read, only npm versions 11.10 and newer respect the setting. Therefore, a count of machines with any capable npm version overstates the actual protection, reinforcing the need to track the configuration directly.

npmsupply chain securityelastic agentconfiguration monitoringdevsecops
ShareXLinkedInWhatsAppFacebook

More News

view all →
security

Canadian cybersecurity executive arrested in federal extortion case

A Canadian cybersecurity executive was arrested in Pennsylvania on Thursday, facing federal charges of conspiracy to commit extortion. Edward Dubrovsky, 54, a co-founder and former Chief Operating Officer of CYPFER, a firm specializing in ransomware negotiation, is charged with conspiring to threaten the confidentiality of information for extortion and conspiring to commit Hobbs Act extortion,…

breach

Criminal IP Introduces AITEM as the Next Evolution of Attack Surface Management

AI SPERA, the company behind the cyber threat intelligence platform Criminal IP, has announced AITEM (AI-Powered Threat Exposure Management), an expansion of its Attack Surface Management (ASM) offerings. AITEM aims to move beyond traditional asset discovery to provide a more comprehensive approach to understanding, prioritizing, and responding to security exposures. The platform is scheduled…

ai

AI Is Getting Really Good at Messing With Cybercriminals

Anti-cybercrime initiatives are increasingly deploying artificial intelligence to disrupt scammers by engaging them with lifelike bots, which the criminals mistake for genuine victims. This strategy aims to waste scammers' time and resources while gathering intelligence on their operations.

ransomware

FBI Arrests Ransomware Negotiation Firm Co-Founder in ShinyHunters Probe

The Federal Bureau of Investigation (FBI) has reportedly arrested Edward Dubrovsky, a co-founder of the ransomware negotiation firm Cypfer and currently associated with CyberSteward. The arrest is said to be part of the ongoing ShinyHunters investigation, specifically in connection with an incident involving FBI job applicant data.

ai

The Third-Party Agent Problem: Why Security Built for AI You Chose Misses the Agents You Didn't

A new report highlights a significant blind spot in enterprise security architectures concerning the proliferation of third-party AI agents. The forthcoming 2026 State of Agent Security Report indicates that current security models, often designed to protect AI systems directly chosen and deployed by an organization, frequently fail to account for AI capabilities embedded within third-party…

security

Insider Cyber Extortion Plot Against Industrial Firm Lands Engineer in Prison

A former core infrastructure engineer has been sentenced to prison for an attempted cyber extortion plot against an industrial firm. The engineer reportedly deleted administrative accounts and reset hundreds of user passwords, subsequently demanding a ransom of 20 Bitcoin to prevent further disruption to the company's servers.