Explorar o código

added cookies (#27)

After solving the CAPTCHA the categorization request will fail without cookies.
UA3 %!s(int64=5) %!d(string=hai) anos
pai
achega
96e89346c4
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      domainhunter.py

+ 1 - 1
domainhunter.py

@@ -109,7 +109,7 @@ def checkBluecoat(domain):
                     response = s.get(url=captchasolutionURL,headers=headers,verify=False,proxies=proxies)
 
                     # Try the categorization request again
-                    response = s.post(url,headers=headers,json=postData,verify=False,proxies=proxies)
+                    response = s.post(url,headers=headers,cookies=c,json=postData,verify=False,proxies=proxies)
 
                     responseJSON = json.loads(response.text)