怎样把这段算法翻译成c语言代码?
00401C70 .68 FF000000 PUSH 0FF ; /Count = FF (255.)00401C75 .68 F0814000 PUSH ccccc.004081F0 ; |Buffer = ccccc.004081F0
00401C7A .68 D8070000 PUSH 7D8 ; |ControlID = 7D8 (2008.)
00401C7F .56 PUSH ESI ; |hWnd
00401C80 .FFD7 CALL EDI ; \GetDlgItemTextA
00401C82 .68 FF000000 PUSH 0FF ; /Count = FF (255.)
00401C87 .68 F0804000 PUSH ccccc.004080F0 ; |Buffer = ccccc.004080F0
00401C8C .68 DB070000 PUSH 7DB ; |ControlID = 7DB (2011.)
00401C91 .56 PUSH ESI ; |hWnd
00401C92 .FFD7 CALL EDI ; \GetDlgItemTextA
00401C94 .68 F0814000 PUSH ccccc.004081F0 ;ASCII "find"
00401C99 .68 F0804000 PUSH ccccc.004080F0 ;ASCII "lacoucou"
00401C9E .E8 CDFBFFFF CALL ccccc.00401870
00401CA3 .83C4 08 ADD ESP,8
00401CA6 .68 F0824000 PUSH ccccc.004082F0 ; /Text = "EHLJDHPHQGHUMEAYLNLF"
00401CAB .68 DA070000 PUSH 7DA ; |ControlID = 7DA (2010.)
00401CB0 .56 PUSH ESI ; |hWnd
00401CB1 .FF15 30614000 CALL DWORD PTR DS:[<&USER32.SetDlgItemTe>; \SetDlgItemTextA
00401CB7 .33C0 XOR EAX,EAX
00401CB9 .5F POP EDI
00401CBA .5E POP ESI
00401CBB .83C4 40 ADD ESP,40
00401CBE .C2 1000 RETN 10
00401870/$81EC 14010000 SUB ESP,114
00401876|.53 PUSH EBX
00401877|.55 PUSH EBP
00401878|.8BAC24 200100>MOV EBP,DWORD PTR SS:
0040187F|.57 PUSH EDI
00401880|.33DB XOR EBX,EBX
00401882|.33C0 XOR EAX,EAX
00401884|.885C24 20 MOV BYTE PTR SS:,BL
00401888|.B9 3F000000 MOV ECX,3F
0040188D|.8D7C24 21 LEA EDI,DWORD PTR SS:
00401891|.F3:AB REP STOS DWORD PTR ES:
00401893|.AA STOS BYTE PTR ES:
00401894|.8BC5 MOV EAX,EBP
00401896|.8D50 01 LEA EDX,DWORD PTR DS:
00401899|.8DA424 000000>LEA ESP,DWORD PTR SS:
004018A0|>8A08 /MOV CL,BYTE PTR DS:
004018A2|.40 |INC EAX
004018A3|.3ACB |CMP CL,BL
004018A5|.^ 75 F9 \JNZ SHORT ccccc.004018A0
004018A7|.2BC2 SUB EAX,EDX
004018A9|.894424 0C MOV DWORD PTR SS:,EAX
004018AD|.75 1F JNZ SHORT ccccc.004018CE
004018AF|.68 FC664000 PUSH ccccc.004066FC ; /Format = "请输入机器码"
004018B4|.68 F0824000 PUSH ccccc.004082F0 ; |s = ccccc.004082F0
004018B9|.FF15 44614000 CALL DWORD PTR DS:[<&USER32.wsprintfA>]; \wsprintfA
004018BF|.83C4 08 ADD ESP,8
004018C2|.5F POP EDI
004018C3|.5D POP EBP
004018C4|.33C0 XOR EAX,EAX
004018C6|.5B POP EBX
004018C7|.81C4 14010000 ADD ESP,114
004018CD|.C3 RETN
004018CE|>56 PUSH ESI
004018CF|.8BB424 2C0100>MOV ESI,DWORD PTR SS:
004018D6|.8BC6 MOV EAX,ESI
004018D8|.8D50 01 LEA EDX,DWORD PTR DS:
004018DB|.EB 03 JMP SHORT ccccc.004018E0
004018DD| 8D49 00 LEA ECX,DWORD PTR DS:
004018E0|>8A08 /MOV CL,BYTE PTR DS:
004018E2|.40 |INC EAX
004018E3|.3ACB |CMP CL,BL
004018E5|.^ 75 F9 \JNZ SHORT ccccc.004018E0
004018E7|.2BC2 SUB EAX,EDX
004018E9|.894424 10 MOV DWORD PTR SS:,EAX
004018ED|.75 20 JNZ SHORT ccccc.0040190F
004018EF|.68 EC664000 PUSH ccccc.004066EC ; /Format = "请输入用户名"
004018F4|.68 F0824000 PUSH ccccc.004082F0 ; |s = ccccc.004082F0
004018F9|.FF15 44614000 CALL DWORD PTR DS:[<&USER32.wsprintfA>]; \wsprintfA
004018FF|.83C4 08 ADD ESP,8
00401902|.5E POP ESI
00401903|.5F POP EDI
00401904|.5D POP EBP
00401905|.33C0 XOR EAX,EAX
00401907|.5B POP EBX
00401908|.81C4 14010000 ADD ESP,114
0040190E|.C3 RETN
0040190F|>83CA FF OR EDX,FFFFFFFF
00401912|.2BD6 SUB EDX,ESI
00401914|.895424 10 MOV DWORD PTR SS:,EDX
00401918|.BA FEFFFFFF MOV EDX,-2
0040191D|.2BD6 SUB EDX,ESI
0040191F|.895424 18 MOV DWORD PTR SS:,EDX
00401923|.BA FDFFFFFF MOV EDX,-3
00401928|.2BD6 SUB EDX,ESI
0040192A|.895424 14 MOV DWORD PTR SS:,EDX
0040192E|.8BFD MOV EDI,EBP
00401930|.2BFE SUB EDI,ESI
00401932|.BA FCFFFFFF MOV EDX,-4
00401937|.8D46 04 LEA EAX,DWORD PTR DS:
0040193A|.2BD6 SUB EDX,ESI
0040193C|.BE 01000000 MOV ESI,1
00401941|.2BF5 SUB ESI,EBP
00401943|.8D4D 03 LEA ECX,DWORD PTR SS:
00401946|.897C24 20 MOV DWORD PTR SS:,EDI
0040194A|.897424 1C MOV DWORD PTR SS:,ESI
0040194E|.EB 10 JMP SHORT ccccc.00401960
00401950|>8B7C24 20 /MOV EDI,DWORD PTR SS:
00401954|.8B7424 1C |MOV ESI,DWORD PTR SS:
00401958|.EB 06 |JMP SHORT ccccc.00401960
0040195A| 8D9B 00000000 |LEA EBX,DWORD PTR DS:
00401960|>0FBE3C07 MOVSX EDI,BYTE PTR DS:
00401964|.0FBE28 |MOVSX EBP,BYTE PTR DS:
00401967|.03F1 |ADD ESI,ECX
00401969|.33FD |XOR EDI,EBP
0040196B|.0FBE69 FD |MOVSX EBP,BYTE PTR DS:
0040196F|.0FAFFE |IMUL EDI,ESI
00401972|.0FBE70 FC |MOVSX ESI,BYTE PTR DS:
00401976|.33F5 |XOR ESI,EBP
00401978|.8D2C02 |LEA EBP,DWORD PTR DS:
0040197B|.0FAFF5 |IMUL ESI,EBP
0040197E|.0FBE69 FE |MOVSX EBP,BYTE PTR DS:
00401982|.03FE |ADD EDI,ESI
00401984|.0FBE70 FD |MOVSX ESI,BYTE PTR DS:
00401988|.33F5 |XOR ESI,EBP
0040198A|.8B6C24 14 |MOV EBP,DWORD PTR SS:
0040198E|.03E8 |ADD EBP,EAX
00401990|.0FAFF5 |IMUL ESI,EBP
00401993|.0FBE69 FF |MOVSX EBP,BYTE PTR DS:
00401997|.03FE |ADD EDI,ESI
00401999|.0FBE70 FE |MOVSX ESI,BYTE PTR DS:
0040199D|.33F5 |XOR ESI,EBP
0040199F|.8B6C24 18 |MOV EBP,DWORD PTR SS:
004019A3|.03E8 |ADD EBP,EAX
004019A5|.0FAFF5 |IMUL ESI,EBP
004019A8|.0FBE29 |MOVSX EBP,BYTE PTR DS:
004019AB|.03FE |ADD EDI,ESI
004019AD|.0FBE70 FF |MOVSX ESI,BYTE PTR DS:
004019B1|.33F5 |XOR ESI,EBP
004019B3|.8B6C24 10 |MOV EBP,DWORD PTR SS:
004019B7|.03E8 |ADD EBP,EAX
004019B9|.0FAFF5 |IMUL ESI,EBP
004019BC|.03F3 |ADD ESI,EBX
004019BE|.83C0 05 |ADD EAX,5
004019C1|.8D1C3E |LEA EBX,DWORD PTR DS:
004019C4|.8D3402 |LEA ESI,DWORD PTR DS:
004019C7|.83C1 05 |ADD ECX,5
004019CA|.83FE 14 |CMP ESI,14
004019CD|.^ 7C 81 \JL SHORT ccccc.00401950
004019CF|.81C3 39300000 ADD EBX,3039
004019D5|.53 PUSH EBX ; /<%d>
004019D6|.8D4424 28 LEA EAX,DWORD PTR SS: ; |
004019DA|.68 E8664000 PUSH ccccc.004066E8 ; |Format = "%d"
004019DF|.50 PUSH EAX ; |s
004019E0|.FF15 44614000 CALL DWORD PTR DS:[<&USER32.wsprintfA>]; \wsprintfA
004019E6|.8A4C24 30 MOV CL,BYTE PTR SS:
004019EA|.8A5424 31 MOV DL,BYTE PTR SS:
004019EE|.8A4424 32 MOV AL,BYTE PTR SS:
004019F2|.81C3 444D0000 ADD EBX,4D44
004019F8|.80C1 14 ADD CL,14
004019FB|.80C2 14 ADD DL,14
004019FE|.895C24 1C MOV DWORD PTR SS:,EBX
00401A02|.DB4424 1C FILD DWORD PTR SS:
00401A06|.880D F0824000 MOV BYTE PTR DS:,CL
00401A0C|.8A4C24 33 MOV CL,BYTE PTR SS:
00401A10|.8815 F1824000 MOV BYTE PTR DS:,DL
00401A16|.8A5424 34 MOV DL,BYTE PTR SS:
00401A1A|.DC0D E0664000 FMUL QWORD PTR DS:
00401A20|.04 14 ADD AL,14
00401A22|.80C1 14 ADD CL,14
00401A25|.80C2 14 ADD DL,14
00401A28|.83C4 0C ADD ESP,0C
00401A2B|.A2 F2824000 MOV BYTE PTR DS:,AL
00401A30|.880D F3824000 MOV BYTE PTR DS:,CL
00401A36|.8815 F4824000 MOV BYTE PTR DS:,DL
00401A3C|.E8 DF350000 CALL ccccc.00405020
00401A41|.99 CDQ
00401A42|.B9 A0860100 MOV ECX,186A0
00401A47|.F7F9 IDIV ECX
00401A49|.B9 0A000000 MOV ECX,0A
00401A4E|.BE 06000000 MOV ESI,6
00401A53|.8BC2 MOV EAX,EDX
00401A55|.99 CDQ
00401A56|.F7F9 IDIV ECX
00401A58|.80C2 41 ADD DL,41
00401A5B|.8815 F5824000 MOV BYTE PTR DS:,DL
00401A61|>E8 AA350000 /CALL <JMP.&MSVCR71.rand> ; [rand
00401A66|.99 |CDQ
00401A67|.B9 1A000000 |MOV ECX,1A
00401A6C|.F7F9 |IDIV ECX
00401A6E|.80C2 41 |ADD DL,41
00401A71|.8896 F0824000 |MOV BYTE PTR DS:,DL
00401A77|.46 |INC ESI
00401A78|.83FE 14 |CMP ESI,14
00401A7B|.^ 7C E4 \JL SHORT ccccc.00401A61
00401A7D|.5E POP ESI
00401A7E|.5F POP EDI
00401A7F|.5D POP EBP
00401A80|.B8 01000000 MOV EAX,1
00401A85|.5B POP EBX
00401A86|.81C4 14010000 ADD ESP,114
00401A8C\.C3 RETN
页:
[1]