Skip to content

Commit ad864cc

Browse files
committed
Delete unnecessary code
1 parent 9245bed commit ad864cc

File tree

1 file changed

+0
-13
lines changed

1 file changed

+0
-13
lines changed

modules/exploits/multi/http/apache_mod_cgi_bash_env_exec.rb

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -94,10 +94,6 @@ def exploit
9494
def execute_command(cmd, opts)
9595
cmd.gsub!('chmod', "#{datastore['RPATH']}/chmod")
9696

97-
if cmd =~ />>/ && first_redirection?
98-
cmd.sub!('>>', '>')
99-
end
100-
10197
req(cmd)
10298
end
10399

@@ -113,13 +109,4 @@ def req(cmd)
113109
def marker
114110
@marker ||= rand_text_alphanumeric(rand(42) + 1)
115111
end
116-
117-
def first_redirection?
118-
unless @first_redirection && @first_redirection == false
119-
@first_redirection = false
120-
return true
121-
end
122-
123-
false
124-
end
125112
end

0 commit comments

Comments
 (0)