Methodology

How the PAC file tester gets from your proxy.pac to a list of findings and a grade, and how to judge how far to trust each part.

1. Running the file: engine profiles

Browsers and operating systems do not share one PAC implementation. The tester models five of them as engine profiles: Chromium (Chrome, Edge, Brave, Opera, Vivaldi), Firefox, pacparser (the library behind pactester), and two Windows profiles: WinHTTP for Windows services and WinINet for desktop applications that use the Windows proxy settings. Each profile has version ranges.

  • Where the licence allows, a profile runs the engine’s own helper library, copied verbatim from the upstream source at a pinned commit. Otherwise the library is emulated.
  • On top of that, the profile models the engine’s documented differences: how much of the URL the script sees, whether host is lower-cased, which functions exist, how DNS behaves and what happens on an exception or a missing return value. The differences table lists them side by side.
  • The PAC runs in a sandboxed worker on a separate origin, with a time limit. myIpAddress(), DNS answers and the date and time come from the values you set, so results are reproducible.

Your URL runs in the profile you choose, and the tester shows the path it took through the file. For the rating, the tester adds probe URLs built from the domains in your file, such as look-alike domains, query strings that contain a trusted name, and IP literals, because the dangerous cases are usually the ones nobody thought to test.

Profiles are models, not browsers. The pacparser profile is compared against the real pacparser library in automated parity tests. Browser behaviour is being confirmed in a lab with real Chrome, Edge and Firefox builds. Windows publishes no source for its PAC engine, so the two Windows profiles imitate the behaviour measured in lab runs on Windows 11. Where a lab result exists, the claim is marked lab.

2. Findings: the rule catalogue

Every check is a public rule with an id, a category, a severity, an explanation, a bad and a good example and, where engines differ, per-engine notes. Rules belong to six categories: errors and robustness, security and fail-safety, correctness, compatibility across engines, performance, and best practice. Delivery (how the file is served) is graded separately when you paste the response headers.

Most rules are static: they read the code. Some depend on evaluation results, for example a function that returns nothing for some URL, or a script that runs out of time.

3. The grade

Each category starts at 100 and loses points for every finding, more for higher severities and for repeated hits. The weighted result gives a letter from A to F. Serious findings, such as a file that does not load or a high-severity security bypass, limit the letter however good the rest is.

A+ requires an A with no warnings at all, a commented default route and the same result in every engine profile. A- is an A with at least one warning. The basic checks run in your browser; the full rating is computed on the server, so the rules can be improved without shipping new code.

4. Evidence: where every engine claim comes from

Each statement about engine behaviour carries a source type and a date:

SourceMeaning
coderead in the engine’s open-source code at a pinned commit or tag
docvendor documentation or release notes
labobserved in a lab run against the real engine
expertpractitioner knowledge, not yet verified (shown as unverified)

New engine releases are watched automatically. When PAC-related source files change, the affected claims are reviewed.

5. Privacy: only the logical shape of your file leaves your browser

Your file never leaves your browser. For the rating, only its logical shape is sent: no names, no addresses from your network, no text. Public, well-known addresses (such as 127.0.0.1 or 10.0.0.0) and network masks stay as written, because they say nothing about you.

  • The PAC file is parsed and run in your browser. The trace of a URL, the basic checks and the path view use the unchanged file, and they run there too.

  • The logical shape is a description of how the file decides. Every name, address and piece of text in it is replaced by what kind of thing it is. A host test becomes, for example, “ends with a domain of 3 labels”, and an address becomes “a private network /16”.

    • Letters become placeholders, while dots, stars and other punctuation stay where they are. The same name gets the same placeholder everywhere in the file, so the rules can see that two tests use the same domain, but not which domain it is.
    • Your own function and variable names become numbered placeholders. The names of the standard PAC functions stay as written.
    • A proxy string keeps its keywords (such as PROXY and DIRECT), its entries and their port numbers, but not the proxy’s name or address.
    • Some public values stay as written, because the rules need them and they say nothing about you. These are numbers of up to four digits (such as ports, hours and years), network masks, well-known addresses such as 127.0.0.1 or 10.0.0.0, common domain endings such as .com, and the published host names and addresses of the security vendors’ services.
    • Comments are left out, apart from a few fixed words that the rules look for.
    • The results of the test runs in your browser are reduced to what happened: a proxy answer, a DIRECT answer, an error or a time-out, and which line decided.

    The rules can be checked against the shape, but your file cannot be rebuilt from it.

  • Every check sends the shape and gets the short report back: the grade, the score and the most important findings. The server keeps a short record of each rating: the grade, the rules that fired and size ranges, with no text, names or addresses.

  • “Show all findings” first asks whether the shape may be kept. If you agree, the same shape is sent once more, and the server keeps it together with its rating. The full report comes back with placeholders, and your browser fills in the names and pieces of text from your file, so you see every finding with its line, what was found there and a fix. The kept shape is used for anonymous statistics about how PAC files are built: which functions and patterns are common, and which mistakes occur. It is deleted after 730 days. Nothing else from your file is kept. A very large shape (over 8 MiB) is not kept at all, but you still see every finding.

  • The site sets no cookies and loads no analytics or third-party scripts.

Limits

A model can be wrong where the real engine has undocumented behaviour, and other PAC consumers exist that have no profile here: macOS and iOS, Android and appliances. Always confirm critical changes in the client you actually deploy to. The tester always flags JavaScript syntax that Windows or older engines reject, whichever engine profile you choose.

Last updated: