← BurntSushi/ripgrep
CodeVetter · Repo Unpack · Risk map

BurntSushi/ripgrep

Scanned commit 3fce3b5bb0 dated 2026-08-04 — last upstream commit. Generated by codevetter codevetter 1.12.0 on 2026-09-22. Deep analysis by claude-opus-5 via the claude CLI on 2026-09-22 (374s).

ripgrep has a small but real attack surface for a search tool: it executes external programs (decompressors, `--pre`, `--hostname-bin`), reads a config file from an environment-variable-named path whose contents become command-line flags, and memory-maps files it does not control. The codebase acknowledges most of these explicitly in comments — the mmap `unsafe` block calls its own reasoning "suspect", and `resolve_binary` exists specifically to stop Windows CWD-relative program resolution. The most fragile coupling is the 246KB `defs.rs` flag table, where a single flag touches parsing, help text, man page and four completion generators. The experimental index path is the least-finished area: `grep-index` opens with `#![allow(warnings)]`, its literal module is self-described as a prototype, and `index::read` doesn't actually use the index yet.