opencode-apex 0.4.0 → 0.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -5,6 +5,14 @@ All notable changes to `opencode-apex`. Format based on
5
5
 
6
6
  ## [Unreleased]
7
7
 
8
+ ## [0.4.1] — 2026-11-26
9
+
10
+ ### Fixed
11
+
12
+ - **Redaction froze OpenCode on long sessions** (backport of 0.5.1). The `k8s-secret-data-value`
13
+ pattern had an unbounded, ambiguous lookbehind: ~80 s of CPU per pass over a ~500 KB context
14
+ in Bun/JSC. Now bounded (~80 ms on the same text).
15
+
8
16
  ## [0.4.0] — 2026-11-25
9
17
 
10
18
  ### Added
package/core/patterns.ts CHANGED
@@ -296,7 +296,10 @@ const BUNDLES: Record<string, PatternDefinition[]> = {
296
296
 
297
297
  // ------------------------------------------------------------ Kubernetes
298
298
  kubernetes: [
299
- { name: "k8s-secret-data-value", regex: /(?<=data:\s*\n(?:\s+\w+:\s*[^\n]*\n)*\s+\w+:\s*)[A-Za-z0-9+/=]{20,}/g, confidence: "medium", source: "warden" },
299
+ // Lookbehind acotado y sin ambigüedad (2026-11-26): el original de warden, con `\s+` que cruza
300
+ // líneas y repetición sin límite, costaba ~80 s sobre un contexto de 500 KB (JSC) y congelaba
301
+ // OpenCode. Ahora: sangría [ \t], hasta 16 claves entre `data:` y el valor, líneas ≤ 512.
302
+ { name: "k8s-secret-data-value", regex: /(?<=\bdata:[ \t]*(?:\r?\n[ \t]{1,16}[\w.-]{1,253}:[^\n]{0,512}){0,16}\r?\n[ \t]{1,16}[\w.-]{1,253}:[ \t]{0,8})[A-Za-z0-9+/=]{20,}/g, confidence: "medium", source: "warden" },
300
303
  { name: "kubeconfig-token", regex: /(?<=token:\s*)[A-Za-z0-9_.-]{20,}/g, confidence: "medium", source: "warden" },
301
304
  { name: "kubeconfig-client-key-data", regex: /(?<=client-key-data:\s*)[A-Za-z0-9+/=\n]{50,}/g, confidence: "high", source: "warden" },
302
305
  { name: "kubeconfig-client-cert-data", regex: /(?<=client-certificate-data:\s*)[A-Za-z0-9+/=\n]{50,}/g, confidence: "high", source: "warden" },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-apex",
3
- "version": "0.4.0",
3
+ "version": "0.4.1",
4
4
  "description": "Modular plugin for OpenCode V2 (>= 2.1): secret redaction, RPC callbacks/webhooks/watchers that wake agents, OpenTunnel endpoints + verified webhooks + supervised microservices (cross-platform daemon), tools.run, AI permission advisor, guard meta-permissions, temp-directory access",
5
5
  "license": "MIT",
6
6
  "author": "Antonio Orizondo Leyva",