Skip to content

Commit

Permalink
Do not cache login requests - Fixes #1395
Browse files Browse the repository at this point in the history
  • Loading branch information
erwanlr committed Sep 16, 2019
1 parent b77e611 commit ab950d6
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/finders/passwords/xml_rpc.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ class XMLRPC < CMSScanner::Finders::Finder
include CMSScanner::Finders::Finder::BreadthFirstDictionaryAttack

def login_request(username, password)
target.method_call('wp.getUsersBlogs', [username, password])
target.method_call('wp.getUsersBlogs', [username, password], cache_ttl: 0)
end

def valid_credentials?(response)
Expand Down
2 changes: 1 addition & 1 deletion app/finders/passwords/xml_rpc_multicall.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ def do_multi_call(users, passwords)
end
end

target.multi_call(methods).run
target.multi_call(methods, cache_ttl: 0).run
end

# @param [ Array<Model::User> ] users
Expand Down
1 change: 1 addition & 0 deletions lib/wpscan/target/platform/wordpress.rb
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ def login_request(username, password)
Browser.instance.forge_request(
login_url,
method: :post,
cache_ttl: 0,
body: { log: username, pwd: password }
)
end
Expand Down

0 comments on commit ab950d6

Please sign in to comment.