Woops, forgot to push the updated mixin.
git-svn-id: file:///home/svn/framework3/trunk@8560 4d416f70-5f16-0410-b530-b9f4589650daunstable
parent
1a53411282
commit
474228a132
|
@ -6,7 +6,7 @@
|
|||
# Dependencies:
|
||||
# - JDK6
|
||||
# - rjb (rjb.rubyforge.org)
|
||||
# - the $JAVA_HOME variable must point to the JDK
|
||||
# - the $JAVA_HOME variable must point to the JDK
|
||||
#
|
||||
# Nathan Keltner <natron@metasploit.com>
|
||||
#
|
||||
|
@ -58,6 +58,24 @@ module Exploit::Java
|
|||
return @jvmInit
|
||||
end
|
||||
|
||||
def save_to_file(classnames, codez, location)
|
||||
path = File.join( Msf::Config.install_root, "external", "source", location )
|
||||
|
||||
if not File.exists? path
|
||||
Dir.mkdir(path)
|
||||
end
|
||||
|
||||
i = 0
|
||||
classnames.each { |fil|
|
||||
file = File.join( path, fil + ".java")
|
||||
fp = File.open( file, "w" )
|
||||
print_status "Writing #{fil} to " + file
|
||||
fp.puts codez[i]
|
||||
i += 1
|
||||
fp.close
|
||||
}
|
||||
end
|
||||
|
||||
def compile(classnames, codez, compile_options=nil)
|
||||
if !@rjb_loaded or !@jvm_init
|
||||
raise RuntimeError, "Could not load rjb and/or the JVM: " + @java_error.to_s
|
||||
|
|
Loading…
Reference in New Issue