home *** CD-ROM | disk | FTP | other *** search
/ KeyGen Studio 2002 / KeyGen_Studio_2002.iso / Tutorials / CrackMesCbjNet / acf_psycho_arjani.txt < prev    next >
Encoding:
Text File  |  2001-09-21  |  7.0 KB  |  226 lines

  1. Ok let`s begin
  2.  
  3. first
  4. UNPACK the crackme with PROCDUMP or upx
  5.  
  6. then run the crackme so you will know the "bad serial" message
  7.  
  8. now the rest
  9.  
  10. 1-) Faire un crack. (make a crack)
  11.  
  12. toolz
  13. -----------
  14. HIEW
  15. Windasm
  16. -----------
  17.  
  18. Ok open the file in windasm click on strn.ref
  19.  
  20. mmm... 
  21. "Bravo, vous " looks nice so click it
  22. then close the little window
  23.  
  24. you are now here:
  25.  
  26. * Referenced by a (U)nconditional or (C)onditional Jump at Addresses:
  27. |:00401216(C)
  28. |
  29.  
  30. * Possible Stringdate Ref from Code Obj ->"Bravo, vous " 
  31.  
  32. :0040122F  6852304000        push 00403052
  33.  
  34.  
  35. ok so the jump at 00401216 jumps to "good code"
  36. press shift+f12 and enter 00401216
  37.  
  38. you will come here
  39.  
  40. cmp eax, ecx
  41. jne 00401218            // he what`s this ?
  42. lea esi, dword ptr [0040320C]
  43. lea edi, dword ptr [00403161]
  44. repz
  45. cmpsb
  46. je 0040122f            // <--- you will come here
  47.  
  48. ok click on "jne 00401218" then jump.to and you will come here:
  49.  
  50. * Possible Stringdate Ref from Code Obj ->"Le serial entr" 
  51.  
  52. :00401218  6873304000        push 00403073
  53.  
  54. remmeber "Le serial entr" ?, this is the "bad code" message
  55. so we need to:
  56.  
  57. let "jne 00401218" never jump
  58. and "je 0040122f" always jump
  59.  
  60. so exit windasm and open hiew
  61. press F4 and select DECODE
  62. press F5 (goto) and enter 806 (hex offset of "jne 00401218")
  63.  
  64. press F3 now change 7510 into 7500 <-- always go down on line
  65. now goto 816 and change 7417 into EB17 <-- always jump to "good code"
  66.  
  67. done
  68.  
  69. -------------------------------------------------------------------------------------------------------------------------------------
  70. 2-) Trouver un serial. (get a valid serial)
  71.  
  72. toolz
  73. -----------
  74. Soft-ice
  75. -----------
  76.  
  77. start up the crackme
  78. press CTRL+D or anthor soft-ice  hotkey
  79. set a breakpoint on getdlgitemtexta (bpx getdlgitemtexta)
  80.  
  81. enter:
  82.  
  83. Psycho Arjani
  84. 888888
  85.  
  86. click OK
  87.  
  88. soft-ice will break
  89. press F11 (return to prog that calls getdlgitemtexta)
  90. now you will see this:
  91. (use F10 to go with the code)
  92.  
  93. 015F:004011A3  CALL      USER32!GetDlgItemTextA
  94. 015F:004011A8  CMP       EAX,00                //check if a lenght name <> 0
  95. 015F:004011AB  JZ        00401274                                               
  96. 015F:004011B1  CMP       EAX,03                //check if the name is 3 chars or less, so your name must be at least 4 chars
  97. 015F:004011B4  JBE       0040125D                                               
  98. 015F:004011BA  CALL      004012B0            // ;) we ingnore this one ok (check the keygen part)
  99. 015F:004011BF  PUSH      EBX                                                    
  100. 015F:004011C0  PUSH      00403039                                               
  101. 015F:004011C5  PUSH      0040320C
  102. 015F:004011CA  CALL      USER32!wsprintfA    
  103. 015F:004011CF  ADD       ESP,0C
  104. 015F:004011D2  PUSH      32                                                     
  105. 015F:004011D4  PUSH      00403161                                               
  106. 015F:004011D9  PUSH      00000BBB                                               
  107. 015F:004011DE  PUSH      DWORD PTR [00403031]                                   
  108. 015F:004011E4  CALL      USER32!GetDlgItemTextA
  109. 015F:004011E9  CMP       EAX,00
  110. 015F:004011EC  JZ        00401246
  111. 015F:004011EE  PUSH      0040320C                                               
  112. 015F:004011F3  CALL      KERNEL32!lstrlen                                       
  113. 015F:004011F8  MOV       ECX,EAX
  114. 015F:004011FA  PUSH      00403161                                               
  115. 015F:004011FF  CALL      KERNEL32!lstrlen                                       
  116. 015F:00401204  CMP       EAX,ECX            //Check if length "our serial" = "real serial"
  117. 015F:00401206  JNZ       00401218       
  118. 015F:00401208  LEA       ESI,DWORD PTR [0040320C]    //do a D 0040320C here and you will see the correct serial       
  119. 015F:0040120E  LEA       EDI,DWORD PTR [00403161]       //do a D 00403161 here and you will see our serail
  120. 015F:00401214  REPZ       
  121. 015F:00401215  CMPSB       
  122. 015F:00401216  JZ        0040122F            //if real serial = our serial then jump
  123.  
  124. done ;)
  125.  
  126. (you could also (AFTER pressing F11) 
  127. put at breakpoint on 00401216 (bpx 00401216 
  128. (you should know this address:))
  129. ("BC *" (clear current breakpoints) first)
  130.  
  131. -------------------------------------------------------------------------------------------------------------------------------------
  132. 3-) Faire un keygen. (make a keygen)
  133.  
  134. toolz
  135. -----------
  136. Soft-ice
  137.  
  138. optial:
  139. HIEW
  140. WINDASM
  141. -----------
  142.  
  143. remeber this:
  144. 015F:004011BA  CALL      004012B0
  145.  
  146. it`s the call to produce the valid serial ;)
  147. so do the same as before but when your at the call press F8
  148.  
  149. now you will see this:
  150.  
  151. 015F:004012AD  RET       0010
  152. 015F:004012B0  PUSH      ESI
  153. 015F:004012B1  PUSH      EDI
  154. 015F:004012B2  XOR       EDI,EDI            //EDI = 0 
  155. 015F:004012B4  MOV       EBX,EAX            //EBX = EAX (EAX = LENGHT NAME)
  156. 015F:004012B6  INC       EDI                //EDI = EDI + 1 (EDI = 1)
  157. 015F:004012B7  MOV       ESI,EAX            //ESI = EAX (EAX = LENGHT NAME)
  158.  
  159. (LOOP here)
  160.  
  161. 015F:004012B9  LEA       EAX,[00403120]            //EAX = NAME
  162. 015F:004012BF  MOVZX     EAX,BYTE PTR [EAX+EDI+01]    //EAX = first chars - (EDI + 1) of your name (eg. your name is "Psycho Arjani" and EDI = 1 then EAX = "ycho Arjani", EDI = 2 then EAX = "cho Arjani"
  163. 015F:004012C4  AND       EAX,000000FF            
  164. 015F:004012C9  ADD       EBX,0984DA1B            //EBX + HEX(0984DA1B)
  165. 015F:004012CF  ADD       EBX,0479631C            //EBX + HEX(0479631C)
  166. 015F:004012D5  ADD       EBX,EAX            //EBX + ascii code of the letter stored in EAX
  167. 015F:004012D7  ADD       EBX,08971365            //EBX + HEX(08971365)
  168. 015F:004012DD  ADD       EBX,085D9C2B            //EBX + HEX(085D9C2B)
  169. 015F:004012E3  INC       EDI                //EDI = EDI + 1
  170. 015F:004012E4  DEC       ESI
  171. 015F:004012E5  JNZ       004012B9            //if ESI <> 0 then it returns to 015F:004012B9
  172.  
  173. simple ha
  174.  
  175. now make a keygen !!!
  176. but if you don`t know how the make one READ ON !
  177.  
  178. open the file in windasm, click strn.ref, click "Le serial entr"
  179. you will see this:
  180.  
  181. * Possible Stringdate Ref from Code Obj ->"Le serial entr" 
  182.  
  183. :00401218  6873304000        push 00403073            //text displayed
  184. :0040121D  68C10B0000        push 00000BC1
  185. :00401222  FF3531304000        push DWORD PTR [00403031]
  186. :00401228  E8F9000000        CALL 00401326            //Calls "display message"
  187. :0040122D  EB7B            JMP 004012AA
  188.  
  189. ok now look at this (it`s the serial check part)
  190.  
  191. cmp eax, ecx
  192. jne 00401218
  193. lea esi, dword ptr [0040320C]    //contains the RIGHT serial
  194. lea edi, dword ptr [00403161]    //contains the WRONG serial
  195. repz
  196. cmpsb
  197. je 0040122f            //if serials are differnt than don`t jump !
  198.  
  199. ok 
  200. so the right serial at "0040320C" is still there when it jumps to bad code, right ? (yes it does)
  201.  
  202. open the crackme with HIEW, select DECODE, goto 818 (hex offset of "00401218")
  203. press F3 then press F2 (asm) change "push 00403073" into "push 0040320C"
  204.  
  205. (in DECODE mode goto 00403073 than select HEX mode, you will see "Le serial entrΘ est incorrect !")
  206.  
  207. now open the crackme and enter a wrong code and ...
  208.  
  209. IT WORKS
  210. instead of "Le serial entrΘ est incorrect !" you will get "2455112272" (for the name "Psycho Arjani")
  211.  
  212. -------------------------------------------------------------------------------------------------------------------------------
  213.  
  214. My rating:
  215. it`s a nice crackme for newbie`s who aren`t good with soft-ice
  216.  
  217. rating 2 of the 10
  218.  
  219. toolz
  220. ---------------------
  221. get them all at
  222. www.protools.cjb.net
  223. ---------------------
  224.  
  225. Psycho Arjani
  226. 2001