UltraEdit 16.10.0.1028,是一款集成了多种功能的文件二进制查看编辑工具。
官方发布30天免费使用版,如果要正式版需要$60。闲来无事,拿来破解了一下。
系统:Windows 7
工具:OllyDBG1.10 汉化第二版
1、因为看此软件主程序有.tls段,为了确定在main()入口之前,是否通过tls回调函数执行了反破解保护,修改一下OD的系统设置“选项->调试设置->事件->第一次中断于->系统断点”,然后加载该软件。待停住后,在Uedit32.exe模块的.text段设置访问断点,然后F9运行。
2、在 00ACB92B > $ E8 8E040200 CALL Uedit32.00AEBDBE 此处停了下来。发现这就是函数的入口点了。说明此时并没有执行反破解保护。程序的入口大致是这样的:
00AEBDF4 |. 50 PUSH EAX ; /pFileTime
00AEBDF5 |. FF15 A8A4CF00 CALL DWORD PTR DS:[<&KERNEL32.GetSystemT>; \GetSystemTimeAsFileTime 取得系统日期和时间
00AEBDFB |. 8B75 FC MOV ESI,DWORD PTR SS:[EBP-4]
00AEBDFE |. 3375 F8 XOR ESI,DWORD PTR SS:[EBP-8]
00AEBE01 |. FF15 9CA6CF00 CALL DWORD PTR DS:[<&KERNEL32.GetCurrent>; [GetCurrentProcessId
00AEBE07 |. 33F0 XOR ESI,EAX
00AEBE09 |. FF15 D0A6CF00 CALL DWORD PTR DS:[<&KERNEL32.GetCurrent>; [GetCurrentThreadId
00AEBE0F |. 33F0 XOR ESI,EAX
00AEBE11 |. FF15 DCA6CF00 CALL DWORD PTR DS:[<&KERNEL32.GetTickCou>; [GetTickCount 取得CPU运行时间,
00AEBE17 |. 33F0 XOR ESI,EAX
00AEBE19 |. 8D45 F0 LEA EAX,DWORD PTR SS:[EBP-10]
00AEBE1C |. 50 PUSH EAX ; /pPerformanceCount
00AEBE1D |. FF15 18A4CF00 CALL DWORD PTR DS:[<&KERNEL32.QueryPerfo>; \QueryPerformanceCounter 取得精确系统时间
00AEBE23 |. 8B45 F4 MOV EAX,DWORD PTR SS:[EBP-C]
00AEBE26 |. 3345 F0 XOR EAX,DWORD PTR SS:[EBP-10]
00AEBE29 |. 33F0 XOR ESI,EAX ; 将上面取得的值都异或在一起,作为一个唯一标志值
00AEBE2B |. 3BF7 CMP ESI,EDI
00AEBE2D |. 75 07 JNZ SHORT Uedit32.00AEBE36
00AEBE2F |. BE 4FE640BB MOV ESI,BB40E64F
00AEBE34 |. EB 0B JMP SHORT Uedit32.00AEBE41
00AEBE36 |> 85F3 TEST EBX,ESI
00AEBE38 |. 75 07 JNZ SHORT Uedit32.00AEBE41
00AEBE3A |. 8BC6 MOV EAX,ESI
00AEBE3C |. C1E0 10 SHL EAX,10
00AEBE3F |. 0BF0 OR ESI,EAX
00AEBE41 |> 8935 B45C0101 MOV DWORD PTR DS:[1015CB4],ESI ; 将这串标志值写到[1015CB4],用于后面的频繁比较
00AEBE47 |. F7D6 NOT ESI
00AEBE49 |. 8935 B85C0101 MOV DWORD PTR DS:[1015CB8],ESI
00AEBE4F |. 5E POP ESI
00AEBE50 |> 5F POP EDI
00AEBE51 |. 5B POP EBX
00AEBE52 |. C9 LEAVE
00AEBE53 \. C3 RETN
00ABA020 $ 3B0D B45C0101 CMP ECX,DWORD PTR DS:[1015CB4] ; 比较标志,防止破解.如果不相等就跳转到AD599C
00ABA026 . 75 02 JNZ SHORT Uedit32.00ABA02A
00ABA028 . F3: PREFIX REP: ; 多余的前缀
00ABA029 . C3 RETN
00ABA02A > E9 6DB90100 JMP Uedit32.00AD599C
00AD599C > \8BFF MOV EDI,EDI
00AD599E /. 55 PUSH EBP
00AD599F |. 8BEC MOV EBP,ESP
00AD59A1 |. 81EC 28030000 SUB ESP,328
00AD59A7 |. A3 C0B40701 MOV DWORD PTR DS:[107B4C0],EAX
00AD59AC |. 890D BCB40701 MOV DWORD PTR DS:[107B4BC],ECX
00AD59B2 |. 8915 B8B40701 MOV DWORD PTR DS:[107B4B8],EDX
00AD59B8 |. 891D B4B40701 MOV DWORD PTR DS:[107B4B4],EBX
00AD59BE |. 8935 B0B40701 MOV DWORD PTR DS:[107B4B0],ESI
00AD59C4 |. 893D ACB40701 MOV DWORD PTR DS:[107B4AC],EDI
00AD59CA |. 66:8C15 D8B40>MOV WORD PTR DS:[107B4D8],SS
00AD59D1 |. 66:8C0D CCB40>MOV WORD PTR DS:[107B4CC],CS
00AD59D8 |. 66:8C1D A8B40>MOV WORD PTR DS:[107B4A8],DS
00AD59DF |. 66:8C05 A4B40>MOV WORD PTR DS:[107B4A4],ES
00AD59E6 |. 66:8C25 A0B40>MOV WORD PTR DS:[107B4A0],FS
00AD59ED |. 66:8C2D 9CB40>MOV WORD PTR DS:[107B49C],GS
00AD59F4 |. 9C PUSHFD
00AD59F5 |. 8F05 D0B40701 POP DWORD PTR DS:[107B4D0]
00AD59FB |. 8B45 00 MOV EAX,DWORD PTR SS:[EBP]
00AD59FE |. A3 C4B40701 MOV DWORD PTR DS:[107B4C4],EAX
00AD5A03 |. 8B45 04 MOV EAX,DWORD PTR SS:[EBP+4]
00AD5A06 |. A3 C8B40701 MOV DWORD PTR DS:[107B4C8],EAX
00AD5A0B |. 8D45 08 LEA EAX,DWORD PTR SS:[EBP+8]
00AD5A0E |. A3 D4B40701 MOV DWORD PTR DS:[107B4D4],EAX
00AD5A13 |. 8B85 E0FCFFFF MOV EAX,DWORD PTR SS:[EBP-320]
00AD5A19 |. C705 10B40701>MOV DWORD PTR DS:[107B410],10001
00AD5A23 |. A1 C8B40701 MOV EAX,DWORD PTR DS:[107B4C8]
00AD5A28 |. A3 C4B30701 MOV DWORD PTR DS:[107B3C4],EAX
00AD5A2D |. C705 B8B30701>MOV DWORD PTR DS:[107B3B8],C0000409
00AD5A37 |. C705 BCB30701>MOV DWORD PTR DS:[107B3BC],1
00AD5A41 |. A1 B45C0101 MOV EAX,DWORD PTR DS:[1015CB4]
00AD5A46 |. 8985 D8FCFFFF MOV DWORD PTR SS:[EBP-328],EAX
00AD5A4C |. A1 B85C0101 MOV EAX,DWORD PTR DS:[1015CB8]
00AD5A51 |. 8985 DCFCFFFF MOV DWORD PTR SS:[EBP-324],EAX
00AD5A57 |. FF15 00A5CF00 CALL DWORD PTR DS:[<&KERNEL32.IsDebugger>; [判断当前是否处在Debugger模式
00AD5A5D |. A3 08B40701 MOV DWORD PTR DS:[107B408],EAX
00AD5A62 |. 6A 01 PUSH 1
00AD5A64 |. E8 CFF7FFFF CALL Uedit32.00AD5238
00AD5A69 |. 59 POP ECX
00AD5A6A |. 6A 00 PUSH 0 ; /pTopLevelFilter = NULL
00AD5A6C |. FF15 BCA7CF00 CALL DWORD PTR DS:[<&KERNEL32.SetUnhandl>; \SetUnhandledExceptionFilter 设置异常处理
00AD5A72 |. 68 90B1DD00 PUSH Uedit32.00DDB190 ; /pExceptionInfo = Uedit32.00DDB190
00AD5A77 |. FF15 E0A4CF00 CALL DWORD PTR DS:[<&KERNEL32.UnhandledE>; \UnhandledExceptionFilter
00AD5A7D |. 833D 08B40701>CMP DWORD PTR DS:[107B408],0
00AD5A84 |. 75 08 JNZ SHORT Uedit32.00AD5A8E
00AD5A86 |. 6A 01 PUSH 1
00AD5A88 |. E8 ABF7FFFF CALL Uedit32.00AD5238
00AD5A8D |. 59 POP ECX
00AD5A8E |> 68 090400C0 PUSH C0000409 ; /ExitCode = C0000409 (-1073740791.)
00AD5A93 |. FF15 C8A7CF00 CALL DWORD PTR DS:[<&KERNEL32.GetCurrent>; |[GetCurrentProcess
00AD5A99 |. 50 PUSH EAX ; |hProcess
00AD5A9A |. FF15 A4A4CF00 CALL DWORD PTR DS:[<&KERNEL32.TerminateP>; \TerninateProces 结束进程
00AD5AA0 |. C9 LEAVE
00AD5AA1 \. C3 RETN
[注意]传递专业知识、拓宽行业人脉——看雪讲师团队等你加入!