fix(ci): redact authentication in case-insensitive URL schemes

This commit is contained in:
gensokyo-dev committed 2026-10-23 13:38:56 +00:00
1 parent 1cd471487b
commit 95eb175457
2 files changed
+8 -1

No files matched your search

+1 -1
View File
@@ -1,6 +1,6 @@
/** Redact only HTTP URL authentication; keep paths, names, queries and other text. */
export function redactTransportAuthentication(text) {
return text.replace(/https?:\/\/[^\s"<>\\]+/gu, (value) => {
return text.replace(/https?:\/\/[^\s"<>\\]+/giu, (value) => {
try {
const parsed = new URL(value);
if (!parsed.username && !parsed.password) return value;