Skip to content

Commit 0b76879

Browse files
Chocapikkjvoisin
andauthored
Update modules/exploits/multi/http/spip_bigup_unauth_rce.rb
Co-authored-by: Julien Voisin <[email protected]>
1 parent 484cdc9 commit 0b76879

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

modules/exploits/multi/http/spip_bigup_unauth_rce.rb

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -117,12 +117,11 @@ def check
117117
# It allows the user to specify a URL via the FORM_PAGE option (e.g., spip.php?article1).
118118
# We need to check multiple pages because the configuration of SPIP can vary.
119119
def get_form_data
120-
pages = []
120+
pages = %w[login spip_pass contact]
121121

122-
form_page = datastore['FORM_PAGE']
123-
pages << form_page if form_page&.downcase != 'auto'
124-
125-
pages.concat(%w[login spip_pass contact]) if pages.empty?
122+
if datastore['FORM_PAGE']&.downcase != 'auto'
123+
pages = [datastore['FORM_PAGE']]
124+
end
126125

127126
pages.each do |page|
128127
url = normalize_uri(target_uri.path, page.start_with?('/') ? page : "spip.php?page=#{page}")

0 commit comments

Comments
 (0)