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

Method checkDbms

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

Source from the content-addressed store, hash-verified

148 return value
149
150 def checkDbms(self):
151 if not conf.extensiveFp and Backend.isDbmsWithin(ACCESS_ALIASES):
152 setDbms(DBMS.ACCESS)
153
154 return True
155
156 infoMsg = "testing %s" % DBMS.ACCESS
157 logger.info(infoMsg)
158
159 result = inject.checkBooleanExpression("VAL(CVAR(1))=1")
160
161 if result:
162 infoMsg = "confirming %s" % DBMS.ACCESS
163 logger.info(infoMsg)
164
165 result = inject.checkBooleanExpression("IIF(ATN(2) IS NOT NULL,1,0) BETWEEN 2 AND 0")
166
167 if not result:
168 warnMsg = "the back-end DBMS is not %s" % DBMS.ACCESS
169 logger.warning(warnMsg)
170 return False
171
172 setDbms(DBMS.ACCESS)
173
174 if not conf.extensiveFp:
175 return True
176
177 infoMsg = "actively fingerprinting %s" % DBMS.ACCESS
178 logger.info(infoMsg)
179
180 version = self._sysTablesCheck()
181
182 if version is not None:
183 Backend.setVersion(version)
184
185 return True
186 else:
187 warnMsg = "the back-end DBMS is not %s" % DBMS.ACCESS
188 logger.warning(warnMsg)
189
190 return False
191
192 def forceDbmsEnum(self):
193 conf.db = ("%s%s" % (DBMS.ACCESS, METADB_SUFFIX)).replace(' ', '_')

Callers

nothing calls this directly

Calls 5

_sysTablesCheckMethod · 0.95
setDbmsFunction · 0.90
isDbmsWithinMethod · 0.80
infoMethod · 0.80
setVersionMethod · 0.80

Tested by

no test coverage detected