Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

Malicious code in @nestjs-passport/jwt (npm)

0
Critical
Published: 08/07/2026 (08/07/2026, 18:02:58 UTC)
Source: GCVE Database
Product: @nestjs-passport/jwt

Description

The npm package @nestjs-passport/jwt contains malicious code disguised as a minimal HS256 JWT helper. It uses heavy JSFuck obfuscation and dynamic code evaluation at import time, executing hidden payloads in the installer's Node.js process. The package is a typosquat of legitimate @nestjs packages and exposes obfuscated private fields inconsistent with normal build outputs. This concealment technique allows arbitrary code execution during module load without readable code paths.

Affected software

npmghsa
@nestjs-passport/jwt
Affected versions
=1.0.7=1.0.4

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 08/08/2026, 15:19:37 UTC

Technical Analysis

The @nestjs-passport/jwt npm package, specifically versions 1.0.4 and 1.0.7, is a malicious typosquatting package that mimics official @nestjs JWT-related packages. Its entrypoint files (dist/index.cjs and dist/index.js) consist of a single-line JSFuck-encoded string (~2.3MB) which is passed to a new Function constructor and executed immediately upon import. This dynamic evaluation executes hidden code inside the installer's Node.js process, enabling arbitrary code execution. The package's advertised functionality as a minimal HS256 JWT helper is inconsistent with the complexity and obfuscation observed, including obfuscated private field names in TypeScript declarations that do not align with the declared build tooling. This combination of typosquatting, heavy obfuscation, and dynamic code execution indicates a deliberate attempt to conceal malicious behavior.

Potential Impact

Installing or importing this package results in execution of hidden malicious code within the Node.js process of the installer or user. This can lead to compromise of the host environment, unauthorized actions, data theft, or further malware deployment. The obfuscation and dynamic execution make detection and analysis difficult, increasing risk to developers and systems that inadvertently include this package.

Mitigation Recommendations

No official patch or remediation is available as this is a malicious package rather than a vulnerability in legitimate software. Users should avoid installing or using @nestjs-passport/jwt versions 1.0.4 and 1.0.7. Verify package authenticity by using official sources and package names. Remove any installations of this package from projects and conduct security reviews to detect any impact. Use trusted package registries and enable supply chain security measures such as package signing and integrity checks.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Gcve Source
db.gcve.eu
Osv Id
MAL-2026-13627
Osv Schema Version
1.7.4
Aliases
[]
Ecosystems
["npm"]
Database Specific Severity
null
Cvss Version
null

Threat ID: 6a7742a8bf8831d539b08cda

Added to database: 08/08/2026, 14:52:24 UTC

Last enriched: 08/08/2026, 15:19:37 UTC

Last updated: 08/08/2026, 20:00:42 UTC

Views: 4

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses