Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

Exorcist: a local Gemma that hunts ghosts in your node_modules

Description and use

Exorcist uses a local Gemma 3 4B model to analyze npm packages, flagging potentially malicious dependencies without sending code to the cloud.

Problem

Installed npm packages may contain malicious code that can compromise applications, but developers rarely inspect them.

Outcome

Exorcist identifies 100 out of 346 dependencies as suspicious, mainly revenant findings; the tool demonstrates that local LLM analysis can be integrated into CI pipelines with minimal overhead (≈11 ms for rule evaluation).

Workflow

  • Clone the Exorcist repo
  • Run npm ci and npm run build
  • Install the target project with npm --prefix demo/victim
  • Execute exorcist CLI on the target directory with --no-oracle
  • Optionally pull Gemma3:4b via Ollama and add --json or --fail-on flags

Evidence

A CLI that scans your installed npm packages for malicious ones. Four fast rules pick the suspects, then a Gemma 3 4B model running on your own laptop reads each one and says what it's actually doing.

Source

In September 2025, attackers phished one maintainer and pushed malicious code into packages downloaded two billion times a week — it sat there rewriting people's crypto wallet addresses.

Source

Rules are the cheap filter — regex and lockfile arithmetic, never executed. Only flagged packages go to the model.

Source

The rule total is a floor: Gemma can raise a score, never lower one.

Source

Sentry tracing (opt-in, SENTRY_DSN) showed the shape of it: resolve, rules and score take about eleven milliseconds for five packages.

Source

  • Record date: 2026-11-02T03:43:47.164Z