瀏覽代碼

added cookies (#27)

After solving the CAPTCHA the categorization request will fail without cookies.
UA3 5 年之前
父節點
當前提交
96e89346c4
共有 1 個文件被更改,包括 1 次插入1 次删除
  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)