渗透测试中需要关注的本地凭据

发表于:2017-4-21 11:42

字体: | 上一篇 | 下一篇 | 我要投稿

 作者:re4lity    来源:51Testing软件测试网采编

  Windows
  Windows自动部署过程中的一些凭证(base64)存储位置
C:\unattend.xml
C:\Windows\Panther\Unattend.xml
C:\Windows\Panther\Unattend\Unattend.xml
C:\Windows\system32\sysprep.inf
C:\Windows\system32\sysprep\sysprep.xml
  使用Metasploit的 post/windows/gather/enum_unattend 模块也可以获取到
  IIS管理凭证的web.config文件常见路径:
  C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Config\web.config
  C:\inetpub\wwwroot\web.config
  文件内容一般如下:
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.web>
<authentication mode="Windows">
<forms>
<credentials passwordFormat="Clear">
<user name="Admin" password="Admin" />
</credentials>
</forms>
</authentication>
</system.web>
</configuration>
  包含密码的groups.xml文件和其他一些可能存储凭证的文件
C:\ProgramData\Microsoft\Group Policy\History\????\Machine\Preferences\Groups\Groups.xml
\\domain\SYSVOL\\Policies\????\MACHINE\Preferences\Groups\Groups.xml
Services\Services.xml
ScheduledTasks\ScheduledTasks.xml
Printers\Printers.xml
Drives\Drives.xml
DataSources\DataSources.xml
  命令查找
  使用命令查找包含密码的文件:
findstr /si password *.txt
findstr /si password *.xml
findstr /si password *.ini
  查找文件的位置:
C:\> dir /b /s unattend.xml
C:\> dir /b /s web.config
C:\> dir /b /s sysprep.inf
C:\> dir /b /s sysprep.xml
C:\> dir /b /s *pass*
C:\> dir /b /s vnc.ini
  第三方软件
  McAfee
  McAfee的加密凭证存储在sitelist.xml文件中:
  %AllUsersProfile%Application Data\McAfee\Common Framework\SiteList.xml
  VNC
  UltraVNC
  [ultravnc]
  passwd=5FAEBBD0EF0A2413
  RealVNC
  RealVNC的密码可以直接在注册表进行查询:
  reg query HKEY_LOCAL_MACHINE\SOFTWARE\RealVNC\WinVNC4 /v password
  Putty
  reg query" HKCU\Software\SimonTatham\PuTTY\Sessions"
  注册表
  Registry某些情况下可能会包含凭证
  reg query HKLM /f password /t REG_SZ /s
  reg query HKCU /f password /t REG_SZ /s
  Windows 自动登陆:
  reg query "HKLM\SOFTWARE\Microsoft\Windows NT\Currentversion\Winlogon"
  SNMP 相关参数:
  reg query "HKLM\SYSTEM\Current\ControlSet\Services\SNMP"
  PowerSploit相关的模块
  PowerSploit也可以用于发现存储的凭证,以下模块支持检查各种文件和注册表中的加密凭证和plain-text:
Get-UnattendedInstallFile
Get-Webconfig
Get-ApplicationHost
Get-SiteListPassword
Get-CachedGPPPassword
Get-RegistryAutoLogon
《2023软件测试行业现状调查报告》独家发布~

关注51Testing

联系我们

快捷面板 站点地图 联系我们 广告服务 关于我们 站长统计 发展历程

法律顾问:上海兰迪律师事务所 项棋律师
版权所有 上海博为峰软件技术股份有限公司 Copyright©51testing.com 2003-2024
投诉及意见反馈:webmaster@51testing.com; 业务联系:service@51testing.com 021-64471599-8017

沪ICP备05003035号

沪公网安备 31010102002173号