diff --git a/lib/core/gui.py b/lib/core/gui.py index 277fc0056..297677fa5 100644 --- a/lib/core/gui.py +++ b/lib/core/gui.py @@ -5,8 +5,11 @@ Copyright (c) 2006-2019 sqlmap developers (http://sqlmap.org/) See the file 'LICENSE' for copying permission """ +import re +import tkinter as tk import webbrowser +from lib.core.defaults import defaults from lib.core.settings import DEV_EMAIL_ADDRESS from lib.core.settings import ISSUES_PAGE from lib.core.settings import GIT_PAGE @@ -14,14 +17,9 @@ from lib.core.settings import SITE from lib.core.settings import VERSION_STRING from lib.core.settings import WIKI_PAGE from thirdparty.six.moves import tkinter_messagebox as _tkinter_messagebox +from tkinter import ttk def runGui(parser): - import re - import tkinter as tk - from tkinter import ttk - - from lib.core.defaults import defaults - # Reference: https://www.reddit.com/r/learnpython/comments/985umy/limit_user_input_to_only_int_with_tkinter/e4dj9k9?utm_source=share&utm_medium=web2x class ConstrainedEntry(tk.Entry): def __init__(self, master=None, **kwargs): diff --git a/lib/core/settings.py b/lib/core/settings.py index 4b2940af3..42927c58e 100644 --- a/lib/core/settings.py +++ b/lib/core/settings.py @@ -18,7 +18,7 @@ from lib.core.enums import OS from thirdparty.six import unichr as _unichr # sqlmap version (...) -VERSION = "1.3.11.88" +VERSION = "1.3.11.89" 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) diff --git a/lib/parse/cmdline.py b/lib/parse/cmdline.py index dfd3ed939..6fa1334df 100644 --- a/lib/parse/cmdline.py +++ b/lib/parse/cmdline.py @@ -79,7 +79,6 @@ from lib.core.dicts import DEPRECATED_OPTIONS from lib.core.enums import AUTOCOMPLETE_TYPE from lib.core.exception import SqlmapShellQuitException from lib.core.exception import SqlmapSyntaxException -from lib.core.gui import runGui from lib.core.option import _createHomeDirectories from lib.core.settings import BASIC_HELP_ITEMS from lib.core.settings import DUMMY_URL @@ -863,6 +862,8 @@ def cmdLineParser(argv=None): checkOldOptions(argv) if "--gui" in argv: + from lib.core.gui import runGui + runGui(parser) elif "--sqlmap-shell" in argv: