Telemetry scrubber: case-insensitive mysql rule redacts an attached port (-P3306) and lets a real password survive in the same command
Maintainer antworten meist innerhalb von 1 Tag
Bewertung
- Schwierigkeit
- 2/5
- Geschätzter Aufwand
- 1-3 Stunden
- Anfängerfreundlichkeit
- 82/100
- Issue-Typ
- Bug
- Klarheit
- Klar beschrieben
- Aktivitätsstatus
- Aktiv
- Tech-Stack
- mysql, typescript
Rechercherichtung
Beginne in server/src/telemetry/scrub.ts und untersuche die mysql-Regel für Zugangsdaten zusammen mit der benachbarten sshpass-Regel. Ergänze Tests für den gemischten Befehl -P3306 und -phunter2, das kleingeschriebene angehängte -p3306 und mysql -p database; bestätige, dass Port und Datenbankname erhalten bleiben, während tatsächliche Zugangsdaten unkenntlich gemacht werden.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Summary
In server/src/telemetry/scrub.ts, the tool-anchored mysql credential rule keeps the i flag:
[
/(\bmysql(?:dump)?\b(?:[^|;&\\\r\n]|\\[\s\S])*?(?:[ \t]|\\\r?\n)-p)("[^"]*"|'[^']*'|[^\s'"-]\S*)/gi,
(_m, lead) => `${lead}${REDACTED}`,
],
i makes (?:[ \t])-p match the uppercase attached port form -P3306 (mysql's syntax for --port attached to a single dash). Because the g continuation after the first match never sees another \bmysql\b anchor, a real password later in the same command line is not redacted.
Repro (upstream tree at e8bb2736)
scrubCommand("mysql -h db -P3306 -phunter2 app")
→ "mysql -h db -P[REDACTED] -phunter2 app"
The port is redacted as if it were a secret, and the actual password -phunter2 survives into OTLP export — contrary to the module header's stated priority ("a secret that survived costs a rotation") and to the sibling sshpass rule, which is deliberately case-sensitive with the comment "Case matters here: -P is sshpass's prompt".
Suggested fix
Drop i from the mysql rule (/gi → /g), matching the sshpass rule's convention:
mysql -h db -P3306 -phunter2 app→mysql -h db -P3306 -p[REDACTED] app- lowercase
-p3306(attached password form) is still redacted mysqldump -phunter2 dbunchanged
Tests worth pinning: the mixed -P/-p command above, the lowercase attached form, and mysql -p database (space form = interactive prompt, database name must not be redacted).
Context: we hit this in a downstream deployment while extending coverage for SSHPASS=… sshpass -e and docker <global-options> login -p …; the case-sensitivity divergence was found by a full-scope review pass. Happy to send a PR if wanted.
- Vorherrschende Sprache
- TypeScript
- Sterne
- 6.6k
- Forks
- 914
- Ø Merge
- 23 Std. 27 Min.
- Gemergte PRs (30 T.)
- 136
Entwicklungsumgebung
- Enthält ein Dockerfile oder eine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Kein Beitragsleitfaden
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus CopilotKit/OpenBot
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
CopilotKit/OpenBot#817 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
Wrong key location at startupEvtl. vergeben @charan-rathore hat das vor 6 Tagen übernommen. Offen
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 68/100
CopilotKit/OpenBot#800 ·
Maintainer antworten meist innerhalb von 1 Tag
-
setup-learning.ts fails on Windows with "spawn npx.cmd EINVAL"Evtl. vergeben @Caldas hat das vor 9 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 80/100
CopilotKit/OpenBot#792 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Remote AG-UI Bots can't use the browser in chat: `computer_*` calls refused as "unavailable for this headless turn"Evtl. vergeben @charan-rathore hat das vor 5 Tagen übernommen. Offen
Schwierigkeit 3/5 1-2 Tage Anfängerfreundlichkeit 68/100
CopilotKit/OpenBot#804 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 4/5 Über eine Woche Anfängerfreundlichkeit 22/100
CopilotKit/OpenBot#786 ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in CopilotKit/OpenBot
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
braintrustdata/braintrust-sdk-javascript#2659 ·
Maintainer antworten meist innerhalb von 1 Tag
-
body-parser 2.3.0 in the published ai-dial-chat-bff image is vulnerable (CVE-2026-111181, HIGH)Evtl. vergeben @illya-havsiyevych hat das heute übernommen. Offenbug
Schwierigkeit 1/5 1-3 Stunden Anfängerfreundlichkeit 87/100
epam/ai-dial-chat#9566 ·
Maintainer antworten meist innerhalb von 1 Tag
-
bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 83/100
Maintainer antworten meist innerhalb von 1 Tag
-
はさみアイコンを修正するOffenbug
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 68/100
-
resource.reload() while params is in error switches the resource to 'idle' instead of retryingOffenarea: core
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
Maintainer antworten meist innerhalb von 1 Tag