joyce8/EMBER2024-capa huggingface dataset:
Function at 0x5c3000
Capabilities:
Get file version info

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push esi
lea eax, [esp + 0xc]
push edi
push eax
push ebx
call sub.VERSION.dll_GetFileVersionInfoSizeW
mov esi, eax
test esi, esi
je 0x5c3131
push esi
call fcn.005c6145
add esp, 4
mov edi, eax
push edi
push esi
push 0
push ebx
call sub.VERSION.dll_GetFileVersionInfoW
push 0
push 0x80
push 3
push 0
push 0
push 0xc0000000
push ebx
call fcn.005b5080
mov ebp, eax
add esp, 0x1c
cmp ebp, 0xffffffff
je 0x5c3131
push 0
push ebp
call fcn.005b53a0
push 0
push 0
push 0
push 4
push 0
push ebp
mov ebx, eax
call fcn.005b5260
add esp, 0x20
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5c308b
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
push 0
push 0
push 0
push 6
push eax
call fcn.005b52f0
mov esi, eax
add esp, 0x14
test esi, esi
je 0x5c3121
push 0x5db918
push edi
call fcn.005c43f0
push eax
push ebx
push esi
call fcn.005c2f60
push 0x5db8f8
push edi
call fcn.005c43f0
push eax
push ebx
push esi
call fcn.005c2f60
push 0x5db8d8
push edi
call fcn.005c43f0
push eax
push ebx
push esi
call fcn.005c2f60
push 0x5db8c0
push edi
call fcn.005c43f0
add esp, 0x44
push eax
push ebx
push esi
call fcn.005c2f60
push 0x5db8a0
push edi
call fcn.005c43f0
push eax
push ebx
push esi
call fcn.005c2f60
push 0x5db888
push edi
call fcn.005c43f0
push eax
push ebx
push esi
call fcn.005c2f60
add esp, 0x34
push esi
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov ecx, dword [esp + 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push ecx
call esi
push ebp
call esi
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
Function at 0x5c41b0
Capabilities:
Acquire debug privileges

Disassembly:
push ecx
lea eax, [esp]
mov dword [esp], 0
push eax
push 0x20
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp]
push 1
push str.SeBackupPrivilege
push ecx
call fcn.005c4140
mov edx, dword [esp + 0xc]
push 1
push str.SeDebugPrivilege
push edx
call fcn.005c4140
mov eax, dword [esp + 0x18]
push 1
push str.SeRestorePrivilege
push eax
call fcn.005c4140
mov ecx, dword [esp + 0x24]
push 1
push str.SeSecurityPrivilege
push ecx
call fcn.005c4140
mov edx, dword [esp + 0x30]
add esp, 0x30
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
pop ecx
ret

Function at 0x5c4bfa
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
lea eax, [ebp - 4]
push eax
push 0x20019
xor esi, esi
push esi
push str.CLSIDADB880A6_D8FF_11CF_9377_00AA003B7A11InprocServer32
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x5c4c50
lea eax, [ebp - 8]
push eax
push dword [ebp + 8]
mov dword [ebp - 8], 0x104
push esi
push esi
push 0x5d687c
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x5c4c43
inc esi
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
jmp 0x5c4c52
xor eax, eax
pop esi
leave
ret 4

Function at 0x42e004
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
mov eax, section..text
nop
mov ebx, 0x407ef8
nop
mov ecx, 0x434754b1
nop
nop
nop
nop
test eax, eax
nop
nop
nop
nop
nop
je 0x42e04e
nop
nop
nop
xor dword [eax], ecx
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
nop
nop
nop
jne 0x42e024
nop
mov eax, section..data
nop
mov ebx, 0x42cd70
mov ecx, 0x2df26906
nop
nop
nop
test eax, eax
nop
nop
nop
nop
je 0x42e084
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
nop
add eax, 4
nop
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
jne 0x42e06c
nop
nop
nop
nop
popal
nop
nop
jmp 0x401219
Function at 0x40e585
Capabilities:
Hash data using sha1

Disassembly:
mov eax, dword [esp + 4]
and dword [eax + 0x18], 0
and dword [eax + 0x14], 0
mov dword [eax], 0x67452301
mov dword [eax + 4], 0xefcdab89
mov dword [eax + 8], 0x98badcfe
mov dword [eax + 0xc], 0x10325476
mov dword [eax + 0x10], 0xc3d2e1f0
ret 4

Function at 0x41259d
Capabilities:
Get common file path

Disassembly:
push dword [esp + 4]
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
neg eax
sbb eax, eax
neg eax
ret 8
Function at 0x77f560
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0x2a7000]
push edi
jmp 0x77f57a
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x77f581
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x77f570
mov eax, 1
add ebx, ebx
jne 0x77f593
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x77f5a4
jne 0x77f5c3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x77f5c3
dec eax
add ebx, ebx
jne 0x77f5b0
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
jmp 0x77f588
add ebx, ebx
jne 0x77f5bf
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jmp 0x77f615
xor ecx, ecx
sub eax, 3
jb 0x77f5db
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x77f64a
sar eax, 1
mov ebp, eax
jmp 0x77f5e6
add ebx, ebx
jne 0x77f5e6
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x77f5b4
inc ecx
add ebx, ebx
jne 0x77f5f4
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x77f5b4
add ebx, ebx
jne 0x77f601
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x77f5f6
jne 0x77f612
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x77f5f6
add ecx, 2
cmp ebp, 0xfffffb00
adc ecx, 2
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x77f634
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x77f626
jmp 0x77f576
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x77f634
add edi, ecx
jmp 0x77f576
pop esi
mov edi, esi
mov ecx, 0x467
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x77f652
cmp byte [edi], 7
jne 0x77f652
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov al, bl
loop 0x77f657
lea edi, [esi + 0x37d000]
mov eax, dword [edi]
or eax, eax
je 0x77f6c6
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x409184]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x4091c0]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x77f684
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x4091c8]
or eax, eax
je 0x77f6c0
mov dword [ebx], eax
add ebx, 4
jmp 0x77f6a1
call dword [esi + 0x4091c4]
mov ebp, dword [esi + 0x4091cc]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x247]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0x77f6fa
sub esp, 0xffffff80
jmp 0x40125d
Function at 0x401120
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x58
mov eax, dword [0x4122f8]
xor eax, dword [esp + 0x58]
push ebx
push ebp
mov dword [esp + 0x5c], eax
mov eax, 0x20
push esi
xor ebp, ebp
push 0x1000
mov dword [esp + 0x10], ebp
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
call fcn.00405455
add esp, 4
mov ebx, eax
lea eax, [esp + 0x18]
push eax
push 0x20119
push ebp
push str.HARDWAREDEVICEMAPSERIALCOMM
push reloc.WS2_32.dll_bind
mov byte [ebx], 0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40123c
push edi
lea esp, [esp]
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x28]
push edx
lea eax, [esp + 0x28]
push eax
mov eax, dword [esp + 0x1c]
push 0
lea ecx, [esp + 0x24]
push ecx
mov ecx, dword [esp + 0x30]
lea edx, [esp + 0x58]
push edx
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegEnumValueA]
test eax, eax
je 0x4011b6
cmp eax, 0xea
jne 0x401214
cmp dword [esp + 0x20], 1
jne 0x401214
test ebp, ebp
jbe 0x4011d6
mov edi, ebx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x4011c4
mov dx, word [0x40e374]
mov word [edi], dx
lea ecx, [esp + 0x24]
mov esi, ecx
lea esp, [esp]
mov dl, byte [ecx]
inc ecx
test dl, dl
jne 0x4011e0
sub ecx, esi
mov edi, ebx
mov edx, ecx
dec edi
mov edi, edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x4011f0
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, 0x20
mov dword [esp + 0x14], ecx
mov dword [esp + 0x18], ecx
inc ebp
mov edx, dword [esp + 0x10]
inc edx
test eax, eax
mov dword [esp + 0x10], edx
je 0x401180
cmp eax, 0xea
je 0x401180
mov eax, dword [esp + 0x1c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
mov ecx, dword [esp + 0x68]
push 0x40e370
push ecx
call fcn.0040539b
mov esi, eax
add esp, 8
test esi, esi
je 0x40126f
push ebx
push str._s_r_n
push esi
call fcn.00404d14
push esi
call fcn.004052e6
push esi
call fcn.00405135
add esp, 0x14
mov ecx, dword [esp + 0x60]
xor ecx, dword [esp + 0x64]
pop esi
pop ebp
pop ebx
add esp, 0x58
jmp fcn.00405498

Function at 0x401670
Capabilities:
Initialize winsock library

Disassembly:
jmp 0x402d50
sub esp, 0x194
mov eax, dword [0x4122f8]
xor eax, dword [esp + 0x194]
push 0
mov dword [esp + 0x194], eax
call fcn.00402d20
add esp, 4
lea eax, [esp]
push eax
push 0x101
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x402d8b
push 0x64
jmp 0x402db5
mov ax, word [esp]
cmp al, 1
jne 0x402db3
cmp ah, al
jne 0x402db3
xor eax, eax
mov ecx, dword [esp + 0x190]
xor ecx, dword [esp + 0x194]
add esp, 0x194
jmp fcn.00405498
push 0x65
call fcn.00402d20
mov ecx, dword [esp + 0x194]
add esp, 4
xor ecx, dword [esp + 0x194]
mov eax, 1
add esp, 0x194
jmp fcn.00405498

Function at 0x402c50
Capabilities:
Get socket status

Disassembly:
sub esp, 0x10c
mov ecx, dword [ecx + 4]
xor eax, eax
lea edx, [esp]
push edx
push eax
mov dword [esp + 0x14], ecx
push eax
lea ecx, [esp + 0x14]
push ecx
push eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], 1
call dword [sym.imp.WS2_32.dll_select]
add esp, 0x10c
ret
Function at 0x403430
Capabilities:
Write file on windows

Disassembly:
movzx edx, word [esp + 8]
mov ecx, dword [ecx + 4]
push 0
lea eax, [esp + 0xc]
push eax
mov eax, dword [esp + 0xc]
push edx
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x403457
mov eax, dword [esp + 8]
ret 8
or eax, 0xffffffff
ret 8

Function at 0x404fd6
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push 8
call fcn.00407362
xor esi, esi
inc esi
cmp dword [0x412ea8], esi
pop ecx
jne 0x404ffe
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
cmp dword [ebp + 0xc], 0
mov al, byte [ebp + 0x10]
mov dword [0x412ea4], esi
mov byte [0x412ea0], al
jne 0x405064
mov ecx, dword [0x41364c]
test ecx, ecx
je 0x405045
mov eax, dword [0x413648]
sub eax, 4
cmp eax, ecx
jmp 0x40503e
mov eax, dword [eax]
test eax, eax
je 0x405030
call eax
mov eax, dword [0x413648]
sub eax, 4
cmp eax, dword [0x41364c]
mov dword [0x413648], eax
jae 0x405028
mov eax, 0x412024
mov esi, 0x412030
cmp eax, esi
mov edi, eax
jae 0x405064
mov eax, dword [edi]
test eax, eax
je 0x40505d
call eax
add edi, 4
cmp edi, esi
jb 0x405055
mov eax, 0x412034
mov esi, 0x41203c
cmp eax, esi
mov edi, eax
jae 0x405083
mov eax, dword [edi]
test eax, eax
je 0x40507c
call eax
add edi, 4
cmp edi, esi
jb 0x405074
cmp dword [ebp + 0x10], 0
pop edi
pop esi
je 0x405094
push 8
call fcn.004072ce
jmp 0x4050a6
push dword [ebp + 8]
mov dword [0x412ea8], 1
call fcn.00404f2f
pop ecx
pop ebp
ret
Function at 0x4061aa
Capabilities:
Accept command line arguments
Parse pe header
Terminate process

Disassembly:
push 0x18
push 0x40feb0
call fcn.00406e90
mov edi, 0x94
mov eax, edi
call fcn.0040a5c0
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 [0x412e68], ecx
mov eax, dword [esi + 4]
mov dword [0x412e74], eax
mov edx, dword [esi + 8]
mov dword [0x412e78], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
mov dword [0x412e6c], esi
cmp ecx, 2
je 0x40620a
or esi, 0x8000
mov dword [0x412e6c], esi
shl eax, 8
add eax, edx
mov dword [0x412e70], eax
xor edi, edi
push edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
cmp word [eax], 0x5a4d
jne 0x406243
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x406243
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x40625b
cmp eax, 0x20b
je 0x406248
mov dword [ebp - 0x1c], edi
jmp 0x40626f
cmp dword [ecx + 0x84], 0xe
jbe 0x406243
xor eax, eax
cmp dword [ecx + 0xf8], edi
jmp 0x406269
cmp dword [ecx + 0x74], 0xe
jbe 0x406243
xor eax, eax
cmp dword [ecx + 0xe8], edi
setne al
mov dword [ebp - 0x1c], eax
push 1
call fcn.00407d23
pop ecx
test eax, eax
jne 0x406283
push 0x1c
call fcn.00406186
pop ecx
call fcn.00408d04
test eax, eax
jne 0x406294
push 0x10
call fcn.00406186
pop ecx
call fcn.0040751d
mov dword [ebp - 4], edi
call fcn.00406edc
test eax, eax
jge 0x4062ad
push 0x1b
call fcn.00406161
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x413640], eax
call fcn.0040a48f
mov dword [0x412ec0], eax
call fcn.0040a3ed
test eax, eax
jge 0x4062d3
push 8
call fcn.00406161
pop ecx
call fcn.0040a1ba
test eax, eax
jge 0x4062e4
push 9
call fcn.00406161
pop ecx
call fcn.00404f71
mov dword [ebp - 0x20], eax
cmp eax, edi
je 0x4062f7
push eax
call fcn.00406161
pop ecx
mov eax, dword [0x412e88]
mov dword [0x412e8c], eax
push eax
push dword [0x412e80]
push dword [0x412e7c]
call fcn.00401290
add esp, 0xc
mov esi, eax
mov dword [ebp - 0x24], esi
cmp dword [ebp - 0x1c], edi
jne 0x406326
push esi
call fcn.004050a9
call fcn.004050cb
jmp 0x406358
or dword [ebp - 4], 0xffffffff
mov eax, esi
lea esp, [ebp - 0x34]
call fcn.00406ecb
ret
Function at 0x4076ee
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x420
mov eax, dword [0x4122f8]
xor eax, dword [ebp + 4]
push edi
xor edi, edi
cmp dword [ebp + 0x10], edi
mov dword [ebp - 4], eax
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x18], edi
jne 0x407717
xor eax, eax
jmp 0x407885
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [ebp + 8]
and eax, 0x1f
sar ebx, 5
push esi
lea esi, [eax + eax*8]
lea ebx, [ebx*4 + 0x413540]
mov eax, dword [ebx]
shl esi, 2
test byte [eax + esi + 4], 0x20
je 0x40774a
push 2
push edi
push edi
push dword [ebp + 8]
call fcn.0040b261
add esp, 0x10
mov eax, dword [ebx]
add eax, esi
test byte [eax + 4], 0x80
je 0x40781c
cmp dword [ebp + 0x10], edi
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x10], eax
mov dword [ebp - 8], edi
jbe 0x407857
mov ecx, dword [ebp - 0x10]
sub ecx, dword [ebp + 0xc]
lea eax, [ebp - 0x420]
mov dword [ebp - 0xc], edi
cmp ecx, dword [ebp + 0x10]
jae 0x4077a5
mov edx, dword [ebp - 0x10]
inc dword [ebp - 0x10]
mov dl, byte [edx]
inc ecx
cmp dl, 0xa
jne 0x407796
inc dword [ebp - 0x18]
mov byte [eax], 0xd
inc eax
inc dword [ebp - 0xc]
mov byte [eax], dl
inc eax
inc dword [ebp - 0xc]
cmp dword [ebp - 0xc], 0x400
jl 0x407779
mov edi, eax
lea eax, [ebp - 0x420]
sub edi, eax
push 0
lea eax, [ebp - 0x1c]
push eax
push edi
lea eax, [ebp - 0x420]
push eax
mov eax, dword [ebx]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4077e5
mov eax, dword [ebp - 0x1c]
add dword [ebp - 0x14], eax
cmp eax, edi
jl 0x4077ee
mov eax, dword [ebp - 0x10]
sub eax, dword [ebp + 0xc]
xor edi, edi
cmp eax, dword [ebp + 0x10]
jb 0x40776a
jmp 0x4077f0
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 8], eax
xor edi, edi
mov eax, dword [ebp - 0x14]
cmp eax, edi
jne 0x407880
cmp dword [ebp - 8], edi
je 0x407857
push 5
pop esi
cmp dword [ebp - 8], esi
jne 0x407849
call fcn.00407b62
mov dword [eax], 9
call fcn.00407b6b
mov dword [eax], esi
jmp 0x407852
push edi
lea ecx, [ebp - 0x1c]
push ecx
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x40783e
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], edi
mov dword [ebp - 0x14], eax
jmp 0x4077f0
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 8], eax
jmp 0x4077f0
push dword [ebp - 8]
call fcn.00407b74
pop ecx
or eax, 0xffffffff
jmp 0x407883
mov eax, dword [ebx]
test byte [eax + esi + 4], 0x40
je 0x40786c
mov eax, dword [ebp + 0xc]
cmp byte [eax], 0x1a
jne 0x40786c
xor eax, eax
jmp 0x407883
call fcn.00407b62
mov dword [eax], 0x1c
call fcn.00407b6b
mov dword [eax], edi
jmp 0x407852
sub eax, dword [ebp - 0x18]
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, dword [ebp + 4]
pop edi
call fcn.00405498
leave
ret
Function at 0x40a00a
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
mov eax, dword [0x4122f8]
xor eax, dword [ebp + 4]
mov ecx, dword [ebp + 8]
push ebx
push esi
mov dword [ebp - 4], eax
xor edx, edx
push edi
xor eax, eax
cmp ecx, dword [eax*8 + 0x412830]
je 0x40a037
inc eax
cmp eax, 0x12
jb 0x40a028
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x412830]
jne 0x40a16b
mov eax, dword [0x412ec8]
cmp eax, 1
je 0x40a146
cmp eax, edx
jne 0x40a067
cmp dword [0x412314], 1
je 0x40a146
cmp ecx, 0xfc
je 0x40a16b
push 0x104
lea eax, [ebp - 0x10c]
push eax
push edx
mov byte [ebp - 8], dl
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x40a0a0
lea eax, [ebp - 0x10c]
push str._program_name_unknown_
push eax
call fcn.0040a600
pop ecx
pop ecx
lea eax, [ebp - 0x10c]
push eax
lea edi, [ebp - 0x10c]
call fcn.0040a700
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x40a0e2
lea eax, [ebp - 0x10c]
push eax
call fcn.0040a700
mov edi, eax
lea eax, [ebp - 0x10c]
sub eax, 0x3b
push 3
add edi, eax
push 0x410054
push edi
call fcn.004054b0
add esp, 0x10
push edi
call fcn.0040a700
push dword [esi + 0x412834]
mov ebx, eax
call fcn.0040a700
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.0040a5c0
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.0040a600
push edi
push ebx
call fcn.0040a610
push 0x410050
push ebx
call fcn.0040a610
push dword [esi + 0x412834]
push ebx
call fcn.0040a610
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.0040b95d
add esp, 0x2c
jmp 0x40a16b
push edx
lea eax, [ebp + 8]
push eax
lea esi, [esi + 0x412834]
push dword [esi]
call fcn.0040a700
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 - 0x118]
mov ecx, dword [ebp - 4]
xor ecx, dword [ebp + 4]
call fcn.00405498
pop edi
pop esi
pop ebx
leave
ret
Function at 0x40b95d
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x413160], ebx
push esi
push edi
jne 0x40b9dd
push str.user32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x40ba18
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxA
push edi
call esi
test eax, eax
mov dword [0x413160], eax
je 0x40ba18
push str.GetActiveWindow
push edi
call esi
push str.GetLastActivePopup
push edi
mov dword [0x413164], eax
call esi
cmp dword [0x412e68], 2
mov dword [0x413168], eax
jne 0x40b9dd
push str.GetUserObjectInformationA
push edi
call esi
test eax, eax
mov dword [0x413170], eax
je 0x40b9dd
push str.GetProcessWindowStation
push edi
call esi
mov dword [0x41316c], eax
mov eax, dword [0x41316c]
test eax, eax
je 0x40ba22
call eax
test eax, eax
je 0x40ba09
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x413170]
test eax, eax
je 0x40ba09
test byte [ebp - 8], 1
jne 0x40ba22
cmp dword [0x412e74], 4
jb 0x40ba1c
or byte [ebp + 0x12], 0x20
jmp 0x40ba41
xor eax, eax
jmp 0x40ba51
or byte [ebp + 0x12], 4
jmp 0x40ba41
mov eax, dword [0x413164]
test eax, eax
je 0x40ba41
call eax
mov ebx, eax
test ebx, ebx
je 0x40ba41
mov eax, dword [0x413168]
test eax, eax
je 0x40ba41
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x413160]
pop edi
pop esi
pop ebx
leave
ret

Function at 0x40c79e
Capabilities:
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
push ebx
push esi
push edi
push 4
pop eax
call fcn.0040a5c0
mov ebx, esp
push 0x1c
lea eax, [ebp - 0x24]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x40c833
mov edi, dword [ebp - 0x20]
lea eax, [ebp - 0x48]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov eax, dword [ebp - 0x44]
lea esi, [eax - 1]
not esi
and esi, ebx
sub esi, eax
mov dword [ebp - 4], eax
mov eax, dword [0x412e68]
mov ecx, eax
dec ecx
neg ecx
sbb ecx, ecx
and ecx, 0xffff1000
add ecx, 0x11000
add ecx, edi
cmp esi, ecx
jb 0x40c833
cmp eax, 1
je 0x40c84b
mov ebx, edi
mov edi, 0x1000
push 0x1c
lea eax, [ebp - 0x24]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x40c833
add ebx, dword [ebp - 0x18]
test dword [ebp - 0x14], edi
je 0x40c808
test byte [ebp - 0xf], 1
mov ebx, dword [ebp - 0x24]
je 0x40c82f
xor eax, eax
inc eax
jmp 0x40c867
cmp esi, ebx
jae 0x40c837
xor eax, eax
jmp 0x40c867
push 4
push edi
push dword [ebp - 4]
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov eax, dword [0x412e68]
jmp 0x40c84d
mov ebx, esi
dec eax
neg eax
sbb eax, eax
and eax, 0x103
lea ecx, [ebp - 8]
push ecx
inc eax
push eax
push dword [ebp - 4]
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea esp, [ebp - 0x54]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x40c878
Capabilities:
Clear file content

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x100c
call fcn.0040a5c0
mov eax, dword [0x4122f8]
xor eax, dword [ebp + 4]
push ebx
push esi
push 1
xor esi, esi
push esi
push dword [ebp + 8]
mov dword [ebp - 4], eax
call fcn.0040ade0
or ebx, 0xffffffff
add esp, 0xc
cmp eax, ebx
mov dword [ebp - 8], eax
je 0x40c9a2
push 2
push esi
push dword [ebp + 8]
call fcn.0040ade0
add esp, 0xc
cmp eax, ebx
je 0x40c9a2
push edi
mov edi, dword [ebp + 0xc]
sub edi, eax
test edi, edi
jle 0x40c945
mov ebx, 0x1000
push ebx
lea eax, [ebp - 0x100c]
push esi
push eax
call fcn.0040ad80
push 0x8000
push dword [ebp + 8]
call fcn.0040cbce
add esp, 0x14
mov dword [ebp - 0xc], eax
cmp edi, ebx
mov eax, ebx
jge 0x40c8fe
mov eax, edi
push eax
lea eax, [ebp - 0x100c]
push eax
push dword [ebp + 8]
call fcn.004076ee
add esp, 0xc
cmp eax, 0xffffffff
je 0x40c91e
sub edi, eax
test edi, edi
jg 0x40c8f6
jmp 0x40c936
call fcn.00407b6b
cmp dword [eax], 5
jne 0x40c933
call fcn.00407b62
mov dword [eax], 0xd
or esi, 0xffffffff
push dword [ebp - 0xc]
push dword [ebp + 8]
call fcn.0040cbce
pop ecx
pop ecx
jmp 0x40c98d
jge 0x40c98d
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.0040ade0
push dword [ebp + 8]
call fcn.0040b03e
add esp, 0x10
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov esi, eax
neg esi
sbb esi, esi
neg esi
dec esi
cmp esi, ebx
jne 0x40c98d
call fcn.00407b62
mov dword [eax], 0xd
call fcn.00407b6b
mov edi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [edi], eax
push 0
push dword [ebp - 8]
push dword [ebp + 8]
call fcn.0040ade0
add esp, 0xc
mov eax, esi
pop edi
jmp 0x40c9a4
mov eax, ebx
mov ecx, dword [ebp - 4]
xor ecx, dword [ebp + 4]
pop esi
pop ebx
call fcn.00405498
leave
ret