joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1002801
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push 0x10013c8
push 0x29
mov edi, eax
call dword [sym.imp.USER32.dll_GetSystemMetrics]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
xor esi, esi
cmp eax, esi
mov dword [ebp - 4], eax
je 0x1002834
push 1
push 1
call eax
push dword [ebp + 0x14]
push edi
call fcn.01001b4a
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.010041ca
test eax, eax
jne 0x1002855
mov dword [ebp - 0x18], esi
jmp 0x1002905
push ebx
push esi
push esi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
push 0x1001c51
push esi
mov eax, 0x800b
push eax
push eax
call dword [sym.imp.USER32.dll_SetWinEventHook]
mov edi, dword [sym.imp.USER32.dll_GetMessageW]
mov ebx, eax
jmp 0x10028db
cmp dword [ebp - 0x1c], 0x50
jne 0x1002895
push esi
push esi
push 0x8001
push dword [0x1008810]
call dword [sym.imp.USER32.dll_PostMessageW]
mov eax, dword [0x100881c]
cmp eax, esi
je 0x10028ad
lea ecx, [ebp - 0x20]
push ecx
push eax
call dword [sym.imp.USER32.dll_IsDialogMessageW]
test eax, eax
jne 0x10028db
lea eax, [ebp - 0x20]
push eax
push dword [0x10096d8]
push dword [0x1008810]
call dword [sym.imp.USER32.dll_TranslateAcceleratorW]
test eax, eax
jne 0x10028db
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.USER32.dll_DispatchMessageW]
push esi
push esi
lea eax, [ebp - 0x20]
push esi
push eax
call edi
test eax, eax
jne 0x100287c
call fcn.010018b0
push dword [0x1009b8c]
call dword [sym.imp.KERNEL32.dll_LocalFree]
cmp ebx, esi
je 0x1002904
push ebx
call dword [sym.imp.USER32.dll_UnhookWinEvent]
pop ebx
cmp dword [ebp - 4], esi
je 0x1002910
push esi
push 1
call dword [ebp - 4]
mov eax, dword [ebp - 0x18]
pop edi
pop esi
leave
ret 0x10

Function at 0x100365a
Capabilities:
Set registry value

Disassembly:
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea eax, [eax + eax + 2]
push eax
push dword [esp + 0x10]
push 1
push 0
push dword [esp + 0x18]
push dword [esp + 0x18]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
ret 0xc

Function at 0x1003682
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
and dword [ebp - 4], 0
cmp dword [ebp + 8], 0
mov dword [ebp - 8], 1
mov dword [ebp - 0xc], 4
je 0x10036c4
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 4]
push eax
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x10036c4
cmp dword [ebp - 4], 4
je 0x10036c9
mov eax, dword [ebp + 0x10]
jmp 0x10036cc
mov eax, dword [ebp - 8]
leave
ret 0xc
Function at 0x10036d0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 0x18]
add esi, esi
cmp dword [ebp + 8], 0
push edi
mov edi, dword [ebp + 0x14]
mov dword [ebp + 0x18], esi
je 0x1003707
lea eax, [ebp + 0x18]
push eax
push edi
lea eax, [ebp + 8]
push eax
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x1003707
cmp dword [ebp + 8], 1
je 0x100371a
mov ecx, esi
mov esi, dword [ebp + 0x10]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
pop ebp
ret 0x14
Function at 0x1004796
Capabilities:
Encode data using xor

Disassembly:
push esi
mov esi, dword [esp + 0x10]
test esi, esi
jbe 0x10047be
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 8]
push ebx
movzx dx, byte [eax + 1]
xor ebx, ebx
mov bh, byte [eax]
xor edx, ebx
mov word [ecx], dx
inc ecx
inc ecx
inc eax
inc eax
dec esi
jne 0x10047a8
pop ebx
pop esi
ret 0xc

Function at 0x10047c2
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [ebp + 0x18], ebx
jne 0x10047d8
xor eax, eax
inc eax
jmp 0x1004868
cmp dword [ebp + 0xc], 0xfde9
mov dword [ebp - 4], ebx
je 0x10047ea
lea eax, [ebp - 0xc]
mov dword [ebp - 4], eax
push esi
mov esi, dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push edi
push dword [ebp - 4]
push ebx
push ebx
push ebx
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call esi
mov edi, eax
cmp edi, ebx
jne 0x1004810
xor eax, eax
jmp 0x1004866
lea eax, [edi + 1]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
cmp eax, ebx
mov dword [ebp - 8], eax
jne 0x100482d
push 8
call dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x100480c
push dword [ebp - 4]
push ebx
push edi
push eax
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call esi
mov esi, eax
cmp esi, ebx
je 0x100485b
push ebx
lea eax, [ebp - 0x10]
push eax
push edi
push dword [ebp - 8]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov esi, eax
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret 0x14
Function at 0x1006a6f
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
lea eax, [ebp - 4]
push esi
xor esi, esi
push eax
push 0x20019
push esi
push 0x1001848
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x1006ac7
lea eax, [ebp - 8]
mov dword [ebp - 8], 0x104
push eax
push dword [ebp + 8]
push esi
push esi
push 0x1001884
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x1006aba
push 1
pop esi
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
jmp 0x1006ac9
xor eax, eax
pop esi
leave
ret 4
Function at 0x1006ae0
Capabilities:
Parse pe header
Terminate process

Disassembly:
push 0x70
push 0x1001888
call fcn.01006ca8
xor ebx, ebx
push ebx
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call edi
cmp word [eax], 0x5a4d
jne 0x1006b1d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x1006b1d
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x1006b35
cmp eax, 0x20b
je 0x1006b22
mov dword [ebp - 0x1c], ebx
jmp 0x1006b49
cmp dword [ecx + 0x84], 0xe
jbe 0x1006b1d
xor eax, eax
cmp dword [ecx + 0xf8], ebx
jmp 0x1006b43
cmp dword [ecx + 0x74], 0xe
jbe 0x1006b1d
xor eax, eax
cmp dword [ecx + 0xe8], ebx
setne al
mov dword [ebp - 0x1c], eax
mov dword [ebp - 4], ebx
push 2
call dword [sym.imp.msvcrt.dll___set_app_type]
pop ecx
or dword [0x1009b9c], 0xffffffff
or dword [0x1009ba0], 0xffffffff
call dword [sym.imp.msvcrt.dll___p__fmode]
mov ecx, dword [0x1008aa0]
mov dword [eax], ecx
call dword [sym.imp.msvcrt.dll___p__commode]
mov ecx, dword [0x1008a9c]
mov dword [eax], ecx
mov eax, dword [sym.imp.msvcrt.dll__adjust_fdiv]
mov eax, dword [eax]
mov dword [0x1009ba4], eax
call fcn.01006d10
cmp dword [0x10085e8], ebx
jne 0x1006ba4
push fcn.01006d10
call dword [sym.imp.msvcrt.dll___setusermatherr]
pop ecx
call fcn.01006cfe
push 0x1001330
push 0x100132c
call sub.msvcrt.dll__initterm
mov eax, dword [0x1008a98]
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x20]
push eax
push dword [0x1008a94]
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.msvcrt.dll___getmainargs]
mov dword [ebp - 0x30], eax
push 0x1001328
push 0x1001324
call sub.msvcrt.dll__initterm
add esp, 0x24
mov eax, dword [sym.imp.msvcrt.dll__acmdln]
mov esi, dword [eax]
mov dword [ebp - 0x34], esi
cmp byte [esi], 0x22
jne 0x1006c3a
inc esi
mov dword [ebp - 0x34], esi
mov al, byte [esi]
cmp al, bl
je 0x1006c0e
cmp al, 0x22
jne 0x1006c00
cmp byte [esi], 0x22
jne 0x1006c17
inc esi
mov dword [ebp - 0x34], esi
mov al, byte [esi]
cmp al, bl
je 0x1006c21
cmp al, 0x20
jbe 0x1006c13
mov dword [ebp - 0x4c], ebx
lea eax, [ebp - 0x78]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
test byte [ebp - 0x4c], 1
je 0x1006c45
movzx eax, word [ebp - 0x48]
jmp 0x1006c48
cmp byte [esi], 0x20
jbe 0x1006c17
inc esi
mov dword [ebp - 0x34], esi
jmp 0x1006c3a
push 0xa
pop eax
push eax
push esi
push ebx
push ebx
call edi
push eax
call main
mov esi, eax
mov dword [ebp - 0x7c], esi
cmp dword [ebp - 0x1c], ebx
jne 0x1006c65
push esi
call dword [sym.imp.msvcrt.dll_exit]
call dword [sym.imp.msvcrt.dll__cexit]
jmp 0x1006c9a
or dword [ebp - 4], 0xffffffff
mov eax, esi
call fcn.01006ce1
ret
Function at 0x401d00
Capabilities:
Hide graphical window
Inspect load icon resource

Disassembly:
sub esp, 0x44
push esi
mov esi, dword [esp + 0x4c]
push 0x40b040
push esi
mov dword [esp + 0x28], 3
mov dword [esp + 0x2c], 0x401000
mov dword [esp + 0x30], 0
mov dword [esp + 0x34], 0x1e
mov dword [esp + 0x38], esi
call dword [sym.imp.USER32.dll_LoadIconA]
push 0x6a
push esi
mov dword [esp + 0x3c], eax
call dword [sym.imp.USER32.dll_LoadCursorA]
mov dword [esp + 0x38], eax
lea eax, [esp + 0x20]
push eax
mov dword [esp + 0x40], 0x10
mov dword [esp + 0x44], 0
mov dword [esp + 0x48], 0x40b040
call dword [sym.imp.USER32.dll_RegisterClassA]
test ax, ax
jne 0x401d8e
push 0x10
push 0x40b040
push str.This_program_requires_Windows_NT_
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xor eax, eax
pop esi
add esp, 0x44
ret 0x10
push edi
push 0
push 0
push 0
push 0x40b040
push esi
call dword [sym.imp.USER32.dll_CreateDialogParamA]
push 0
push eax
mov dword [0x40bb9c], eax
call dword [sym.imp.USER32.dll_GetSystemMenu]
mov edi, dword [sym.imp.USER32.dll_AppendMenuA]
push 0
push 0
mov esi, eax
push 0x800
push esi
call edi
push 0x4092bc
push 0xb
push 0
push esi
call edi
push 0x4092b4
push 0xc
push 0
push esi
call edi
mov ecx, dword [esp + 0x5c]
mov edx, dword [0x40bb9c]
push ecx
push edx
call dword [sym.imp.USER32.dll_ShowWindow]
mov esi, dword [sym.imp.USER32.dll_GetMessageA]
push 0
push 0
push 0
lea eax, [esp + 0x14]
push eax
call esi
test eax, eax
je 0x401e31
mov edi, dword [sym.imp.USER32.dll_TranslateMessage]
push ebx
mov ebx, dword [sym.imp.USER32.dll_DispatchMessageA]
lea ecx, [esp + 0xc]
push ecx
call edi
lea edx, [esp + 0xc]
push edx
call ebx
push 0
push 0
push 0
lea eax, [esp + 0x18]
push eax
call esi
test eax, eax
jne 0x401e11
pop ebx
mov eax, dword [esp + 0x10]
pop edi
pop esi
add esp, 0x44
ret 0x10
Function at 0x4020d6
Capabilities:
Accept command line arguments
Parse pe header
Terminate process

Disassembly:
push 0x60
push 0x409318
call fcn.004031fc
mov edi, 0x94
mov eax, edi
call fcn.00404260
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 [0x40bc98], ecx
mov eax, dword [esi + 4]
mov dword [0x40bca4], eax
mov edx, dword [esi + 8]
mov dword [0x40bca8], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
mov dword [0x40bc9c], esi
cmp ecx, 2
je 0x402136
or esi, 0x8000
mov dword [0x40bc9c], esi
shl eax, 8
add eax, edx
mov dword [0x40bca0], eax
xor esi, esi
push esi
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call edi
cmp word [eax], 0x5a4d
jne 0x402171
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x402171
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x402189
cmp eax, 0x20b
je 0x402176
mov dword [ebp - 0x1c], esi
jmp 0x40219d
cmp dword [ecx + 0x84], 0xe
jbe 0x402171
xor eax, eax
cmp dword [ecx + 0xf8], esi
jmp 0x402197
cmp dword [ecx + 0x74], 0xe
jbe 0x402171
xor eax, eax
cmp dword [ecx + 0xe8], esi
setne al
mov dword [ebp - 0x1c], eax
push esi
call fcn.0040420b
pop ecx
test eax, eax
jne 0x4021c9
cmp dword [0x40bc54], 1
jne 0x4021b6
call fcn.004039b4
push 0x1c
call fcn.0040383d
push 0xff
call fcn.004036a6
pop ecx
pop ecx
call fcn.00404169
mov dword [ebp - 4], esi
call fcn.00403fbe
test eax, eax
jge 0x4021e2
push 0x1b
call fcn.004020b1
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x40d230], eax
call fcn.00403e9c
mov dword [0x40bc4c], eax
call fcn.00403dfa
test eax, eax
jge 0x402208
push 8
call fcn.004020b1
pop ecx
call fcn.00403bc7
test eax, eax
jge 0x402219
push 9
call fcn.004020b1
pop ecx
call fcn.004036d6
mov dword [ebp - 0x20], eax
cmp eax, esi
je 0x40222c
push eax
call fcn.004020b1
pop ecx
mov dword [ebp - 0x38], esi
lea eax, [ebp - 0x64]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
call fcn.00403b5e
mov dword [ebp - 0x68], eax
test byte [ebp - 0x38], 1
je 0x40224d
movzx eax, word [ebp - 0x34]
jmp 0x402250
push 0xa
pop eax
push eax
push dword [ebp - 0x68]
push esi
push esi
call edi
push eax
call fcn.00401d00
mov edi, eax
mov dword [ebp - 0x6c], edi
cmp dword [ebp - 0x1c], esi
jne 0x40226e
push edi
call fcn.004037fd
call fcn.0040381f
jmp 0x4022a0
or dword [ebp - 4], 0xffffffff
mov eax, edi
lea esp, [ebp - 0x7c]
call fcn.00403237
ret
Function at 0x40373b
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push esi
xor esi, esi
inc esi
cmp dword [0x40bcd8], esi
push edi
jne 0x40375b
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 [0x40bcd4], esi
mov byte [0x40bcd0], al
jne 0x4037c1
mov ecx, dword [0x40d228]
test ecx, ecx
je 0x4037a2
mov eax, dword [0x40d224]
sub eax, 4
cmp eax, ecx
jmp 0x40379b
mov eax, dword [eax]
test eax, eax
je 0x40378d
call eax
mov eax, dword [0x40d224]
sub eax, 4
cmp eax, dword [0x40d228]
mov dword [0x40d224], eax
jae 0x403785
mov eax, 0x40b024
mov esi, 0x40b02c
cmp eax, esi
mov edi, eax
jae 0x4037c1
mov eax, dword [edi]
test eax, eax
je 0x4037ba
call eax
add edi, 4
cmp edi, esi
jb 0x4037b2
mov eax, 0x40b030
mov esi, 0x40b038
cmp eax, esi
mov edi, eax
jae 0x4037e0
mov eax, dword [edi]
test eax, eax
je 0x4037d9
call eax
add edi, 4
cmp edi, esi
jb 0x4037d1
cmp dword [ebp + 0x10], 0
pop edi
pop esi
jne 0x4037fb
push dword [ebp + 8]
mov dword [0x40bcd8], 1
call fcn.004036a6
pop ecx
pop ebp
ret

Function at 0x40383d
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
mov eax, dword [0x40b07c]
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 + 0x40b100]
je 0x40386a
inc eax
cmp eax, 0x12
jb 0x40385b
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x40b100]
jne 0x40399e
mov eax, dword [0x40bc54]
cmp eax, 1
je 0x403979
cmp eax, edx
jne 0x40389a
cmp dword [0x40b098], 1
je 0x403979
cmp ecx, 0xfc
je 0x40399e
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 0x4038d3
lea eax, [ebp - 0x10c]
push str._program_name_unknown_
push eax
call fcn.00404dc0
pop ecx
pop ecx
lea eax, [ebp - 0x10c]
push eax
lea edi, [ebp - 0x10c]
call fcn.00402f50
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x403915
lea eax, [ebp - 0x10c]
push eax
call fcn.00402f50
mov edi, eax
lea eax, [ebp - 0x10c]
sub eax, 0x3b
push 3
add edi, eax
push 0x40982c
push edi
call fcn.004060a0
add esp, 0x10
push edi
call fcn.00402f50
push dword [esi + 0x40b104]
mov ebx, eax
call fcn.00402f50
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.00404260
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.00404dc0
push edi
push ebx
call fcn.00404dd0
push 0x409828
push ebx
call fcn.00404dd0
push dword [esi + 0x40b104]
push ebx
call fcn.00404dd0
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.00405fa6
add esp, 0x2c
jmp 0x40399e
push edx
lea eax, [ebp + 8]
push eax
lea esi, [esi + 0x40b104]
push dword [esi]
call fcn.00402f50
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.00401fdd
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4051d4
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x41c
mov eax, dword [0x40b07c]
xor eax, dword [ebp + 4]
mov ecx, dword [ebp + 8]
cmp ecx, dword [0x40d108]
push ebx
push esi
mov dword [ebp - 4], eax
push edi
jae 0x405364
mov eax, ecx
sar eax, 5
lea ebx, [eax*4 + 0x40d120]
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 - 0x18], ebx
je 0x405364
xor edi, edi
cmp dword [ebp + 0x10], edi
mov dword [ebp - 0xc], edi
mov dword [ebp - 0x14], edi
jne 0x405233
xor eax, eax
jmp 0x405378
test al, 0x20
je 0x405244
push 2
push edi
push edi
push ecx
call fcn.00407317
add esp, 0x10
mov eax, dword [ebx]
add eax, esi
test byte [eax + 4], 0x80
je 0x405300
cmp dword [ebp + 0x10], edi
mov eax, dword [ebp + 0xc]
mov dword [ebp - 8], eax
mov dword [ebp + 8], edi
jbe 0x405338
mov ecx, dword [ebp - 8]
sub ecx, dword [ebp + 0xc]
lea eax, [ebp - 0x41c]
cmp ecx, dword [ebp + 0x10]
jae 0x40529a
mov edx, dword [ebp - 8]
inc dword [ebp - 8]
mov dl, byte [edx]
inc ecx
cmp dl, 0xa
jne 0x40528b
inc dword [ebp - 0x14]
mov byte [eax], 0xd
inc eax
inc edi
mov ebx, dword [ebp - 0x18]
mov byte [eax], dl
inc eax
inc edi
cmp edi, 0x400
jl 0x405270
mov edi, eax
lea eax, [ebp - 0x41c]
sub edi, eax
push 0
lea eax, [ebp - 0x10]
push eax
push edi
lea eax, [ebp - 0x41c]
push eax
mov eax, dword [ebx]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4052da
mov eax, dword [ebp - 0x10]
add dword [ebp - 0xc], eax
cmp eax, edi
jl 0x4052e3
mov eax, dword [ebp - 8]
sub eax, dword [ebp + 0xc]
xor edi, edi
cmp eax, dword [ebp + 0x10]
jb 0x405264
jmp 0x4052e5
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp + 8], eax
xor edi, edi
mov eax, dword [ebp - 0xc]
cmp eax, edi
jne 0x40535f
cmp dword [ebp + 8], edi
je 0x405338
push 5
pop eax
cmp dword [ebp + 8], eax
jne 0x40532d
mov dword [0x40bc90], eax
jmp 0x40536b
push edi
lea ecx, [ebp - 0x10]
push ecx
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x405322
mov eax, dword [ebp - 0x10]
mov dword [ebp + 8], edi
mov dword [ebp - 0xc], eax
jmp 0x4052e5
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp + 8], eax
jmp 0x4052e5
push dword [ebp + 8]
call fcn.00407202
pop ecx
jmp 0x405375
mov eax, dword [ebx]
test byte [eax + esi + 4], 0x40
je 0x40534d
mov eax, dword [ebp + 0xc]
cmp byte [eax], 0x1a
je 0x40522c
mov dword [0x40bc8c], 0x1c
mov dword [0x40bc90], edi
jmp 0x405375
sub eax, dword [ebp - 0x14]
jmp 0x405378
and dword [0x40bc90], 0
mov dword [0x40bc8c], 9
or eax, 0xffffffff
mov ecx, dword [ebp - 4]
xor ecx, dword [ebp + 4]
pop edi
pop esi
pop ebx
call fcn.00401fdd
leave
ret
Function at 0x405fa6
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x40be24], ebx
push esi
push edi
jne 0x406026
push str.user32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x406061
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x409df4
push edi
call esi
test eax, eax
mov dword [0x40be24], eax
je 0x406061
push str.GetActiveWindow
push edi
call esi
push str.GetLastActivePopup
push edi
mov dword [0x40be28], eax
call esi
cmp dword [0x40bc98], 2
mov dword [0x40be2c], eax
jne 0x406026
push str.GetUserObjectInformationA
push edi
call esi
test eax, eax
mov dword [0x40be34], eax
je 0x406026
push str.GetProcessWindowStation
push edi
call esi
mov dword [0x40be30], eax
mov eax, dword [0x40be30]
test eax, eax
je 0x40606b
call eax
test eax, eax
je 0x406052
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x40be34]
test eax, eax
je 0x406052
test byte [ebp - 8], 1
jne 0x40606b
cmp dword [0x40bca4], 4
jb 0x406065
or byte [ebp + 0x12], 0x20
jmp 0x40608a
xor eax, eax
jmp 0x40609a
or byte [ebp + 0x12], 4
jmp 0x40608a
mov eax, dword [0x40be28]
test eax, eax
je 0x40608a
call eax
mov ebx, eax
test ebx, ebx
je 0x40608a
mov eax, dword [0x40be2c]
test eax, eax
je 0x40608a
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x40be24]
pop edi
pop esi
pop ebx
leave
ret

Function at 0x407c31
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.00404260
mov ebx, esp
push 0x1c
lea eax, [ebp - 0x24]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x407cc6
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 [0x40bc98]
mov ecx, eax
dec ecx
neg ecx
sbb ecx, ecx
and ecx, 0xffff1000
add ecx, 0x11000
add ecx, edi
cmp esi, ecx
jb 0x407cc6
cmp eax, 1
je 0x407cde
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 0x407cc6
add ebx, dword [ebp - 0x18]
test dword [ebp - 0x14], edi
je 0x407c9b
test byte [ebp - 0xf], 1
mov ebx, dword [ebp - 0x24]
je 0x407cc2
xor eax, eax
inc eax
jmp 0x407cfa
cmp esi, ebx
jae 0x407cca
xor eax, eax
jmp 0x407cfa
push 4
push edi
push dword [ebp - 4]
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov eax, dword [0x40bc98]
jmp 0x407ce0
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 0x4012c0
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4040d8
push 0x402518
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
add esp, 0xffffffa8
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
call dword [sym.imp.KERNEL32.dll_GetVersion]
xor edx, edx
mov dl, ah
mov dword [0x407598], edx
mov ecx, eax
and ecx, 0xff
mov dword [0x407594], ecx
shl ecx, 8
add ecx, edx
mov dword [0x407590], ecx
shr eax, 0x10
mov dword [0x40758c], eax
call fcn.004023e0
test eax, eax
jne 0x40132a
push 0x1c
call fcn.00401490
add esp, 4
mov dword [ebp - 4], 0
call fcn.004021e0
call fcn.004021d0
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x407a74], eax
call fcn.00401b90
mov dword [0x407574], eax
test eax, eax
je 0x40135d
mov eax, dword [0x407a74]
test eax, eax
jne 0x401367
push 0xffffffffffffffff
call fcn.004014f0
add esp, 4
call fcn.004018e0
call fcn.004017f0
call fcn.004014c0
mov esi, dword [0x407a74]
mov dword [ebp - 0x64], esi
cmp byte [esi], 0x22
jne 0x401446
inc esi
mov dword [ebp - 0x64], esi
mov al, byte [esi]
cmp al, 0x22
je 0x4013ae
test al, al
je 0x4013ae
and eax, 0xff
push eax
call fcn.00401790
add esp, 4
test eax, eax
je 0x401388
inc esi
mov dword [ebp - 0x64], esi
jmp 0x401388
cmp byte [esi], 0x22
jne 0x4013b7
inc esi
mov dword [ebp - 0x64], esi
mov al, byte [esi]
test al, al
je 0x4013c7
cmp al, 0x20
ja 0x4013c7
inc esi
mov dword [ebp - 0x64], esi
jmp 0x4013b7
mov dword [ebp - 0x30], 0
lea eax, [ebp - 0x5c]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
test byte [ebp - 0x30], 1
je 0x4013e8
mov eax, dword [ebp - 0x2c]
and eax, 0xffff
jmp 0x4013ed
mov eax, 0xa
push eax
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call main
mov dword [ebp - 0x60], eax
push eax
call fcn.004014f0
jmp 0x40142b
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp byte [esi], 0x20
jbe 0x4013b7
inc esi
mov dword [ebp - 0x64], esi
jmp 0x401446

Function at 0x401490
Capabilities:
Terminate process

Disassembly:
cmp dword [0x40757c], 1
jne 0x40149e
call fcn.004025f0
mov eax, dword [esp + 4]
push eax
call fcn.00402630
add esp, 4
push 0xff
call dword [sym.imp.KERNEL32.dll_ExitProcess]