joyce8/EMBER2024-capa huggingface dataset:
Function at 0x403479
Capabilities:
Enumerate processes
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x268
mov eax, dword [ebp + 0x10]
push ebx
xor ebx, ebx
cmp eax, ebx
push esi
push edi
je 0x403490
mov dword [eax], ebx
cmp dword [ebp + 8], ebx
je 0x4034c5
xor eax, eax
push ebx
mov ecx, 0x8a
lea edi, [ebp - 0x264]
rep stosd dword es:[edi], eax
push 2
mov dword [ebp - 0x268], 0x22c
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
cmp eax, 0xffffffff
mov dword [ebp - 8], eax
jne 0x4034cc
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor al, al
jmp 0x40361d
lea eax, [ebp - 0x268]
push eax
push dword [ebp - 8]
mov byte [ebp - 1], 1
call sub.KERNEL32.dll_Process32FirstW
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x403608
push dword [ebp + 8]
lea eax, [ebp - 0x244]
push eax
call fcn.004088c3
test eax, eax
pop ecx
pop ecx
jne 0x4035f9
xor edi, edi
inc edi
cmp dword [ebp + 0xc], edi
jne 0x403538
push dword [ebp - 0x260]
push edi
push edi
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov edi, eax
cmp edi, ebx
je 0x403578
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
test eax, eax
push edi
jne 0x4035ee
mov byte [ebp - 1], bl
jmp 0x4035ea
cmp dword [ebp + 0xc], 2
jne 0x4035f0
lea eax, [ebp - 0xc]
push eax
push dword [ebp - 0x260]
mov dword [ebp - 0xc], ebx
call fcn.00403ac7
cmp dword [ebp - 0xc], 2
pop ecx
pop ecx
jne 0x4035f9
push dword [ebp - 0x260]
push edi
push 0x400
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov edi, eax
cmp edi, ebx
jne 0x40357d
mov byte [ebp - 1], bl
jmp 0x4035f9
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x14]
push eax
push edi
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], ebx
call dword [sym.imp.KERNEL32.dll_GetProcessTimes]
test eax, eax
jne 0x4035b6
mov byte [ebp - 1], bl
push edi
jmp 0x4035ea
lea eax, [ebp - 0x34]
push eax
call fcn.004033a7
push ecx
push ecx
mov eax, esp
mov dword [eax], 0x1312d00
mov dword [eax + 4], ebx
push dword [ebp - 0x10]
lea eax, [ebp - 0x3c]
push dword [ebp - 0x14]
lea ecx, [ebp - 0x34]
push eax
call fcn.00403403
mov ecx, eax
call fcn.0040338a
cmp al, bl
push edi
je 0x4035ee
call esi
jmp 0x4035f9
call esi
mov eax, dword [ebp + 0x10]
cmp eax, ebx
je 0x4035f9
inc dword [eax]
lea eax, [ebp - 0x268]
push eax
push dword [ebp - 8]
call sub.KERNEL32.dll_Process32NextW
test eax, eax
jne 0x4034ea
cmp dword [ebp - 8], ebx
je 0x40361a
push dword [ebp - 8]
call esi
mov al, byte [ebp - 1]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x40375b
Capabilities:
Get user security identifier

Disassembly:
push ebp
lea ebp, [esp - 0x70]
sub esp, 0xdc
cmp dword [ebp + 0x78], 0
push esi
mov esi, ecx
jne 0x403776
xor al, al
jmp 0x4038c6
and dword [ebp - 0x6c], 0
push ebx
push edi
lea eax, [ebp + 0x1c]
push pe_nt_image_headers32
lea ecx, [ebp - 0x6c]
mov dword [ebp + 0x18], eax
call fcn.00403436
mov ecx, dword [ebp - 0x6c]
mov eax, dword [ebp + 0x18]
mov edi, dword [sym.imp.ADVAPI32.dll_LookupAccountNameW]
lea ebx, [esi + 8]
push ebx
lea edx, [ebp + 0x64]
push edx
push ecx
mov dword [ebp + 0x60], ecx
lea ecx, [ebp + 0x6c]
push ecx
push eax
push dword [ebp + 0x78]
mov dword [ebp + 0x68], eax
push dword [ebp + 0x7c]
mov dword [ebp + 0x6c], 0x44
mov dword [ebp + 0x64], 0x80
call edi
test eax, eax
jne 0x403824
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x40389b
cmp dword [ebp + 0x6c], 0x44
jbe 0x4037ef
push dword [ebp + 0x6c]
lea ecx, [ebp + 0x18]
call fcn.004036b0
mov eax, dword [ebp + 0x18]
mov dword [ebp + 0x68], eax
cmp dword [ebp + 0x64], 0x80
jbe 0x403809
push dword [ebp + 0x64]
lea ecx, [ebp - 0x6c]
call fcn.0040365b
mov eax, dword [ebp - 0x6c]
mov dword [ebp + 0x60], eax
push ebx
lea eax, [ebp + 0x64]
push eax
push dword [ebp + 0x60]
lea eax, [ebp + 0x6c]
push eax
push dword [ebp + 0x68]
push dword [ebp + 0x78]
push dword [ebp + 0x7c]
call edi
test eax, eax
je 0x40389b
push dword [ebp + 0x68]
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
push dword [esi + 4]
mov dword [ebp + 0x6c], eax
call fcn.00407a4d
push dword [ebp + 0x6c]
call fcn.004088b1
pop ecx
pop ecx
push dword [ebp + 0x68]
mov dword [esi + 4], eax
push eax
push dword [ebp + 0x6c]
call dword [sym.imp.ADVAPI32.dll_CopySid]
test eax, eax
je 0x40389b
push dword [ebp + 0x60]
lea ecx, [esi + 0x10]
call fcn.0040181c
push dword [ebp + 0x78]
lea ecx, [esi + 0xc]
call fcn.0040181c
push dword [ebp + 0x7c]
lea ecx, [esi + 0x18]
call fcn.0040181c
lea eax, [ebp - 0x68]
cmp dword [ebp - 0x6c], eax
je 0x403887
lea ecx, [ebp - 0x6c]
call fcn.004033fa
lea eax, [ebp + 0x1c]
cmp dword [ebp + 0x18], eax
je 0x403897
lea ecx, [ebp + 0x18]
call fcn.004033fa
mov al, 1
jmp 0x4038c4
mov ecx, esi
call fcn.00403622
lea eax, [ebp - 0x68]
cmp dword [ebp - 0x6c], eax
je 0x4038b2
lea ecx, [ebp - 0x6c]
call fcn.004033fa
lea eax, [ebp + 0x1c]
cmp dword [ebp + 0x18], eax
je 0x4038c2
lea ecx, [ebp + 0x18]
call fcn.004033fa
xor al, al
pop edi
pop ebx
pop esi
add ebp, 0x70
leave
ret 8
Function at 0x403959
Capabilities:
Get session user name

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
lea ecx, [ebp - 4]
call fcn.00404f67
lea ecx, [ebp - 8]
mov eax, 0x7fff
push ecx
push eax
lea ecx, [ebp - 4]
mov dword [ebp - 8], eax
call fcn.004016b1
push eax
call dword [sym.imp.ADVAPI32.dll_GetUserNameW]
test eax, eax
jne 0x4039a1
mov ecx, dword [ebp + 8]
push 0x412750
call fcn.00401841
mov ecx, dword [ebp - 4]
add ecx, 0xfffffff0
call fcn.004012bf
jmp 0x4039f1
push esi
push dword [ebp - 8]
lea ecx, [ebp - 4]
call fcn.00402720
mov esi, dword [ebp - 4]
push 0
push esi
lea ecx, [ebp - 0x24]
call fcn.00403907
push dword [ebp - 0x20]
call dword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
jne 0x4039cf
push 0x412750
jmp 0x4039d8
lea ecx, [ebp - 0x24]
call fcn.004038ce
push eax
mov ecx, dword [ebp + 8]
call fcn.00401841
lea ecx, [ebp - 0x24]
call fcn.00403700
lea ecx, [esi - 0x10]
call fcn.004012bf
pop esi
mov eax, dword [ebp + 8]
leave
ret

Function at 0x403b89
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
push esi
xor esi, esi
cmp dword [ebp + 0x14], esi
mov dword [ebp - 0x3c], 0x3c
mov dword [ebp - 0x38], 0x400
je 0x403bac
mov dword [ebp - 0x38], 0x440
mov eax, dword [ebp + 8]
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x3c]
push eax
mov dword [ebp - 4], esi
mov dword [ebp - 0x34], esi
mov dword [ebp - 0x30], 0x41329c
mov dword [ebp - 0x24], esi
mov dword [ebp - 0x1c], esi
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
jne 0x403be6
call fcn.004029ea
jmp 0x403c0d
cmp dword [ebp + 0x14], esi
je 0x403c0b
push 0xffffffffffffffff
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp + 0x14]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
pop esi
leave
ret

Function at 0x404bb0
Capabilities:
Query or enumerate registry value

Disassembly:
mov eax, dword [ecx + 4]
test eax, eax
jne 0x404bbb
xor al, al
jmp 0x404bdc
push dword [esp + 0xc]
mov ecx, dword [esp + 8]
push dword [esp + 0xc]
mov ecx, dword [ecx]
push dword [esp + 0x18]
push 0
push ecx
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
neg eax
sbb eax, eax
inc eax
ret 0x10
Function at 0x405c91
Capabilities:
Delete registry key

Disassembly:
push ebp
mov ebp, esp
cmp byte [0x417f50], 0
push esi
mov esi, ecx
je 0x405ca9
cmp byte [0x417f51], 0
je 0x405caf
cmp dword [esi + 4], 0
jne 0x405cb3
xor al, al
jmp 0x405d1d
cmp byte [esi], 0
push ecx
mov ecx, esp
push dword [ebp + 8]
je 0x405ce5
call fcn.00401aba
lea eax, [ebp + 8]
push eax
mov ecx, esi
call fcn.00405ab5
mov ecx, dword [eax]
mov eax, dword [esi + 8]
test eax, eax
jne 0x405cda
mov eax, dword [esi + 4]
push ecx
push eax
call fcn.004063a4
pop ecx
pop ecx
jmp 0x405d09
call fcn.00401aba
lea eax, [ebp + 8]
push eax
mov ecx, esi
call fcn.00405ab5
mov ecx, dword [eax]
mov eax, dword [esi + 8]
test eax, eax
jne 0x405d01
mov eax, dword [esi + 4]
push ecx
push eax
call dword [sym.imp.SHLWAPI.dll_SHDeleteKeyW]
mov ecx, dword [ebp + 8]
add ecx, 0xfffffff0
mov esi, eax
call fcn.004012bf
xor eax, eax
test esi, esi
sete al
pop esi
pop ebp
ret 4

Function at 0x4060b2
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
lea ecx, [ebp - 4]
call fcn.00404f67
lea ecx, [ebp - 8]
mov eax, 0x104
push ecx
push eax
lea ecx, [ebp - 4]
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], 1
call fcn.004027ad
push eax
lea eax, [ebp - 0xc]
push eax
push 0
push str.CLSID0002DF01_0000_0000_C000_000000000046LocalServer32
push 0x80000000
call dword [sym.imp.SHLWAPI.dll_SHGetValueW]
push 0xffffffffffffffff
lea ecx, [ebp - 4]
call fcn.00402720
mov ecx, dword [ebp + 8]
lea eax, [ebp - 4]
push eax
call fcn.00401aba
mov ecx, dword [ebp - 4]
add ecx, 0xfffffff0
call fcn.004012bf
mov eax, dword [ebp + 8]
leave
ret

Function at 0x4062ba
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
push ebx
lea eax, [ebp - 4]
push esi
push eax
call fcn.004060b2
lea ecx, [ebp - 4]
mov dword [esp], 0x413c3c
call fcn.0040615d
push dword [ebp + 8]
lea ecx, [ebp - 4]
call fcn.00406145
push 0x413c38
lea ecx, [ebp - 4]
call fcn.0040615d
push 0x44
pop esi
push esi
xor ebx, ebx
lea eax, [ebp - 0x58]
push ebx
push eax
call fcn.00407550
add esp, 0xc
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x58]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
lea ecx, [ebp - 4]
mov dword [ebp - 0x58], esi
call fcn.00403118
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x40633c
push dword [ebp - 0x14]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x10]
call esi
mov bl, 1
mov ecx, dword [ebp - 4]
add ecx, 0xfffffff0
call fcn.004012bf
pop esi
mov al, bl
pop ebx
leave
ret
Function at 0x408156
Capabilities:
Parse pe header
Terminate process

Disassembly:
push 0x60
push 0x414098
call fcn.004075b0
mov edi, 0x94
mov eax, edi
call fcn.004080d0
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 [0x418204], ecx
mov eax, dword [esi + 4]
mov dword [0x418210], eax
mov edx, dword [esi + 8]
mov dword [0x418214], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
mov dword [0x418208], esi
cmp ecx, 2
je 0x4081b6
or esi, 0x8000
mov dword [0x418208], esi
shl eax, 8
add eax, edx
mov dword [0x41820c], eax
xor esi, esi
push esi
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call edi
cmp word [eax], 0x5a4d
jne 0x4081f1
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4081f1
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x408209
cmp eax, 0x20b
je 0x4081f6
mov dword [ebp - 0x1c], esi
jmp 0x40821d
cmp dword [ecx + 0x84], 0xe
jbe 0x4081f1
xor eax, eax
cmp dword [ecx + 0xf8], esi
jmp 0x408217
cmp dword [ecx + 0x74], 0xe
jbe 0x4081f1
xor eax, eax
cmp dword [ecx + 0xe8], esi
setne al
mov dword [ebp - 0x1c], eax
push 1
call fcn.004095d2
pop ecx
test eax, eax
jne 0x408231
push 0x1c
call fcn.00408132
pop ecx
call fcn.0040cdaa
test eax, eax
jne 0x408242
push 0x10
call fcn.00408132
pop ecx
call fcn.0040cb44
mov dword [ebp - 4], esi
call fcn.0040c946
test eax, eax
jge 0x40825b
push 0x1b
call fcn.0040810d
pop ecx
call fcn.0040c8a7
mov dword [0x4199dc], eax
call fcn.0040c73d
mov dword [0x41802c], eax
call fcn.0040c6a7
test eax, eax
jge 0x408280
push 8
call fcn.0040810d
pop ecx
call fcn.0040c474
test eax, eax
jge 0x408291
push 9
call fcn.0040810d
pop ecx
push 1
call fcn.0040a324
pop ecx
mov dword [ebp - 0x28], eax
cmp eax, esi
je 0x4082a7
push eax
call fcn.0040810d
pop ecx
mov dword [ebp - 0x44], esi
lea eax, [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoW]
call fcn.0040c42e
mov dword [ebp - 0x20], eax
test byte [ebp - 0x44], 1
je 0x4082c8
movzx eax, word [ebp - 0x40]
jmp 0x4082cb
push 0xa
pop eax
push eax
push dword [ebp - 0x20]
push esi
push esi
call edi
push eax
call fcn.004018cd
mov edi, eax
mov dword [ebp - 0x2c], edi
cmp dword [ebp - 0x1c], esi
jne 0x4082e9
push edi
call fcn.0040a451
call fcn.0040a473
jmp 0x40831b
or dword [ebp - 4], 0xffffffff
mov eax, edi
lea esp, [ebp - 0x7c]
call fcn.004075eb
ret
Function at 0x408b0b
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.004080d0
mov esi, esp
push 0x1c
lea eax, [ebp - 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x408ba6
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 [0x418204]
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 0x408ba6
cmp eax, 1
je 0x408bc7
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 0x408ba6
mov eax, dword [ebp - 0x1c]
add dword [ebp - 4], eax
test dword [ebp - 0x18], ebx
je 0x408b73
test byte [ebp - 0x13], 1
mov eax, dword [ebp - 0x28]
mov dword [ebp - 4], eax
je 0x408ba2
xor eax, eax
inc eax
jmp 0x408be6
cmp edi, eax
jae 0x408baa
xor eax, eax
jmp 0x408be6
cmp eax, esi
jae 0x408bb1
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 [0x418204]
jmp 0x408bca
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 0x40938f
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 0x4093bd
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 0x4093c4
cmp ebx, dword [eax + 4]
jae 0x4093c4
xor eax, eax
jmp 0x4095b4
push edi
mov edi, dword [esi + 0xc]
cmp edi, 0xffffffff
jne 0x4093d5
xor eax, eax
inc eax
jmp 0x4095b3
xor edx, edx
mov dword [ebp + 8], edx
mov eax, ebx
mov ecx, dword [eax]
cmp ecx, 0xffffffff
je 0x4093eb
cmp ecx, edx
jae 0x409530
cmp dword [eax + 4], 0
je 0x4093f4
inc dword [ebp + 8]
inc edx
add eax, 0xc
cmp edx, edi
jbe 0x4093dc
cmp dword [ebp + 8], 0
je 0x409416
mov eax, dword [esi - 8]
cmp eax, dword [ebp - 4]
jb 0x409530
cmp eax, esi
jae 0x409530
mov eax, dword [0x418060]
mov edi, ebx
and edi, 0xfffff000
xor esi, esi
test eax, eax
jle 0x40943b
cmp dword [esi*4 + 0x418068], edi
je 0x409534
inc esi
cmp esi, eax
jl 0x409429
push 0x1c
lea eax, [ebp - 0x20]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x4095b0
cmp dword [ebp - 8], 0x1000000
jne 0x4095b0
test byte [ebp - 0xc], 0xcc
je 0x4094b9
mov ecx, dword [ebp - 0x1c]
cmp word [ecx], 0x5a4d
jne 0x4095b0
mov eax, dword [ecx + 0x3c]
add eax, ecx
cmp dword [eax], 0x4550
jne 0x4095b0
cmp word [eax + 0x18], 0x10b
jne 0x4095b0
sub ebx, ecx
cmp word [eax + 6], 0
movzx ecx, word [eax + 0x14]
lea ecx, [ecx + eax + 0x18]
jbe 0x4095b0
mov eax, dword [ecx + 0xc]
cmp ebx, eax
jb 0x4094b9
mov edx, dword [ecx + 8]
add edx, eax
cmp ebx, edx
jae 0x4094b9
test byte [ecx + 0x27], 0x80
jne 0x409530
push 1
push 0x4180a8
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
test eax, eax
jne 0x4093cd
mov ecx, dword [0x418060]
test ecx, ecx
mov edx, ecx
jle 0x4094ed
lea eax, [ecx*4 + 0x418064]
cmp dword [eax], edi
je 0x4094ed
dec edx
sub eax, 4
test edx, edx
jg 0x4094e1
test edx, edx
jne 0x40951e
push 0xf
pop ebx
cmp ecx, ebx
jg 0x4094fa
mov ebx, ecx
xor edx, edx
test ebx, ebx
jl 0x409512
lea eax, [edx*4 + 0x418068]
mov esi, dword [eax]
inc edx
cmp edx, ebx
mov dword [eax], edi
mov edi, esi
jle 0x409500
cmp ecx, 0x10
jge 0x40951e
inc ecx
mov dword [0x418060], ecx
push 0
push 0x4180a8
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
jmp 0x4093cd
xor eax, eax
jmp 0x4095b3
test esi, esi
jle 0x4093cd
mov ebx, dword [sym.imp.KERNEL32.dll_InterlockedExchange]
push 1
push 0x4180a8
call ebx
test eax, eax
jne 0x4093cd
cmp dword [esi*4 + 0x418068], edi
je 0x40958a
mov eax, dword [0x418060]
lea esi, [eax - 1]
test esi, esi
jl 0x409578
cmp dword [esi*4 + 0x418068], edi
je 0x409574
dec esi
jns 0x409568
test esi, esi
jge 0x409588
cmp eax, 0x10
jge 0x409583
inc eax
mov dword [0x418060], eax
lea esi, [eax - 1]
jmp 0x40958a
je 0x4095a2
xor ecx, ecx
test esi, esi
jl 0x4095a2
lea eax, [ecx*4 + 0x418068]
mov edx, dword [eax]
inc ecx
cmp ecx, esi
mov dword [eax], edi
mov edi, edx
jle 0x409590
push 0
push 0x4180a8
call ebx
jmp 0x4093cd
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret
Function at 0x40a38e
Capabilities:
Terminate process

Disassembly:
push 8
push 0x4141b0
call fcn.004075b0
push 8
call fcn.00409776
pop ecx
xor edi, edi
mov dword [ebp - 4], edi
xor esi, esi
inc esi
cmp dword [0x418244], esi
jne 0x40a3c2
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov dword [0x418240], esi
mov al, byte [ebp + 0x10]
mov byte [0x41823c], al
cmp dword [ebp + 0xc], edi
jne 0x40a40c
cmp dword [0x4199ac], edi
je 0x40a3fc
mov eax, dword [0x4199a8]
sub eax, 4
mov dword [0x4199a8], eax
cmp eax, dword [0x4199ac]
jb 0x40a3fc
mov eax, dword [eax]
cmp eax, edi
je 0x40a3dd
call eax
jmp 0x40a3dd
push 0x417044
mov eax, 0x41703c
call fcn.0040a30c
pop ecx
push 0x417050
mov eax, 0x417048
call fcn.0040a30c
pop ecx
or dword [ebp - 4], 0xffffffff
call 0x40a43d
cmp dword [ebp + 0x10], edi
jne 0x40a44b
mov dword [0x418244], esi
push dword [ebp + 8]
call fcn.0040a2ca
xor edi, edi
xor esi, esi
inc esi
cmp dword [ebp + 0x10], edi
je 0x40a44a
push 8
call fcn.004096c1
pop ecx
ret
call fcn.004075eb
ret

Function at 0x40c11a
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x8c]
sub esp, 0x10c
mov eax, dword [0x4172a0]
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 + 0x417670]
je 0x40c14f
inc eax
cmp eax, 0x13
jb 0x40c140
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x417670]
jne 0x40c275
mov eax, dword [0x418030]
cmp eax, 1
je 0x40c24d
cmp eax, edx
jne 0x40c17f
cmp dword [0x417294], 1
je 0x40c24d
cmp ecx, 0xfc
je 0x40c275
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 0x40c1b5
lea eax, [ebp - 0x80]
push str._program_name_unknown_
push eax
call fcn.0040e910
pop ecx
pop ecx
lea edi, [ebp - 0x80]
mov eax, edi
push eax
call fcn.00408a80
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x40c1e9
mov eax, edi
push eax
call fcn.00408a80
mov edi, eax
lea eax, [ebp - 0x80]
sub eax, 0x3b
push 3
add edi, eax
push 0x4145c8
push edi
call fcn.0040f690
add esp, 0x10
push edi
call fcn.00408a80
push dword [esi + 0x417674]
mov ebx, eax
call fcn.00408a80
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.004080d0
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.0040e910
push edi
push ebx
call fcn.0040e920
push 0x4145a8
push ebx
call fcn.0040e920
push dword [esi + 0x417674]
push ebx
call fcn.0040e920
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.0040f597
add esp, 0x2c
jmp 0x40c275
push edx
lea eax, [ebp + 0x94]
push eax
lea esi, [esi + 0x417674]
push dword [esi]
call fcn.00408a80
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.00408d53
pop edi
pop esi
pop ebx
add ebp, 0x8c
leave
ret
Function at 0x40c73d
Capabilities:
Query environment variable

Disassembly:
push ecx
push ecx
mov eax, dword [0x41845c]
push ebx
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
push esi
push edi
xor ebx, ebx
xor esi, esi
xor edi, edi
cmp eax, ebx
jne 0x40c786
call ebp
mov esi, eax
cmp esi, ebx
je 0x40c76c
mov dword [0x41845c], 1
jmp 0x40c78b
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x78
jne 0x40c781
push 2
pop eax
mov dword [0x41845c], eax
jmp 0x40c786
mov eax, dword [0x41845c]
cmp eax, 1
jne 0x40c7e3
cmp esi, ebx
jne 0x40c79e
call ebp
mov esi, eax
cmp esi, ebx
jne 0x40c79e
xor eax, eax
jmp 0x40c88a
cmp word [esi], bx
mov eax, esi
je 0x40c7b3
inc eax
inc eax
cmp word [eax], bx
jne 0x40c7a5
inc eax
inc eax
cmp word [eax], bx
jne 0x40c7a5
sub eax, esi
inc eax
inc eax
mov ebp, eax
push ebp
call fcn.004088b1
mov edi, eax
cmp edi, ebx
pop ecx
jne 0x40c7d6
xor edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
jmp 0x40c88a
push ebp
push esi
push edi
call fcn.00407710
add esp, 0xc
jmp 0x40c7c8
cmp eax, 2
je 0x40c7ec
cmp eax, ebx
jne 0x40c797
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStrings]
mov ebp, eax
cmp ebp, ebx
je 0x40c797
cmp byte [ebp], bl
mov esi, ebp
je 0x40c822
push ebx
push ebx
push 0xffffffffffffffff
push esi
push 1
push ebx
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
cmp eax, ebx
je 0x40c797
push esi
add edi, eax
call fcn.00408a80
lea esi, [esi + eax + 1]
cmp byte [esi], bl
pop ecx
jne 0x40c7ff
inc edi
lea eax, [edi + edi]
push eax
mov dword [esp + 0x18], edi
call fcn.004088b1
cmp eax, ebx
pop ecx
mov dword [esp + 0x10], eax
je 0x40c89b
cmp byte [ebp], bl
mov edi, ebp
mov esi, eax
je 0x40c87c
mov ecx, dword [esp + 0x14]
mov eax, esi
sub eax, dword [esp + 0x10]
sar eax, 1
sub ecx, eax
push ecx
push esi
push 0xffffffffffffffff
push edi
push 1
push ebx
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
je 0x40c891
push edi
call fcn.00408a80
push esi
lea edi, [edi + eax + 1]
call fcn.00407abe
cmp byte [edi], bl
pop ecx
pop ecx
lea esi, [esi + eax*2 + 2]
jne 0x40c842
push ebp
mov word [esi], bx
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsA]
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
pop ecx
pop ecx
ret
push dword [esp + 0x10]
call fcn.00407a4d
pop ecx
push ebp
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsA]
jmp 0x40c797
Function at 0x40c8a7
Capabilities:
Accept command line arguments

Disassembly:
mov eax, dword [0x418460]
push ebp
xor ebp, ebp
cmp eax, ebp
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetCommandLineW]
jne 0x40c8e7
call esi
test eax, eax
je 0x40c8cc
mov dword [0x418460], 1
jmp 0x40c8ec
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x78
jne 0x40c8e3
mov dword [0x418460], 2
jmp 0x40c8f5
xor eax, eax
jmp 0x40c943
cmp eax, 1
jne 0x40c8f0
call esi
jmp 0x40c943
cmp eax, 2
jne 0x40c8e3
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov edi, dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push ebp
push ebp
push 0xffffffffffffffff
mov ebx, eax
push ebx
push 1
push ebp
call edi
mov esi, eax
cmp esi, ebp
je 0x40c93b
lea eax, [esi + esi]
push eax
call fcn.004088b1
mov ebp, eax
test ebp, ebp
pop ecx
je 0x40c93b
push esi
push ebp
push 0xffffffffffffffff
push ebx
push 1
push 0
call edi
test eax, eax
jne 0x40c93f
push ebp
call fcn.00407a4d
pop ecx
xor eax, eax
jmp 0x40c941
mov eax, ebp
pop edi
pop ebx
pop esi
pop ebp
ret