bugfixing

This commit is contained in:
Christian Mehlmauer
2013-01-13 23:56:30 +01:00
parent 716e07803c
commit 255bbcdac2
2 changed files with 3 additions and 2 deletions

View File

@@ -24,6 +24,7 @@ CACHE_DIR = ROOT_DIR + "/cache"
WPSCAN_LIB_DIR = LIB_DIR + "/wpscan" WPSCAN_LIB_DIR = LIB_DIR + "/wpscan"
WPSTOOLS_LIB_DIR = LIB_DIR + "/wpstools" WPSTOOLS_LIB_DIR = LIB_DIR + "/wpstools"
UPDATER_LIB_DIR = LIB_DIR + "/updater" UPDATER_LIB_DIR = LIB_DIR + "/updater"
LOG_FILE = ROOT_DIR + "/log.txt"
WPSCAN_VERSION = "2.0" WPSCAN_VERSION = "2.0"
@@ -150,6 +151,6 @@ end
def puts(o = "") def puts(o = "")
# remove color for logging # remove color for logging
temp = o.gsub(/\[\d+m(?<text>.*)?\[0m/, '\k<text>') temp = o.gsub(/\[\d+m(?<text>.*)?\[0m/, '\k<text>')
File.open("log.txt", "a+") { |f| f.puts(temp) } File.open(LOG_FILE, "a+") { |f| f.puts(temp) }
super(o) super(o)
end end

View File

@@ -35,7 +35,7 @@ def output_vulnerabilities(vulns)
end end
# delete old logfile # delete old logfile
File.delete("log.txt") File.delete(LOG_FILE) if File.exist?(LOG_FILE)
banner() banner()