Skip to content

This is a simple lldb plugin designed to inspect heap information in libmalloc on macOS.

Notifications You must be signed in to change notification settings

DanisJiang/mHeap

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

mHeap

This is a simple lldb plugin designed to inspect heap information in libmalloc on macOS. It is still under development...

As there has been no tool available on macOS to view global heap information (tools like malloc_history only show the history of individual chunk malloc and free operations), mHeap was developed. Understanding the overall heap status is crucial, especially when pwning applications on macOS.

(Written in 2022, have tested on macOS 13)

Install

pip install libnum

Add the following code to .lldbinit:

command script import ~/mHeap/mheap.py

Commands

  • tinybins

Outputs information about the last free and free list of the current tiny heap.

1

  • smallbins

Functions similarly to tinybins, providing information about the last free and free list of the small heap.

The current version may have issues and the information provided might be inaccurate.

TODO

  • Support for the small heap
  • Support for the nano heap
  • Support for the large heap

About

This is a simple lldb plugin designed to inspect heap information in libmalloc on macOS.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages