Don't Trust the Marketing Page: Score Your Proxy Provider's IP Quality in ~60 Lines of Python

작성자

카테고리:

← 피드로
DEV Community · Proxy Universe · 2026-07-22 개발(SW)

Proxy Universe

Subtitle: Every provider claims “clean residential IPs”. After the 2026 outage wave I trust none of them — I test. Here’s the scorer I run before putting money on any network: latency, fraud score, and ban-rate against real targets.

In my previous posts I covered building a failover layer and monitoring provider uptime. This closes the trilogy: how do you know a provider’s IPs are actually good before you commit a deposit?

“Good” is measurable. For any proxy, three numbers tell you most of what matters:

  1. Latency — time to first byte through the proxy
  2. Fraud/abuse score — is the IP already burned in reputation databases
  3. Target survival — does the IP get challenged by the sites you actually care about

The scorer

import concurrent.futures as cf
import time
import requests

# proxies to test: grab 20-50 fresh IPs from the provider's gateway
PROXIES = [
    "http://user:[email protected]:7777",
    # ... more sessions/IPs
]

# swap for your real targets
TARGETS = [
    "https://www.amazon.com/",
    "https://www.google.com/search?q=test",
]

IPINFO = "https://ipinfo.io/json"
SCAMALYTICS = "https://scamalytics.com/ip/{ip}"  # manual check; API is paid

def test_proxy(proxy_url: str) -> dict:
    p = {"http": proxy_url, "https": proxy_url}
    result = {"proxy": proxy_url[:40], "ok": False}

    # 1. latency + exit IP
    t0 = time.time()
    try:
        r = requests.get(IPINFO, proxies=p, timeout=12)
        result["latency_ms"] = round((time.time() - t0) * 1000)
        info = r.json()
        result["exit_ip"] = info.get("ip")
        result["geo"] = f'{info.get("country")}/{info.get("city")}'
        result["org"] = info.get("org", "")[:40]
    except Exception as e:
        result["error"] = f"connect: {type(e).__name__}"
        return result

    # 2. datacenter smell test: residential orgs are ISPs, not clouds
    dc_words = ("amazon", "google", "digitalocean", "ovh", "hetzner", "m247")
    result["looks_dc"] = any(w in result["org"].lower() for w in dc_words)

    # 3. target survival: 200 = pass, 403/429/503 or captcha markers = burned
    burned = 0
    for url in TARGETS:
        try:
            tr = requests.get(url, proxies=p, timeout=15,
                              headers={"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64)"})
            text_sample = tr.text[:4000].lower()
            if tr.status_code != 200 or "captcha" in text_sample:
                burned += 1
        except Exception:
            burned += 1
    result["burned_targets"] = f"{burned}/{len(TARGETS)}"
    result["ok"] = True
    return result

with cf.ThreadPoolExecutor(max_workers=10) as ex:
    rows = list(ex.map(test_proxy, PROXIES))

rows.sort(key=lambda r: r.get("latency_ms", 99999))
for r in rows:
    print(r)

good = [r for r in rows if r["ok"] and not r["looks_dc"] and r["burned_targets"].startswith("0")]
print(f"\nPASS: {len(good)}/{len(rows)} "
      f"(median latency {sorted(r['latency_ms'] for r in rows if r['ok'])[len(rows)//2]}ms)")

Enter fullscreen mode Exit fullscreen mode

How to read the results

Latency. Residential proxies add 300–900ms TTFB normally. Median above ~1.5s means an overloaded gateway — it won’t get better under your production load.

The looks_dc flag. If a “residential” provider’s exit IPs resolve to Amazon or M247 orgs, you’re paying residential prices for datacenter IPs. Walk away. (This exact test has saved me from two providers this year.)

Burned targets. This is the one that matters most and the one no review can tell you, because it depends on your targets. A pool that’s clean for Amazon may be torched for sneaker sites. Test with 30+ IPs to get a real rate: anything above ~15% burned on first contact means the pool is oversold in your niche.

The workflow that actually protects you

  1. Deposit the minimum ($5–10) at any new provider.
  2. Pull 30–50 IPs, run the scorer against your real targets.
  3. Score again a week later — pool quality drifts as providers resell capacity.
  4. Keep results per provider; when quality drops two checks in a row, shift volume to your backup before it becomes an emergency.

Step 4 is why I do all of this on an aggregator (one balance across 10+ networks) — moving volume between networks is a dropdown, not a new vendor onboarding. After watching PIA S5, IP2World, 922 S5 and 9Proxy users scramble this year, “migration is one click” stopped being a convenience and became the whole point.

Next post: putting the three scripts together into a self-healing proxy layer with automatic weight shifting. If you want it sooner, say so in the comments.

원문에서 계속 ↗

코멘트

답글 남기기

이메일 주소는 공개되지 않습니다. 필수 필드는 *로 표시됩니다