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

Method evalCmd

lib/takeover/abstraction.py:65–84  ·  view source on GitHub ↗
(self, cmd, first=None, last=None)

Source from the content-addressed store, hash-verified

63 raise SqlmapUnsupportedFeatureException(errMsg)
64
65 def evalCmd(self, cmd, first=None, last=None):
66 retVal = None
67
68 if Backend.isDbms(DBMS.PGSQL) and self.checkCopyExec():
69 retVal = self.copyExecCmd(cmd)
70
71 elif self.webBackdoorUrl and (not isStackingAvailable() or kb.udfFail):
72 retVal = self.webBackdoorRunCmd(cmd)
73
74 elif Backend.getIdentifiedDbms() in (DBMS.MYSQL, DBMS.PGSQL):
75 retVal = self.udfEvalCmd(cmd, first, last)
76
77 elif Backend.isDbms(DBMS.MSSQL):
78 retVal = self.xpCmdshellEvalCmd(cmd, first, last)
79
80 else:
81 errMsg = "Feature not yet implemented for the back-end DBMS"
82 raise SqlmapUnsupportedFeatureException(errMsg)
83
84 return safechardecode(retVal)
85
86 def runCmd(self, cmd):
87 choice = None

Callers 2

runCmdMethod · 0.95
readRegKeyMethod · 0.80

Calls 10

isStackingAvailableFunction · 0.90
safechardecodeFunction · 0.90
isDbmsMethod · 0.80
checkCopyExecMethod · 0.80
copyExecCmdMethod · 0.80
webBackdoorRunCmdMethod · 0.80
getIdentifiedDbmsMethod · 0.80
udfEvalCmdMethod · 0.80
xpCmdshellEvalCmdMethod · 0.80

Tested by

no test coverage detected