MOON
Server: Apache
System: Linux 54-179-220-51.cprapid.com 3.10.0-1160.144.1.el7.tuxcare.els4.x86_64 #1 SMP Tue Apr 7 08:40:40 UTC 2026 x86_64
User: thehunarfound (1001)
PHP: 7.4.29
Disabled: NONE
Upload Files
File: /home/thehunarfound/public_html/DMSold/node_modules/degenerator/test/pac-resolver-gh-3.js
// FindProxyForURL, isInNet
function FindProxyForURL(url, host) {
    if (isHostInAnySubnet(host, ['10.1.2.0', '10.1.3.0'], '255.255.255.0')) {
        return "HTTPS proxy.example.com";
    }

    if (isHostInAnySubnet(host, ['10.2.2.0', '10.2.3.0'], '255.255.255.0')) {
        return "HTTPS proxy.example.com";
    }

    // Everything else, go direct:
    return "DIRECT";
}

// Checks if the single host is within a list of subnets using the single mask.
function isHostInAnySubnet(host, subnets, mask) {
    var subnets_length = subnets.length;
    for (i = 0; i < subnets_length; i++) {
        if (isInNet(host, subnets[i], mask)) {
            return true;
        }
    }
}
;;