mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-10-19 21:22:50 +03:00
fix partial password masking and ambiguous ice server restore
- Mask userinfo before query params so a credential key inside a password can't leave the rest of it visible - Reject restoring redacted ice servers when saved servers share urls but hold different accounts
This commit is contained in:
@@ -21,8 +21,8 @@ export const maskCredentials = (value: string): string => {
|
||||
}
|
||||
|
||||
return value
|
||||
.replace(CREDENTIAL_QUERY_PATTERN, "$1*")
|
||||
.replace(URL_USERINFO_PATTERN, "://*:*@");
|
||||
.replace(URL_USERINFO_PATTERN, "://*:*@")
|
||||
.replace(CREDENTIAL_QUERY_PATTERN, "$1*");
|
||||
};
|
||||
|
||||
export const hasCredentials = (value: string): boolean =>
|
||||
|
||||
Reference in New Issue
Block a user