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

Method likeOrExact

plugins/generic/misc.py:188–204  ·  view source on GitHub ↗
(self, what)

Source from the content-addressed store, hash-verified

186 logger.warning(warnMsg)
187
188 def likeOrExact(self, what):
189 message = "do you want sqlmap to consider provided %s(s):\n" % what
190 message += "[1] as LIKE %s names (default)\n" % what
191 message += "[2] as exact %s names" % what
192
193 choice = readInput(message, default='1')
194
195 if not choice or choice == '1':
196 choice = '1'
197 condParam = " LIKE '%%%s%%'"
198 elif choice == '2':
199 condParam = "='%s'"
200 else:
201 errMsg = "invalid value"
202 raise SqlmapNoneDataException(errMsg)
203
204 return choice, condParam

Callers 5

searchDbMethod · 0.80
searchTableMethod · 0.80
searchColumnMethod · 0.80
searchTableMethod · 0.80
searchColumnMethod · 0.80

Calls 2

readInputFunction · 0.90

Tested by

no test coverage detected