joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401976
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push esi
mov esi, dword [ebp + 8]
shr esi, 2
mov eax, esi
shr eax, 1
add eax, 3
mov dword [ecx], eax
add ecx, 0x10
xor eax, eax
push edi
mov dword [ebp - 4], 1
test esi, esi
je 0x4019aa
mov edi, dword [edx]
mov dword [ecx + eax*4], edi
inc eax
add edx, 4
cmp eax, esi
jb 0x40199d
mov eax, dword [ecx + esi*4 - 4]
mov edx, esi
imul edx, edx, 0xc
and dword [ebp + 8], 0
lea edx, [edx + ecx + 0x70]
mov dword [ebp - 8], edx
mov edx, 0xff
cmp dword [ebp + 8], 0
jne 0x401a24
mov edi, eax
and edi, edx
movzx edi, byte [edi + str.cw]
mov ebx, eax
shr ebx, 0x18
movzx ebx, byte [ebx + str.cw]
shl edi, 8
or edi, ebx
mov ebx, eax
shr eax, 8
shr ebx, 0x10
and eax, edx
movzx eax, byte [eax + str.cw]
xor eax, dword [ebp - 4]
shl dword [ebp - 4], 1
and ebx, edx
movzx ebx, byte [ebx + str.cw]
shl edi, 8
or edi, ebx
shl edi, 8
or eax, edi
test dword [ebp - 4], 0x100
je 0x401a1f
mov dword [ebp - 4], 0x1b
mov dword [ebp + 8], esi
jmp 0x401a6f
cmp dword [ebp + 8], 4
jne 0x401a6f
cmp esi, 6
jbe 0x401a6f
mov edi, eax
shr edi, 0x10
mov ebx, eax
shr ebx, 0x18
movzx ebx, byte [ebx + str.cw]
and edi, edx
movzx edi, byte [edi + str.cw]
shl ebx, 8
or edi, ebx
mov ebx, eax
shr ebx, 8
and ebx, edx
movzx ebx, byte [ebx + str.cw]
shl edi, 8
and eax, edx
movzx eax, byte [eax + str.cw]
or edi, ebx
shl edi, 8
or eax, edi
xor eax, dword [ecx]
dec dword [ebp + 8]
mov dword [ecx + esi*4], eax
add ecx, 4
cmp ecx, dword [ebp - 8]
jne 0x4019c3
pop edi
pop esi
pop ebx
leave
ret 4

Function at 0x402b35
Capabilities:
Check os version
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2d4
mov eax, dword [0x43e160]
xor eax, ebp
mov dword [ebp - 4], eax
call dword [sym.imp.KERNEL32.dll_GetVersion]
cmp ax, 6
je 0x402b7e
push str.SetDefaultDllDirectories
push str.kernel32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x402b7e
push 0xc00
call eax
test eax, eax
jne 0x402c12
push 0x106
lea eax, [ebp - 0x2d4]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x402c12
cmp eax, 0x104
ja 0x402c12
cmp word [ebp + eax*2 - 0x2d6], 0x5c
je 0x402bb2
push 0x5c
pop ecx
mov word [ebp + eax*2 - 0x2d4], cx
inc eax
cmp byte [str.userenv], 0
push esi
mov esi, str.userenv
je 0x402c11
push edi
lea edi, [ebp + eax*2 - 0x2d4]
mov eax, edi
jmp 0x402bd6
movzx ecx, cl
mov word [eax], cx
add eax, 2
mov cl, byte [esi]
inc esi
test cl, cl
jne 0x402bcd
push 0x2e
pop ecx
push 0x64
mov word [eax], cx
pop ecx
push 0x6c
mov word [eax + 2], cx
pop ecx
mov word [eax + 4], cx
mov word [eax + 6], cx
xor ecx, ecx
push 8
mov word [eax + 8], cx
push ecx
lea eax, [ebp - 0x2d4]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
cmp byte [esi], 0
jne 0x402bc9
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042ac2b
leave
ret
Function at 0x407585
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
lea eax, [ebp + 0x10]
push eax
xor eax, eax
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push eax
push eax
call fcn.0042ade1
mov ecx, dword [ebp + 8]
add esp, 0x18
push eax
mov dword [ecx], eax
call fcn.004074f3
pop ebp
ret 0xc

Function at 0x4094a8
Capabilities:
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
cmp byte [0x4413f0], 0
jne 0x4094e4
push esi
push dword [ebp + 8]
lea eax, [ebp - 0xc]
push eax
call fcn.00408413
push dword [ebp + 0xc]
mov eax, dword [eax]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push dword [ebp - 0xc]
mov esi, eax
call fcn.0042b07f
pop ecx
test esi, esi
pop esi
je 0x4094f4
mov al, 1
jmp 0x4094f6
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
jmp 0x4094de
xor al, al
leave
ret 8

Function at 0x4094fa
Capabilities:
Delete directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
cmp byte [0x4413f0], 0
jne 0x409532
push esi
push dword [ebp + 8]
lea eax, [ebp - 0xc]
push eax
call fcn.00408413
push dword [eax]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
push dword [ebp - 0xc]
mov esi, eax
call fcn.0042b07f
pop ecx
test esi, esi
pop esi
je 0x40953f
mov al, 1
jmp 0x409541
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
jmp 0x40952c
xor al, al
leave
ret 4

Function at 0x409545
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
cmp byte [0x4413f0], 0
jne 0x409580
push esi
push dword [ebp + 8]
lea eax, [ebp - 0xc]
push eax
call fcn.00408413
mov eax, dword [eax]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push dword [ebp - 0xc]
mov esi, eax
call fcn.0042b07f
pop ecx
test esi, esi
pop esi
je 0x40958f
mov al, 1
jmp 0x409591
push 0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jmp 0x40957a
xor al, al
leave
ret 4

Function at 0x40959f
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
mov esi, dword [ebp + 8]
push esi
call fcn.0040a371
cmp eax, 0xffffffff
je 0x4095ca
test al, 0x10
jne 0x4095ca
test al, 1
je 0x4095ca
and eax, 0xfffffffe
push eax
push esi
call fcn.004094a8
test al, al
je 0x409602
cmp byte [0x4413f0], 0
push esi
jne 0x4095f8
lea eax, [ebp - 0xc]
push eax
call fcn.00408413
push dword [eax]
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push dword [ebp - 0xc]
mov esi, eax
call fcn.0042b07f
pop ecx
test esi, esi
je 0x409602
mov al, 1
jmp 0x409604
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jmp 0x4095f2
xor al, al
pop esi
leave
ret 4

Function at 0x409609
Capabilities:
Set current directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
cmp byte [0x4413f0], 0
jne 0x409640
push esi
push dword [ebp + 8]
lea eax, [ebp - 0xc]
push eax
call fcn.00408413
push dword [eax]
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
push dword [ebp - 0xc]
mov esi, eax
call fcn.0042b07f
test esi, esi
pop ecx
setne al
pop esi
jmp 0x40964f
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
neg eax
sbb eax, eax
neg eax
leave
ret 4
Function at 0x4099f5
Capabilities:
Create directory

Disassembly:
push 0x5c
mov eax, 0x435874
call fcn.0042b5a1
mov esi, dword [ebp + 8]
push esi
call fcn.0040a371
cmp eax, 0xffffffff
je 0x409a1a
test al, 0x10
je 0x409a1a
mov al, 1
jmp 0x409bec
push esi
call fcn.0040af70
test al, al
jne 0x409bea
push esi
call fcn.0040b0b3
push esi
lea ecx, [ebp - 0x18]
mov dword [ebp + 8], eax
call fcn.00407f8d
and dword [ebp - 4], 0
lea ecx, [ebp - 0x18]
call fcn.00408346
test eax, eax
js 0x409a77
mov edx, dword [ebp - 0x14]
lea ecx, [edx - 1]
cmp eax, ecx
jne 0x409a77
cmp edx, 1
jne 0x409a6b
mov bl, dl
push dword [ebp - 0x18]
call fcn.0042b07f
pop ecx
mov al, bl
jmp 0x409bec
mov edx, dword [ebp - 0x18]
xor eax, eax
mov dword [ebp - 0x14], ecx
mov word [edx + ecx*2], ax
lea eax, [ebp - 0x18]
push eax
lea ecx, [ebp - 0x24]
call fcn.00408009
mov esi, dword [ebp - 0x14]
mov byte [ebp - 4], 1
cmp byte [0x4413f0], 0
mov ebx, dword [ebp - 0x18]
jne 0x409aba
push ebx
lea eax, [ebp - 0x30]
push eax
call fcn.00408413
mov eax, dword [eax]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push dword [ebp - 0x30]
mov edi, eax
call fcn.0042b07f
pop ecx
test edi, edi
jmp 0x409ac5
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x409bac
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
call edi
cmp eax, 0xb7
jne 0x409b21
lea ecx, [ebp - 0x68]
call fcn.00409f19
lea ecx, [ebp - 0x40]
call fcn.00407f69
push 0
push ebx
lea ecx, [ebp - 0x68]
mov byte [ebp - 4], 2
call fcn.0040a498
push dword [ebp - 0x40]
mov byte [ebp - 4], 1
test al, al
jne 0x409b0c
call fcn.0042b07f
pop ecx
jmp 0x409b21
mov ebx, dword [ebp - 0x48]
shr ebx, 4
call fcn.0042b07f
and bl, 1
pop ecx
jne 0x409bac
call edi
cmp eax, 0xb7
je 0x409bc8
lea ecx, [ebp - 0x18]
call fcn.00408346
mov esi, eax
test esi, esi
js 0x409bd8
je 0x409bd8
mov ecx, dword [ebp - 0x18]
cmp esi, 1
jne 0x409b5b
movzx eax, word [ecx]
cmp eax, 0x5c
je 0x409bc8
cmp eax, 0x2f
je 0x409bc8
lea eax, [esi + 1]
cmp dword [ebp + 8], eax
jae 0x409bc8
cmp esi, dword [ebp - 0x14]
jae 0x409a8a
xor eax, eax
mov dword [ebp - 0x14], esi
mov word [ecx + esi*2], ax
jmp 0x409a8a
mov eax, dword [ebp - 0x24]
lea eax, [eax + esi*2 + 2]
push eax
call fcn.0040ad99
test eax, eax
jns 0x409b90
mov esi, dword [ebp - 0x20]
jmp 0x409b94
lea esi, [esi + eax + 1]
push esi
push dword [ebp - 0x24]
lea ecx, [ebp - 0x18]
call fcn.004080fc
push dword [ebp - 0x18]
call fcn.00409545
test al, al
je 0x409bc8
cmp esi, dword [ebp - 0x20]
jl 0x409b7a
push dword [ebp - 0x24]
call fcn.0042b07f
push dword [ebp - 0x18]
call fcn.0042b07f
pop ecx
pop ecx
jmp 0x409a13
push dword [ebp - 0x24]
call fcn.0042b07f
pop ecx
xor bl, bl
jmp 0x409a5b
push dword [ebp - 0x24]
call fcn.0042b07f
push dword [ebp - 0x18]
call fcn.0042b07f
pop ecx
pop ecx
xor al, al
call fcn.0042b679
ret 4
Function at 0x40a371
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
cmp byte [0x4413f0], 0
jne 0x40a3a5
push esi
push dword [ebp + 8]
lea eax, [ebp - 0xc]
push eax
call fcn.00408413
push dword [eax]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
push dword [ebp - 0xc]
mov esi, eax
call fcn.0042b07f
pop ecx
mov eax, esi
pop esi
jmp 0x40a3b5
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40a3b5
or eax, eax
leave
ret 4

Function at 0x40a973
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
push esi
lea eax, [ebp - 4]
push eax
push dword [ecx]
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp esi, 0xffffffff
jne 0x40a99d
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x40a99d
xor al, al
jmp 0x40a9b2
mov edx, dword [ebp - 4]
xor eax, eax
xor ecx, ecx
add ecx, esi
adc edx, eax
mov eax, dword [ebp + 8]
mov dword [eax], ecx
mov dword [eax + 4], edx
mov al, 1
pop esi
leave
ret 4
Function at 0x419cc2
Capabilities:
Hide graphical window

Disassembly:
push 0xc
mov eax, 0x435626
call fcn.0042b5a1
mov esi, ecx
push 0
push dword [ebp + 0xc]
lea ecx, [esi + 0x68]
push dword [ebp + 8]
call fcn.00419c48
push 0xce4
lea eax, [ebp - 0x18]
push eax
call fcn.0041907c
push dword [eax]
and dword [ebp - 4], 0
push dword [esi + 0x6c]
call fcn.0040b98e
push dword [ebp - 0x18]
call fcn.0042b07f
pop ecx
push 1
push dword [esi + 0x6c]
call dword [sym.imp.USER32.dll_ShowWindow]
xor eax, eax
call fcn.0042b679
ret 8

Function at 0x41a834
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
push esi
lea eax, [ebp - 4]
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp esi, 0xffffffff
jne 0x41a85f
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x41a85f
xor al, al
jmp 0x41a874
mov edx, dword [ebp - 4]
xor eax, eax
xor ecx, ecx
add ecx, esi
adc edx, eax
mov eax, dword [ebp + 0xc]
mov dword [eax], ecx
mov dword [eax + 4], edx
mov al, 1
pop esi
leave
ret 8

Function at 0x41a879
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x214
mov eax, dword [0x43e160]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 8]
xor eax, eax
push 0x206
mov word [ebp - 0x20c], ax
xor ebx, ebx
lea eax, [ebp - 0x20a]
push ebx
push eax
call fcn.0042ac70
add esp, 0xc
push 0x104
lea eax, [ebp - 0x20c]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push ebx
push 0x80
push 3
push ebx
push 1
push SysReAllocStringLen
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x210], eax
cmp eax, 0xffffffff
je 0x41a92a
push esi
push eax
call fcn.0041a834
push dword [esi]
mov dword [ebp - 0x214], ebx
call fcn.0042b095
pop ecx
push ebx
lea ecx, [ebp - 0x214]
push ecx
mov dword [edi], eax
push dword [esi]
push eax
push dword [ebp - 0x210]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x210]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0042ac2b
leave
ret 8
Function at 0x42ac2b
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x43e160]
jne 0x42ac35
repz ret
jmp fcn.0042f185

Function at 0x431eec
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x43e160]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0xc]
push esi
push edi
mov dword [ebp - 0x1c], eax
call fcn.0042ebae
and dword [ebp - 0x14], 0
cmp dword [0x442058], 0
mov dword [ebp - 0x18], eax
jne 0x431f9f
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ebx, eax
test ebx, ebx
je 0x432047
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x439a38
push ebx
call edi
test eax, eax
je 0x432047
mov esi, dword [sym.imp.KERNEL32.dll_EncodePointer]
push eax
call esi
push str.GetActiveWindow
push ebx
mov dword [0x442058], eax
call edi
push eax
call esi
push str.GetLastActivePopup
push ebx
mov dword [0x44205c], eax
call edi
push eax
call esi
push str.GetUserObjectInformationW
push ebx
mov dword [0x442060], eax
call edi
push eax
call esi
mov dword [0x442068], eax
test eax, eax
je 0x431f9f
push str.GetProcessWindowStation
push ebx
call edi
push eax
call esi
mov dword [0x442064], eax
mov eax, dword [0x442064]
mov ecx, dword [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, ecx
je 0x431ff8
cmp dword [0x442068], ecx
je 0x431ff8
push eax
call esi
push dword [0x442068]
mov edi, eax
call esi
mov ebx, eax
test edi, edi
je 0x431ff8
test ebx, ebx
je 0x431ff8
call edi
test eax, eax
je 0x431fef
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call ebx
test eax, eax
je 0x431fef
test byte [ebp - 8], 1
jne 0x431ff8
or dword [ebp + 0x10], 0x200000
jmp 0x43202b
mov eax, dword [0x44205c]
cmp eax, dword [ebp - 0x18]
je 0x43202b
push eax
call esi
test eax, eax
je 0x43202b
call eax
mov dword [ebp - 0x14], eax
test eax, eax
je 0x43202b
mov eax, dword [0x442060]
cmp eax, dword [ebp - 0x18]
je 0x43202b
push eax
call esi
test eax, eax
je 0x43202b
push dword [ebp - 0x14]
call eax
mov dword [ebp - 0x14], eax
push dword [0x442058]
call esi
test eax, eax
je 0x432047
push dword [ebp + 0x10]
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push dword [ebp - 0x14]
call eax
jmp 0x432049
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0042ac2b
leave
ret
Function at 0x401ec0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push edi
mov edi, dword [esp + 0x10]
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x401ed9
pop edi
pop ebx
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x401f14
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [esp + 0x18]
add eax, esi
and ecx, 0xf
jbe 0x401f10
lea ebx, [ebx]
cmp esi, eax
jae 0x401f14
sub ecx, 1
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x401f00
cmp esi, eax
jb 0x401f1a
pop esi
pop edi
xor eax, eax
pop ebx
ret
mov ax, word [esi]
neg ax
sbb eax, eax
and eax, esi
pop esi
pop edi
pop ebx
ret

Function at 0x4021c0
Capabilities:
Identify system language via api

Disassembly:
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetUserDefaultUILanguage]
movzx edi, ax
call dword [sym.imp.KERNEL32.dll_GetSystemDefaultUILanguage]
movzx ebx, ax
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLangID]
movzx esi, ax
call dword [sym.imp.KERNEL32.dll_GetSystemDefaultLangID]
cmp di, si
movzx eax, ax
jne 0x402224
cmp di, ax
jne 0x402224
xor eax, eax
movzx edx, di
mov ecx, 0x4362f8
jmp 0x402200
cmp dword [ecx], edx
je 0x402216
add eax, 1
add ecx, 0x10
cmp eax, 0x26
jb 0x402200
movzx eax, di
pop edi
pop esi
pop ebx
ret
pop edi
shl eax, 4
movzx eax, word [eax + 0x4362fc]
pop esi
pop ebx
ret
xor eax, eax
movzx edx, bx
mov ecx, 0x4362f8
mov edi, edi
cmp dword [ecx], edx
je 0x402216
add eax, 1
add ecx, 0x10
cmp eax, 0x26
jb 0x402230
pop edi
pop esi
movzx eax, bx
pop ebx
ret
Function at 0x402610
Capabilities:
Create process on windows

Disassembly:
mov eax, 0x1a68
call fcn.00415f10
mov eax, dword [0x434dc0]
xor eax, esp
mov dword [esp + 0x1a64], eax
push ebx
push ebp
push esi
push edi
xor ebp, ebp
push 0x206
lea eax, [esp + 0x72]
mov ebx, edx
push ebp
push eax
mov esi, ecx
mov dword [esp + 0x20], ebx
mov word [esp + 0x78], bp
call fcn.00413de0
push esi
lea ecx, [esp + 0x7c]
push 0x104
push ecx
mov dword [esp + 0x28], ebp
call fcn.00412c0d
add esp, 0x18
cmp word [esi], 0x22
lea edi, [esp + 0x6c]
jne 0x4026a9
lea eax, [esp + 0x6c]
lea edi, [esp + 0x6e]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bp
jne 0x402677
sub eax, edx
sar eax, 1
cmp word [esp + eax*2 + 0x6a], 0x22
jne 0x4026a9
lea eax, [esp + 0x6c]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bp
jne 0x402695
sub eax, edx
sar eax, 1
mov word [esp + eax*2 + 0x6a], bp
push 0x44
lea edx, [esp + 0x2c]
push ebp
push edx
call fcn.00413de0
push 0xffe
lea eax, [esp + 0xa86]
push ebp
push eax
mov dword [esp + 0x40], 0x44
mov word [esp + 0xa8c], bp
call fcn.00413de0
push ebx
push edi
push str._s__s
lea ecx, [esp + 0xa98]
push 0x800
push ecx
call fcn.004120ac
push 0x7fe
lea edx, [esp + 0x2a6]
push ebp
push edx
mov word [esp + 0x2ac], bp
call fcn.00413de0
push esi
push str.__s_
lea eax, [esp + 0x2b4]
push 0x400
push eax
call fcn.004120ac
add esp, 0x48
lea ecx, [esp + 0xa74]
push ecx
push str.CreateProcess__s
call fcn.00402dc0
mov edi, eax
call fcn.004032a0
add esp, 8
lea edx, [esp + 0x18]
push edx
lea eax, [esp + 0x2c]
push eax
push ebp
push ebp
push 8
push ebp
push ebp
push ebp
lea ecx, [esp + 0xa94]
push ecx
push ebp
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
jne 0x4027f6
push str.CreateProcess_failed
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
call fcn.00402dc0
mov ecx, eax
call fcn.00403400
add esp, 4
push str.Attempt_spawn_before_giving_up...
call fcn.00402dc0
mov edi, eax
call fcn.004032a0
mov ebx, dword [esp + 0x18]
add esp, 4
push ebx
lea edx, [esp + 0x278]
push edx
push str._tspawnl__s__s
call fcn.00402dc0
mov edi, eax
call fcn.004032a0
push ebp
push ebx
lea eax, [esp + 0x288]
push eax
push esi
push ebp
call fcn.004128dd
add esp, 0x20
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
jne 0x40283f
call fcn.00412967
push str.tspawn_failed
mov esi, eax
call fcn.00402dc0
mov ebx, dword [esi]
mov ecx, eax
call fcn.00403400
add esp, 4
jmp 0x40283b
push str.Waiting_for_CreateProcess_to_complete
call fcn.00402dc0
mov edi, eax
call fcn.004032a0
mov ecx, dword [esp + 0x1c]
add esp, 4
push 0xffffffffffffffff
push ecx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [esp + 0x18]
lea edx, [esp + 0x10]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
mov ecx, dword [esp + 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push ecx
call esi
mov edx, dword [esp + 0x1c]
push edx
call esi
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x1a74]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00411f67
add esp, 0x1a68
ret
Function at 0x402a60
Capabilities:
Check os version

Disassembly:
sub esp, 0x120
mov eax, dword [0x434dc0]
xor eax, esp
mov dword [esp + 0x11c], eax
lea eax, [esp]
push eax
mov dword [esp + 4], 0x11c
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
mov eax, dword [esp + 4]
cmp eax, 5
jbe 0x402aa9
mov eax, 1
mov ecx, dword [esp + 0x11c]
xor ecx, esp
call fcn.00411f67
add esp, 0x120
ret
jae 0x402ac3
or eax, 0xffffffff
mov ecx, dword [esp + 0x11c]
xor ecx, esp
call fcn.00411f67
add esp, 0x120
ret
mov eax, dword [esp + 8]
cmp eax, 1
ja 0x402a8f
jb 0x402aab
xor ecx, ecx
cmp ecx, dword [esp + 0xc]
mov ecx, dword [esp + 0x11c]
sbb eax, eax
xor ecx, esp
neg eax
call fcn.00411f67
add esp, 0x120
ret
Function at 0x4032a0
Capabilities:
Print debug messages

Disassembly:
mov eax, 0x2008
call fcn.00415f10
mov eax, dword [0x434dc0]
xor eax, esp
mov dword [esp + 0x2004], eax
cmp dword [esp + 0x200c], 0
je 0x4033dd
push 0x1ffe
lea eax, [esp + 0xa]
push 0
push eax
mov word [esp + 0x10], 0
call fcn.00413de0
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
lea ecx, [edi + 0x248]
push ecx
push str._s__X_:
lea edx, [esp + 0x10]
push 0x1000
push edx
call fcn.004120ac
mov edx, dword [esp + 0x2020]
lea ecx, [esp + 0x2024]
push ecx
push edx
mov ecx, 0x1000
sub ecx, eax
push ecx
lea edx, [esp + eax*2 + 0x24]
push edx
call fcn.00412fe0
push 0x42ea94
lea eax, [esp + 0x2c]
push 0x1000
push eax
call fcn.004121df
lea eax, [edi + 0x40]
add esp, 0x30
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x403342
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub eax, edx
sar eax, 1
push esi
je 0x403377
lea esi, [edi + 4]
push esi
call ebx
lea ecx, [esp + 0x10]
push ecx
mov eax, edi
call fcn.00403210
push esi
call ebp
lea eax, [esp + 0x10]
xor edx, edx
lea esi, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x403380
sub eax, esi
sar eax, 1
add eax, 0xfffffffe
je 0x4033c6
cmp word [esp + edx*2 + 0x10], 0xa
jne 0x4033a3
mov word [esp + edx*2 + 0x10], 0x20
lea eax, [esp + 0x10]
add edx, 1
lea esi, [eax + 2]
lea ecx, [ecx]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4033b0
sub eax, esi
sar eax, 1
add eax, 0xfffffffe
cmp edx, eax
jb 0x403394
lea esi, [edi + 4]
push esi
call ebx
lea edx, [esp + 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
push esi
call ebp
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x2004]
xor ecx, esp
call fcn.00411f67
add esp, 0x2008
ret

Function at 0x403ff0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x429958
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push ebp
push esi
push edi
mov eax, dword [0x434dc0]
xor eax, esp
push eax
lea eax, [esp + 0x1c]
mov dword fs:[0], eax
mov ebx, 1
mov dword [esp + 0x24], ebx
mov edi, dword [esp + 0x34]
push 0
push ecx
add edi, 0xfffffff0
mov dword [esp + 0x1c], esp
mov esi, esp
push edi
call fcn.00401c00
add eax, 0x10
mov dword [esi], eax
mov byte [esp + 0x30], 2
mov esi, dword [esp + 0x3c]
add esi, 0xfffffff0
mov dword [esp + 0x24], esp
mov ebp, esp
push esi
call fcn.00401c00
mov ecx, dword [esp + 0x3c]
add eax, 0x10
mov dword [ebp], eax
add esp, 4
mov byte [esp + 0x30], bl
call fcn.00403da0
mov ebx, eax
mov byte [esp + 0x24], 0
lea eax, [esi + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x404089
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
mov dword [esp + 0x24], 0xffffffff
lea ecx, [edi + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4040aa
mov ecx, dword [edi]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push edi
call edx
mov eax, ebx
mov ecx, dword [esp + 0x1c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret 0xc