当前位置:网站首页>Breakpad usage and DMP analysis
Breakpad usage and DMP analysis
2022-06-25 14:58:00 【qq_ twenty-three million nine hundred and fifty-three thousand 】
breakpad compile
1,breakpad Source download path
https://chromium.googlesource.com/breakpad/breakpad
The latest version requires g++ Support c++11, If g++ I won't support it c++11, You can use a lower version breakpad, Choose... Here 42
2,./configure && make
3, There are few problems encountered during compilation lss file , Download here https://chromium.googlesource.com/linux-syscall-support/
4, If gcc Version is too low , Will be submitted to the -Werror Wait for several unrecognized error messages , At this time, you can Makefile in -Werror Relevant settings are commented out
breakpad Use
1, Include header file
“client/linux/handler/minidump_descriptor.h”
“client/linux/handler/exception_handler.h”
2, google_breakpad::MinidumpDescriptor descriptor("./tmp"); // Appoint minidump File write Directory
google_breakpad::ExceptionHandler eh(descriptor, NULL, breakpad_callback, NULL, true ,-1);
// finish writing sth. minidump Callback function after
static bool breakpad_callback(const google_breakpad::MinidumpDescriptor& descriptor,
void* context, bool succeeded)
{
printf("Dump path: %s\n", descriptor.path());
return succeeded;
}
int main()
{
google_breakpad::MinidumpDescriptor descriptor("./tmp"); // Appoint minidump File write Directory
google_breakpad::ExceptionHandler eh(descriptor, NULL, breakpad_callback, NULL, true ,-1);
char *p = NULL;
*p=1;
return 0;
}
}
dmp analysis
dmp File analysis requires two executable programs , The first is dump_syms, The second is minidump_stackwalk
1,dump_syms A symbol table used to generate executable programs , Such as
./dump_syms main >main.sym
./dump_syms libsecmodel.so > libsecmodel.so.sym
2, according to main.sym obtain version number
perform head main.sym -n 1
obtain MODULE Linux x86_64 0B3BFC770A76BCA18E2ECC7A19DF61DF0 main
Create folder symobols/main/0B3BFC770A76BCA18E2ECC7A19DF61DF0
3, take main.sym Copied to the symobols/main/0B3BFC770A76BCA18E2ECC7A19DF61DF0 Next
4, Suppose the program crashes and generates dmp File for 7f0a5ae5-4ea2-150e-55e9b70e-05c9ae40.dmp
5, Generate readable stack information
minidump_stackwalk 7f0a5ae5-4ea2-150e-55e9b70e-05c9ae40.dmp ./symbols > main.result
Stack information is stored in main.result In file
边栏推荐
- Common operations in VIM
- 【Try to Hack】vulhub靶场搭建
- 90 后眼中的理想 L9:最简单的产品哲学,造最猛的爆款 | 指南斟
- JS to add elements to the header, or tail of an array
- Add the resources directory under test in idea
- 使用sphinx根据py源文件自动生成API文档
- JS capture, target, bubble phase
- [try to hack] vulhub shooting range construction
- JS recursion and while
- 分饼干问题
猜你喜欢

Gif动图如何裁剪?收下这个图片在线裁剪工具

What moment makes you think there is a bug in the world?

Js- get the mouse coordinates and follow them

Character encoding minutes

JS recursion and while

【Try to Hack】vulnhub DC1

从0到1完全掌握 XSS

JGG | overview of duhuilong group of Hebei University Research on plant pan genomics

QQ love talk candy love talk content acquisition and storage

Open a restaurant
随机推荐
3. Sequential structure multiple choice questions
Design and implementation of timer
How to make GIF animation online? Try this GIF online production tool
QQ情话糖果情话内容获取并保存
Use Matplotlib to draw a line chart
Qt: Pro project file
成员变量与局部变量的区别
New title of PTA
定位position(5种方式)
Luogu p5707 [deep foundation 2. example 12] late for school
Why should the coroutine be set to non blocking IO
Gif动画怎么在线制作?快试试这款gif在线制作工具
Iterator failure condition
开餐馆
Sequential programming 1
Std:: vector minutes
System Verilog - function and task
Vs2019 scanf error
Kubernetes understands kubectl/ debugging
Application of TSDB in civil aircraft industry