mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-12-08 05:31:32 +00:00
Another update for an Issue #28
This commit is contained in:
@@ -591,26 +591,18 @@ def __setMetasploit():
|
||||
if not conf.msfPath:
|
||||
def _(key, value):
|
||||
retVal = None
|
||||
|
||||
try:
|
||||
from _winreg import ConnectRegistry, OpenKey, QueryValueEx, HKEY_LOCAL_MACHINE
|
||||
_ = ConnectRegistry(None, HKEY_LOCAL_MACHINE)
|
||||
_ = OpenKey(_, key)
|
||||
retval = QueryValueEx(_, value)[0]
|
||||
except:
|
||||
pass
|
||||
|
||||
retVal = QueryValueEx(_, value)[0]
|
||||
except Exception, ex:
|
||||
print ex
|
||||
return retVal
|
||||
|
||||
conf.msfPath = _(r"SOFTWARE\Rapid7\Metasploit", "Location")
|
||||
|
||||
warnMsg = "some sqlmap takeover functionalities are not yet "
|
||||
warnMsg += "supported on Windows. Please use Linux in a virtual "
|
||||
warnMsg += "machine for out-of-band features."
|
||||
|
||||
logger.critical(warnMsg)
|
||||
|
||||
raise sqlmapSilentQuitException
|
||||
if conf.msfPath:
|
||||
conf.msfPath = os.path.join(conf.msfPath, "msf3")
|
||||
|
||||
if conf.osSmb:
|
||||
isAdmin = runningAsAdmin()
|
||||
|
||||
Reference in New Issue
Block a user