Traceback (most recent call last):
File "E:/Pycharm Project/CTF/xman-ctf��¼.py", line 56, in <module>
if accesss(urllib.unquote(sub_tables(i, w))):
File "E:/Pycharm Project/CTF/xman-ctf��¼.py", line 31, in accesss
if "成功" in text:
UnicodeDecodeError: 'gb2312' codec can't decode bytes in position 0-1: illegal multibyte sequence

解决盲注中,当判断为TRUE的时候,关键词为中文时,产生的编码问题,对返回包进行 encode('utf-8'),形如下面

1 response = requests.post(url, data=data, headers=headers)
2     print response.text
3     text = response.text
4 
5     print data['username']
6     text = text.encode('utf-8')
7     if "成功" in text:
8         ...

就可解决

相关文章:

  • 2021-09-20
  • 2022-12-23
  • 2022-01-01
  • 2022-01-11
  • 2021-06-25
  • 2021-05-28
  • 2022-02-02
  • 2021-10-01
猜你喜欢
  • 2021-06-22
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-11
  • 2022-02-24
相关资源
相似解决方案