好友
阅读权限10
听众
最后登录1970-1-1
|
我是人民币
发表于 2014-5-20 21:24
前几天sqlbk牛逼轰轰的在精易上发了反调试模块2.0,声称有强大的硬盘逻辑锁。
如果电脑被加了锁,重启后,显示屏上有几个鲜红的大字,po jie zhe !!!
新手遇到这种情况只有找sqlbk要密码,或者干脆重新分区然后装系统,这样的话,损失就大了。
根据sqlbk群里的有人透露,sqlbk的硬盘逻辑锁是花钱在别人那里买的。
今天新注册了吾爱的号,没事就分析了一下具体实现原理,和破解方案。
--------------------------------------------------------------------------------
sqlbk声称有强大的OD检测,可以检测99%的OD。
sqlbk在群里发了一个简单的CM,我已经放在压缩包里。
用OD的字符串搜索,居然搜索出如此奇葩的东西:
注意这里,
地址=004871E0
反汇编=mov eax,防破解成.004FD75A
文本字符串=\\.\\physicaldrive0
大家可能已经猜的八九不离10 用 \\.\\physicaldrive0 来读写硬盘,而360正好对这里不管~
这一下就方便多了,Hook CreateFileA 或 CreateFileW 不就好了吗?
但是这样仍旧麻烦。
把目光往上看,"密码不可以为空"
跟进去。
[Asm] 纯文本查看 复制代码 00486EAC |. 6A 00 push 0x0
00486EAE |. 6A 00 push 0x0
00486EB0 |. 6A 00 push 0x0
00486EB2 |. 68 01030080 push 0x80000301
00486EB7 |. 6A 00 push 0x0
00486EB9 |. 68 00000000 push 0x0
00486EBE |. 68 04000080 push 0x80000004
00486EC3 |. 6A 00 push 0x0
00486EC5 |. 68 1CD54F00 push 防破解成.004FD51C ; 密码不可以为空的!!
00486ECA |. 68 03000000 push 0x3
00486ECF |. BB F0034900 mov ebx,防破解成.004903F0
00486ED4 |. E8 07830000 call 防破解成.0048F1E0
这里大概是在调用易语言的信息框显示信息把!
所以往上找,最后跟到了函数的首部,
[Asm] 纯文本查看 复制代码 00486DEF /$ 55 push ebp
00486DF0 |. 8BEC mov ebp,esp
00486DF2 |. 81EC 20000000 sub esp,0x20
00486DF8 C745 FC 00000>mov dword ptr ss:[ebp-0x4],0x0
00486DFF |. C745 F8 00000>mov [local.2],0x0
00486E06 |. C745 F4 00000>mov [local.3],0x0
00486E0D |. C745 F0 00000>mov [local.4],0x0
00486E14 |. C745 FC 01000>mov [local.1],0x1
00486E1B |. 837D FC 01 cmp [local.1],0x1
00486E1F 0F85 E8020000 jnz 防破解成.0048710D
00486E25 |. FF45 FC inc [local.1]
00486E28 |. 68 04000080 push 0x80000004
00486E2D |. 6A 00 push 0x0
00486E2F |. 8B5D 08 mov ebx,[arg.1]
00486E32 |. 8B03 mov eax,dword ptr ds:[ebx]
00486E34 |. 85C0 test eax,eax
00486E36 |. 75 05 jnz X防破解成.00486E3D
用鼠标选中 00486E1F 0F85 E8020000 jnz 防破解成.0048710D 这一行,借助吾爱的OD,很清晰的可以看见,他跳过了一段很长的地方。
再找到目的地,发现已经到了尾部,所以 jmp 过去。
硬盘逻辑锁这一强大的暗庄就被一个简单的jmp解决。
返回到上层调用,小心翼翼的一步一步跟踪下去,发现了一些提升进程权限的代码,所以后面他可能要干一些坏事。
继续走,最后在这个附近你可能要格外的小心,
[Asm] 纯文本查看 复制代码 004D99A1 . /74 02 je X防破解成.004D99A5
004D99A3 . |0C 04 or al,0x4
004D99A5 \6A 00 push 0x0 ; /Reserved = 0
004D99A7 50 push eax ; |Options
004D99A8 FF15 ECB34F00 call dword ptr ds:[<&USER32.ExitWindowsEx>] ; \ExitWindowsEx
这段代码不比过多的解释,关机。
跳过调用,这个模块的反调试就彻底被损坏了,随心所欲把,鄙视模块作者,源码居然想卖500多~
研究了一下加锁函数,
反汇编如下:
[Asm] 纯文本查看 复制代码 00486DEF /$ 55 push ebp
00486DF0 |. 8BEC mov ebp,esp
00486DF2 |. 81EC 20000000 sub esp,0x20
00486DF8 C745 FC 00000>mov dword ptr ss:[ebp-0x4],0x0
00486DFF |. C745 F8 00000>mov [local.2],0x0
00486E06 |. C745 F4 00000>mov [local.3],0x0
00486E0D |. C745 F0 00000>mov [local.4],0x0
00486E14 |. C745 FC 01000>mov [local.1],0x1
00486E1B |. 837D FC 01 cmp [local.1],0x1
00486E1F 0F85 E8020000 jnz 防破解成.0048710D
00486E25 |. FF45 FC inc [local.1]
00486E28 |. 68 04000080 push 0x80000004
00486E2D |. 6A 00 push 0x0
00486E2F |. 8B5D 08 mov ebx,[arg.1]
00486E32 |. 8B03 mov eax,dword ptr ds:[ebx]
00486E34 |. 85C0 test eax,eax
00486E36 |. 75 05 jnz X防破解成.00486E3D
00486E38 |. B8 4BD24F00 mov eax,防破解成.004FD24B
00486E3D |> 50 push eax
00486E3E |. 68 01000000 push 0x1
00486E43 |. BB D0FD4800 mov ebx,防破解成.0048FDD0
00486E48 |. E8 93830000 call 防破解成.0048F1E0
00486E4D |. 83C4 10 add esp,0x10
00486E50 |. 8945 EC mov [local.5],eax
00486E53 |. 8B45 EC mov eax,[local.5]
00486E56 |. 50 push eax
00486E57 |. 8B5D F8 mov ebx,[local.2]
00486E5A |. 85DB test ebx,ebx
00486E5C |. 74 09 je X防破解成.00486E67
00486E5E |. 53 push ebx
00486E5F |. E8 64830000 call 防破解成.0048F1C8
00486E64 |. 83C4 04 add esp,0x4
00486E67 |> 58 pop eax
00486E68 |. 8945 F8 mov [local.2],eax
00486E6B |. B8 13D54F00 mov eax,防破解成.004FD513
00486E70 |. 33C9 xor ecx,ecx
00486E72 |. 85C0 test eax,eax
00486E74 |. 74 03 je X防破解成.00486E79
00486E76 |. 8B48 04 mov ecx,dword ptr ds:[eax+0x4]
00486E79 |> 51 push ecx
00486E7A |. 83C0 08 add eax,0x8
00486E7D |. 50 push eax
00486E7E |. 8B45 F8 mov eax,[local.2]
00486E81 |. 33DB xor ebx,ebx
00486E83 |. 85C0 test eax,eax
00486E85 |. 74 03 je X防破解成.00486E8A
00486E87 |. 8B58 04 mov ebx,dword ptr ds:[eax+0x4]
00486E8A |> 83C0 08 add eax,0x8
00486E8D |. 50 push eax
00486E8E |. 3BD9 cmp ebx,ecx
00486E90 |. B8 01000000 mov eax,0x1
00486E95 |. 75 0A jnz X防破解成.00486EA1
00486E97 |. 48 dec eax
00486E98 |. 85C9 test ecx,ecx
00486E9A |. 74 05 je X防破解成.00486EA1
00486E9C |. E8 A2FEFFFF call 防破解成.00486D43
00486EA1 |> 83C4 0C add esp,0xC
00486EA4 |. 85C0 test eax,eax
00486EA6 |. 0F85 35000000 jnz 防破解成.00486EE1
00486EAC |. 6A 00 push 0x0
00486EAE |. 6A 00 push 0x0
00486EB0 |. 6A 00 push 0x0
00486EB2 |. 68 01030080 push 0x80000301
00486EB7 |. 6A 00 push 0x0
00486EB9 |. 68 00000000 push 0x0
00486EBE |. 68 04000080 push 0x80000004
00486EC3 |. 6A 00 push 0x0
00486EC5 |. 68 1CD54F00 push 防破解成.004FD51C ; 密码不可以为空的!!
00486ECA |. 68 03000000 push 0x3
00486ECF |. BB F0034900 mov ebx,防破解成.004903F0
00486ED4 |. E8 07830000 call 防破解成.0048F1E0
00486ED9 |. 83C4 28 add esp,0x28
00486EDC |. E9 55020000 jmp 防破解成.00487136
00486EE1 |> 68 05000080 push 0x80000005
00486EE6 |. 6A 00 push 0x0
00486EE8 |. 8B45 F8 mov eax,[local.2]
00486EEB |. 85C0 test eax,eax
00486EED |. 75 05 jnz X防破解成.00486EF4
00486EEF |. B8 73D24F00 mov eax,防破解成.004FD273
00486EF4 |> 50 push eax
00486EF5 |. 68 01000000 push 0x1
00486EFA |. BB 50F34800 mov ebx,防破解成.0048F350
00486EFF |. E8 DC820000 call 防破解成.0048F1E0
00486F04 |. 83C4 10 add esp,0x10
00486F07 |. 8945 EC mov [local.5],eax
00486F0A |. 68 05000080 push 0x80000005
00486F0F |. 6A 00 push 0x0
00486F11 |. 8B45 F8 mov eax,[local.2]
00486F14 |. 85C0 test eax,eax
00486F16 |. 75 05 jnz X防破解成.00486F1D
00486F18 |. B8 73D24F00 mov eax,防破解成.004FD273
00486F1D |> 50 push eax
00486F1E |. 68 01030080 push 0x80000301
00486F23 |. 6A 00 push 0x0
00486F25 |. FF75 EC push [local.5]
00486F28 |. 68 01030080 push 0x80000301
00486F2D |. 6A 00 push 0x0
00486F2F |. 68 D9000000 push 0xD9
00486F34 |. 68 05000080 push 0x80000005
00486F39 |. 6A 00 push 0x0
00486F3B |. 68 31D54F00 push 防破解成.004FD531
00486F40 |. 68 04000000 push 0x4
00486F45 |. BB 00004900 mov ebx,防破解成.00490000
00486F4A |. E8 91820000 call 防破解成.0048F1E0
00486F4F |. 83C4 34 add esp,0x34
00486F52 |. 8945 E8 mov [local.6],eax
00486F55 |. 8B45 E8 mov eax,[local.6]
00486F58 |. 50 push eax
00486F59 |. 8B5D F4 mov ebx,[local.3]
00486F5C |. 85DB test ebx,ebx
00486F5E |. 74 09 je X防破解成.00486F69
00486F60 |. 53 push ebx
00486F61 |. E8 62820000 call 防破解成.0048F1C8
00486F66 |. 83C4 04 add esp,0x4
00486F69 |> 58 pop eax
00486F6A |. 8945 F4 mov [local.3],eax
00486F6D |. 68 05000080 push 0x80000005
00486F72 |. 6A 00 push 0x0
00486F74 |. 8B45 F8 mov eax,[local.2]
00486F77 |. 85C0 test eax,eax
00486F79 |. 75 05 jnz X防破解成.00486F80
00486F7B |. B8 73D24F00 mov eax,防破解成.004FD273
00486F80 |> 50 push eax
00486F81 |. 68 01000000 push 0x1
00486F86 |. BB 50F34800 mov ebx,防破解成.0048F350
00486F8B |. E8 50820000 call 防破解成.0048F1E0
00486F90 |. 83C4 10 add esp,0x10
00486F93 |. 68 01030080 push 0x80000301
00486F98 |. 6A 00 push 0x0
00486F9A |. 50 push eax
00486F9B |. 68 01000000 push 0x1
00486FA0 |. BB F0F84800 mov ebx,防破解成.0048F8F0
00486FA5 |. E8 36820000 call 防破解成.0048F1E0
00486FAA |. 83C4 10 add esp,0x10
00486FAD |. 68 01010080 push 0x80000101
00486FB2 |. 6A 00 push 0x0
00486FB4 |. 50 push eax
00486FB5 |. 68 01000000 push 0x1
00486FBA |. BB D0FD4800 mov ebx,防破解成.0048FDD0
00486FBF |. E8 1C820000 call 防破解成.0048F1E0
00486FC4 |. 83C4 10 add esp,0x10
00486FC7 |. 8945 E4 mov [local.7],eax
00486FCA |. 68 05000080 push 0x80000005
00486FCF |. 6A 00 push 0x0
00486FD1 |. 8B45 E4 mov eax,[local.7]
00486FD4 |. 85C0 test eax,eax
00486FD6 |. 75 05 jnz X防破解成.00486FDD
00486FD8 |. B8 73D24F00 mov eax,防破解成.004FD273
00486FDD |> 50 push eax
00486FDE |. 68 01030080 push 0x80000301
00486FE3 |. 6A 00 push 0x0
00486FE5 |. 68 01000000 push 0x1
00486FEA |. 68 01030080 push 0x80000301
00486FEF |. 6A 00 push 0x0
00486FF1 |. 68 D8000000 push 0xD8
00486FF6 |. 68 05000080 push 0x80000005
00486FFB |. 6A 00 push 0x0
00486FFD |. 8B45 F4 mov eax,[local.3]
00487000 |. 85C0 test eax,eax
00487002 |. 75 05 jnz X防破解成.00487009
00487004 |. B8 73D24F00 mov eax,防破解成.004FD273
00487009 |> 50 push eax
0048700A |. 68 04000000 push 0x4
0048700F |. BB 00004900 mov ebx,防破解成.00490000
00487014 |. E8 C7810000 call 防破解成.0048F1E0
00487019 |. 83C4 34 add esp,0x34
0048701C |. 8945 E0 mov [local.8],eax
0048701F |. 8B5D E4 mov ebx,[local.7]
00487022 |. 85DB test ebx,ebx
00487024 |. 74 09 je X防破解成.0048702F
00487026 |. 53 push ebx
00487027 |. E8 9C810000 call 防破解成.0048F1C8
0048702C |. 83C4 04 add esp,0x4
0048702F |> 8B45 E0 mov eax,[local.8]
00487032 |. 50 push eax
00487033 |. 8B5D F4 mov ebx,[local.3]
00487036 |. 85DB test ebx,ebx
00487038 |. 74 09 je X防破解成.00487043
0048703A |. 53 push ebx
0048703B |. E8 88810000 call 防破解成.0048F1C8
00487040 |. 83C4 04 add esp,0x4
00487043 |> 58 pop eax
00487044 |. 8945 F4 mov [local.3],eax
00487047 |. 68 01000000 push 0x1
0048704C |. 68 00000000 push 0x0
00487051 |. E8 16010000 call 防破解成.0048716C
00487056 |. 8945 EC mov [local.5],eax
00487059 |. 8B45 EC mov eax,[local.5]
0048705C |. 50 push eax
0048705D |. 8B5D F0 mov ebx,[local.4]
00487060 |. 85DB test ebx,ebx
00487062 |. 74 09 je X防破解成.0048706D
00487064 |. 53 push ebx
00487065 |. E8 5E810000 call 防破解成.0048F1C8
0048706A |. 83C4 04 add esp,0x4
0048706D |> 58 pop eax
0048706E |. 8945 F0 mov [local.4],eax
00487071 |. B8 13D54F00 mov eax,防破解成.004FD513
00487076 |. 33C9 xor ecx,ecx
00487078 |. 85C0 test eax,eax
0048707A |. 74 03 je X防破解成.0048707F
0048707C |. 8B48 04 mov ecx,dword ptr ds:[eax+0x4]
0048707F |> 51 push ecx
00487080 |. 83C0 08 add eax,0x8
00487083 |. 50 push eax
00487084 |. 8B45 F0 mov eax,[local.4]
00487087 |. 33DB xor ebx,ebx
00487089 |. 85C0 test eax,eax
0048708B |. 74 03 je X防破解成.00487090
0048708D |. 8B58 04 mov ebx,dword ptr ds:[eax+0x4]
00487090 |> 83C0 08 add eax,0x8
00487093 |. 50 push eax
00487094 |. 3BD9 cmp ebx,ecx
00487096 |. B8 01000000 mov eax,0x1
0048709B |. 75 0A jnz X防破解成.004870A7
0048709D |. 48 dec eax
0048709E |. 85C9 test ecx,ecx
004870A0 |. 74 05 je X防破解成.004870A7
004870A2 |. E8 9CFCFFFF call 防破解成.00486D43
004870A7 |> 83C4 0C add esp,0xC
004870AA |. 85C0 test eax,eax
004870AC |. 0F85 35000000 jnz 防破解成.004870E7
004870B2 |. 6A 00 push 0x0
004870B4 |. 6A 00 push 0x0
004870B6 |. 6A 00 push 0x0
004870B8 |. 68 01030080 push 0x80000301
004870BD |. 6A 00 push 0x0
004870BF |. 68 00000000 push 0x0
004870C4 |. 68 04000080 push 0x80000004
004870C9 |. 6A 00 push 0x0
004870CB |. 68 39D74F00 push 防破解成.004FD739 ; 读取原来引导扇区失败!!
004870D0 |. 68 03000000 push 0x3
004870D5 |. BB F0034900 mov ebx,防破解成.004903F0
004870DA |. E8 01810000 call 防破解成.0048F1E0
004870DF |. 83C4 28 add esp,0x28
004870E2 |. E9 4F000000 jmp 防破解成.00487136
004870E7 |> 68 01000000 push 0x1
004870EC |. 68 02000000 push 0x2
004870F1 |. 8D45 F0 lea eax,[local.4]
004870F4 |. 50 push eax
004870F5 |. E8 ED020000 call 防破解成.004873E7
004870FA |. 68 01000000 push 0x1
004870FF |. 68 00000000 push 0x0
00487104 |. 8D45 F4 lea eax,[local.3]
00487107 |. 50 push eax
00487108 |. E8 DA020000 call 防破解成.004873E7
0048710D |> 6A 00 push 0x0
0048710F |. 6A 00 push 0x0
00487111 |. 6A 00 push 0x0
00487113 |. 68 01030080 push 0x80000301
00487118 |. 6A 00 push 0x0
0048711A |. 68 02000000 push 0x2
0048711F |. 68 02000000 push 0x2
00487124 |. B8 06000000 mov eax,0x6
00487129 |. BB F0984D00 mov ebx,防破解成.004D98F0
0048712E |. E8 B9800000 call 防破解成.0048F1EC
00487133 |. 83C4 1C add esp,0x1C
00487136 |> 8B5D F8 mov ebx,[local.2]
00487139 |. 85DB test ebx,ebx
0048713B |. 74 09 je X防破解成.00487146
0048713D |. 53 push ebx
0048713E |. E8 85800000 call 防破解成.0048F1C8
00487143 |. 83C4 04 add esp,0x4
00487146 |> 8B5D F4 mov ebx,[local.3]
00487149 |. 85DB test ebx,ebx
0048714B |. 74 09 je X防破解成.00487156
0048714D |. 53 push ebx
0048714E |. E8 75800000 call 防破解成.0048F1C8
00487153 |. 83C4 04 add esp,0x4
00487156 |> 8B5D F0 mov ebx,[local.4]
00487159 |. 85DB test ebx,ebx
0048715B |. 74 09 je X防破解成.00487166
0048715D |. 53 push ebx
0048715E |. E8 65800000 call 防破解成.0048F1C8
00487163 |. 83C4 04 add esp,0x4
00487166 |> 8BE5 mov esp,ebp
00487168 |. 5D pop ebp
00487169 \. C2 0400 retn 0x4
实现的功能大概是,先 判断参数1是否为空,然后进行易语言的字节集替换,大概是在修改锁的一些地方,然后把原来的MBR读取到内存,然后,
写的 逻辑2扇区,然后把锁写到MBR,最后退出。
锁的代码大家可以用WinHex提取出来,然后用IDA研究一下把。
最后, 锁的密码是: bukudie00369
Desktop.rar
(651.06 KB, 下载次数: 223)
|
免费评分
-
查看全部评分
|