Jump to content
Tuts 4 You

Edit History

Salin

Salin


hide keygen code

Name:leet

Serial:77fe1a9ac6d0e41b35c---

simple string hash + xor some stuff

need constants to meet constraint of word count.

keygen:

Spoiler

	char buff[0x20], d[0x20];
	memset(buff, 0x0, 0x20);
	cin >> buff;
	
	//simple hash
	char* c = buff;
	int r = 0;
	while (*c)
	{
		r += *c;
		c++;
	}
	//xor
	r ^= 0x7654;
	sprintf(buff, "%x", r);

	int i = 3;
	do {
		r = r << 2 | r >> 30;
		r ^= 0x7654;
		sprintf(d, "%x", r);
		strncat(buff, d, 5);
		i--;
	} while (i);

	buff[19] = 45;
	buff[20] = 45;
	buff[21] = 45;
	buff[22] = '\0';

	cout << buff;

 

 

 

 

 

 

 

Salin

Salin

Name:leet

Serial:77fe1a9ac6d0e41b35c---

simple string hash + xor some stuff

need constants to meet constraint of word count.

keygen:

	char buff[0x20], d[0x20];
	memset(buff, 0x0, 0x20);
	cin >> buff;
	
	//simple hash
	char* c = buff;
	int r = 0;
	while (*c)
	{
		r += *c;
		c++;
	}
	//xor
	r ^= 0x7654;
	sprintf(buff, "%x", r);

	int i = 3;
	do {
		r = r << 2 | r >> 30;
		r ^= 0x7654;
		sprintf(d, "%x", r);
		strncat(buff, d, 5);
		i--;
	} while (i);

	buff[19] = 45;
	buff[20] = 45;
	buff[21] = 45;
	buff[22] = '\0';

	cout << buff;

 

 

 

 

 

Salin

Salin

Name:leet

Serial:77fe1a9ac6d0e41b35c---

simple string hash + xor some stuff

need constants to meet constraint of word count.

	char buff[0x20], d[0x20];
	memset(buff, 0x0, 0x20);
	cin >> buff;
	
	//simple hash
	char* c = buff;
	int r = 0;
	while (*c)
	{
		r += *c;
		c++;
	}
	//xor
	r ^= 0x7654;
	sprintf(buff, "%x", r);

	int i = 3;
	do {
		r = r << 2 | r >> 30;
		r ^= 0x7654;
		sprintf(d, "%x", r);
		strncat(buff, d, 5);
		i--;
	} while (i);

	buff[19] = 45;
	buff[20] = 45;
	buff[21] = 45;
	buff[22] = '\0';

	cout << buff;

 

 

 

 

 

×
×
  • Create New...