Skip to content

Commit 1ac31a3

Browse files
committed
Merge branch 'bug/web-path-api-update' of github.com:tasos-r7/metasploit-framework into tasos-r7-bug/web-path-api-update
2 parents dea48b4 + 11c38d9 commit 1ac31a3

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

lib/msf/core/auxiliary/web/path.rb

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,6 @@ class Path < Fuzzable
2222
# URL String to which to submit the params
2323
attr_accessor :action
2424

25-
# Injected value as a String
26-
attr_accessor :input
27-
2825
# Mdm::WebForm model if available
2926
attr_accessor :model
3027

@@ -48,8 +45,15 @@ def initialize( opts = {} )
4845
def input=( value )
4946
@inputs = value.to_s.dup
5047
end
48+
def input
49+
@inputs
50+
end
5151
alias :param :input
5252

53+
def method
54+
'GET'
55+
end
56+
5357
#
5458
# Examples
5559
#
@@ -104,7 +108,7 @@ def empty?
104108
#
105109
def permutations
106110
return [] if empty?
107-
seeds_for( value ).map { |seed| permutation_for( nil, seed ) }.uniq
111+
fuzzer.seeds_for( altered_value ).map { |seed| permutation_for( nil, seed ) }.uniq
108112
end
109113

110114
def permutation_for( field_name, field_value )
@@ -118,7 +122,7 @@ def to_hash
118122
end
119123

120124
def self.from_model( form )
121-
e = new( :action => "#{form.path}?#{form.query}", :input => form.inputs[0][1] )
125+
e = new( :action => "#{form.path}?#{form.query}", :input => form.params[0][1] )
122126
e.model = form
123127
e
124128
end

0 commit comments

Comments
 (0)