BUU crackMe wp

用户名:'welcomebeijing',要找出密码

从后往前看

image

在main函数里面看到判断

image

下面的函数可以确定v16数组是什么

image

所以v16是dbappsec

可以验证一下

#include <stdio.h>
#include <string.h>

int main() {
	int a=0;
	a|=4;
	a|=0x14;
	a|=0x84;
	a|=0x114;
	a|=0x380;
	a|=0xa04;
	a|=0x2310;
	a|=0x8a10;
	printf("%d",a);
	return 0;
}

image

对于上面这个函数关键是异或,可以看到将byte_E06050存到cl,这是ecx的低八位,所以数组的值是存到ecx里面

用ollydbg动调,密码随便

看到偏移是1B3E

image

手动提取吧

byte:0x2A,0xD7,0x92,0xE9,0x53,0xE2,0xC4,0xCD

异或回去就是密码了

#include <stdio.h>
#include <string.h>

int main() {
	int a[]={0x2A,0xD7,0x92,0xE9,0x53,0xE2,0xC4,0xCD};
	char b[]="dbappsec";
	for(int i=0;i<8;i++){
		printf("%x",a[i] ^ b[i]);
	}
}
posted @ 2025-07-10 02:44  zzz222666  阅读(29)  评论(0)    收藏  举报