各位大侠!请求帮助小弟!急急急!

ballfun 2007-02-10 02:56:15
下面这段汇编代码如何转换成pascal语言
006912B8 55 push ebp
006912B9 8BEC mov ebp, esp
006912BB 83C4D8 add esp, -$28
006912BE 53 push ebx
006912BF 56 push esi
006912C0 57 push edi
006912C1 33C9 xor ecx, ecx
006912C3 894DD8 mov [ebp-$28], ecx
006912C6 894DDC mov [ebp-$24], ecx
006912C9 8BF8 mov edi, eax
006912CB 33C0 xor eax, eax
006912CD 55 push ebp

* Possible String Reference to: '轫-?腓_^[嬪]?*'
|
006912CE 68CE146900 push $006914CE

***** TRY
|
006912D3 64FF30 push dword ptr fs:[eax]
006912D6 648920 mov fs:[eax], esp
006912D9 80BF9703000000 cmp byte ptr [edi+$0397], $00
006912E0 7516 jnz 006912F8

* Possible String Reference to: '没有指定文本文件或读入数据错误,无?
| ǖ既耄?
|
006912E2 B9E4146900 mov ecx, $006914E4
006912E7 B201 mov dl, $01

* Reference to class Exception
|
006912E9 A1B0AB4000 mov eax, dword ptr [$0040ABB0]

|
006912EE E8C9F1D7FF call 004104BC

* Reference to: system.@RaiseExcept;
|
006912F3 E8C030D7FF call 004043B8
006912F8 8B8764030000 mov eax, [edi+$0364]

* Reference to field Exception.OFFS_0047
|
006912FE 80784700 cmp byte ptr [eax+$47], $00
00691302 7434 jz 00691338
00691304 8D55DC lea edx, [ebp-$24]
00691307 8B87D4020000 mov eax, [edi+$02D4]

|
0069130D E8C644DBFF call 004457D8
00691312 8B45DC mov eax, [ebp-$24]
00691315 8945E0 mov [ebp-$20], eax
00691318 C645E40B mov byte ptr [ebp-$1C], $0B
0069131C 8D45E0 lea eax, [ebp-$20]
0069131F 50 push eax
00691320 6A00 push $00
...全文
233 点赞 收藏 3
写回复
3 条回复
切换为时间正序
当前发帖距今超过3年,不再开放新的回复
发表回复
江南一书生 2007-02-14
先看懂汇编的思路,再用高级语言重新把这个思路演绎出来,当然复杂的代码就做不到了。不可能有直接从汇编转化到高级语言的,要不然软件公司还能护着自己的源代码么
回复
ballfun 2007-02-10
* Reference to field Exception.OFFS_0234
|
00691433 8B9234020000 mov edx, [edx+$0234]
00691439 0355F0 add edx, [ebp-$10]
0069143C 4A dec edx
0069143D 4A dec edx
0069143E 3B45F4 cmp eax, [ebp-$0C]
00691441 7D03 jnl 00691446
00691443 8945F4 mov [ebp-$0C], eax
00691446 3B55EC cmp edx, [ebp-$14]
00691449 7D03 jnl 0069144E
0069144B 8955EC mov [ebp-$14], edx
0069144E 8B45F8 mov eax, [ebp-$08]
00691451 8B55F4 mov edx, [ebp-$0C]
00691454 2BD0 sub edx, eax
00691456 7C4E jl 006914A6
00691458 42 inc edx
00691459 8955E8 mov [ebp-$18], edx
0069145C 8945FC mov [ebp-$04], eax
0069145F 8B5DF0 mov ebx, [ebp-$10]
00691462 8B75EC mov esi, [ebp-$14]
00691465 2BF3 sub esi, ebx
00691467 7C35 jl 0069149E
00691469 46 inc esi
0069146A 8D45D8 lea eax, [ebp-$28]
0069146D 50 push eax
0069146E 8BCB mov ecx, ebx
00691470 2B4DF0 sub ecx, dword ptr [ebp-$10]
00691473 41 inc ecx
00691474 8B55FC mov edx, [ebp-$04]
00691477 2B55F8 sub edx, dword ptr [ebp-$08]
0069147A 42 inc edx
0069147B 8B877C030000 mov eax, [edi+$037C]

* Reference to : TStringSparseList._PROC_004CD5D8()
|
00691481 E852C1E3FF call 004CD5D8
00691486 8B45D8 mov eax, [ebp-$28]
00691489 50 push eax
0069148A 8B8788030000 mov eax, [edi+$0388]
00691490 8BCB mov ecx, ebx
00691492 8B55FC mov edx, [ebp-$04]

|
00691495 E882D1E6FF call 004FE61C
0069149A 43 inc ebx
0069149B 4E dec esi
0069149C 75CC jnz 0069146A
0069149E FF45FC inc dword ptr [ebp-$04]
006914A1 FF4DE8 dec dword ptr [ebp-$18]
006914A4 75B9 jnz 0069145F
006914A6 C7873402000001000000 mov dword ptr [edi+$0234], $00000001
006914B0 33C0 xor eax, eax
006914B2 5A pop edx
006914B3 59 pop ecx
006914B4 59 pop ecx
006914B5 648910 mov fs:[eax], edx

****** FINALLY
|

* Possible String Reference to: '_^[嬪]?*'
|
006914B8 68D5146900 push $006914D5
006914BD 8D45D8 lea eax, [ebp-$28]

* Reference to: system.@LStrClr(String;String);
|
006914C0 E8DF35D7FF call 00404AA4
006914C5 8D45DC lea eax, [ebp-$24]

* Reference to: system.@LStrClr(String;String);
|
006914C8 E8D735D7FF call 00404AA4
006914CD C3 ret


* Reference to: system.@HandleFinally;
|
006914CE E9ED2DD7FF jmp 004042C0
006914D3 EBE8 jmp 006914BD

****** END
|
006914D5 5F pop edi
006914D6 5E pop esi
006914D7 5B pop ebx
006914D8 8BE5 mov esp, ebp
006914DA 5D pop ebp
006914DB C3 ret

回复
ballfun 2007-02-10
* Possible String Reference to: '文本文件%s格式与指定格式不相符,无?
| ǖ既耄?
|
00691322 B918156900 mov ecx, $00691518
00691327 B201 mov dl, $01

* Reference to class Exception
|
00691329 A1B0AB4000 mov eax, dword ptr [$0040ABB0]

|
0069132E E8D1F1D7FF call 00410504

* Reference to: system.@RaiseExcept;
|
00691333 E88030D7FF call 004043B8
00691338 8B8740030000 mov eax, [edi+$0340]

* Reference to : TTabStrings._PROC_00491924()
|
0069133E E8E105E0FF call 00491924
00691343 0FBFC0 movsx eax, ax
00691346 8945F8 mov [ebp-$08], eax
00691349 8B873C030000 mov eax, [edi+$033C]

* Reference to : TTabStrings._PROC_00491924()
|
0069134F E8D005E0FF call 00491924
00691354 0FBFC0 movsx eax, ax
00691357 8945F0 mov [ebp-$10], eax
0069135A 8B8748030000 mov eax, [edi+$0348]

* Reference to : TTabStrings._PROC_00491924()
|
00691360 E8BF05E0FF call 00491924
00691365 0FBFC0 movsx eax, ax
00691368 8B9F7C030000 mov ebx, [edi+$037C]
0069136E 8B9304020000 mov edx, [ebx+$0204]
00691374 4A dec edx
00691375 3BC2 cmp eax, edx
00691377 7E13 jle 0069138C
00691379 668B9304020000 mov dx, word ptr [ebx+$0204]
00691380 4A dec edx
00691381 8B8748030000 mov eax, [edi+$0348]

* Reference to : TTabStrings._PROC_00491AC4()
|
00691387 E83807E0FF call 00491AC4
0069138C 8B8744030000 mov eax, [edi+$0344]

* Reference to : TTabStrings._PROC_00491924()
|
00691392 E88D05E0FF call 00491924
00691397 0FBFC0 movsx eax, ax
0069139A 8B9F7C030000 mov ebx, [edi+$037C]
006913A0 8B9334020000 mov edx, [ebx+$0234]
006913A6 4A dec edx
006913A7 3BC2 cmp eax, edx
006913A9 7E13 jle 006913BE
006913AB 668B9334020000 mov dx, word ptr [ebx+$0234]
006913B2 4A dec edx
006913B3 8B8744030000 mov eax, [edi+$0344]

* Reference to : TTabStrings._PROC_00491AC4()
|
006913B9 E80607E0FF call 00491AC4
006913BE 8B8748030000 mov eax, [edi+$0348]

* Reference to : TTabStrings._PROC_00491924()
|
006913C4 E85B05E0FF call 00491924
006913C9 0FBFC0 movsx eax, ax
006913CC 0345F8 add eax, [ebp-$08]
006913CF 48 dec eax
006913D0 8945F4 mov [ebp-$0C], eax
006913D3 8B8744030000 mov eax, [edi+$0344]

* Reference to : TTabStrings._PROC_00491924()
|
006913D9 E84605E0FF call 00491924
006913DE 0FBFC0 movsx eax, ax
006913E1 0345F0 add eax, [ebp-$10]
006913E4 48 dec eax
006913E5 8945EC mov [ebp-$14], eax
006913E8 8B45F8 mov eax, [ebp-$08]
006913EB 8B55F4 mov edx, [ebp-$0C]
006913EE 2BD0 sub edx, eax
006913F0 7C30 jl 00691422
006913F2 42 inc edx
006913F3 8955E8 mov [ebp-$18], edx
006913F6 8945FC mov [ebp-$04], eax
006913F9 8B5DF0 mov ebx, [ebp-$10]
006913FC 8B75EC mov esi, [ebp-$14]
006913FF 2BF3 sub esi, ebx
00691401 7C17 jl 0069141A
00691403 46 inc esi
00691404 6A00 push $00
00691406 8B8788030000 mov eax, [edi+$0388]
0069140C 8BCB mov ecx, ebx
0069140E 8B55FC mov edx, [ebp-$04]

|
00691411 E806D2E6FF call 004FE61C
00691416 43 inc ebx
00691417 4E dec esi
00691418 75EA jnz 00691404
0069141A FF45FC inc dword ptr [ebp-$04]
0069141D FF4DE8 dec dword ptr [ebp-$18]
00691420 75D7 jnz 006913F9
00691422 8B977C030000 mov edx, [edi+$037C]

* Reference to field Exception.OFFS_0204
|
00691428 8B8204020000 mov eax, [edx+$0204]
0069142E 0345F8 add eax, [ebp-$08]
00691431 48 dec eax
00691432 48 dec eax

回复
相关推荐
发帖
汇编语言
创建于2007-08-27

2.0w+

社区成员

汇编语言(Assembly Language)是任何一种用于电子计算机、微处理器、微控制器或其他可编程器件的低级语言,亦称为符号语言。
申请成为版主
帖子事件
创建了帖子
2007-02-10 02:56
社区公告
暂无公告