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

Method getUsers

plugins/dbms/sybase/enumeration.py:36–56  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

34
35class Enumeration(GenericEnumeration):
36 def getUsers(self):
37 infoMsg = "fetching database users"
38 logger.info(infoMsg)
39
40 rootQuery = queries[DBMS.SYBASE].users
41
42 query = rootQuery.inband.query
43
44 if any(isTechniqueAvailable(_) for _ in (PAYLOAD.TECHNIQUE.UNION, PAYLOAD.TECHNIQUE.ERROR, PAYLOAD.TECHNIQUE.QUERY)) or conf.direct:
45 blinds = (False, True)
46 else:
47 blinds = (True,)
48
49 for blind in blinds:
50 retVal = pivotDumpTable("(%s) AS %s" % (query, kb.aliasName), ['%s.name' % kb.aliasName], blind=blind, alias=kb.aliasName)
51
52 if retVal:
53 kb.data.cachedUsers = list(retVal[0].values())[0]
54 break
55
56 return kb.data.cachedUsers
57
58 def getPrivileges(self, *args, **kwargs):
59 warnMsg = "on Sybase it is not possible to fetch "

Callers 1

getPrivilegesMethod · 0.95

Calls 4

isTechniqueAvailableFunction · 0.90
pivotDumpTableFunction · 0.90
infoMethod · 0.80
valuesMethod · 0.80

Tested by

no test coverage detected