Guten Tag,
Ich habe mich mit Starzboys Keygenme #2 beschäftigt und bin auf ein Problem gestoßen, denn ich will folgenden Assembly-Code in C++ schreiben, da ich allerdings nie zuvor so etwas gemacht habe (ich habe schon Keygens aus dem Keygenme estellt, aber nicht in C++), habe ich keinen Anhaltspunkt, wo ich anfangen soll.
Könnt ihr mir sagen wie ihr dabei vorgeht? Die Ide ist Dev-C++, wenn das jemanden nützt. Der Code ist aus IDA, ich habe schon einen Teil der Variablen benennen können.
Vielen Dank
PS: Hat jemand genau für dieses Problem einen Link zu einem Tutorial?
Ich habe mich mit Starzboys Keygenme #2 beschäftigt und bin auf ein Problem gestoßen, denn ich will folgenden Assembly-Code in C++ schreiben, da ich allerdings nie zuvor so etwas gemacht habe (ich habe schon Keygens aus dem Keygenme estellt, aber nicht in C++), habe ich keinen Anhaltspunkt, wo ich anfangen soll.
Könnt ihr mir sagen wie ihr dabei vorgeht? Die Ide ist Dev-C++, wenn das jemanden nützt. Der Code ist aus IDA, ich habe schon einen Teil der Variablen benennen können.
Code:
.text:0040155F mov [ebp+i], 0
.text:00401569
.text:00401569 LoopTop1: ; CODE XREF: _main+286j
.text:00401569 lea eax, [ebp+InputUserCompanyName] ; Load Effective Address
.text:0040156F mov [esp+158h+sonst], eax
.text:00401572 call strlen ; Call Procedure
.text:00401577 cmp eax, [ebp+i] ; Compare Two Operands
.text:0040157D jbe AfterLoop1 ; Jump if Below or Equal (CF=1 | ZF=1)
.text:00401583 lea eax, [ebp+unbekannt1] ; Load Effective Address
.text:00401586 add eax, [ebp+i] ; Add
.text:0040158C sub eax, 256 ; Integer Subtraction
.text:00401591 movsx eax, byte ptr [eax] ; Move with Sign-Extend
.text:00401594 mov [ebp+sum1], eax
.text:0040159A lea eax, [ebp+sum1] ; Load Effective Address
.text:004015A0 add dword ptr [eax], 1456982h ; Add
.text:004015A6 lea eax, [ebp+sum1] ; Load Effective Address
.text:004015AC add dword ptr [eax], 5893632h ; Add
.text:004015B2 mov eax, [ebp+sum1]
.text:004015B8 add eax, [ebp+sum1] ; Add
.text:004015BE add eax, 9061 ; Add
.text:004015C3 mov [ebp+sum1], eax
.text:004015C9 mov ecx, [ebp+calculatedPwd]
.text:004015CF mov eax, ecx
.text:004015D1 mov edx, eax
.text:004015D3 shl edx, 6 ; Shift Logical Left
.text:004015D6 sub edx, ecx ; Integer Subtraction
.text:004015D8 mov eax, [ebp+sum1]
.text:004015DE add eax, eax ; Add
.text:004015E0 lea eax, [edx+eax] ; Load Effective Address
.text:004015E3 mov [ebp+calculatedPwd], eax
.text:004015E9 mov eax, [ebp+calculatedPwd]
.text:004015EF add eax, eax ; Add
.text:004015F1 add eax, [ebp+unbekannt2] ; Add
.text:004015F7 mov [ebp+calculatedPwd], eax
.text:004015FD mov eax, [ebp+calculatedPwd]
.text:00401603 add eax, eax ; Add
.text:00401605 add eax, 4 ; Add
.text:00401608 mov [ebp+calculatedPwd], eax
.text:0040160E lea eax, [ebp+i] ; Load Effective Address
.text:00401614 inc dword ptr [eax] ; Increment by 1
.text:00401616 jmp LoopTop1 ; Jump
.text:0040161B ; ---------------------------------------------------------------------------
.text:0040161B
.text:0040161B AfterLoop1: ; CODE XREF: _main+1EDj
.text:0040161B call rand ; Call Procedure
.text:00401620 mov edx, eax
.text:00401622 lea ecx, [ebp+var_12C] ; Load Effective Address
.text:00401628 mov [ebp+var_13C], ecx
.text:0040162E mov eax, edx
.text:00401630 mov ecx, [ebp+var_13C]
.text:00401636 cdq ; EAX -> EDX:EAX (with sign)
.text:00401637 idiv dword ptr [ecx] ; Signed Divide
.text:00401639 mov eax, edx
.text:0040163B add eax, [ebp+calculatedPwd] ; Add
.text:00401641 mov [ebp+CalculatedIdentityCode], eax
Vielen Dank
PS: Hat jemand genau für dieses Problem einen Link zu einem Tutorial?