From 41faa4bb9e4b9278f54c80175acedf1b5cfbffdc Mon Sep 17 00:00:00 2001 From: Jah-yee <166608075+Jah-yee@users.noreply.github.com> Date: Sun, 20 Sep 2026 21:49:21 +0800 Subject: [PATCH] fix: correct .config/gcloud to gcloud in SENSITIVE_DIRS SENSITIVE_DIRS entries are checked against single path segments (split on '/'), so '.config/gcloud' (contains '/') can never match. Changed to 'gcloud' so any path segment named 'gcloud' triggers the sensitive-path guard. Fixes Brainwires/jevwire#2 --- src/util/sensitive-path.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/sensitive-path.ts b/src/util/sensitive-path.ts index 4059c28..07ff106 100644 --- a/src/util/sensitive-path.ts +++ b/src/util/sensitive-path.ts @@ -40,7 +40,7 @@ const SENSITIVE_BASENAMES = [ const SENSITIVE_EXTENSIONS = [/\.pem$/i, /\.p12$/i, /\.pfx$/i, /\.key$/i, /\.keystore$/i, /\.jks$/i]; -const SENSITIVE_DIRS = new Set([".ssh", ".aws", ".gnupg", ".config/gcloud", ".kube", ".docker"]); +const SENSITIVE_DIRS = new Set([".ssh", ".aws", ".gnupg", "gcloud", ".kube", ".docker"]); /** True when reading or writing here is a decision a human should make. */ export function isSensitivePath(path: string): boolean {