docs(browse): keep a basic-auth URL out of the scheme-guard comment so the pregate secret scan stays clean

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
This commit is contained in:
garrytanandcapy-ai[bot] committed 2026-10-26 06:02:49 +00:00
1 parent 8ca299f2c7
commit 1f6c85af7c
1 file changed
+3 -3
+3 -3
View File
@@ -332,9 +332,9 @@ export function directProxyLogLine(env: NodeJS.ProcessEnv, platform: NodeJS.Plat
* parser as written, so a typo such as `http:/host:3128` keeps the * parser as written, so a typo such as `http:/host:3128` keeps the
* diagnostic it had; parseProxyConfig then rejects any path, query or * diagnostic it had; parseProxyConfig then rejects any path, query or
* fragment, so no part of a password can land outside the redacted userinfo. * fragment, so no part of a password can land outside the redacted userinfo.
* A userinfo that opens with a known scheme (`https:bob:pw@host:3128`, the * A userinfo that opens with a known scheme (`https:bob@host:3128`, the
* slash-less spelling the URL parser reads as `https://bob:pw@host:3128`) * slash-less spelling the URL parser reads as an `https://` URL with user
* is a scheme, not credentials, so it is excluded too. * `bob`) is a scheme, not credentials, so it is excluded too.
*/ */
const SCHEMELESS_PROXY_RE = /^(?:[^/\\?#@\s]+@)?(?:\[[0-9a-f:.]+\]|(?=[^:]*[a-z.])[^/\\?#@\s:[\]]+)(?::\d+)?$/i; const SCHEMELESS_PROXY_RE = /^(?:[^/\\?#@\s]+@)?(?:\[[0-9a-f:.]+\]|(?=[^:]*[a-z.])[^/\\?#@\s:[\]]+)(?::\d+)?$/i;
const LEADING_SCHEME_RE = /^(?:https?|socks5h?):/i; const LEADING_SCHEME_RE = /^(?:https?|socks5h?):/i;