Class: WPScan::Finders::Passwords::XMLRPC
- Includes:
- Finder::BreadthFirstDictionaryAttack
- Defined in:
- app/finders/passwords/xml_rpc.rb
Overview
Password attack against the XMLRPC interface
Constant Summary
Constants inherited from Finder
Instance Attribute Summary
Attributes inherited from Finder
Instance Method Summary collapse
- #errored_response?(response) ⇒ Boolean
- #login_request(username, password) ⇒ Object
- #valid_credentials?(response) ⇒ Boolean
Methods included from Finder::BreadthFirstDictionaryAttack
Methods inherited from Finder
#aggressive, #browser, #create_progress_bar, #found_by, #hydra, #initialize, #passive, #titleize
Constructor Details
This class inherits a constructor from WPScan::Finders::Finder
Instance Method Details
#errored_response?(response) ⇒ Boolean
18 19 20 |
# File 'app/finders/passwords/xml_rpc.rb', line 18 def errored_response?(response) response.code != 200 && response.body !~ /Incorrect username or password/i end |
#login_request(username, password) ⇒ Object
10 11 12 |
# File 'app/finders/passwords/xml_rpc.rb', line 10 def login_request(username, password) target.method_call('wp.getUsersBlogs', [username, password], cache_ttl: 0) end |
#valid_credentials?(response) ⇒ Boolean
14 15 16 |
# File 'app/finders/passwords/xml_rpc.rb', line 14 def valid_credentials?(response) response.code == 200 && response.body.include?('blogName') end |