spring actuator未授权之heapdump自动化分析【JDumpSpider】

admin 2023年3月9日01:02:27评论199 views字数 1291阅读4分18秒阅读模式

目录概要

    前言
    工具介绍
        工具简介
        支持范围
        工具使用
    实战记录
    结语

前言

在日常的渗透测试工作中,经常遇到spring actuator未授权漏洞,而且在实际过程中也常常会下载到heapdump这个文件。了解过这个文件的人都知道,Heap Dump也叫堆转储文件,是一个Java进程在某个时间点上的内存快照。Heap Dump是有着多种类型的。不过总体上heap dump在触发快照的时候都保存了java对象和类的信息。通常在写heap dump文件前会触发一次FullGC,所以heap dump文件中保存的是FullGC后留下的对象信息。
    一般在渗透测试中我们会通过Eclipse MemoryAnalyzer工具对泄露的heapdump文件进行分析,查询加载到内存中的明文密码信息,比如redis密码,mysql数据库账号和密码。但是这样可能导致获取的敏感信息不全面,甚至无法获取到敏感信息,今天推荐一款自动化分析heapdumo的工具 - JDumpSpider。

工具介绍

工具简介
HeapDump敏感信息提取工具
项目地址:

https://github.com/whwlsfb/JDumpSpider

支持范围
该工具暂支持提取以下类型的敏感信息

数据源    SpringDataSourceProperties    WeblogicDataSourceConnectionPoolConfig    MongoClient    AliDruidDataSourceWrapper配置文件信息    MapPropertySource    OriginTrackedMapPropertySource    MutablePropertySource    ConsulPropertySource    OSS(模糊搜索)Redis配置    RedisStandaloneConfiguration    JedisClientShiroKey    CookieRememberMeManager


工具使用

本工具需要使用Oracle JDK 1.8版本(更高版本将导致异常)。

$ java -jar .targetJDumpSpider-1.0-SNAPSHOT-full.jarMissing required parameter: ‘’Usage: JDumpSpider [-hV]Extract sensitive information from heapdump file.Heap file path.-h, --help Show this help message and exit.-V, --version Print version information and exit.

实战记录

 java -jar JDumpSpider-1.0-SNAPSHOT-full.jar heapdump

spring actuator未授权之heapdump自动化分析【JDumpSpider】


结语

有的时候光有思路,没用趁手的“兵器”是不能把战果最大化的,如果你拿着一把好武器,而且具备很好的思维,那么战果一定不凡!欢迎各位关注我的公众号:小白学IT


原文始发于微信公众号(小白学IT):spring actuator未授权之heapdump自动化分析【JDumpSpider】

  • 左青龙
  • 微信扫一扫
  • weinxin
  • 右白虎
  • 微信扫一扫
  • weinxin
admin
  • 本文由 发表于 2023年3月9日01:02:27
  • 转载请保留本文链接(CN-SEC中文网:感谢原作者辛苦付出):
                   spring actuator未授权之heapdump自动化分析【JDumpSpider】http://cn-sec.com/archives/1238855.html

发表评论

匿名网友 填写信息