This commit is contained in:
Miroslav Stampar 2018-06-01 11:23:41 +02:00
parent e7d448c56c
commit c1825b2651
3 changed files with 6 additions and 3 deletions

View file

@ -19,7 +19,7 @@ from lib.core.enums import DBMS_DIRECTORY_NAME
from lib.core.enums import OS
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
VERSION = "1.2.6.0"
VERSION = "1.2.6.1"
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34}
VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE)

View file

@ -49,6 +49,7 @@ def update():
errMsg = "unable to update content of directory '%s' ('%s')" % (directory, getSafeExString(ex))
logger.error(errMsg)
else:
attrs = os.stat(os.path.join(directory, "sqlmap.py")).st_mode
for wildcard in ('*', ".*"):
for _ in glob.glob(os.path.join(directory, wildcard)):
try:
@ -83,6 +84,8 @@ def update():
else:
if not success:
logger.error("update could not be completed")
else:
os.chmod(os.path.join(directory, "sqlmap.py"), attrs)
else:
infoMsg = "updating sqlmap to the latest development revision from the "
infoMsg += "GitHub repository"