Pier Angelo Vendrame pushed to branch tor-browser-102.9.0esr-12.5-1 at The Tor Project / Applications / Tor Browser

Commits:

1 changed file:

Changes:

  • browser/base/content/pageinfo/security.js
    ... ... @@ -66,7 +66,12 @@ var security = {
    66 66
             Ci.nsIWebProgressListener.STATE_LOADED_MIXED_DISPLAY_CONTENT);
    
    67 67
         var isEV = ui.state & Ci.nsIWebProgressListener.STATE_IDENTITY_EV_TOPLEVEL;
    
    68 68
         var isOnion = false;
    
    69
    -    const hostName = this.windowInfo.hostName;
    
    69
    +    let hostName;
    
    70
    +    try {
    
    71
    +      hostName = Services.eTLD.getBaseDomain(this.uri);
    
    72
    +    } catch (e) {
    
    73
    +      hostName = this.windowInfo.hostName;
    
    74
    +    }
    
    70 75
         if (hostName && hostName.endsWith(".onion")) {
    
    71 76
           isOnion = true;
    
    72 77
         }