MCPcopy Index your code
hub / github.com/sqlmapproject/sqlmap / _getDatabaseDir

Method _getDatabaseDir

plugins/dbms/access/fingerprint.py:87–106  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

85 return None
86
87 def _getDatabaseDir(self):
88 retVal = None
89
90 infoMsg = "searching for database directory"
91 logger.info(infoMsg)
92
93 randStr = randomStr()
94 inject.checkBooleanExpression("EXISTS(SELECT * FROM %s.%s WHERE [RANDNUM]=[RANDNUM])" % (randStr, randStr))
95
96 if wasLastResponseDBMSError():
97 threadData = getCurrentThreadData()
98 match = re.search(r"Could not find file\s+'([^']+?)'", threadData.lastErrorPage[1])
99
100 if match:
101 retVal = match.group(1).rstrip("%s.mdb" % randStr)
102
103 if retVal.endswith('\\'):
104 retVal = retVal[:-1]
105
106 return retVal
107
108 def getFingerprint(self):
109 value = ""

Callers 1

getFingerprintMethod · 0.95

Calls 5

randomStrFunction · 0.90
wasLastResponseDBMSErrorFunction · 0.90
getCurrentThreadDataFunction · 0.85
infoMethod · 0.80
searchMethod · 0.45

Tested by

no test coverage detected