|
67 | 67 | from lib.core.enums import PRIORITY |
68 | 68 | from lib.core.enums import PROXYTYPE |
69 | 69 | from lib.core.enums import REFLECTIVE_COUNTER |
| 70 | +from lib.core.enums import WIZARD |
70 | 71 | from lib.core.exception import sqlmapConnectionException |
71 | 72 | from lib.core.exception import sqlmapFilePathException |
72 | 73 | from lib.core.exception import sqlmapGenericException |
@@ -1382,6 +1383,9 @@ class _(unicode): pass |
1382 | 1383 | if conf.string: |
1383 | 1384 | conf.string = conf.string.decode("unicode_escape") |
1384 | 1385 |
|
| 1386 | + if conf.getAll: |
| 1387 | + map(lambda x: conf.__setitem__(x, True), WIZARD.ALL) |
| 1388 | + |
1385 | 1389 | threadData = getCurrentThreadData() |
1386 | 1390 | threadData.reset() |
1387 | 1391 |
|
@@ -1613,19 +1617,20 @@ def __useWizardInterface(): |
1613 | 1617 | conf.risk = 1 |
1614 | 1618 | conf.level = 1 |
1615 | 1619 |
|
1616 | | - choice = None |
| 1620 | + if not conf.getAll: |
| 1621 | + choice = None |
1617 | 1622 |
|
1618 | | - while choice is None or choice not in ("", "1", "2", "3"): |
1619 | | - message = "Enumeration (--banner/--current-user/etc). Please choose:\n" |
1620 | | - message += "[1] Basic (default)\n[2] Smart\n[3] All" |
1621 | | - choice = readInput(message, default='1') |
| 1623 | + while choice is None or choice not in ("", "1", "2", "3"): |
| 1624 | + message = "Enumeration (--banner/--current-user/etc). Please choose:\n" |
| 1625 | + message += "[1] Basic (default)\n[2] Smart\n[3] All" |
| 1626 | + choice = readInput(message, default='1') |
1622 | 1627 |
|
1623 | | - if choice == '2': |
1624 | | - map(lambda x: conf.__setitem__(x, True), ['getBanner', 'getCurrentUser', 'getCurrentDb', 'isDba', 'getUsers', 'getDbs', 'getTables', 'getSchema', 'excludeSysDbs']) |
1625 | | - elif choice == '3': |
1626 | | - map(lambda x: conf.__setitem__(x, True), ['getBanner', 'getCurrentUser', 'getCurrentDb', 'isDba', 'getUsers', 'getPasswordHashes', 'getPrivileges', 'getRoles', 'dumpAll']) |
1627 | | - else: |
1628 | | - map(lambda x: conf.__setitem__(x, True), ['getBanner', 'getCurrentUser', 'getCurrentDb', 'isDba']) |
| 1628 | + if choice == '2': |
| 1629 | + map(lambda x: conf.__setitem__(x, True), WIZARD.SMART) |
| 1630 | + elif choice == '3': |
| 1631 | + map(lambda x: conf.__setitem__(x, True), WIZARD.ALL) |
| 1632 | + else: |
| 1633 | + map(lambda x: conf.__setitem__(x, True), WIZARD.BASIC) |
1629 | 1634 |
|
1630 | 1635 | logger.debug("muting sqlmap.. it will do the magic for you") |
1631 | 1636 | conf.verbose = 0 |
|
0 commit comments