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

Skip to content

Commit 017ea9e

Browse files
committed
update
1 parent 73f33c1 commit 017ea9e

7 files changed

Lines changed: 11 additions & 54 deletions

File tree

lib/controller/checks.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -387,7 +387,7 @@ def checkSqlInjection(place, parameter, value):
387387
elif detailKey == "os" and injection.os is None:
388388
injection.os = detailValue
389389

390-
if conf.beep or conf.scriptKiddie:
390+
if conf.beep or conf.realTest:
391391
beep()
392392

393393
# There is no need to perform this test for other
@@ -589,7 +589,7 @@ def checkStability():
589589
logger.warn(warnMsg)
590590

591591
message = "how do you want to proceed? [C(ontinue)/s(tring)/r(egex)/q(uit)] "
592-
if not conf.scriptKiddie:
592+
if not conf.realTest:
593593
test = readInput(message, default="C")
594594
else:
595595
test = None

lib/controller/controller.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ def start():
227227
elif test[0] in ("q", "Q"):
228228
break
229229

230-
elif conf.scriptKiddie:
230+
elif conf.realTest:
231231
logger.info(message)
232232
else:
233233
message += "\ndo you want to test this url? [Y/n/q]"
@@ -343,7 +343,7 @@ def start():
343343

344344
if testSqlInj:
345345
check = heuristicCheckSqlInjection(place, parameter, value)
346-
if not check and conf.scriptKiddie:
346+
if not check and conf.realTest:
347347
continue
348348

349349
logMsg = "testing sql injection on %s " % place
@@ -376,7 +376,7 @@ def start():
376376
logger.warn(warnMsg)
377377

378378
if len(kb.injections) == 0 or (len(kb.injections) == 1 and kb.injections[0].place is None):
379-
if not conf.scriptKiddie:
379+
if not conf.realTest:
380380
errMsg = "all parameters are not injectable, try "
381381
errMsg += "a higher --level"
382382
raise sqlmapNotVulnerableException, errMsg

lib/core/common.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -676,7 +676,6 @@ def setPaths():
676676
paths.COMMON_COLUMNS = os.path.join(paths.SQLMAP_TXT_PATH, "common-columns.txt")
677677
paths.COMMON_TABLES = os.path.join(paths.SQLMAP_TXT_PATH, "common-tables.txt")
678678
paths.COMMON_OUTPUTS = os.path.join(paths.SQLMAP_TXT_PATH, 'common-outputs.txt')
679-
paths.DORKS = os.path.join(paths.SQLMAP_TXT_PATH, "dorks.txt")
680679
paths.SQL_KEYWORDS = os.path.join(paths.SQLMAP_TXT_PATH, "keywords.txt")
681680
paths.ORACLE_DEFAULT_PASSWD = os.path.join(paths.SQLMAP_TXT_PATH, "oracle-default-passwords.txt")
682681
paths.WORDLIST = os.path.join(paths.SQLMAP_TXT_PATH, "wordlist.txt")

lib/core/option.py

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -303,20 +303,6 @@ def __setRequestFromFile():
303303

304304
__feedTargetsDict(conf.requestFile, addedTargetUrls)
305305

306-
def __setScriptKiddie():
307-
"""
308-
This function sets a random google dork
309-
"""
310-
if not conf.scriptKiddie or conf.url or conf.list or conf.requestFile or conf.googleDork:
311-
return
312-
313-
dorks = getFileItems(paths.DORKS)
314-
conf.googleDork = dorks[randomRange(0, len(dorks) - 1)]
315-
conf.multipleTargets = True
316-
317-
logMsg = "setting random google dork to: '%s'" % conf.googleDork
318-
logger.info(logMsg)
319-
320306
def __setGoogleDorking():
321307
"""
322308
This function checks if the way to request testable hosts is through
@@ -1393,7 +1379,7 @@ def init(inputOptions=advancedDict()):
13931379
parseTargetUrl()
13941380
parseTargetDirect()
13951381

1396-
if conf.url or conf.list or conf.requestFile or conf.googleDork or conf.liveTest or conf.scriptKiddie:
1382+
if conf.url or conf.list or conf.requestFile or conf.googleDork or conf.liveTest:
13971383
__setHTTPTimeout()
13981384
__setHTTPExtraHeaders()
13991385
__setHTTPCookies()
@@ -1404,7 +1390,6 @@ def init(inputOptions=advancedDict()):
14041390
__setHTTPProxy()
14051391
__setSafeUrl()
14061392
__setUnion()
1407-
__setScriptKiddie()
14081393
__setGoogleDorking()
14091394
__urllib2Opener()
14101395
__findPageForms()

lib/parse/cmdline.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -529,10 +529,10 @@ def cmdLineParser():
529529
parser.add_option("--live-test", dest="liveTest", action="store_true",
530530
default=False, help=SUPPRESS_HELP)
531531

532-
parser.add_option("--technique", dest="technique", type="int",
532+
parser.add_option("--real-test", dest="realTest", action="store_true",
533533
default=False, help=SUPPRESS_HELP)
534534

535-
parser.add_option("--script-kiddie", dest="scriptKiddie", action="store_true",
535+
parser.add_option("--technique", dest="technique", type="int",
536536
default=False, help=SUPPRESS_HELP)
537537

538538
parser.add_option_group(target)
@@ -561,7 +561,7 @@ def cmdLineParser():
561561

562562
if not args.direct and not args.url and not args.list and not args.googleDork and not args.configFile\
563563
and not args.requestFile and not args.updateAll and not args.smokeTest and not args.liveTest\
564-
and not args.scriptKiddie:
564+
and not args.realTest:
565565
errMsg = "missing a mandatory parameter ('-d', '-u', '-l', '-r', '-g', '-c' or '--update'), "
566566
errMsg += "-h for help"
567567
parser.error(errMsg)

lib/request/connect.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ def getPage(**kwargs):
195195
if hasattr(conn, "setcookie"):
196196
kb.redirectSetCookie = conn.setcookie
197197

198-
if hasattr(conn, "redurl") and hasattr(conn, "redcode") and not conf.redirectHandled and not conf.scriptKiddie:
198+
if hasattr(conn, "redurl") and hasattr(conn, "redcode") and not conf.redirectHandled and not conf.realTest:
199199
msg = "sqlmap got a %d redirect to " % conn.redcode
200200
msg += "%s - What target address do you " % conn.redurl
201201
msg += "want to use from now on? %s " % conf.url
@@ -294,7 +294,7 @@ def getPage(**kwargs):
294294

295295
if silent or (ignoreTimeout and "timeout" in tbMsg):
296296
return None, None
297-
elif kb.retriesCount < conf.retries and not kb.threadException and not conf.scriptKiddie:
297+
elif kb.retriesCount < conf.retries and not kb.threadException and not conf.realTest:
298298
kb.retriesCount += 1
299299

300300
warnMsg += ", sqlmap is going to retry the request"

txt/dorks.txt

Lines changed: 0 additions & 27 deletions
This file was deleted.

0 commit comments

Comments
 (0)