mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-25 02:53:46 +03:00
avoid tracebacks because the parameter does not exist
This commit is contained in:
parent
c9c520a325
commit
d42d28392a
|
@ -65,7 +65,7 @@ class Registry:
|
|||
logger.debug("creating batch file '%s'" % self._batPathRemote)
|
||||
|
||||
self._createLocalBatchFile()
|
||||
self.writeFile(self._batPathLocal, self._batPathRemote, "text")
|
||||
self.writeFile(self._batPathLocal, self._batPathRemote, "text", forceCheck=True)
|
||||
|
||||
os.unlink(self._batPathLocal)
|
||||
|
||||
|
|
|
@ -16,6 +16,6 @@ class Filesystem(GenericFilesystem):
|
|||
errMsg = "on Microsoft Access it is not possible to read files"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
||||
def writeFile(self, wFile, dFile, fileType=None):
|
||||
def writeFile(self, wFile, dFile, fileType=None, forceCheck=False):
|
||||
errMsg = "on Microsoft Access it is not possible to write files"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
|
|
@ -16,6 +16,6 @@ class Filesystem(GenericFilesystem):
|
|||
errMsg = "on Firebird it is not possible to read files"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
||||
def writeFile(self, wFile, dFile, fileType=None):
|
||||
def writeFile(self, wFile, dFile, fileType=None, forceCheck=False):
|
||||
errMsg = "on Firebird it is not possible to write files"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
|
|
@ -16,6 +16,6 @@ class Filesystem(GenericFilesystem):
|
|||
errMsg = "on SAP MaxDB reading of files is not supported"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
||||
def writeFile(self, wFile, dFile, fileType=None):
|
||||
def writeFile(self, wFile, dFile, fileType=None, forceCheck=False):
|
||||
errMsg = "on SAP MaxDB writing of files is not supported"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
|
|
@ -158,7 +158,7 @@ class Filesystem(GenericFilesystem):
|
|||
|
||||
return result
|
||||
|
||||
def unionWriteFile(self, wFile, dFile, fileType):
|
||||
def unionWriteFile(self, wFile, dFile, fileType, forceCheck=False):
|
||||
errMsg = "Microsoft SQL Server does not support file upload with "
|
||||
errMsg += "UNION query SQL injection technique"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
@ -340,8 +340,7 @@ class Filesystem(GenericFilesystem):
|
|||
wFileContent = f.read()
|
||||
|
||||
self._stackedWriteFileVbs(tmpPath, wFileContent, dFile, fileType)
|
||||
|
||||
written = self.askCheckWrittenFile(wFile, dFile)
|
||||
written = self.askCheckWrittenFile(wFile, dFile, forceCheck)
|
||||
|
||||
if written is False:
|
||||
message = "do you want to try to upload the file with "
|
||||
|
|
|
@ -17,7 +17,7 @@ class Filesystem(GenericFilesystem):
|
|||
errMsg += "Oracle"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
||||
def writeFile(self, wFile, dFile, fileType=None):
|
||||
def writeFile(self, wFile, dFile, fileType=None, forceCheck=False):
|
||||
errMsg = "File system write access not yet implemented for "
|
||||
errMsg += "Oracle"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
|
|
@ -28,7 +28,7 @@ class Filesystem(GenericFilesystem):
|
|||
|
||||
return self.udfEvalCmd(cmd=rFile, udfName="sys_fileread")
|
||||
|
||||
def unionWriteFile(self, wFile, dFile, fileType):
|
||||
def unionWriteFile(self, wFile, dFile, fileType, forceCheck=False):
|
||||
errMsg = "PostgreSQL does not support file upload with UNION "
|
||||
errMsg += "query SQL injection technique"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
|
|
@ -16,6 +16,6 @@ class Filesystem(GenericFilesystem):
|
|||
errMsg = "on SQLite it is not possible to read files"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
||||
def writeFile(self, wFile, dFile, fileType=None):
|
||||
def writeFile(self, wFile, dFile, fileType=None, forceCheck=False):
|
||||
errMsg = "on SQLite it is not possible to write files"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
|
|
@ -16,6 +16,6 @@ class Filesystem(GenericFilesystem):
|
|||
errMsg = "on Sybase it is not possible to read files"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
||||
def writeFile(self, wFile, dFile, fileType=None):
|
||||
def writeFile(self, wFile, dFile, fileType=None, forceCheck=False):
|
||||
errMsg = "on Sybase it is not possible to write files"
|
||||
raise SqlmapUnsupportedFeatureException(errMsg)
|
||||
|
|
|
@ -171,12 +171,12 @@ class Filesystem:
|
|||
errMsg += "into the specific DBMS plugin"
|
||||
raise SqlmapUndefinedMethod(errMsg)
|
||||
|
||||
def unionWriteFile(self, localFile, remoteFile, fileType):
|
||||
def unionWriteFile(self, localFile, remoteFile, fileType, forceCheck=False):
|
||||
errMsg = "'unionWriteFile' method must be defined "
|
||||
errMsg += "into the specific DBMS plugin"
|
||||
raise SqlmapUndefinedMethod(errMsg)
|
||||
|
||||
def stackedWriteFile(self, localFile, remoteFile, fileType):
|
||||
def stackedWriteFile(self, localFile, remoteFile, fileType, forceCheck=False):
|
||||
errMsg = "'stackedWriteFile' method must be defined "
|
||||
errMsg += "into the specific DBMS plugin"
|
||||
raise SqlmapUndefinedMethod(errMsg)
|
||||
|
|
Loading…
Reference in New Issue
Block a user