简体   繁体   English

C中的逆向工程; 炸弹实验室

[英]reverse engineering in C; bomb lab

I am doing a lab for my cs class and we are reverse engineering a "binary bomb".我正在为我的 cs 课程做一个实验室,我们正在对“二进制炸弹”进行逆向工程。 I am confused on a few assembler instructions.我对一些汇编​​指令感到困惑。 If anyone could explain what these do and how the work I would greatly appreciate it.如果有人能解释这些是做什么的以及如何工作,我将不胜感激。

lea   0x10(%rbx), %rbp. 

Im pretty sure rbx is supposed to hold the address of rbp, but im confused on the 0x10 argument.我很确定 rbx 应该保存 rbp 的地址,但我对 0x10 参数感到困惑。

mov   0x4(%rbx), %eax. 

Same thing as above, don't understand what the 0x4 argument is.和上面一样,不明白 0x4 参数是什么。

These are offsets (0x10 = 16bytes and 0x4=4bytes) to the pointers in rbp and eax.这些是 rbp 和 eax 中指针的偏移量(0x10 = 16 字节和 0x4 = 4 字节)。 Most likely iterating over elements in an array/vector.最有可能迭代数组/向量中的元素。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM