joyce8/EMBER2024-capa huggingface dataset:
Function at 0x406d20
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
push ebx
push esi
push edi
mov dword [ebp - 0xc], 0
mov dword [ebp - 4], 0
cmp dword [ebp + 0x10], 0
jne 0x406d47
xor eax, eax
jmp 0x406f09
mov eax, dword [ebp + 8]
mov edx, eax
and edx, 0x1f
imul edx, edx, 0x24
sar eax, 5
mov eax, dword [eax*4 + 0x430e14]
test byte [eax + edx + 4], 0x20
je 0x406d73
push 2
push 0
mov eax, dword [ebp + 8]
push eax
call fcn.00406c10
add esp, 0xc
mov eax, dword [ebp + 8]
mov edx, eax
and edx, 0x1f
imul edx, edx, 0x24
sar eax, 5
mov eax, dword [eax*4 + 0x430e14]
test byte [eax + edx + 4], 0x80
je 0x406e54
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x10], 0
jmp 0x406e40
lea edi, [ebp - 0x411]
jmp 0x406dc2
mov eax, esi
inc esi
mov bl, byte [eax]
cmp bl, 0xa
jne 0x406dbd
inc dword [ebp - 4]
mov eax, edi
inc edi
mov byte [eax], 0xd
mov eax, edi
inc edi
mov byte [eax], bl
lea eax, [ebp - 0x411]
mov edx, edi
sub edx, eax
cmp edx, 0x400
jge 0x406de2
mov eax, dword [ebp + 0xc]
mov edx, esi
sub edx, eax
mov eax, edx
cmp eax, dword [ebp + 0x10]
jb 0x406daa
push 0
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x411]
mov edx, edi
sub edx, eax
mov eax, edx
push eax
lea eax, [ebp - 0x411]
push eax
mov eax, dword [ebp + 8]
mov edx, eax
and edx, 0x1f
imul edx, edx, 0x24
sar eax, 5
mov eax, dword [eax*4 + 0x430e14]
mov eax, dword [eax + edx]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x406e35
mov eax, dword [ebp - 8]
add dword [ebp - 0xc], eax
lea edx, [ebp - 0x411]
mov ecx, edi
sub ecx, edx
cmp eax, ecx
jge 0x406e40
jmp 0x406e9d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
jmp 0x406e9d
mov eax, dword [ebp + 0xc]
mov edx, esi
sub edx, eax
mov eax, edx
cmp eax, dword [ebp + 0x10]
jb 0x406da2
jmp 0x406e9d
push 0
lea eax, [ebp - 8]
push eax
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp + 0xc]
push eax
mov eax, dword [ebp + 8]
mov edx, eax
and edx, 0x1f
imul edx, edx, 0x24
sar eax, 5
mov eax, dword [eax*4 + 0x430e14]
mov eax, dword [eax + edx]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x406e94
mov dword [ebp - 0x10], 0
mov eax, dword [ebp - 8]
mov dword [ebp - 0xc], eax
jmp 0x406e9d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0xc], 0
jne 0x406f03
cmp dword [ebp - 0x10], 0
je 0x406ecb
cmp dword [ebp - 0x10], 5
jne 0x406ebc
call fcn.00403dd0
mov dword [eax], 9
jmp 0x406ec6
mov eax, dword [ebp - 0x10]
push eax
call fcn.00403c70
pop ecx
or eax, 0xffffffff
jmp 0x406f09
mov eax, dword [ebp + 8]
mov edx, eax
and edx, 0x1f
imul edx, edx, 0x24
sar eax, 5
mov eax, dword [eax*4 + 0x430e14]
test byte [eax + edx + 4], 0x40
je 0x406ef3
mov eax, dword [ebp + 0xc]
cmp byte [eax], 0x1a
jne 0x406ef3
xor eax, eax
jmp 0x406f09
call fcn.00403dd0
mov dword [eax], 0x1c
or eax, 0xffffffff
jmp 0x406f09
mov eax, dword [ebp - 0xc]
sub eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4092e0
Capabilities:
Clear file content

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1014
call fcn.004097a0
push ebx
push esi
push edi
mov ebx, dword [ebp + 8]
mov dword [ebp - 4], 0
push 1
push 0
push ebx
call fcn.00406c10
add esp, 0xc
mov dword [ebp - 0xc], eax
cmp eax, 0xffffffff
je 0x409324
push 2
push 0
push ebx
call fcn.00406c10
add esp, 0xc
mov dword [ebp - 8], eax
cmp eax, 0xffffffff
jne 0x40932c
or eax, 0xffffffff
jmp 0x409420
mov eax, dword [ebp + 0xc]
mov esi, eax
sub esi, dword [ebp - 8]
test esi, esi
jle 0x4093d1
lea edx, [ebp - 0x1010]
mov ecx, 0x1000
xor eax, eax
push edi
mov edi, edx
rep stosb byte es:[edi], al
pop edi
mov eax, edx
push 0x8000
push ebx
call fcn.004097d0
add esp, 8
mov dword [ebp - 0x10], eax
cmp esi, 0x1000
jb 0x409376
mov dword [ebp - 0x1014], 0x1000
jmp 0x40937e
mov eax, esi
mov dword [ebp - 0x1014], eax
mov eax, dword [ebp - 0x1014]
push eax
lea eax, [ebp - 0x1010]
push eax
push ebx
call fcn.00406d20
add esp, 0xc
mov edi, eax
cmp eax, 0xffffffff
jne 0x4093b8
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x4093b2
call fcn.00403dd0
mov dword [eax], 0xd
or dword [ebp - 4], 0xffffffff
jmp 0x4093c2
mov eax, esi
sub eax, edi
mov esi, eax
test eax, eax
jg 0x409362
mov eax, dword [ebp - 0x10]
push eax
push ebx
call fcn.004097d0
add esp, 8
jmp 0x40940e
test esi, esi
jge 0x40940e
push 0
mov eax, dword [ebp + 0xc]
push eax
push ebx
call fcn.00406c10
add esp, 0xc
push ebx
call fcn.00407210
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
setne al
and eax, 1
dec eax
mov dword [ebp - 4], eax
cmp eax, 0xffffffff
jne 0x40940e
call fcn.00403dd0
mov dword [eax], 0xd
push 0
mov eax, dword [ebp - 0xc]
push eax
push ebx
call fcn.00406c10
add esp, 0xc
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4017f0
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
cmp dword [ebp + 0x10], 0
jne 0x401806
mov eax, 1
jmp 0x4018ba
mov eax, dword [ebp + 0x10]
push eax
call fcn.00401aa0
add esp, 4
add eax, 1
mov dword [ebp - 0xc], eax
cmp dword [ebp + 8], 1
jne 0x401827
mov dword [ebp - 8], 0x80000000
jmp 0x40184c
cmp dword [ebp + 8], 2
jne 0x401836
mov dword [ebp - 8], 0x80000002
jmp 0x40184c
cmp dword [ebp + 8], 4
jne 0x401845
mov dword [ebp - 8], 0x80000001
jmp 0x40184c
mov eax, 1
jmp 0x4018ba
lea ecx, [ebp - 4]
push ecx
lea edx, [ebp - 0x10]
push edx
push 0
push 0xf003f
push 0
push 0x40833c
push 0
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp - 8]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
je 0x40187d
mov eax, 1
jmp 0x4018ba
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp + 0x10]
push eax
push 1
push 0
push 0x40833d
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x4018a3
mov eax, 1
jmp 0x4018ba
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test eax, eax
je 0x4018b8
mov eax, 1
jmp 0x4018ba
xor eax, eax
mov esp, ebp
pop ebp
ret

Function at 0x401920
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [ebp + 0x10]
mov dword [eax], 0
cmp dword [ebp + 8], 1
jne 0x401951
lea ecx, [ebp - 4]
push ecx
push 1
push 0
mov edx, dword [ebp + 0xc]
push edx
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov dword [ebp - 8], eax
jmp 0x4019be
cmp dword [ebp + 8], 2
jne 0x401973
lea eax, [ebp - 4]
push eax
push 1
push 0
mov ecx, dword [ebp + 0xc]
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov dword [ebp - 8], eax
jmp 0x4019be
cmp dword [ebp + 8], 3
jne 0x401995
lea edx, [ebp - 4]
push edx
push 1
push 0
mov eax, dword [ebp + 0xc]
push eax
push 0x80000003
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov dword [ebp - 8], eax
jmp 0x4019be
cmp dword [ebp + 8], 4
jne 0x4019b7
lea ecx, [ebp - 4]
push ecx
push 1
push 0
mov edx, dword [ebp + 0xc]
push edx
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov dword [ebp - 8], eax
jmp 0x4019be
mov eax, 1
jmp 0x401a0b
cmp dword [ebp - 8], 0
je 0x4019c8
xor eax, eax
jmp 0x401a0b
lea eax, [ebp + 0x18]
push eax
mov ecx, dword [ebp + 0x14]
push ecx
push 0
push 0
push 0x40833e
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x4019eb
xor eax, eax
jmp 0x401a0b
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test eax, eax
je 0x401a00
mov eax, 1
jmp 0x401a0b
mov ecx, dword [ebp + 0x10]
mov dword [ecx], 1
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x401bcc
Capabilities:
Accept command line arguments
Parse pe header
Terminate process

Disassembly:
push 0x60
push 0x408340
call fcn.00403630
mov edi, 0x94
mov eax, edi
call fcn.00403790
mov dword [ebp - 0x18], esp
mov esi, esp
mov dword [esi], edi
push esi
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov ecx, dword [esi + 0x10]
mov dword [0x40b458], ecx
mov eax, dword [esi + 4]
mov dword [0x40b464], eax
mov edx, dword [esi + 8]
mov dword [0x40b468], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
mov dword [0x40b45c], esi
cmp ecx, 2
je 0x401c2c
or esi, 0x8000
mov dword [0x40b45c], esi
shl eax, 8
add eax, edx
mov dword [0x40b460], eax
xor esi, esi
push esi
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call edi
cmp word [eax], 0x5a4d
jne 0x401c67
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x401c67
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x401c7f
cmp eax, 0x20b
je 0x401c6c
mov dword [ebp - 0x1c], esi
jmp 0x401c93
cmp dword [ecx + 0x84], 0xe
jbe 0x401c67
xor eax, eax
cmp dword [ecx + 0xf8], esi
jmp 0x401c8d
cmp dword [ecx + 0x74], 0xe
jbe 0x401c67
xor eax, eax
cmp dword [ecx + 0xe8], esi
setne al
mov dword [ebp - 0x1c], eax
push 1
call fcn.004035de
pop ecx
test eax, eax
jne 0x401ca7
push 0x1c
call fcn.00401ba8
pop ecx
call fcn.004034d5
test eax, eax
jne 0x401cb8
push 0x10
call fcn.00401ba8
pop ecx
call fcn.0040326f
mov dword [ebp - 4], esi
call fcn.00403071
test eax, eax
jge 0x401cd1
push 0x1b
call fcn.00401b83
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x40cc94], eax
call fcn.00402f4f
mov dword [0x40b448], eax
call fcn.00402ead
test eax, eax
jge 0x401cf7
push 8
call fcn.00401b83
pop ecx
call fcn.00402c7a
test eax, eax
jge 0x401d08
push 9
call fcn.00401b83
pop ecx
push 1
call fcn.0040279c
pop ecx
mov dword [ebp - 0x28], eax
cmp eax, esi
je 0x401d1e
push eax
call fcn.00401b83
pop ecx
mov dword [ebp - 0x44], esi
lea eax, [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
call fcn.00402c1d
mov dword [ebp - 0x20], eax
test byte [ebp - 0x44], 1
je 0x401d3f
movzx eax, word [ebp - 0x40]
jmp 0x401d42
push 0xa
pop eax
push eax
push dword [ebp - 0x20]
push esi
push esi
call edi
push eax
call section..text
mov edi, eax
mov dword [ebp - 0x2c], edi
cmp dword [ebp - 0x1c], esi
jne 0x401d60
push edi
call fcn.004028c9
call fcn.004028eb
jmp 0x401d92
or dword [ebp - 4], 0xffffffff
mov eax, edi
lea esp, [ebp - 0x7c]
call fcn.0040366b
ret
Function at 0x402806
Capabilities:
Terminate process

Disassembly:
push 8
push 0x4083e0
call fcn.00403630
push 8
call fcn.00404118
pop ecx
xor edi, edi
mov dword [ebp - 4], edi
xor esi, esi
inc esi
cmp dword [0x40b498], esi
jne 0x40283a
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov dword [0x40b494], esi
mov al, byte [ebp + 0x10]
mov byte [0x40b490], al
cmp dword [ebp + 0xc], edi
jne 0x402884
cmp dword [0x40cc88], edi
je 0x402874
mov eax, dword [0x40cc84]
sub eax, 4
mov dword [0x40cc84], eax
cmp eax, dword [0x40cc88]
jb 0x402874
mov eax, dword [eax]
cmp eax, edi
je 0x402855
call eax
jmp 0x402855
push 0x40a028
mov eax, 0x40a020
call fcn.00402784
pop ecx
push 0x40a030
mov eax, 0x40a02c
call fcn.00402784
pop ecx
or dword [ebp - 4], 0xffffffff
call 0x4028b5
cmp dword [ebp + 0x10], edi
jne 0x4028c3
mov dword [0x40b498], esi
push dword [ebp + 8]
call fcn.00402742
xor edi, edi
xor esi, esi
inc esi
cmp dword [ebp + 0x10], edi
je 0x4028c2
push 8
call fcn.00404063
pop ecx
ret
call fcn.0040366b
ret

Function at 0x402909
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x8c]
sub esp, 0x10c
mov eax, dword [0x40a440]
mov ecx, dword [ebp + 0x94]
push ebx
push esi
mov dword [ebp + 0x88], eax
xor edx, edx
push edi
xor eax, eax
cmp ecx, dword [eax*8 + 0x40a050]
je 0x40293e
inc eax
cmp eax, 0x13
jb 0x40292f
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x40a050]
jne 0x402a64
mov eax, dword [0x40b450]
cmp eax, 1
je 0x402a3c
cmp eax, edx
jne 0x40296e
cmp dword [0x40a044], 1
je 0x402a3c
cmp ecx, 0xfc
je 0x402a64
push 0x104
lea eax, [ebp - 0x80]
push eax
push edx
mov byte [ebp + 0x84], dl
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x4029a4
lea eax, [ebp - 0x80]
push str._program_name_unknown_
push eax
call fcn.00404340
pop ecx
pop ecx
lea edi, [ebp - 0x80]
mov eax, edi
push eax
call fcn.00401aa0
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x4029d8
mov eax, edi
push eax
call fcn.00401aa0
mov edi, eax
lea eax, [ebp - 0x80]
sub eax, 0x3b
push 3
add edi, eax
push 0x4087d8
push edi
call fcn.00404440
add esp, 0x10
push edi
call fcn.00401aa0
push dword [esi + 0x40a054]
mov ebx, eax
call fcn.00401aa0
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.00403790
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.00404340
push edi
push ebx
call fcn.00404350
push 0x4087b8
push ebx
call fcn.00404350
push dword [esi + 0x40a054]
push ebx
call fcn.00404350
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.0040423b
add esp, 0x2c
jmp 0x402a64
push edx
lea eax, [ebp + 0x94]
push eax
lea esi, [esi + 0x40a054]
push dword [esi]
call fcn.00401aa0
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
lea esp, [ebp - 0x8c]
mov ecx, dword [ebp + 0x88]
call fcn.00403f16
pop edi
pop esi
pop ebx
add ebp, 0x8c
leave
ret
Function at 0x4038ec
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x3a0]
sub esp, 0x420
mov eax, dword [0x40a440]
push edi
xor edi, edi
cmp dword [ebp + 0x3b0], edi
mov dword [ebp + 0x39c], eax
mov dword [ebp - 0x78], edi
mov dword [ebp - 0x7c], edi
jne 0x40391d
xor eax, eax
jmp 0x403aa6
mov eax, dword [ebp + 0x3a8]
push ebx
mov ebx, dword [ebp + 0x3a8]
and eax, 0x1f
sar ebx, 5
push esi
lea esi, [eax + eax*8]
lea ebx, [ebx*4 + 0x40cb80]
mov eax, dword [ebx]
shl esi, 2
test byte [eax + esi + 4], 0x20
je 0x403959
push 2
push edi
push edi
push dword [ebp + 0x3a8]
call fcn.00406132
add esp, 0x10
mov eax, dword [ebx]
add eax, esi
test byte [eax + 4], 0x80
je 0x403a34
cmp dword [ebp + 0x3b0], edi
mov eax, dword [ebp + 0x3ac]
mov dword [ebp - 0x74], eax
mov dword [ebp - 0x6c], edi
jbe 0x403a72
mov ecx, dword [ebp - 0x74]
sub ecx, dword [ebp + 0x3ac]
lea eax, [ebp - 0x68]
mov dword [ebp - 0x70], edi
cmp ecx, dword [ebp + 0x3b0]
jae 0x4039bd
mov edx, dword [ebp - 0x74]
inc dword [ebp - 0x74]
mov dl, byte [edx]
inc ecx
cmp dl, 0xa
jne 0x4039ae
inc dword [ebp - 0x7c]
mov byte [eax], 0xd
inc eax
inc dword [ebp - 0x70]
mov byte [eax], dl
inc eax
inc dword [ebp - 0x70]
cmp dword [ebp - 0x70], 0x400
jl 0x40398e
mov edi, eax
lea eax, [ebp - 0x68]
sub edi, eax
push 0
lea eax, [ebp - 0x80]
push eax
push edi
lea eax, [ebp - 0x68]
push eax
mov eax, dword [ebx]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4039fd
mov eax, dword [ebp - 0x80]
add dword [ebp - 0x78], eax
cmp eax, edi
jl 0x403a06
mov eax, dword [ebp - 0x74]
sub eax, dword [ebp + 0x3ac]
xor edi, edi
cmp eax, dword [ebp + 0x3b0]
jb 0x40397f
jmp 0x403a08
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x6c], eax
xor edi, edi
mov eax, dword [ebp - 0x78]
cmp eax, edi
jne 0x403aa1
cmp dword [ebp - 0x6c], edi
je 0x403a72
push 5
pop esi
cmp dword [ebp - 0x6c], esi
jne 0x403a67
call fcn.00405f2b
mov dword [eax], 9
call fcn.00405f34
mov dword [eax], esi
jmp 0x403a9c
push edi
lea ecx, [ebp - 0x80]
push ecx
push dword [ebp + 0x3b0]
push dword [ebp + 0x3ac]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x403a5c
mov eax, dword [ebp - 0x80]
mov dword [ebp - 0x6c], edi
mov dword [ebp - 0x78], eax
jmp 0x403a08
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x6c], eax
jmp 0x403a08
push dword [ebp - 0x6c]
call fcn.00405f3d
pop ecx
jmp 0x403a9c
mov eax, dword [ebx]
test byte [eax + esi + 4], 0x40
je 0x403a8a
mov eax, dword [ebp + 0x3ac]
cmp byte [eax], 0x1a
jne 0x403a8a
xor eax, eax
jmp 0x403aa4
call fcn.00405f2b
mov dword [eax], 0x1c
call fcn.00405f34
mov dword [eax], edi
or eax, 0xffffffff
jmp 0x403aa4
sub eax, dword [ebp - 0x7c]
pop esi
pop ebx
mov ecx, dword [ebp + 0x39c]
pop edi
call fcn.00403f16
add ebp, 0x3a0
leave
ret
Function at 0x40423b
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x40b710], ebx
push esi
push edi
jne 0x4042bb
push str.user32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x4042f6
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxA
push edi
call esi
test eax, eax
mov dword [0x40b710], eax
je 0x4042f6
push str.GetActiveWindow
push edi
call esi
push str.GetLastActivePopup
push edi
mov dword [0x40b714], eax
call esi
cmp dword [0x40b458], 2
mov dword [0x40b718], eax
jne 0x4042bb
push str.GetUserObjectInformationA
push edi
call esi
test eax, eax
mov dword [0x40b720], eax
je 0x4042bb
push str.GetProcessWindowStation
push edi
call esi
mov dword [0x40b71c], eax
mov eax, dword [0x40b71c]
test eax, eax
je 0x404300
call eax
test eax, eax
je 0x4042e7
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x40b720]
test eax, eax
je 0x4042e7
test byte [ebp - 8], 1
jne 0x404300
cmp dword [0x40b464], 4
jb 0x4042fa
or byte [ebp + 0x12], 0x20
jmp 0x40431f
xor eax, eax
jmp 0x40432f
or byte [ebp + 0x12], 4
jmp 0x40431f
mov eax, dword [0x40b714]
test eax, eax
je 0x40431f
call eax
mov ebx, eax
test ebx, ebx
je 0x40431f
mov eax, dword [0x40b718]
test eax, eax
je 0x40431f
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x40b710]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x405d02
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
mov esi, dword [ebp + 8]
mov ebx, dword [esi + 8]
test bl, 3
jne 0x405d30
mov eax, dword fs:[0x18]
mov dword [ebp + 8], eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 8]
cmp ebx, ecx
mov dword [ebp - 4], ecx
jb 0x405d37
cmp ebx, dword [eax + 4]
jae 0x405d37
xor eax, eax
jmp 0x405f27
push edi
mov edi, dword [esi + 0xc]
cmp edi, 0xffffffff
jne 0x405d48
xor eax, eax
inc eax
jmp 0x405f26
xor edx, edx
mov dword [ebp + 8], edx
mov eax, ebx
mov ecx, dword [eax]
cmp ecx, 0xffffffff
je 0x405d5e
cmp ecx, edx
jae 0x405ea3
cmp dword [eax + 4], 0
je 0x405d67
inc dword [ebp + 8]
inc edx
add eax, 0xc
cmp edx, edi
jbe 0x405d4f
cmp dword [ebp + 8], 0
je 0x405d89
mov eax, dword [esi - 8]
cmp eax, dword [ebp - 4]
jb 0x405ea3
cmp eax, esi
jae 0x405ea3
mov eax, dword [0x40b738]
mov edi, ebx
and edi, 0xfffff000
xor esi, esi
test eax, eax
jle 0x405dae
cmp dword [esi*4 + 0x40b740], edi
je 0x405ea7
inc esi
cmp esi, eax
jl 0x405d9c
push 0x1c
lea eax, [ebp - 0x20]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x405f23
cmp dword [ebp - 8], 0x1000000
jne 0x405f23
test byte [ebp - 0xc], 0xcc
je 0x405e2c
mov ecx, dword [ebp - 0x1c]
cmp word [ecx], 0x5a4d
jne 0x405f23
mov eax, dword [ecx + 0x3c]
add eax, ecx
cmp dword [eax], 0x4550
jne 0x405f23
cmp word [eax + 0x18], 0x10b
jne 0x405f23
sub ebx, ecx
cmp word [eax + 6], 0
movzx ecx, word [eax + 0x14]
lea ecx, [ecx + eax + 0x18]
jbe 0x405f23
mov eax, dword [ecx + 0xc]
cmp ebx, eax
jb 0x405e2c
mov edx, dword [ecx + 8]
add edx, eax
cmp ebx, edx
jae 0x405e2c
test byte [ecx + 0x27], 0x80
jne 0x405ea3
push 1
push 0x40b780
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
test eax, eax
jne 0x405d40
mov ecx, dword [0x40b738]
test ecx, ecx
mov edx, ecx
jle 0x405e60
lea eax, [ecx*4 + 0x40b73c]
cmp dword [eax], edi
je 0x405e60
dec edx
sub eax, 4
test edx, edx
jg 0x405e54
test edx, edx
jne 0x405e91
push 0xf
pop ebx
cmp ecx, ebx
jg 0x405e6d
mov ebx, ecx
xor edx, edx
test ebx, ebx
jl 0x405e85
lea eax, [edx*4 + 0x40b740]
mov esi, dword [eax]
inc edx
cmp edx, ebx
mov dword [eax], edi
mov edi, esi
jle 0x405e73
cmp ecx, 0x10
jge 0x405e91
inc ecx
mov dword [0x40b738], ecx
push 0
push 0x40b780
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
jmp 0x405d40
xor eax, eax
jmp 0x405f26
test esi, esi
jle 0x405d40
mov ebx, dword [sym.imp.KERNEL32.dll_InterlockedExchange]
push 1
push 0x40b780
call ebx
test eax, eax
jne 0x405d40
cmp dword [esi*4 + 0x40b740], edi
je 0x405efd
mov eax, dword [0x40b738]
lea esi, [eax - 1]
test esi, esi
jl 0x405eeb
cmp dword [esi*4 + 0x40b740], edi
je 0x405ee7
dec esi
jns 0x405edb
test esi, esi
jge 0x405efb
cmp eax, 0x10
jge 0x405ef6
inc eax
mov dword [0x40b738], eax
lea esi, [eax - 1]
jmp 0x405efd
je 0x405f15
xor ecx, ecx
test esi, esi
jl 0x405f15
lea eax, [ecx*4 + 0x40b740]
mov edx, dword [eax]
inc ecx
cmp ecx, esi
mov dword [eax], edi
mov edi, edx
jle 0x405f03
push 0
push 0x40b780
call ebx
jmp 0x405d40
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret
Function at 0x407892
Capabilities:
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
push ebx
push esi
push edi
push 4
pop eax
call fcn.00403790
mov esi, esp
push 0x1c
lea eax, [ebp - 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x40792d
mov ebx, dword [ebp - 0x24]
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov ecx, dword [ebp - 0x48]
mov eax, dword [0x40b458]
lea edi, [ecx - 1]
not edi
and edi, esi
sub edi, ecx
mov esi, eax
dec esi
neg esi
sbb esi, esi
and esi, 0xfffffff1
add esi, 0x11
imul esi, ecx
add esi, ebx
cmp edi, esi
mov dword [ebp - 8], ecx
jb 0x40792d
cmp eax, 1
je 0x40794e
mov dword [ebp - 4], ebx
mov ebx, 0x1000
push 0x1c
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x40792d
mov eax, dword [ebp - 0x1c]
add dword [ebp - 4], eax
test dword [ebp - 0x18], ebx
je 0x4078fa
test byte [ebp - 0x13], 1
mov eax, dword [ebp - 0x28]
mov dword [ebp - 4], eax
je 0x407929
xor eax, eax
inc eax
jmp 0x40796d
cmp edi, eax
jae 0x407931
xor eax, eax
jmp 0x40796d
cmp eax, esi
jae 0x407938
mov dword [ebp - 4], esi
push 4
push ebx
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov eax, dword [0x40b458]
jmp 0x407951
mov dword [ebp - 4], edi
dec eax
neg eax
sbb eax, eax
and eax, 0x103
lea ecx, [ebp - 0xc]
push ecx
inc eax
push eax
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea esp, [ebp - 0x58]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x53953e
Capabilities:
Decompress data using aplib

Disassembly:
push ebp
mov ebp, esp
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
cld
mov dl, 0x80
movsb byte es:[edi], byte [esi]
call fcn.005395bd
jae 0x53954a
xor ecx, ecx
call fcn.005395bd
jae 0x539574
xor eax, eax
call fcn.005395bd
jae 0x539585
mov al, 0x10
call fcn.005395bd
adc al, al
jae 0x539566
jne 0x5395b2
stosb byte es:[edi], al
jmp 0x53954b
call fcn.005395c9
dec ecx
loop 0x539591
mov eax, ebp
call fcn.005395c7
jmp 0x5395b3
lodsb al, byte [esi]
shr eax, 1
je 0x5395d9
adc ecx, 2
mov ebp, eax
jmp 0x5395b3
xchg ecx, eax
dec eax
shl eax, 8
lodsb al, byte [esi]
mov ebp, eax
call fcn.005395c7
cmp eax, 0x7d00
jae 0x5395b1
cmp eax, 0x500
jae 0x5395b2
cmp eax, 0x7f
ja 0x5395b3
inc ecx
inc ecx
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x53954b
pop ebp
ret 8