gpt4 book ai didi

linux - 在 GDB 日志中查找文本

转载 作者:太空宇宙 更新时间:2023-11-04 11:30:16 36 4
gpt4 key购买 nike

我将一些数据从 GDB 记录到文件 gdb.txt,如下所示:

    0x00fca0ab:    pop    ebp
0x00fca0ac: dec edx
0x00fca0ad: xlat BYTE PTR ds:[ebx]
0x00fca0ae: jmp 0xb31bbe76
0x00fca0b3: mov bl,0x8a
0x00fca0b5: fmul DWORD PTR [edi+0x21828f9b]
0x00fca0bb: mov BYTE PTR [ebp+0x45],ah
0x00fca0be: adc BYTE PTR ds:0x66e7d2ad,ch
0x00fca0c4: xchg edx,eax

我想搜索特定的 ROP 小工具,所以我会寻找类似这样的东西:

    [address]:    xchg   esi,eax
[address]: ret

我将如何去搜索这样的文本?我将不得不查看特定的列,那么最好的方法是什么?顺便说一句,这是 Ubuntu 11.10。

最佳答案

试试这个:

awk '{print $2}' gdb.txt #it prints the second column in the file

然后您可以使用 grep 查找所需的数据。总计:

awk '{print $2}' gdb.txt | grep data

关于linux - 在 GDB 日志中查找文本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11751088/

36 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com