首先使用exeinfo查看

该程序无壳,为64位程序
buuctf reverse1-逆向学习记录

拖入64位IDA

shift+F12查看字符串
发现形似flag的{hello_world}
buuctf reverse1-逆向学习记录
双击跳转到该值地址处,发现有被sub_1400118C0引用
buuctf reverse1-逆向学习记录
跳转到sub_1400118C0的引用处
buuctf reverse1-逆向学习记录
F5查看伪代码
buuctf reverse1-逆向学习记录

分析伪代码可知,程序将输入的值与程序中的Str2进行比较,若输入的值与Str2相同,则输出this is the right flag!buuctf reverse1-逆向学习记录
双击查看Str2的值,发现Str2就是{hello_world}
buuctf reverse1-逆向学习记录
提交flag{hello_world}显示flag错误,再回到伪代码,可以发现还有四处地方操作过Str2,其中v2和v6处是获取Str2的长度,重点在中间两处
buuctf reverse1-逆向学习记录
IDA中选中值,可将十进制转换成chr,根据代码可知,是遍历Str2,将‘o’改为‘0’,则将{hello_world}改为{hell0_w0rld}即可
buuctf reverse1-逆向学习记录
则flag为{hell0_w0rld}

相关文章:

  • 2022-12-23
  • 2021-12-16
  • 2021-08-21
  • 2022-01-05
  • 2021-11-15
  • 2022-01-18
  • 2021-06-02
  • 2021-05-12
猜你喜欢
  • 2022-01-16
  • 2021-06-07
  • 2022-12-23
  • 2022-12-23
  • 2021-04-30
  • 2021-10-15
相关资源
相似解决方案