Skip to content

Commit 1c94b2c

Browse files
authored
Merge pull request rapid7#20181 from bwatters-r7/fix/wordpress_login
Change check for redirect in wordpress_login to be less specific
2 parents ba25dd4 + 13d18f2 commit 1c94b2c

File tree

1 file changed

+1
-1
lines changed
  • lib/msf/core/exploit/remote/http/wordpress

1 file changed

+1
-1
lines changed

lib/msf/core/exploit/remote/http/wordpress/login.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def wordpress_login(user, pass, timeout = 20)
1414
'uri' => wordpress_url_login,
1515
'vars_post' => wordpress_helper_login_post_data(user, pass, redirect)
1616
}, timeout)
17-
if res && res.redirect? && res.redirection && res.redirection.to_s == redirect
17+
if res && res.redirect? && res.redirection&.path.end_with?(redirect)
1818
cookies = res.get_cookies
1919
# Check if a valid wordpress cookie is returned
2020
return cookies if

0 commit comments

Comments
 (0)