Skip to content

Commit a09a0a2

Browse files
committed
Fix finalize_admin
1 parent 0c556ff commit a09a0a2

File tree

1 file changed

+14
-12
lines changed

1 file changed

+14
-12
lines changed

modules/exploits/multi/http/wp_suretriggers_auth_bypass.rb

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -221,32 +221,34 @@ def finalize_admin
221221
)
222222
vprint_good("Credential for user '#{datastore['WP_USER']}' stored successfully.")
223223

224+
report_host(host: datastore['RHOST'])
225+
226+
service = report_service(
227+
host: datastore['RHOST'],
228+
port: datastore['RPORT'],
229+
proto: 'tcp',
230+
name: fullname,
231+
info: 'WordPress with vulnerable SureTriggers plugin allowing unauthenticated admin creation'
232+
)
233+
224234
loot_data = "Username: #{datastore['WP_USER']}, Password: #{datastore['WP_PASS']}\n"
225235
loot_path = store_loot(
226236
'wordpress.admin.created',
227237
'text/plain',
228238
datastore['RHOST'],
229239
loot_data,
230240
'wp_admin_credentials.txt',
231-
'WordPress Created Admin Credentials'
241+
'WordPress Created Admin Credentials',
242+
service
232243
)
233244
vprint_good("Loot saved to: #{loot_path}")
234245

235-
report_host(host: datastore['RHOST'])
236-
237-
report_service(
238-
host: datastore['RHOST'],
239-
port: datastore['RPORT'],
240-
proto: 'tcp',
241-
name: fullname,
242-
info: 'WordPress with vulnerable SureTriggers plugin allowing unauthenticated admin creation'
243-
)
244-
245246
report_vuln(
246247
host: datastore['RHOST'],
247248
port: datastore['RPORT'],
248249
proto: 'tcp',
249-
name: 'SureTriggers Auth Bypass',
250+
service: service,
251+
name: "SureTriggers Auth Bypass (#{action.name})",
250252
refs: references,
251253
info: 'Unauthenticated admin creation via SureTriggers plugin'
252254
)

0 commit comments

Comments
 (0)