Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 10fd004

Browse files
committed
Reverting set() brace form because of Python 2.6 compatibility issues
1 parent 0a8bc52 commit 10fd004

8 files changed

Lines changed: 18 additions & 15 deletions

File tree

lib/core/common.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -770,7 +770,7 @@ def getManualDirectories():
770770
checkFile(listPath)
771771
directories = getFileItems(listPath)
772772
elif choice == '4':
773-
targets = {conf.hostname}
773+
targets = set([conf.hostname])
774774
_ = conf.hostname.split('.')
775775

776776
if _[0] == "www":

lib/core/settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
from lib.core.enums import OS
2020

2121
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
22-
VERSION = "1.2.1.22"
22+
VERSION = "1.2.1.23"
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)

lib/takeover/web.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ def webInit(self):
205205

206206
if readInput(message, default='Y', boolean=True):
207207
headers = {}
208-
been = {conf.url}
208+
been = set([conf.url])
209209

210210
for match in re.finditer(r"=['\"]((https?):)?(//[^/'\"]+)?(/[\w/.-]*)\bwp-", kb.originalPage or "", re.I):
211211
url = "%s%s" % (conf.url.replace(conf.path, match.group(4)), "wp-content/wp-db.php")

lib/utils/crawler.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ def crawlThread():
126126
dataToStdout("\r[%s] [INFO] %s" % (time.strftime("%X"), status), True)
127127

128128
threadData.shared.deeper = set()
129-
threadData.shared.unprocessed = {target}
129+
threadData.shared.unprocessed = set([target])
130130

131131
if not conf.sitemapUrl:
132132
message = "do you want to check for the existence of "

lib/utils/har.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ def toDict(self):
180180
"size": len(self.content or "")
181181
}
182182

183-
binary = {'\0', '\1'}
183+
binary = set(['\0', '\1'])
184184
if any(c in binary for c in self.content):
185185
content["encoding"] = "base64"
186186
content["text"] = base64.b64encode(self.content)

plugins/generic/enumeration.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,13 @@ def getBanner(self):
6060
bannerParser(kb.data.banner)
6161

6262
if conf.os and conf.os == "windows":
63-
kb.bannerFp["type"] = {"Windows"}
63+
kb.bannerFp["type"] = set(["Windows"])
6464

6565
elif conf.os and conf.os == "linux":
66-
kb.bannerFp["type"] = {"Linux"}
66+
kb.bannerFp["type"] = set(["Linux"])
6767

6868
elif conf.os:
69-
kb.bannerFp["type"] = {"%s%s" % (conf.os[0].upper(), conf.os[1:])}
69+
kb.bannerFp["type"] = set(["%s%s" % (conf.os[0].upper(), conf.os[1:])])
7070

7171
if conf.os:
7272
setOs()

sqlmap.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -381,3 +381,6 @@ def main():
381381

382382
if __name__ == "__main__":
383383
main()
384+
else:
385+
# cancelling postponed imports (because of Travis CI checks)
386+
from lib.controller.controller import start

txt/checksum.md5

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ a7b0c8e5a18a3abe8803999dcfc4664f lib/controller/handler.py
2727
1e5532ede194ac9c083891c2f02bca93 lib/controller/__init__.py
2828
e3a3f5218b2e52dd0afafdfc9fed2002 lib/core/agent.py
2929
86a4703d5474badd8462146510b2c460 lib/core/bigarray.py
30-
e4fa4177b9d3c24555fb275335496e29 lib/core/common.py
30+
27d1b0a4609eece643141408d1f18716 lib/core/common.py
3131
2a40d5b5997265daa890545d4a4a59b9 lib/core/convert.py
3232
9f87391b6a3395f7f50830b391264f27 lib/core/data.py
3333
72016ea5c994a711a262fd64572a0fcd lib/core/datatype.py
@@ -46,7 +46,7 @@ ffa5f01f39b17c8d73423acca6cfe86a lib/core/readlineng.py
4646
0c3eef46bdbf87e29a3f95f90240d192 lib/core/replication.py
4747
a7db43859b61569b601b97f187dd31c5 lib/core/revision.py
4848
fcb74fcc9577523524659ec49e2e964b lib/core/session.py
49-
7fc35bef60750c8ba2475c154d7d481c lib/core/settings.py
49+
ee202f91d95b559f4cd9355f55203946 lib/core/settings.py
5050
d0adc28a38e43a787df4471f7f027413 lib/core/shell.py
5151
63491be462c515a1a3880c27c2acc4a2 lib/core/subprocessng.py
5252
505aaa61e1bba3c3d4567c3e667699e3 lib/core/target.py
@@ -85,7 +85,7 @@ acc1db3667bf910b809eb279b60595eb lib/takeover/icmpsh.py
8585
703e15714316a8cc4bbe54cdd0a8cb87 lib/takeover/metasploit.py
8686
0fc9b00596df21c8878ef92f513ecad7 lib/takeover/registry.py
8787
48575dde7bb867b7937769f569a98309 lib/takeover/udf.py
88-
3972e3e00115c6e4e03336e23e35b1de lib/takeover/web.py
88+
1398cb4ee55becf628367854b5310f33 lib/takeover/web.py
8989
d8c10f278e5943b137a222f4cedca59d lib/takeover/xp_cmdshell.py
9090
f6844893afa7569052529e1c8d89bc35 lib/techniques/blind/inference.py
9191
1e5532ede194ac9c083891c2f02bca93 lib/techniques/blind/__init__.py
@@ -100,10 +100,10 @@ c497003ecf231d03a311a816a6b3b753 lib/techniques/union/test.py
100100
6c3c4c7d43ad75e61a73184323a81eac lib/techniques/union/use.py
101101
e4146464cf968d4015a52cb8c10e3da5 lib/utils/api.py
102102
37dfb641358669f62c2acedff241348b lib/utils/brute.py
103-
8f2f246d17f5891a2e584533bd18e65c lib/utils/crawler.py
103+
a34c4fd2e7d78c5dfdd9eeccb079fb1c lib/utils/crawler.py
104104
985c737cd8a6a722160c55cf5ee224f4 lib/utils/deps.py
105105
a6d6888e14a7c11f0884c8cc18489caa lib/utils/getch.py
106-
2384f77330583b53018a7dab5fc1c90f lib/utils/har.py
106+
7af29f61302c8693cd6436d4b69e22d3 lib/utils/har.py
107107
9bd8fbfb9c25ee685c97b260331e7165 lib/utils/hashdb.py
108108
29dee8f54cfb39feb0545d237542f866 lib/utils/hash.py
109109
145120b21fcfca843d5e2c8b0562e4db lib/utils/htmlentities.py
@@ -205,7 +205,7 @@ a3db8618eed5bb2807b6f77605cba9cc plugins/dbms/sybase/__init__.py
205205
e6cd1c5a5244d83396b401f7db43d323 plugins/generic/custom.py
206206
315a3ced9667065b24de040af296037a plugins/generic/databases.py
207207
b1bd764e8f417222ebb1890232290679 plugins/generic/entries.py
208-
00e0b1b5713784c8131660bfc40bbaac plugins/generic/enumeration.py
208+
d82f2c78c1d4d7c6487e94fd3a68a908 plugins/generic/enumeration.py
209209
ea0f3b9085061b272bfd98c13ad2d977 plugins/generic/filesystem.py
210210
f5d5419efddfe04648ea5e953c650793 plugins/generic/fingerprint.py
211211
1e5532ede194ac9c083891c2f02bca93 plugins/generic/__init__.py
@@ -224,7 +224,7 @@ c3cc8b7727161e64ab59f312c33b541a shell/stagers/stager.aspx_
224224
1f7f125f30e0e800beb21e2ebbab18e1 shell/stagers/stager.jsp_
225225
01e3505e796edf19aad6a996101c81c9 shell/stagers/stager.php_
226226
4eaeef94314956e4517e5310a28d579a sqlmapapi.py
227-
1bef42b51e59db28d04181955c405931 sqlmap.py
227+
3e2e790c370442c3d98eaa88a3523b15 sqlmap.py
228228
4c3b8a7daa4bff52e01d4168be0eedbe tamper/apostrophemask.py
229229
4115a55b8aba464723d645b7d3156b6e tamper/apostrophenullencode.py
230230
4b1024cecb00f13a4e1be78391e9cedb tamper/appendnullbyte.py

0 commit comments

Comments
 (0)