Skip to content

Commit

Permalink
[PM-3575] Public Suffix List Incorrectly Detected (#6735)
Browse files Browse the repository at this point in the history
  • Loading branch information
cagonzalezcs authored Nov 15, 2023
1 parent 8e047f6 commit 91fd4f7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion libs/common/src/platform/misc/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,10 @@ export class Utils {
}

try {
const parseResult = parse(uriString, { validHosts: this.validHosts });
const parseResult = parse(uriString, {
validHosts: this.validHosts,
allowPrivateDomains: true,
});
if (parseResult != null && parseResult.hostname != null) {
if (parseResult.hostname === "localhost" || parseResult.isIp) {
return parseResult.hostname;
Expand Down

0 comments on commit 91fd4f7

Please sign in to comment.