joyce8/EMBER2024-capa huggingface dataset:
Function at 0x44ce20
Capabilities:
Enumerate gui resources

Disassembly:
push ebx
push esi
add esp, 0xfffffff8
mov ebx, eax
mov eax, dword [0x451c00]
cmp dword [eax + 0x30], 0
je 0x44ceca
cmp dword [ebx + 0x94], 0
jne 0x44cec4
mov eax, dword [ebx + 0x30]
mov dword [esp], eax
mov byte [esp + 4], dl
mov eax, esp
push eax
push 0x44cdb0
call sub.user32.dll_EnumWindows
mov eax, dword [ebx + 0x90]
cmp dword [eax + 8], 0
je 0x44cec4
push 3
mov eax, dword [esp + 4]
push eax
call sub.user32.dll_GetWindow
mov esi, eax
mov dword [esp], esi
push 0xffffffffffffffec
push esi
call sub.user32.dll_GetWindowLongA
test al, 8
je 0x44ce8a
mov dword [esp], 0xfffffffe
mov eax, dword [ebx + 0x90]
mov esi, dword [eax + 8]
dec esi
cmp esi, 0
jl 0x44cec4
push 0x213
push 0
push 0
push 0
push 0
mov eax, dword [esp + 0x14]
push eax
mov edx, esi
mov eax, dword [ebx + 0x90]
call fcn.00413a2c
push eax
call sub.user32.dll_SetWindowPos
dec esi
cmp esi, 0xffffffff
jne 0x44ce99
inc dword [ebx + 0x94]
pop ecx
pop edx
pop esi
pop ebx
ret

Function at 0x44d9a8
Capabilities:
Get graphical window text

Disassembly:
push ebx
push esi
add esp, 0xffffff00
mov esi, edx
mov ebx, eax
cmp byte [ebx + 0xa4], 0
je 0x44d9dd
push pe_nt_image_headers32
lea eax, [esp + 4]
push eax
mov eax, dword [ebx + 0x30]
push eax
call sub.user32.dll_GetWindowTextA
mov ecx, eax
mov edx, esp
mov eax, esi
call fcn.004043dc
jmp 0x44d9ea
mov eax, esi
mov edx, dword [ebx + 0x8c]
call fcn.00404340
add esp, 0x100
pop esi
pop ebx
ret

Function at 0x44e9f8
Capabilities:
Hide graphical window

Disassembly:
push ebx
push esi
mov ebx, eax
mov esi, dword [ebx + 0x84]
test esi, esi
je 0x44ea39
mov eax, esi
call fcn.00434ffc
test al, al
je 0x44ea39
mov eax, dword [ebx + 0x84]
call fcn.00434cf8
push eax
call sub.user32.dll_IsWindowVisible
test eax, eax
je 0x44ea39
push 0
mov eax, dword [ebx + 0x84]
call fcn.00434cf8
push eax
call sub.user32.dll_ShowWindow
pop esi
pop ebx
ret
Function at 0x1001a093
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x1001a0d2
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x1001a0d2
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x1001a0d2
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x1001a0d2
cmp dword [ecx + 0x74], 0xe
jbe 0x1001a0d2
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x1001cd4f
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x1001cdec
push ebx
push esi
call fcn.1001cd18
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.1001ccac
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x1001cd99
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1001cdeb
push edi
push eax
call fcn.1001dd0a
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x1001cdb9
call fcn.1001b7f4
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1001cdea
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.1001ccac
add esp, 0x20
test eax, eax
jne 0x1001cdd8
push edi
call fcn.1001b7f4
jmp 0x1001cde0
push ebx
call fcn.1001b7f4
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret

Function at 0x1001d059
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10024cc8
push 0x10024cc0
push str.FlsAlloc
push 0x1f
call fcn.1001cf75
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1001d08d
push dword [ebp + 8]
mov ecx, esi
call dword [0x1002314c]
call esi
jmp 0x1001d093
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x1001d0d7
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10024cd8
push 0x10024cd0
push str.FlsGetValue
push 0x21
call fcn.1001cf75
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1001d10e
push dword [ebp + 8]
mov ecx, esi
call dword [0x1002314c]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x1001d116
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10024ce0
push 0x10024cd8
push str.FlsSetValue
push 0x22
call fcn.1001cf75
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1001d150
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x1002314c]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x100227d0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x100227fd
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x100227fd
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret

Function at 0x4014aa
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
push edi
mov byte [ebp - 4], 0x13
mov byte [ebp - 3], 0x35
mov byte [ebp - 2], 0x86
mov byte [ebp - 1], 7
call dword [0x43625c]
mov ebx, eax
push ebx
call fcn.004274b7
mov esi, eax
pop ecx
test esi, esi
je 0x4014f8
xor edx, edx
test ebx, ebx
jbe 0x4014f8
sub edi, esi
mov eax, edx
lea ecx, [edx + esi]
and eax, 3
mov al, byte [ebp + eax - 4]
xor al, byte [edi + ecx]
inc edx
cmp edx, ebx
mov byte [ecx], al
jb 0x4014e2
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret

Function at 0x41b1a2
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 0xc]
mov eax, edx
dec edx
test eax, eax
je 0x41b1dc
mov eax, dword [ecx + 0x70]
push esi
lea esi, [edx + 1]
mov edx, dword [ebp + 8]
push edi
mov ecx, dword [ebp + 0x10]
movzx edi, byte [edx]
and ecx, 0xff
xor ecx, edi
mov edi, dword [ebp + 0x10]
shr edi, 8
mov ecx, dword [eax + ecx*4]
inc edx
xor edi, ecx
dec esi
mov dword [ebp + 0x10], edi
jne 0x41b1ba
pop edi
pop esi
mov eax, dword [ebp + 0x10]
pop ebp
ret 0xc

Function at 0x41d35d
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x118
push dword [ebp + 8]
call dword [0x4363a4]
test eax, eax
je 0x41d413
lea eax, [ebp - 0x118]
push 0xff
push eax
push dword [ebp + 0xc]
call fcn.004204d4
add esp, 0xc
cmp dword [ebp + 0xc], 0x452
jne 0x41d403
lea eax, [ebp - 0x118]
push eax
call dword [0x43625c]
test eax, eax
je 0x41d3bf
lea eax, [ebp - 0x118]
push 0x43d290
push eax
call fcn.00428f80
pop ecx
test eax, eax
pop ecx
jne 0x41d3db
mov eax, 0x486
push eax
mov dword [0x445424], eax
call fcn.0042045d
pop ecx
push dword [0x445424]
call fcn.00428e80
lea eax, [ebp - 0x18]
push eax
push 0
call fcn.004216cf
pop ecx
lea eax, [ebp - 0x18]
pop ecx
push eax
lea eax, [ebp - 0x118]
push eax
lea eax, [ebp - 0x118]
push eax
call dword [0x4363f0]
add esp, 0xc
lea eax, [ebp - 0x118]
push eax
push dword [ebp + 8]
call dword [0x436378]
leave
ret 8
Function at 0x4015b0
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
sub esp, 0xc
push esi
mov esi, dword [esp + 0x14]
lea eax, [esp + 8]
push eax
mov eax, dword [esi]
lea ecx, [esp + 8]
push ecx
lea edx, [esp + 0x14]
push edx
push 0
push str.AutoChkTimeOut
push eax
mov dword [esp + 0x24], 4
mov dword [esp + 0x20], 4
mov dword [esp + 0x1c], 0
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
sub eax, 0
je 0x40161c
sub eax, 2
jne 0x401641
mov ecx, dword [esi]
push 4
push 0x4164fc
push 4
push 0
push str.AutoChkTimeOut
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
neg eax
sbb eax, eax
inc eax
pop esi
add esp, 0xc
ret
mov eax, dword [esp + 4]
test eax, eax
je 0x401648
mov edx, dword [esi]
push 4
push 0x4164fc
push 4
push 0
push str.AutoChkTimeOut
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x401648
xor eax, eax
pop esi
add esp, 0xc
ret
mov eax, 1
pop esi
add esp, 0xc
ret

Function at 0x401660
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x414
mov eax, dword [0x41c870]
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov dword [esp + 0x41c], eax
xor eax, eax
mov ecx, 0x100
lea edi, [esp + 0x18]
rep stosd dword es:[edi], eax
lea eax, [esp + 0x14]
push eax
mov eax, dword [ebx]
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x18]
push edx
push 0
push str.BootExecute
push eax
mov dword [esp + 0x28], 7
mov dword [esp + 0x2c], 0x400
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
sub eax, 0
je 0x4016f5
sub eax, 2
jne 0x401725
mov ecx, dword [ebx]
push 0x15
push str.autocheck_autochk_
push 7
push 0
push str.BootExecute
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
neg eax
sbb eax, eax
inc eax
mov ecx, dword [esp + 0x41c]
call fcn.00402bae
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, 0x15
mov edi, str.autocheck_autochk_
lea esi, [esp + 0x18]
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
je 0x40173a
mov eax, dword [ebx]
push 0x15
push str.autocheck_autochk_
push 7
push edx
push str.BootExecute
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x40173a
xor eax, eax
mov ecx, dword [esp + 0x41c]
call fcn.00402bae
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [esp + 0x41c]
mov eax, 1
call fcn.00402bae
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x4018b0
Capabilities:
Accept command line arguments

Disassembly:
push esi
xor esi, esi
push esi
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
push eax
push esi
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call fcn.0041309d
test eax, eax
jne 0x4018e1
push 0x416534
call fcn.004036ed
add esp, 4
mov eax, 1
pop esi
ret
call fcn.004018a0
mov eax, esi
pop esi
ret
Function at 0x4018ea
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x4018ff
pop ebp
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
jne 0x401911
xor eax, eax
jmp 0x401943
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [ebp + 0x10]
add eax, esi
and ecx, 0xf
jbe 0x401935
cmp esi, eax
jae 0x40190d
dec ecx
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x401927
cmp esi, eax
jae 0x40190d
mov ax, word [esi]
neg ax
sbb eax, eax
and eax, esi
pop esi
pop ebp
ret

Function at 0x4038c7
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.00403760
mov esi, esp
push 0x1c
lea eax, [ebp - 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x403962
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 [0x42013c]
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 0x403962
cmp eax, 1
je 0x403983
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 0x403962
mov eax, dword [ebp - 0x1c]
add dword [ebp - 4], eax
test dword [ebp - 0x18], ebx
je 0x40392f
test byte [ebp - 0x13], 1
mov eax, dword [ebp - 0x28]
mov dword [ebp - 4], eax
je 0x40395e
xor eax, eax
inc eax
jmp 0x4039a2
cmp edi, eax
jae 0x403966
xor eax, eax
jmp 0x4039a2
cmp eax, esi
jae 0x40396d
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 [0x42013c]
jmp 0x403986
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 0x403c47
Capabilities:
Accept command line arguments
Parse pe header
Terminate process

Disassembly:
push 0x18
push 0x4178d0
call fcn.00404638
mov edi, 0x94
mov eax, edi
call fcn.00403760
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 [0x42013c], ecx
mov eax, dword [esi + 4]
mov dword [0x420148], eax
mov edx, dword [esi + 8]
mov dword [0x42014c], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
mov dword [0x420140], esi
cmp ecx, 2
je 0x403ca7
or esi, 0x8000
mov dword [0x420140], esi
shl eax, 8
add eax, edx
mov dword [0x420144], eax
xor edi, edi
push edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
cmp word [eax], 0x5a4d
jne 0x403ce0
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x403ce0
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x403cf8
cmp eax, 0x20b
je 0x403ce5
mov dword [ebp - 0x1c], edi
jmp 0x403d0c
cmp dword [ecx + 0x84], 0xe
jbe 0x403ce0
xor eax, eax
cmp dword [ecx + 0xf8], edi
jmp 0x403d06
cmp dword [ecx + 0x74], 0xe
jbe 0x403ce0
xor eax, eax
cmp dword [ecx + 0xe8], edi
setne al
mov dword [ebp - 0x1c], eax
push 1
call fcn.00407035
pop ecx
test eax, eax
jne 0x403d20
push 0x1c
call fcn.00403c23
pop ecx
call fcn.00405723
test eax, eax
jne 0x403d31
push 0x10
call fcn.00403c23
pop ecx
call fcn.004086f6
mov dword [ebp - 4], edi
call fcn.004084f8
test eax, eax
jge 0x403d4a
push 0x1b
call fcn.00403bfe
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x421a10], eax
call fcn.004083d6
mov dword [0x42012c], eax
call fcn.00408334
test eax, eax
jge 0x403d70
push 8
call fcn.00403bfe
pop ecx
call fcn.00408101
test eax, eax
jge 0x403d81
push 9
call fcn.00403bfe
pop ecx
push 1
call fcn.004044c9
pop ecx
mov dword [ebp - 0x24], eax
cmp eax, edi
je 0x403d97
push eax
call fcn.00403bfe
pop ecx
mov eax, dword [0x42015c]
mov dword [0x420160], eax
push eax
push dword [0x420154]
push dword [0x420150]
call fcn.004018b0
add esp, 0xc
mov esi, eax
mov dword [ebp - 0x28], esi
cmp dword [ebp - 0x1c], edi
jne 0x403dc6
push esi
call fcn.004045f6
call fcn.00404618
jmp 0x403df8
or dword [ebp - 4], 0xffffffff
mov eax, esi
lea esp, [ebp - 0x34]
call fcn.00404673
ret
Function at 0x404533
Capabilities:
Terminate process

Disassembly:
push 8
push 0x417908
call fcn.00404638
push 8
call fcn.00405965
pop ecx
xor edi, edi
mov dword [ebp - 4], edi
xor esi, esi
inc esi
cmp dword [0x42017c], esi
jne 0x404567
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov dword [0x420178], esi
mov al, byte [ebp + 0x10]
mov byte [0x420174], al
cmp dword [ebp + 0xc], edi
jne 0x4045b1
cmp dword [0x421a08], edi
je 0x4045a1
mov eax, dword [0x421a04]
sub eax, 4
mov dword [0x421a04], eax
cmp eax, dword [0x421a08]
jb 0x4045a1
mov eax, dword [eax]
cmp eax, edi
je 0x404582
call eax
jmp 0x404582
push 0x41c078
mov eax, 0x41c070
call fcn.004044b1
pop ecx
push 0x41c084
mov eax, 0x41c07c
call fcn.004044b1
pop ecx
or dword [ebp - 4], 0xffffffff
call 0x4045e2
cmp dword [ebp + 0x10], edi
jne 0x4045f0
mov dword [0x42017c], esi
push dword [ebp + 8]
call fcn.0040446f
xor edi, edi
xor esi, esi
inc esi
cmp dword [ebp + 0x10], edi
je 0x4045ef
push 8
call fcn.004058b0
pop ecx
ret
call fcn.00404673
ret
Function at 0x407bc4
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 0x407bf2
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 0x407bf9
cmp ebx, dword [eax + 4]
jae 0x407bf9
xor eax, eax
jmp 0x407de9
push edi
mov edi, dword [esi + 0xc]
cmp edi, 0xffffffff
jne 0x407c0a
xor eax, eax
inc eax
jmp 0x407de8
xor edx, edx
mov dword [ebp + 8], edx
mov eax, ebx
mov ecx, dword [eax]
cmp ecx, 0xffffffff
je 0x407c20
cmp ecx, edx
jae 0x407d65
cmp dword [eax + 4], 0
je 0x407c29
inc dword [ebp + 8]
inc edx
add eax, 0xc
cmp edx, edi
jbe 0x407c11
cmp dword [ebp + 8], 0
je 0x407c4b
mov eax, dword [esi - 8]
cmp eax, dword [ebp - 4]
jb 0x407d65
cmp eax, esi
jae 0x407d65
mov eax, dword [0x4203f8]
mov edi, ebx
and edi, 0xfffff000
xor esi, esi
test eax, eax
jle 0x407c70
cmp dword [esi*4 + 0x420400], edi
je 0x407d69
inc esi
cmp esi, eax
jl 0x407c5e
push 0x1c
lea eax, [ebp - 0x20]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x407de5
cmp dword [ebp - 8], 0x1000000
jne 0x407de5
test byte [ebp - 0xc], 0xcc
je 0x407cee
mov ecx, dword [ebp - 0x1c]
cmp word [ecx], 0x5a4d
jne 0x407de5
mov eax, dword [ecx + 0x3c]
add eax, ecx
cmp dword [eax], 0x4550
jne 0x407de5
cmp word [eax + 0x18], 0x10b
jne 0x407de5
sub ebx, ecx
cmp word [eax + 6], 0
movzx ecx, word [eax + 0x14]
lea ecx, [ecx + eax + 0x18]
jbe 0x407de5
mov eax, dword [ecx + 0xc]
cmp ebx, eax
jb 0x407cee
mov edx, dword [ecx + 8]
add edx, eax
cmp ebx, edx
jae 0x407cee
test byte [ecx + 0x27], 0x80
jne 0x407d65
push 1
push 0x420440
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
test eax, eax
jne 0x407c02
mov ecx, dword [0x4203f8]
test ecx, ecx
mov edx, ecx
jle 0x407d22
lea eax, [ecx*4 + 0x4203fc]
cmp dword [eax], edi
je 0x407d22
dec edx
sub eax, 4
test edx, edx
jg 0x407d16
test edx, edx
jne 0x407d53
push 0xf
pop ebx
cmp ecx, ebx
jg 0x407d2f
mov ebx, ecx
xor edx, edx
test ebx, ebx
jl 0x407d47
lea eax, [edx*4 + 0x420400]
mov esi, dword [eax]
inc edx
cmp edx, ebx
mov dword [eax], edi
mov edi, esi
jle 0x407d35
cmp ecx, 0x10
jge 0x407d53
inc ecx
mov dword [0x4203f8], ecx
push 0
push 0x420440
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
jmp 0x407c02
xor eax, eax
jmp 0x407de8
test esi, esi
jle 0x407c02
mov ebx, dword [sym.imp.KERNEL32.dll_InterlockedExchange]
push 1
push 0x420440
call ebx
test eax, eax
jne 0x407c02
cmp dword [esi*4 + 0x420400], edi
je 0x407dbf
mov eax, dword [0x4203f8]
lea esi, [eax - 1]
test esi, esi
jl 0x407dad
cmp dword [esi*4 + 0x420400], edi
je 0x407da9
dec esi
jns 0x407d9d
test esi, esi
jge 0x407dbd
cmp eax, 0x10
jge 0x407db8
inc eax
mov dword [0x4203f8], eax
lea esi, [eax - 1]
jmp 0x407dbf
je 0x407dd7
xor ecx, ecx
test esi, esi
jl 0x407dd7
lea eax, [ecx*4 + 0x420400]
mov edx, dword [eax]
inc ecx
cmp ecx, esi
mov dword [eax], edi
mov edi, edx
jle 0x407dc5
push 0
push 0x420440
call ebx
jmp 0x407c02
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret
Function at 0x407ded
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x8c]
sub esp, 0x10c
mov eax, dword [0x41c870]
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 + 0x41d1c8]
je 0x407e22
inc eax
cmp eax, 0x13
jb 0x407e13
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x41d1c8]
jne 0x407f48
mov eax, dword [0x420134]
cmp eax, 1
je 0x407f20
cmp eax, edx
jne 0x407e52
cmp dword [0x41c8b4], 1
je 0x407f20
cmp ecx, 0xfc
je 0x407f48
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 0x407e88
lea eax, [ebp - 0x80]
push str._program_name_unknown_
push eax
call fcn.00408780
pop ecx
pop ecx
lea edi, [ebp - 0x80]
mov eax, edi
push eax
call fcn.00404150
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x407ebc
mov eax, edi
push eax
call fcn.00404150
mov edi, eax
lea eax, [ebp - 0x80]
sub eax, 0x3b
push 3
add edi, eax
push 0x41798c
push edi
call fcn.00402bc0
add esp, 0x10
push edi
call fcn.00404150
push dword [esi + 0x41d1cc]
mov ebx, eax
call fcn.00404150
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.00403760
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.00408780
push edi
push ebx
call fcn.00408790
push 0x417988
push ebx
call fcn.00408790
push dword [esi + 0x41d1cc]
push ebx
call fcn.00408790
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.0040a156
add esp, 0x2c
jmp 0x407f48
push edx
lea eax, [ebp + 0x94]
push eax
lea esi, [esi + 0x41d1cc]
push dword [esi]
call fcn.00404150
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.00402bae
pop edi
pop esi
pop ebx
add ebp, 0x8c
leave
ret
Function at 0x40a156
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x42057c], ebx
push esi
push edi
jne 0x40a1d6
push 0x416704
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x40a211
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x41833c
push edi
call esi
test eax, eax
mov dword [0x42057c], eax
je 0x40a211
push 0x41832c
push edi
call esi
push 0x418318
push edi
mov dword [0x420580], eax
call esi
cmp dword [0x42013c], 2
mov dword [0x420584], eax
jne 0x40a1d6
push str.GetUserObjectInformationA
push edi
call esi
test eax, eax
mov dword [0x42058c], eax
je 0x40a1d6
push str.GetProcessWindowStation
push edi
call esi
mov dword [0x420588], eax
mov eax, dword [0x420588]
test eax, eax
je 0x40a21b
call eax
test eax, eax
je 0x40a202
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x42058c]
test eax, eax
je 0x40a202
test byte [ebp - 8], 1
jne 0x40a21b
cmp dword [0x420148], 4
jb 0x40a215
or byte [ebp + 0x12], 0x20
jmp 0x40a23a
xor eax, eax
jmp 0x40a24a
or byte [ebp + 0x12], 4
jmp 0x40a23a
mov eax, dword [0x420580]
test eax, eax
je 0x40a23a
call eax
mov ebx, eax
test ebx, ebx
je 0x40a23a
mov eax, dword [0x420584]
test eax, eax
je 0x40a23a
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x42057c]
pop edi
pop esi
pop ebx
leave
ret