mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-06-16 02:53:21 +03:00
minor update
This commit is contained in:
parent
b18397fbc7
commit
818c9787b2
|
@ -213,12 +213,21 @@ class Web:
|
||||||
localPath = directory
|
localPath = directory
|
||||||
uriPath = directory[2:] if isWindowsDriveLetterPath(directory) else directory
|
uriPath = directory[2:] if isWindowsDriveLetterPath(directory) else directory
|
||||||
docRoot = docRoot[2:] if isWindowsDriveLetterPath(docRoot) else docRoot
|
docRoot = docRoot[2:] if isWindowsDriveLetterPath(docRoot) else docRoot
|
||||||
uriPath = uriPath.replace(docRoot, "/")
|
if docRoot in uriPath:
|
||||||
uriPath = "/%s" % normalizePath(uriPath)
|
uriPath = uriPath.replace(docRoot, "/")
|
||||||
uriPath = uriPath.replace("//", "/")
|
uriPath = "/%s" % normalizePath(uriPath)
|
||||||
|
else:
|
||||||
|
webDir = extractRegexResult(r"//[^/]+?/(?P<result>.*)/.", conf.url)
|
||||||
|
if webDir:
|
||||||
|
uriPath = "/%s" % webDir
|
||||||
|
else:
|
||||||
|
continue
|
||||||
|
|
||||||
|
uriPath = uriPath.replace("//", "/").rstrip('/')
|
||||||
localPath = localPath.rstrip('/')
|
localPath = localPath.rstrip('/')
|
||||||
uriPath = uriPath.rstrip('/')
|
|
||||||
|
if not uriPath:
|
||||||
|
uriPath = '/'
|
||||||
|
|
||||||
# Upload the file stager
|
# Upload the file stager
|
||||||
self.__webFileInject(stagerContent, stagerName, localPath)
|
self.__webFileInject(stagerContent, stagerName, localPath)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user