Jump to content
Tuts 4 You

Keygenme


Guest paperclip2

Recommended Posts

Guest paperclip2

An easier one, but still worth the try:


/>http://rapidshare.de/files/16982524/KeyGenMe1.zip.html

(sorry for rapidshare :^ )

Link to comment
  • 1 month later...

C++ solutuion with comments : meh who needs asm :P

				if(HIWORD(wParam) == EN_CHANGE){
int nLen = GetWindowTextLength(GetDlgItem(hWnd, IDC_NAME)) + 1;
LPSTR lpszName = new CHAR[nLen];
GetDlgItemText(hWnd, IDC_NAME, lpszName, nLen);
nLen--;
if(nLen > 20) nLen = 20; // only loops through first 20 characters
if(nLen > 5){ // name can't be less than 5
int Value[7] = { 252, 172, 84, 209, 201, 181, 228 }; // stores static values in array (converted to decimal)
for(int nChar = 0, ulSum = 0, nCount = 0; nChar < nLen; nChar++, nCount++) {
int nValue2 = nCount % 4; // equivalent of "CDQ" "IDIV X" position % 4
ulSum = ulSum << nValue2; // shift logic to left
ulSum += (lpszName[nChar]); // sum of name character
int nValue3 = nCount % 7; // position % 7
ulSum += Value[nValue3]; // nValue2 is used to retrieve value from static array
} int nValue4 = ulSum % 127;
if (abs(nValue4) != nValue4) nValue4 *= -1; // checks if negative, if so convert to positive
nValue4 = nValue4 | 2; // logical OR
nValue4 = 2*nValue4+(32767);
nValue4 &= 0x000000FF; // equivalent of AND EAX,0FFF
nValue4 = nValue4 << 8; // shift logic to left 8
nValue4 += 10000; // nValue = nValue + 1000 SetDlgItemInt(hWnd, IDC_RESULT, nValue4, FALSE);
}else{
SetDlgItemText(hWnd, IDC_RESULT, "- Enter Name -");
}
delete lpszName;
}

Compiled keygen:

http://rapidshare.de/files/20870114/keygen.exe.html
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...