Skip to content

Commit

Permalink
Added the --print-http option to CLI::WebVulnCommand (closes #51).
Browse files Browse the repository at this point in the history
  • Loading branch information
postmodern committed Sep 30, 2023
1 parent 4b02eac commit 3d59ef7
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lib/ronin/vulns/cli/web_vuln_command.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ class WebVulnCommand < Command

option :print_curl, desc: 'Also prints an example curl command for each vulnerability'

option :print_http, desc: 'Also prints an example HTTP request for each vulnerability'

option :header, short: '-H',
value: {
type: /[A-Za-z0-9-]+:\s*\w+/,
Expand Down Expand Up @@ -287,6 +289,12 @@ def log_vuln(vuln)
puts
puts " #{vuln.to_curl}"
puts
elsif options[:print_http]
puts
vuln.to_http.each_line do |line|
puts " #{line}"
end
puts
end
end

Expand Down

0 comments on commit 3d59ef7

Please sign in to comment.