Using proxy-scraper 1.34 from Python Without Trusting It Blindly: Wheel Audit, Check States, and ProxyRotator
proxy-scraper is a two-month-old Python project (repository created 2026-09-24, 104 stars on 2026-12-02, MIT) that publishes a free HTTP/SOCKS4/SOCKS5 proxy list every hour and ships a CLI, a Python API, a rotating local proxy server and an MCP server. The pitch that got our attention: every entry carries the result of each check it went through (passed, failed, unavailable or skipped, with a reason code), not just an ip:port.
Young repo, network tool, pulls lists from hundreds of strangers’ URLs. So before we wrote a single line against it we read the source. This post covers what we checked in the 1.34.0 release, then how to use its list from Python in a way that doesn’t depend on trusting it.
We did not run a scan on our machines, because a full scan opens connections to up to 150,000 unknown addresses. Everything below comes from reading the source, diffing the PyPI artifact, and analysing the files the project publishes. The stdlib script in this post we did run.
Step 1: check that PyPI ships what GitHub shows
The package on PyPI is proxy-scraper-cli (the plain name was taken). A clean repo means little if the wheel differs from it, so download the wheel without installing and diff it against the release commit:
mkdir -p audit && cd audit
pip download proxy-scraper-cli==1.34.0 --no-deps --only-binary :all: -d wheel
unzip -q wheel/proxy_scraper_cli-1.34.0-py3-none-any.whl -d wheel/x
shasum -a 256 wheel/*.whl
git clone https://github.com/maximilianfeix/proxy-scraper repo
git -C repo log --oneline --grep "Release 1.34.0" # df826e1
mkdir src && git -C repo archive df826e1 proxyscraper | tar -x -C src
diff -rq wheel/x/proxyscraper src/proxyscraper && echo "wheel matches df826e1"
On 2026-12-02 the wheel (SHA-256 starting cdca7ef0301b7945) matched commit df826e1 file for file. main is already 17 files ahead of that release, so pin the version you audited.
Step 2: grep for the things that matter
A static pass over proxyscraper/ (about 15,700 lines) for exec, eval, pickle, marshal, subprocess, base64 and hard-coded hosts turned up no obfuscated payloads and no telemetry. Three things stood out:
- It reads your GitHub CLI token.
sources.py:github_token()usesGITHUB_TOKEN/GH_TOKEN, and if neither is set it runsgh auth tokento lift the GitHub search API limit from 60 to 5,000 requests per hour. The token is only sent as a Bearer header toapi.github.com, andnetio.without_credentials()dropsAuthorization,CookieandProxy-Authorizationon any redirect to another host or from HTTPS down to HTTP. Fine in intent, but if yourghlogin hasrepooradminscopes, run scans withGH_TOKENset to a fine-grained token that has no permissions, or in a container withoutgh. - Source lists may be fetched over unverified TLS.
netio.http_request()defaults toinsecure_fallback=True: when certificate verification fails on a GET with no body and no custom headers, it retries withCERT_NONE. The author’s reasoning is that public lists are re-checked proxy by proxy anyway. The hourly list itself is loaded by the Python API and MCP tools throughverified_get(), which never falls back. - The rotating server won’t become an open proxy by accident. Binding
--serve-hostto anything other than loopback without a password exits with an error unless you add--serve-open. The code comment names the reason: Docker publishes ports past host firewalls such as ufw.
URLs mined from other scrapers’ config files go through a separate public_get() with a policy that rejects localhost, private ranges and disguised IPv4 forms like 127.1 or 0x7f000001, and pins the resolved address so DNS can’t swap it between the check and the connect.
Step 3: read the list without installing anything
You don’t need the package to use the data. https://proxy-scraper.de/proxies.json (also on the proxy-list branch) has one object per proxy with a checks map. This is the filter we use: every check passed, including the HTTPS one, exit IP not on the SpamCop blocklist, listed in at least half of the week’s runs.
import json
import urllib.request
from collections import Counter
LIST_URL = "https://proxy-scraper.de/proxies.json"
REQUIRED = ("basic", "confirm", "content", "https")
def load_rows(url: str = LIST_URL) -> list:
with urllib.request.urlopen(url, timeout=30) as resp:
return json.load(resp)
def passed_all(row: dict) -> bool:
checks = row.get("checks") or {}
return all((checks.get(name) or {}).get("state") == "passed" for name in REQUIRED)
def strict_pool(rows: list, min_uptime: int = 50) -> list:
return [
row for row in rows
if passed_all(row)
and row.get("blocklisted") is False
and (row.get("uptime_7d") or 0) >= min_uptime
]
def https_outcomes(rows: list) -> Counter:
def outcome(row):
check = (row.get("checks") or {}).get("https") or {}
return f"{check.get('state', 'missing')}:{check.get('reason', '')}".rstrip(":")
return Counter(outcome(row) for row in rows)
if __name__ == "__main__":
rows = load_rows()
pool = strict_pool(rows)
print(f"{len(rows)} listed, {len(pool)} pass the strict filter")
for reason, count in https_outcomes(rows).most_common():
print(f" https {reason}: {count}")
Against the list published at 09:38 UTC on 2026-12-02:
797 listed, 28 pass the strict filter
https passed: 450
https failed:timeout: 180
https failed:tunnel_refused: 91
https failed:connection_closed: 46
https failed:tls_certificate_invalid: 27
https failed:connect_refused: 3
So the strict pool is 28 of 797 entries, about 3.5 %. The filter that cuts the most is the blocklist: 422 of the 797 exit IPs (53 %) were on SpamCop in that run. The 27 tls_certificate_invalid entries are proxies that presented a certificate which did not verify for the test host. They’re still on the main list, because HTTPS is recorded but not required for all.txt. If you use all.txt directly, you get them.
Step 4: the Python API, once you’ve decided to install
The API surface is small. live_proxies() downloads the hourly list (verified TLS) and filters it, with no checks of its own:
from proxyscraper import live_proxies
proxies = live_proxies(
types=["socks5", "http"],
https=True,
no_blocklisted=True,
min_uptime=50,
limit=20,
)
for p in proxies:
https_check = p.checks.get("https")
print(p.url, p.latency, p.country, p.uptime_7d, https_check.state if https_check else "missing")
Each result is a LiveProxy with url, latency, exit_ip, country, org, hosting, blocklisted, uptime_24h, uptime_7d, sites, speed_kbps and checks (name → Check with state, reason, target, at, ms). The list was checked from a GitHub Actions runner up to an hour earlier, not from your network.
If you’d rather not write the retry loop, ProxyRotator starts the project’s rotating server on 127.0.0.1 with a random password and hands you one URL that rotates behind the scenes:
import requests
from proxyscraper import ProxyRotator
with ProxyRotator(country="DE") as rotator:
proxy = rotator.proxy_url()
r = requests.get("https://api.ipify.org", proxies={"http": proxy, "https": proxy}, timeout=30)
print(r.text)
# httpx.Client(proxy=proxy)
# Playwright: chromium.launch(proxy=rotator.playwright_proxy())
Two behaviours from docs/proxy-server.md that matter in real code. It only retries GET, HEAD, OPTIONS and TRACE through another proxy once a request may have reached the target, so a POST that dies midway comes back as 502 with X-Proxy-Scraper: no-retry-after-send instead of being sent twice. And for HTTPS it prefers proxies that passed the verified-TLS check but falls back to the others when none match your filter, so keep certificate verification on in your client.
Guardrails we’d keep
- Pin
proxy-scraper-cli==1.34.0(or whatever you diffed) and repeat Step 1 on upgrades. - Run scans with a no-scope
GH_TOKEN, or none, in a container or a throwaway VM. - Use the
checksmap, not file membership.all.txtrequiresbasic,confirmandcontent. HTTPS is extra. - Nothing authenticated goes through these proxies: no logins, cookies or API keys. The project’s own README says the same.
- Expect churn. In that run the median entry had been listed for one consecutive run and was present in 30 % of the week’s runs.
Where free proxies stop being worth it
The list includes a per-site test. For TikTok, 52 of the 225 HTTPS-capable proxies tested got a normal page from one request in that run, and Amazon was 0 of 277. That’s fine for testing a parser. It falls apart for a job that has to deliver every profile on a schedule. For TikTok and X data we call Ultimate TikTok Scraper or the X.com Twitter API Scraper from apify-client and don’t handle proxies at all:
from apify_client import ApifyClient
client = ApifyClient("<APIFY_TOKEN>")
run = client.actor("novi/tiktok-scraper-ultimate").call(run_input={
"keywords": ["web scraping"],
"maxItems": 30,
"outputFormat": "clean",
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
print(item.get("url"), item.get("views"), item.get("text", "")[:60])
The clean output format flattens each video into fields like url, text, author, views, likes and engagementRate.
References
- proxy-scraper repository, README,
docs/python.md,docs/proxy-server.md,docs/ARCHITECTURE.md(commit8594ca0, read2026-12-02): https://github.com/maximilianfeix/proxy-scraper - PyPI
proxy-scraper-cli1.34.0, uploaded2026-11-12: https://pypi.org/project/proxy-scraper-cli/ - Published list files (
proxies.json,stats.json,run.json) of the run that started2026-12-02 09:31 UTC: https://github.com/maximilianfeix/proxy-scraper/tree/proxy-list