joyce8/EMBER2024-capa huggingface dataset:
Function at 0x468750
Capabilities:
Access peb ldr_data
Get number of processors

Disassembly:
push 0xffffffffffffffff
push 0x4aae43
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0xc], esi
call fcn.0049d87f
lea edi, [esi + 0x64]
mov dword [esp + 0x18], 0
mov dword [edi + 4], 0
mov dword [edi], vtable.CBrush.0
mov eax, dword [esp + 0x2c]
mov ebp, dword [esp + 0x24]
mov ecx, dword [esp + 0x30]
mov dword [esi + 0x3c], eax
mov eax, ebp
mov dword [esi], method.CEdit.virtual_0
mov dword [esi + 0x40], ecx
mov dword [esi + 0x44], 0
mov ecx, dword [eax]
lea edx, [esi + 0x48]
mov byte [esp + 0x18], 1
mov dword [edx], ecx
mov ecx, dword [eax + 4]
mov dword [edx + 4], ecx
mov ecx, dword [eax + 8]
mov dword [edx + 8], ecx
mov eax, dword [eax + 0xc]
mov ecx, dword [esp + 0x40]
mov dword [edx + 0xc], eax
mov eax, dword [esp + 0x44]
push eax
mov dword [esi + 0x5c], ecx
mov dword [esi + 0x60], eax
call dword [sym.imp.GDI32.dll_CreateSolidBrush]
push eax
mov ecx, edi
call fcn.004a2f1b
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x20]
push edx
push eax
push ebp
push 0x50800044
mov ecx, esi
call fcn.004a447a
test eax, eax
je 0x46886c
mov ecx, dword [esp + 0x3c]
call fcn.004a2f48
mov ecx, dword [esi + 0x1c]
mov ebp, dword [sym.imp.USER32.dll_SendMessageA]
push 0
push eax
push 0x30
push ecx
mov dword [esi + 0x58], eax
call ebp
mov edi, dword [esp + 0x34]
test edi, edi
je 0x468830
push edi
mov ecx, esi
call fcn.004a05a6
mov ecx, esi
call fcn.004689d0
cmp dword [esp + 0x38], 1
jne 0x468865
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
mov edx, dword [esi + 0x1c]
push 0xffffffffffffffff
not ecx
dec ecx
push ecx
push 0xb1
push edx
call ebp
mov eax, dword [esi + 0x1c]
push 0
push 0
push 0xb7
push eax
call ebp
mov ecx, esi
call fcn.004a06e1
mov ecx, dword [esp + 0x10]
mov eax, esi
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
add esp, 0x10
ret 0x28
Function at 0x46b2b0
Capabilities:
Check for software breakpoints

Disassembly:
push esi
mov esi, dword [esp + 8]
cmp dword [esi + 0x10], 0xca
jne 0x46b2e3
push esi
call fcn.0046e3c0
mov eax, dword [esi + 0x40]
add esp, 4
test eax, eax
je 0x46b2dc
mov dword [esi + 0x10], 0xcf
mov eax, 1
pop esi
ret
mov dword [esi + 0x10], 0xcb
mov eax, dword [esi + 0x10]
cmp eax, 0xcb
jne 0x46b369
mov eax, dword [esi + 0x1b0]
mov ecx, dword [eax + 0x10]
test ecx, ecx
je 0x46b352
mov eax, dword [esi + 8]
test eax, eax
je 0x46b307
push esi
call dword [eax]
add esp, 4
mov ecx, dword [esi + 0x1b0]
push esi
call dword [ecx]
add esp, 4
test eax, eax
je 0x46b34e
cmp eax, 2
je 0x46b352
mov ecx, dword [esi + 8]
test ecx, ecx
je 0x46b2fa
cmp eax, 3
je 0x46b32d
cmp eax, 1
jne 0x46b2fa
mov eax, dword [ecx + 4]
inc eax
mov dword [ecx + 4], eax
mov eax, dword [esi + 8]
mov ecx, dword [eax + 8]
mov edx, dword [eax + 4]
cmp edx, ecx
jl 0x46b2fa
mov edx, dword [esi + 0x13c]
add edx, ecx
mov dword [eax + 8], edx
jmp 0x46b2fa
xor eax, eax
pop esi
ret
mov eax, dword [esi + 0x90]
push esi
mov dword [esi + 0x98], eax
call fcn.0046b390
add esp, 4
pop esi
ret
cmp eax, 0xcc
je 0x46b378
mov ecx, dword [esi]
push esi
call dword [ecx]
add esp, 4
push esi
call fcn.0046b390
add esp, 4
pop esi
ret

Function at 0x477500
Capabilities:
Capture webcam image

Disassembly:
mov eax, dword [esp + 8]
push ebx
push esi
mov esi, ecx
mov eax, dword [eax + 4]
cmp dword [esi + 0xec], 1
jne 0x4775a3
test eax, eax
jbe 0x4775a3
mov ecx, dword [esi + 0xbc]
test ecx, ecx
jle 0x4775a3
mov ecx, dword [esi + 0x1c]
push edi
push 0
push eax
push 0x419
push ecx
call dword [sym.imp.USER32.dll_SendMessageA]
mov edi, eax
mov eax, dword [esi + 0xbc]
inc edi
test eax, eax
jne 0x47754e
xor esi, esi
jmp 0x477554
mov esi, dword [esi + 0xb4]
add esi, 4
xor ebx, ebx
test edi, edi
jbe 0x47757f
push ebp
mov ebp, edi
add esi, 6
push esi
call fcn.00429d20
add esi, eax
push esi
mov ebx, esi
call fcn.00429d20
add esp, 8
add esi, eax
dec edi
dec ebp
jne 0x477560
pop ebp
test edi, edi
pop edi
jne 0x4775a3
test ebx, ebx
je 0x4775a3
mov edx, dword [esp + 0x10]
push 0x4e
add edx, 0x10
push ebx
push edx
call fcn.0048c170
add esp, 0xc
mov eax, 1
pop esi
pop ebx
ret 0xc
pop esi
xor eax, eax
pop ebx
ret 0xc
Function at 0x4776e5
Capabilities:
Capture webcam image

Disassembly:
sub esp, 0x44
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov eax, dword [esi + 0x3c]
test eax, eax
je 0x4777fd
push eax
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x4777fd
mov eax, dword [esi + 0x3c]
push eax
call fcn.0049dcd1
mov esi, eax
test esi, esi
je 0x4777fd
mov ebx, dword [esp + 0x58]
mov ecx, dword [esi + 0x1c]
mov ebp, dword [sym.imp.USER32.dll_SendMessageA]
push 0
push ebx
push 0x419
push ecx
call ebp
mov edi, eax
test edi, edi
jl 0x4777fd
mov ecx, esi
call fcn.00477650
cmp edi, eax
jge 0x4777fd
mov eax, dword [esi + 0xc4]
mov edx, dword [esi + 0xc0]
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x5c]
xor ecx, ecx
mov dword [esp + 0x28], edx
cmp eax, ecx
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], ecx
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x50], ecx
mov dword [esp + 0x38], edi
jne 0x477783
mov dword [esp + 0x34], 1
jmp 0x4777de
mov edx, dword [esi + 0x1c]
lea ecx, [esp + 0x18]
push ecx
push ebx
push 0x433
push edx
call ebp
test eax, eax
je 0x4777fd
mov eax, dword [esp + 0x60]
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x24]
mov dword [esp + 0x10], ecx
mov dword [eax], 0
mov ecx, dword [esi + 0x1c]
lea eax, [esp + 0x10]
add edx, 2
push eax
push ecx
mov dword [esp + 0x1c], edx
call dword [sym.imp.USER32.dll_ClientToScreen]
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 0x14]
mov dword [esp + 0x34], 3
mov dword [esp + 0x3c], edx
mov dword [esp + 0x40], eax
xor ecx, ecx
push ecx
lea ecx, [esp + 0x2c]
push ecx
push 0x7d8
call fcn.00476be0
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x44
ret 0xc
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x44
ret 0xc

Function at 0x47aee0
Capabilities:
Check for time delay via gettickcount

Disassembly:
sub esp, 0xa0
push ebx
push ebp
mov ebp, dword [esp + 0xac]
push esi
push edi
push ebp
call sub.RASAPI32.dll_RasHangUpA
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, 0x28
xor eax, eax
lea edi, [esp + 0x10]
rep stosd dword es:[edi], eax
mov dword [esp + 0x10], 0xa0
call esi
mov edi, eax
call esi
sub eax, edi
cmp eax, 0xbb8
jae 0x47af46
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
lea eax, [esp + 0x10]
push eax
push ebp
call sub.RASAPI32.dll_RasGetConnectStatusA
cmp eax, 6
je 0x47af46
push 0
call ebx
call esi
sub eax, edi
cmp eax, 0xbb8
jb 0x47af27
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xa0
ret

Function at 0x47b2d0
Capabilities:
Create http request

Disassembly:
push esi
mov esi, ecx
cmp dword [esi], 0
jne 0x47b308
mov edx, dword [esi + 4]
xor eax, eax
push 0
push 0
mov ecx, dword [edx - 8]
test ecx, ecx
setne al
mov ecx, eax
neg ecx
sbb ecx, ecx
and ecx, edx
neg eax
sbb eax, eax
push ecx
and eax, 2
inc eax
push eax
push str.Mozilla_4.0__compatible__MSIE_6.0__Windows_NT_5.0_
call dword [sym.imp.WININET.dll_InternetOpenA]
mov dword [esi], eax
mov ecx, dword [esi]
xor eax, eax
test ecx, ecx
setne al
pop esi
ret
Function at 0x47bf30
Capabilities:
Get socket status

Disassembly:
sub esp, 0x10c
mov eax, dword [ecx]
lea ecx, [esp]
push ecx
push 0
lea edx, [esp + 0x10]
push 0
push edx
push 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x20], eax
mov dword [esp + 0x1c], 1
call sub.WS2_32.dll_select
cmp eax, 0xffffffff
jne 0x47bf79
xor eax, eax
add esp, 0x10c
ret 4
mov edx, dword [esp + 0x110]
xor ecx, ecx
test eax, eax
setne cl
mov dword [edx], ecx
mov eax, 1
add esp, 0x10c
ret 4

Function at 0x47c3f0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x4ab6f0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
push esi
mov esi, ecx
lea ecx, [esp + 4]
call fcn.0047bfa0
lea eax, [esp + 4]
lea ecx, [esi + 4]
push eax
mov dword [esp + 0x18], 0
call fcn.0047c020
lea ecx, [esp + 4]
push ecx
lea ecx, [esi + 0x14]
call fcn.0047c020
lea ecx, [esi + 0xc]
call fcn.0049c22f
lea ecx, [esi + 0x10]
call fcn.0049c22f
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x1c]
call fcn.0047d5b0
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x30]
call fcn.0047d5b0
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x44]
call fcn.0047d5b0
lea ecx, [esp + 8]
mov dword [esp + 0x14], 1
call fcn.0049c2a4
lea ecx, [esp + 4]
mov dword [esp + 0x14], 0xffffffff
call fcn.0049c2a4
mov ecx, dword [esp + 0xc]
pop esi
mov dword fs:[0], ecx
add esp, 0x14
ret
Function at 0x49e675
Capabilities:
Get graphical window text

Disassembly:
push esi
mov esi, ecx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x49e6ad
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
lea ecx, [eax + 1]
push ecx
mov ecx, dword [esp + 0xc]
push eax
call fcn.0049c6ff
push eax
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov ecx, dword [esp + 8]
push 0xffffffffffffffff
call fcn.0049c6d7
jmp 0x49e6b9
mov eax, dword [ecx]
push dword [esp + 8]
call dword [eax + 0x88]
pop esi
ret 4

Function at 0x49fd63
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push esi
push edi
xor edi, edi
cmp dword [esp + 0x10], edi
mov ebx, ecx
je 0x49fda5
call fcn.004a5b20
mov esi, dword [eax + 0xc]
push 0xf0
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x49fda5
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x49fd9c
xor eax, eax
jmp 0x49fdad
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.0049fdb3
pop edi
pop esi
pop ebx
ret 4

Function at 0x4a6050
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, ecx
lea ebx, [esi + 0x1c]
push ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esp + 0x10], 0
jne 0x4a607e
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x4a609c
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.004a5fb6
jmp 0x4a609c
mov eax, dword [esi + 0x14]
test eax, eax
je 0x4a609c
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
mov ecx, esi
push eax
call fcn.004a5fb6
test edi, edi
mov eax, edi
jne 0x4a6086
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8
Function at 0x40a7a6
Capabilities:
Encode data using xor

Disassembly:
pop esi
push esi
xor dword [esi], ebx
lodsd eax, dword [esi]
add ebx, eax
test eax, eax
jne 0x40a7a8
ret
Function at 0x401430
Capabilities:
Create http request
Read data from internet
Receive data

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x114
push ebx
push esi
push edi
push 0
push 0
push 0
push 0
push str.MyAgent
mov dword [esp + 0x24], 0x7d0
call dword [sym.imp.WININET.dll_InternetOpenA]
mov esi, dword [sym.imp.WININET.dll_InternetSetOptionA]
push 4
mov ebx, eax
lea eax, [esp + 0x14]
push eax
push 2
push 0
call esi
push 4
lea ecx, [esp + 0x14]
push ecx
push 6
push 0
call esi
push 4
lea edx, [esp + 0x14]
push edx
push 5
push 0
call esi
push 4
lea eax, [esp + 0x14]
push eax
push 6
push 0
call esi
push 4
lea ecx, [esp + 0x14]
push ecx
push 5
push 0
call esi
test ebx, ebx
je 0x4014f2
mov edx, dword [ebp + 8]
push 0
push 0x80000000
push 0
push 0
push edx
push ebx
call dword [sym.imp.WININET.dll_InternetOpenUrlA]
mov esi, eax
test esi, esi
je 0x4014f2
xor eax, eax
mov ecx, 0x41
lea edi, [esp + 0x18]
rep stosd dword es:[edi], eax
lea eax, [esp + 0x14]
push eax
push 0x104
lea ecx, [esp + 0x20]
push ecx
push esi
call dword [sym.imp.WININET.dll_InternetReadFile]
push esi
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
call esi
push ebx
call esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x401500
Capabilities:
Set registry value

Disassembly:
push ecx
mov ecx, dword [esp + 8]
push ebx
lea eax, [esp + 4]
push eax
push ecx
push 0x80000002
mov bl, 1
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
test eax, eax
jne 0x40154c
mov edx, dword [esp + 0x14]
mov eax, edx
push esi
lea esi, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x401527
sub eax, esi
inc eax
push eax
mov eax, dword [esp + 0xc]
push edx
mov edx, dword [esp + 0x1c]
push 2
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
pop esi
je 0x40154e
xor bl, bl
mov ecx, dword [esp + 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov al, bl
pop ebx
pop ecx
ret
Function at 0x4017a5
Capabilities:
Accept command line arguments
Parse pe header
Terminate process

Disassembly:
push 0x18
push 0x407210
call fcn.00402e5c
mov edi, 0x94
mov eax, edi
call fcn.00402fc0
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 [0x4096d8], ecx
mov eax, dword [esi + 4]
mov dword [0x4096e4], eax
mov edx, dword [esi + 8]
mov dword [0x4096e8], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
mov dword [0x4096dc], esi
cmp ecx, 2
je 0x401805
or esi, 0x8000
mov dword [0x4096dc], esi
shl eax, 8
add eax, edx
mov dword [0x4096e0], eax
xor edi, edi
push edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
cmp word [eax], 0x5a4d
jne 0x40183e
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x40183e
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x401856
cmp eax, 0x20b
je 0x401843
mov dword [ebp - 0x1c], edi
jmp 0x40186a
cmp dword [ecx + 0x84], 0xe
jbe 0x40183e
xor eax, eax
cmp dword [ecx + 0xf8], edi
jmp 0x401864
cmp dword [ecx + 0x74], 0xe
jbe 0x40183e
xor eax, eax
cmp dword [ecx + 0xe8], edi
setne al
mov dword [ebp - 0x1c], eax
push edi
call fcn.00402e0a
pop ecx
test eax, eax
jne 0x401896
cmp dword [0x4096c8], 2
je 0x401883
call fcn.0040261c
push 0x1c
call fcn.004024a5
push 0xff
call fcn.0040230a
pop ecx
pop ecx
call fcn.00402d68
mov dword [ebp - 4], edi
call fcn.00402bbd
test eax, eax
jge 0x4018af
push 0x1b
call fcn.00401780
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x40ac74], eax
call fcn.00402a9b
mov dword [0x4096c0], eax
call fcn.004029f9
test eax, eax
jge 0x4018d5
push 8
call fcn.00401780
pop ecx
call fcn.004027c6
test eax, eax
jge 0x4018e6
push 9
call fcn.00401780
pop ecx
push 1
call fcn.0040233a
pop ecx
mov dword [ebp - 0x24], eax
cmp eax, edi
je 0x4018fc
push eax
call fcn.00401780
pop ecx
mov eax, dword [0x4096f8]
mov dword [0x4096fc], eax
push eax
push dword [0x4096f0]
push dword [0x4096ec]
call fcn.00401610
add esp, 0xc
mov esi, eax
mov dword [ebp - 0x28], esi
cmp dword [ebp - 0x1c], edi
jne 0x40192b
push esi
call fcn.00402465
call fcn.00402487
jmp 0x40195d
or dword [ebp - 4], 0xffffffff
mov eax, esi
lea esp, [ebp - 0x34]
call fcn.00402e97
ret
Function at 0x4023a4
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push esi
xor esi, esi
inc esi
cmp dword [0x409718], esi
push edi
jne 0x4023c4
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 [0x409714], esi
mov byte [0x409710], al
jne 0x40242a
mov ecx, dword [0x40ac68]
test ecx, ecx
je 0x40240b
mov eax, dword [0x40ac64]
sub eax, 4
cmp eax, ecx
jmp 0x402404
mov eax, dword [eax]
test eax, eax
je 0x4023f6
call eax
mov eax, dword [0x40ac64]
sub eax, 4
cmp eax, dword [0x40ac68]
mov dword [0x40ac64], eax
jae 0x4023ee
mov eax, 0x409020
mov esi, 0x409028
cmp eax, esi
mov edi, eax
jae 0x40242a
mov eax, dword [edi]
test eax, eax
je 0x402423
call eax
add edi, 4
cmp edi, esi
jb 0x40241b
mov eax, 0x40902c
mov esi, 0x409030
cmp eax, esi
mov edi, eax
jae 0x402449
mov eax, dword [edi]
test eax, eax
je 0x402442
call eax
add edi, 4
cmp edi, esi
jb 0x40243a
cmp dword [ebp + 0x10], 0
pop edi
pop esi
jne 0x402463
push dword [ebp + 8]
mov dword [0x409718], 1
call fcn.0040230a
pop ebp
ret

Function at 0x4024a5
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x8c]
sub esp, 0x10c
mov eax, dword [0x409420]
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 + 0x409050]
je 0x4024da
inc eax
cmp eax, 0x13
jb 0x4024cb
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x409050]
jne 0x402600
mov eax, dword [0x4096c8]
cmp eax, 1
je 0x4025d8
cmp eax, edx
jne 0x40250a
cmp dword [0x409044], 1
je 0x4025d8
cmp ecx, 0xfc
je 0x402600
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 0x402540
lea eax, [ebp - 0x80]
push str._program_name_unknown_
push eax
call fcn.004037f0
pop ecx
pop ecx
lea edi, [ebp - 0x80]
mov eax, edi
push eax
call fcn.004033e0
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x402574
mov eax, edi
push eax
call fcn.004033e0
mov edi, eax
lea eax, [ebp - 0x80]
sub eax, 0x3b
push 3
add edi, eax
push 0x4076a0
push edi
call fcn.004038f0
add esp, 0x10
push edi
call fcn.004033e0
push dword [esi + 0x409054]
mov ebx, eax
call fcn.004033e0
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.00402fc0
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.004037f0
push edi
push ebx
call fcn.00403800
push 0x407680
push ebx
call fcn.00403800
push dword [esi + 0x409054]
push ebx
call fcn.00403800
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.004036f1
add esp, 0x2c
jmp 0x402600
push edx
lea eax, [ebp + 0x94]
push eax
lea esi, [esi + 0x409054]
push dword [esi]
call fcn.004033e0
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.00403586
pop edi
pop esi
pop ebx
add ebp, 0x8c
leave
ret
Function at 0x403089
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x39c]
sub esp, 0x41c
mov ecx, dword [ebp + 0x3a4]
cmp ecx, dword [0x40ab4c]
mov eax, dword [0x409420]
push ebx
push esi
mov dword [ebp + 0x398], eax
push edi
jae 0x40324f
mov eax, ecx
sar eax, 5
lea ebx, [eax*4 + 0x40ab60]
mov eax, dword [ebx]
mov esi, ecx
and esi, 0x1f
shl esi, 3
mov al, byte [eax + esi + 4]
test al, 1
mov dword [ebp - 0x80], ebx
je 0x40324f
xor edi, edi
cmp dword [ebp + 0x3ac], edi
mov dword [ebp - 0x74], edi
mov dword [ebp - 0x7c], edi
jne 0x4030f3
xor eax, eax
jmp 0x403263
test al, 0x20
je 0x403104
push 2
push edi
push edi
push ecx
call fcn.0040508c
add esp, 0x10
mov eax, dword [ebx]
add eax, esi
test byte [eax + 4], 0x80
je 0x4031d9
cmp dword [ebp + 0x3ac], edi
mov eax, dword [ebp + 0x3a8]
mov dword [ebp - 0x70], eax
mov dword [ebp + 0x3a4], edi
jbe 0x403220
mov ecx, dword [ebp - 0x70]
sub ecx, dword [ebp + 0x3a8]
lea eax, [ebp - 0x6c]
cmp ecx, dword [ebp + 0x3ac]
jae 0x403166
mov edx, dword [ebp - 0x70]
inc dword [ebp - 0x70]
mov dl, byte [edx]
inc ecx
cmp dl, 0xa
jne 0x403157
inc dword [ebp - 0x7c]
mov byte [eax], 0xd
inc eax
inc edi
mov ebx, dword [ebp - 0x80]
mov byte [eax], dl
inc eax
inc edi
cmp edi, 0x400
jl 0x403139
mov edi, eax
lea eax, [ebp - 0x6c]
sub edi, eax
push 0
lea eax, [ebp - 0x78]
push eax
push edi
lea eax, [ebp - 0x6c]
push eax
mov eax, dword [ebx]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4031a6
mov eax, dword [ebp - 0x78]
add dword [ebp - 0x74], eax
cmp eax, edi
jl 0x4031b2
mov eax, dword [ebp - 0x70]
sub eax, dword [ebp + 0x3a8]
xor edi, edi
cmp eax, dword [ebp + 0x3ac]
jb 0x40312d
jmp 0x4031b4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp + 0x3a4], eax
xor edi, edi
mov eax, dword [ebp - 0x74]
cmp eax, edi
jne 0x40324a
cmp dword [ebp + 0x3a4], edi
je 0x403220
push 5
pop eax
cmp dword [ebp + 0x3a4], eax
jne 0x403212
mov dword [0x4096d0], eax
jmp 0x403256
push edi
lea ecx, [ebp - 0x78]
push ecx
push dword [ebp + 0x3ac]
push dword [ebp + 0x3a8]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x403204
mov eax, dword [ebp - 0x78]
mov dword [ebp + 0x3a4], edi
mov dword [ebp - 0x74], eax
jmp 0x4031b4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp + 0x3a4], eax
jmp 0x4031b4
push dword [ebp + 0x3a4]
call fcn.00404f77
pop ecx
jmp 0x403260
mov eax, dword [ebx]
test byte [eax + esi + 4], 0x40
je 0x403238
mov eax, dword [ebp + 0x3a8]
cmp byte [eax], 0x1a
je 0x4030ec
mov dword [0x4096cc], 0x1c
mov dword [0x4096d0], edi
jmp 0x403260
sub eax, dword [ebp - 0x7c]
jmp 0x403263
and dword [0x4096d0], 0
mov dword [0x4096cc], 9
or eax, 0xffffffff
mov ecx, dword [ebp + 0x398]
pop edi
pop esi
pop ebx
call fcn.00403586
add ebp, 0x39c
leave
ret
Function at 0x4036f1
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x409838], ebx
push esi
push edi
jne 0x403771
push str.user32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x4037ac
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxA
push edi
call esi
test eax, eax
mov dword [0x409838], eax
je 0x4037ac
push str.GetActiveWindow
push edi
call esi
push str.GetLastActivePopup
push edi
mov dword [0x40983c], eax
call esi
cmp dword [0x4096d8], 2
mov dword [0x409840], eax
jne 0x403771
push str.GetUserObjectInformationA
push edi
call esi
test eax, eax
mov dword [0x409848], eax
je 0x403771
push str.GetProcessWindowStation
push edi
call esi
mov dword [0x409844], eax
mov eax, dword [0x409844]
test eax, eax
je 0x4037b6
call eax
test eax, eax
je 0x40379d
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x409848]
test eax, eax
je 0x40379d
test byte [ebp - 8], 1
jne 0x4037b6
cmp dword [0x4096e4], 4
jb 0x4037b0
or byte [ebp + 0x12], 0x20
jmp 0x4037d5
xor eax, eax
jmp 0x4037e5
or byte [ebp + 0x12], 4
jmp 0x4037d5
mov eax, dword [0x40983c]
test eax, eax
je 0x4037d5
call eax
mov ebx, eax
test ebx, ebx
je 0x4037d5
mov eax, dword [0x409840]
test eax, eax
je 0x4037d5
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x409838]
pop edi
pop esi
pop ebx
leave
ret