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

Skip to content

Commit a851dc4

Browse files
committed
Couple of trivialities
1 parent 9077734 commit a851dc4

4 files changed

Lines changed: 9 additions & 7 deletions

File tree

lib/core/common.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1274,7 +1274,7 @@ def checkPipedInput():
12741274
# Reference: https://stackoverflow.com/a/33873570
12751275
"""
12761276

1277-
return not os.isatty(sys.stdin.fileno()) if hasattr(sys.stdin, "fileno") else False
1277+
return hasattr(sys.stdin, "fileno") and not os.isatty(sys.stdin.fileno())
12781278

12791279
def isZipFile(filename):
12801280
"""
@@ -1364,9 +1364,9 @@ def parsePasswordHash(password):
13641364
>>> kb.forcedDbms = popValue()
13651365
"""
13661366

1367-
blank = " " * 8
1367+
blank = ' ' * 8
13681368

1369-
if isNoneValue(password) or password == " ":
1369+
if isNoneValue(password) or password == ' ':
13701370
retVal = NULL
13711371
else:
13721372
retVal = password
@@ -1510,7 +1510,7 @@ def parseTargetDirect():
15101510
if details:
15111511
conf.dbms = details.group("dbms")
15121512

1513-
if details.group('credentials'):
1513+
if details.group("credentials"):
15141514
conf.dbmsUser = details.group("user")
15151515
conf.dbmsPass = details.group("pass")
15161516
else:
@@ -1622,7 +1622,7 @@ def parseTargetUrl():
16221622

16231623
originalUrl = conf.url
16241624

1625-
if re.search(r"\[.+\]", conf.url) and not socket.has_ipv6:
1625+
if re.search(r"://\[.+\]", conf.url) and not socket.has_ipv6:
16261626
errMsg = "IPv6 communication is not supported "
16271627
errMsg += "on this platform"
16281628
raise SqlmapGenericException(errMsg)

lib/core/settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
from thirdparty.six import unichr as _unichr
1919

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

lib/request/redirecthandler.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,7 @@ class _(object):
154154
except AttributeError:
155155
def _(self):
156156
return getattr(self, "hdrs") or {}
157+
157158
result.info = types.MethodType(_, result)
158159

159160
if not hasattr(result, "read"):
@@ -164,6 +165,7 @@ def _(self, length=None):
164165
retVal = ""
165166
finally:
166167
return retVal
168+
167169
result.read = types.MethodType(_, result)
168170

169171
if not getattr(result, "url", None):

sqlmap.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -534,4 +534,4 @@ def main():
534534
sys.exit(getattr(os, "_exitcode", 0))
535535
else:
536536
# cancelling postponed imports (because of Travis CI checks)
537-
from lib.controller.controller import start
537+
__import__("lib.controller.controller")

0 commit comments

Comments
 (0)