0

Hello, so I am trying to get requests to some https page using proxies, but it gives me an error.

I tried couple of proxies from http://free-proxy.cz/en/proxylist/country/all/https/ping/all and other free proxy lists but none of them works (only http)

import requests
proxies = [
 {
 "https" : "207.236.12.76:10458"
 }
]
url = "https://api.ipify.org?format=json"
for proxy in proxies:
 resp = requests.get(url, proxies=proxy)
 print(resp.text)

This gives me this:

raise SSLError(e, request=request)
requests.exceptions.SSLError: HTTPSConnectionPool(host='api.ipify.org', port=443): Max retries exceeded with url: /?format=json (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1129)')))

When i tried adding https like {"https" : "https://207.236.12.76:10458" }:

raise ProxyError(e, request=request)
requests.exceptions.ProxyError: HTTPSConnectionPool(host='api.ipify.org', port=443): Max retries exceeded with url: /?format=json (Caused by ProxyError('Cannot connect to proxy.', OSError('Tunnel connection failed: 403 Forbidden')))

Am I doing something wrong or the proxies just doesn't work?

asked Jun 24, 2022 at 18:35
2
  • It probably just means that the proxies are dead Commented Jun 24, 2022 at 19:02
  • Yea, you are right. Commented Jun 24, 2022 at 19:35

1 Answer 1

1

Before implementation I'd suggest you check all proxies by curl like this

curl -v -L "https://2ip.ru/" -x "https://205.207.100.81:8282"
answered Jun 28, 2022 at 11:30
Sign up to request clarification or add additional context in comments.

1 Comment

As it’s currently written, your answer is unclear. Please edit to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers in the help center.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.