Skip to content

Commit 79aa315

Browse files
committed
Some Python DREI patch
1 parent 79f4cfb commit 79aa315

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

Diff for: data/txt/sha256sums.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ bf77f9fc4296f239687297aee1fd6113b34f855965a6f690b52e26bd348cb353 lib/core/profi
187187
4eff81c639a72b261c8ba1c876a01246e718e6626e8e77ae9cc6298b20a39355 lib/core/replication.py
188188
bbd1dcda835934728efc6d68686e9b0da72b09b3ee38f3c0ab78e8c18b0ba726 lib/core/revision.py
189189
eed6b0a21b3e69c5583133346b0639dc89937bd588887968ee85f8389d7c3c96 lib/core/session.py
190-
f54817044034f9b2bbaecb0468ba4bc3048d5823552b039f21d5972a0f08331b lib/core/settings.py
190+
b11db6c466811af77273660cfade43de6450d9a05ddeab5231d37ae73921cb21 lib/core/settings.py
191191
2bec97d8a950f7b884e31dfe9410467f00d24f21b35672b95f8d68ed59685fd4 lib/core/shell.py
192192
e90a359b37a55c446c60e70ccd533f87276714d0b09e34f69b0740fd729ddbf8 lib/core/subprocessng.py
193193
54f7c70b4c7a9931f7ff3c1c12030180bde38e35a306d5e343ad6052919974cd lib/core/target.py
@@ -622,7 +622,7 @@ d1d54fc08f80148a4e2ac5eee84c8475617e8c18bfbde0dfe6894c0f868e4659 thirdparty/pyd
622622
1c61d71502a80f642ff34726aa287ac40c1edd8f9239ce2e094f6fded00d00d4 thirdparty/six/__init__.py
623623
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 thirdparty/socks/__init__.py
624624
7027e214e014eb78b7adcc1ceda5aca713a79fc4f6a0c52c9da5b3e707e6ffe9 thirdparty/socks/LICENSE
625-
5ac11e932896dfb7d50353dd16f717bd98cb1fb235f28e6fe8880c03655838bb thirdparty/socks/socks.py
625+
543217f63a4f0a7e7b4f9063058d2173099d54d010a6a4432e15a97f76456520 thirdparty/socks/socks.py
626626
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 thirdparty/termcolor/__init__.py
627627
b14474d467c70f5fe6cb8ed624f79d881c04fe6aeb7d406455da624fe8b3c0df thirdparty/termcolor/termcolor.py
628628
4db695470f664b0d7cd5e6b9f3c94c8d811c4c550f37f17ed7bdab61bc3bdefc thirdparty/wininetpton/__init__.py

Diff for: lib/core/settings.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
from thirdparty import six
2020

2121
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
22-
VERSION = "1.8.6.16"
22+
VERSION = "1.8.6.17"
2323
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
2424
TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34}
2525
VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE)

Diff for: thirdparty/socks/socks.py

+8-8
Original file line numberDiff line numberDiff line change
@@ -185,31 +185,31 @@ def __negotiatesocks5(self, destaddr, destport):
185185
# We'll receive the server's response to determine which
186186
# method was selected
187187
chosenauth = self.__recvall(2)
188-
if chosenauth[0:1] != chr(0x05).encode():
188+
if chosenauth[0:1] != b'\x05':
189189
self.close()
190190
raise GeneralProxyError((1, _generalerrors[1]))
191191
# Check the chosen authentication method
192-
if chosenauth[1:2] == chr(0x00).encode():
192+
if chosenauth[1:2] == b'\x00':
193193
# No authentication is required
194194
pass
195-
elif chosenauth[1:2] == chr(0x02).encode():
195+
elif chosenauth[1:2] == b'\x02':
196196
# Okay, we need to perform a basic username/password
197197
# authentication.
198-
self.sendall(chr(0x01).encode() + chr(len(self.__proxy[4])).encode() + self.__proxy[4].encode() + chr(len(self.__proxy[5])).encode() + self.__proxy[5].encode())
198+
self.sendall(b'\x01' + chr(len(self.__proxy[4])).encode() + self.__proxy[4].encode() + chr(len(self.__proxy[5])).encode() + self.__proxy[5].encode())
199199
authstat = self.__recvall(2)
200-
if authstat[0:1] != chr(0x01).encode():
200+
if authstat[0:1] != b'\x01':
201201
# Bad response
202202
self.close()
203203
raise GeneralProxyError((1, _generalerrors[1]))
204-
if authstat[1:2] != chr(0x00).encode():
204+
if authstat[1:2] != b'\x00':
205205
# Authentication failed
206206
self.close()
207207
raise Socks5AuthError((3, _socks5autherrors[3]))
208208
# Authentication succeeded
209209
else:
210210
# Reaching here is always bad
211211
self.close()
212-
if chosenauth[1] == chr(0xFF).encode():
212+
if chosenauth[1:2] == b'\xff':
213213
raise Socks5AuthError((2, _socks5autherrors[2]))
214214
else:
215215
raise GeneralProxyError((1, _generalerrors[1]))
@@ -219,7 +219,7 @@ def __negotiatesocks5(self, destaddr, destport):
219219
# use the IPv4 address request even if remote resolving was specified.
220220
try:
221221
ipaddr = socket.inet_aton(destaddr)
222-
req = req + chr(0x01).encode() + ipaddr
222+
req = req + b'\x01' + ipaddr
223223
except socket.error:
224224
# Well it's not an IP number, so it's probably a DNS name.
225225
if self.__proxy[3]:

0 commit comments

Comments
 (0)