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

Skip to content

Commit 64b9f94

Browse files
committed
Renamed --common-prediction switch to --predict-output
1 parent f54c134 commit 64b9f94

4 files changed

Lines changed: 6 additions & 6 deletions

File tree

lib/core/option.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -979,7 +979,7 @@ def __cleanupOptions():
979979
conf.multipleTargets = True
980980

981981
if conf.optimize:
982-
conf.commonPrediction = conf.keepAlive = True
982+
conf.predictOutput = conf.keepAlive = True
983983
conf.nullConnection = not conf.textOnly
984984

985985
def __setConfAttributes():

lib/core/optiondict.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747

4848
"Optimization": {
4949
"optimize": "boolean",
50-
"commonPrediction": "boolean",
50+
"predictOutput": "boolean",
5151
"keepAlive": "boolean",
5252
"nullConnection": "boolean",
5353
"threads": "integer"

lib/parse/cmdline.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,8 +137,8 @@ def cmdLineParser():
137137
action="store_true", default=False,
138138
help="Use all optimization options")
139139

140-
optimization.add_option("--common-prediction", dest="commonPrediction", action="store_true",
141-
default=False, help="Use 'Good samaritan' feature")
140+
optimization.add_option("--predict-output", dest="predictOutput", action="store_true",
141+
default=False, help="Predict common queries output")
142142

143143
optimization.add_option("--keep-alive", dest="keepAlive", action="store_true",
144144
default=False, help="Use persistent HTTP(s) connections")

lib/techniques/blind/inference.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ def bisection(payload, expression, length=None, charsetType=None, firstChar=None
4545

4646
# Set kb.partRun in case "common prediction" feature (a.k.a. "good
4747
# samaritan") is used
48-
kb.partRun = getPartRun() if conf.commonPrediction else None
48+
kb.partRun = getPartRun() if conf.predictOutput else None
4949

5050
if "LENGTH(" in expression or "LEN(" in expression:
5151
firstChar = 0
@@ -427,7 +427,7 @@ def downloadThread():
427427
# Common prediction feature (a.k.a. "good samaritan")
428428
# NOTE: to be used only when multi-threading is not set for
429429
# the moment
430-
if conf.commonPrediction and len(finalValue) > 0 and kb.partRun is not None:
430+
if conf.predictOutput and len(finalValue) > 0 and kb.partRun is not None:
431431
val = None
432432
commonValue, commonPattern, commonCharset, otherCharset = goGoodSamaritan(finalValue, asciiTbl)
433433

0 commit comments

Comments
 (0)