ProxyHealthList

/ 사용 사례 / curl

curl로 프록시 사용법

curl은 HTTP·HTTPS·SOCKS 프록시를 기본 지원합니다. 각 유형의 정확한 플래그와, 매시간 검증되는 무료 목록에서 바로 프록시를 가져오는 명령을 소개합니다.

전체 프록시 (TXT) 테스트 명령 생성

프록시 유형별 플래그

프록시 유형curl 명령
HTTP / HTTPScurl -x http://host:port URL
SOCKS5 (원격 DNS)curl --socks5-hostname host:port URL
SOCKS5 (로컬 DNS)curl --socks5 host:port URL
SOCKS4curl --socks4 host:port URL

죽은 프록시에서 멈추지 않도록 항상 --max-time 10을 추가하세요.

환경 변수

export http_proxy="http://1.2.3.4:8080"
export https_proxy="http://1.2.3.4:8080"
curl -I "https://example.com/"

한 줄로 작동하는 프록시 가져오기

proxy="$(curl -sL https://raw.githubusercontent.com/xyzs996/free-proxy-health-list/main/proxies/protocols/http/data.txt | head -n 1)"
curl -x "http://$proxy" -I "https://example.com/" --max-time 10

자주 묻는 질문

--socks5 인가 --socks5-hostname 인가?

--socks5는 DNS를 로컬 해석, --socks5-hostname은 프록시로 해석. DNS 유출을 피하려면 후자를 권장.

curl이 프록시에서 멈추면?

--max-time을 추가하세요. 무료 프록시는 죽으므로 빨리 타임아웃하고 다음으로.

스크립트 없이 프록시를 테스트할 수 있나요?

예 — 명령 생성기가 실행 가능한 curl을 만듭니다.

관련