mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-05-29 02:03:08 +03:00
added CPU throttling for lowering sqlmap's CPU intensivity
This commit is contained in:
parent
d96723a135
commit
5396f13bab
|
@ -1109,4 +1109,4 @@ def parseXmlFile(xmlFile, handler):
|
||||||
xfile.close()
|
xfile.close()
|
||||||
|
|
||||||
def calculateDeltaSeconds(start, epsilon=0.05):
|
def calculateDeltaSeconds(start, epsilon=0.05):
|
||||||
return int(time.time() - start + epsilon)
|
return int(time.time() - start + epsilon)
|
||||||
|
|
|
@ -878,32 +878,33 @@ def __setConfAttributes():
|
||||||
debugMsg = "initializing the configuration"
|
debugMsg = "initializing the configuration"
|
||||||
logger.debug(debugMsg)
|
logger.debug(debugMsg)
|
||||||
|
|
||||||
conf.cj = None
|
conf.cpuThrottleDelay = 0.001
|
||||||
conf.dbmsConnector = None
|
conf.cj = None
|
||||||
conf.dbmsHandler = None
|
conf.dbmsConnector = None
|
||||||
conf.dumpPath = None
|
conf.dbmsHandler = None
|
||||||
conf.httpHeaders = []
|
conf.dumpPath = None
|
||||||
conf.hostname = None
|
conf.httpHeaders = []
|
||||||
conf.loggedToOut = None
|
conf.hostname = None
|
||||||
conf.matchRatio = None
|
conf.loggedToOut = None
|
||||||
conf.md5hash = None
|
conf.matchRatio = None
|
||||||
conf.multipleTargets = False
|
conf.md5hash = None
|
||||||
conf.outputPath = None
|
conf.multipleTargets = False
|
||||||
conf.paramDict = {}
|
conf.outputPath = None
|
||||||
conf.parameters = {}
|
conf.paramDict = {}
|
||||||
conf.path = None
|
conf.parameters = {}
|
||||||
conf.port = None
|
conf.path = None
|
||||||
conf.redirectHandled = False
|
conf.port = None
|
||||||
conf.retriesCount = 0
|
conf.redirectHandled = False
|
||||||
conf.scheme = None
|
conf.retriesCount = 0
|
||||||
#conf.seqMatcher = difflib.SequenceMatcher(lambda x: x in " \t")
|
conf.scheme = None
|
||||||
conf.seqMatcher = difflib.SequenceMatcher(None)
|
#conf.seqMatcher = difflib.SequenceMatcher(lambda x: x in " \t")
|
||||||
conf.seqLock = None
|
conf.seqMatcher = difflib.SequenceMatcher(None)
|
||||||
conf.sessionFP = None
|
conf.seqLock = None
|
||||||
conf.start = True
|
conf.sessionFP = None
|
||||||
conf.threadContinue = True
|
conf.start = True
|
||||||
conf.threadException = False
|
conf.threadContinue = True
|
||||||
conf.wFileType = None
|
conf.threadException = False
|
||||||
|
conf.wFileType = None
|
||||||
|
|
||||||
width = getConsoleWidth()
|
width = getConsoleWidth()
|
||||||
|
|
||||||
|
|
|
@ -262,6 +262,8 @@ class Connect:
|
||||||
|
|
||||||
logger.log(8, responseMsg)
|
logger.log(8, responseMsg)
|
||||||
|
|
||||||
|
time.sleep(conf.cpuThrottleDelay)
|
||||||
|
|
||||||
return page, responseHeaders
|
return page, responseHeaders
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
|
|
Loading…
Reference in New Issue
Block a user