Skip to content

Commit

Permalink
peer review
Browse files Browse the repository at this point in the history
  • Loading branch information
h00die committed Nov 29, 2024
1 parent 4ebc6f1 commit d13bccc
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ Default parking lot is called "Default lot" in the website interface, however it
1. Install the application
1. Start msfconsole
1. Do: `use exploit/linux/misc/asterisk_ami_originate_auth_rce `
1. Do: `use exploit/linux/misc/asterisk_ami_originate_auth_rce`
1. Do: `set rhosts <rhost>`
1. Do: `set lhost <lhost>`
1. Do: `set username <username>`
Expand Down
7 changes: 2 additions & 5 deletions lib/msf/core/exploit/remote/asterisk.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,8 @@ def send_command(cmd = '')
res
rescue Timeout::Error
print_error "Timeout (#{timeout} seconds)"
rescue StandardError
# unsure why but getting no implicit conversion of nil into String with the following code
# this can be tested with successful exploitation of asterisk_ami_originate_auth_rce module
# print_error e.message
print_error('Unknown exception')
rescue StandardError => e
print_error e.message
end

#
Expand Down
11 changes: 0 additions & 11 deletions modules/exploits/linux/misc/asterisk_ami_originate_auth_rce.rb
Original file line number Diff line number Diff line change
Expand Up @@ -201,15 +201,4 @@ def on_new_session(client)
super
print_good("!!!Don't forget to clean evidence from #{datastore['CONF']}!!!")
end

private

def username
datastore['USERNAME']
end

def password
datastore['PASSWORD']
end

end

0 comments on commit d13bccc

Please sign in to comment.