joyce8/EMBER2024-capa huggingface dataset:
Function at 0x406034
Capabilities:
Resolve function by parsing pe exports

Disassembly:
mov ebp, esp
add ebp, 0x24
push esp
call fcn.00403e80
mov ebx, 0x64a9b218
mov eax, dword [0x30]
add byte [ebx + 0x708b0c40], cl
sbb al, 0xad
add byte [ebx + 0x708b0c40], cl
sbb al, 0xad
cmp byte [eax + 0x1c], 0x18
je 0x406044
xchg esi, eax
lodsd eax, dword [esi]
mov eax, dword [eax + 8]
push eax
call fcn.00403e80
mov eax, 0x8b56c708
clc
mov eax, dword [edi + 0x3c]
mov edx, dword [edi + eax + 0x78]
add edx, edi
pop es
js 0x40605e
xlatb
mov ecx, dword [edx + 0x18]
mov ebx, dword [edx + 0x20]
add ebx, edi
sbb byte [ebx - 0x20fcdfa6], cl
call fcn.00403e80
jl 0x406020
push 0x3c
dec ecx
mov esi, dword [ebx + ecx*4]
add esi, edi
mov eax, 0x50746547
cmp dword [esi], eax
jne 0x40606d
mov eax, 0x41636f72
cmp dword [esi + 4], eax
jne 0x40606d
call fcn.00403e80
or byte [ebx + 3], ch
in al, dx
mov ebx, dword [edx + 0x24]
add ebx, edi
mov cx, word [ebx + ecx*2]
mov ebx, dword [edx + 0x1c]
add ebx, edi
mov eax, dword [ebx + ecx*4]
add eax, edi
push eax
call fcn.00403e80
ja 0x406058
inc edi
retf

Function at 0x406248
Capabilities:
Check if file exists
Get file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
je 0x406271
mov eax, dword [0x40b058]
cmp eax, 0xffffffff
je 0x406265
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or dword [0x40b058], 0xffffffff
jmp 0x40631c
cmp dword [0x461530], ebx
je 0x40631c
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_WriteFile]
cmp word [0x46a560], bx
je 0x4062e8
cmp dword [0x40b058], 0xffffffff
jne 0x4062f1
mov esi, 0x46a560
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
push 4
push 0x40000000
push esi
mov dword [ebp + 8], eax
call fcn.00405fb0
mov dword [0x40b058], eax
cmp eax, 0xffffffff
je 0x40631a
cmp dword [ebp + 8], 0xffffffff
jne 0x4062dd
push ebx
lea ecx, [ebp - 4]
push ecx
push 2
lea ecx, [ebp + 8]
push ecx
push eax
mov dword [ebp + 8], 0xfeff
call edi
mov eax, dword [0x40b058]
push 2
push ebx
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp dword [0x40b058], 0xffffffff
je 0x40631a
push 0x4096a8
mov esi, 0x461540
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push ebx
lea ecx, [ebp + 8]
push ecx
add eax, eax
push eax
push esi
push dword [0x40b058]
call edi
pop edi
pop esi
pop ebx
leave
ret 4
Function at 0x40159b
Capabilities:
Compare security identifiers

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [0x407140]
push ebx
xor ebx, ebx
mov dword [ebp - 0xc], ebx
mov word [ebp - 8], 0x500
mov dword [ebp - 0x10], ebx
cmp eax, 2
jne 0x4016c2
lea eax, [ebp - 0x10]
push eax
call fcn.004014f5
test eax, eax
jne 0x4016b1
lea eax, [ebp - 0x14]
push eax
push 8
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x4016c2
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
lea eax, [ebp - 0x18]
push eax
push ebx
push ebx
push 2
push dword [ebp - 0x14]
call edi
test eax, eax
jne 0x4016a2
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x4016a2
push esi
push dword [ebp - 0x18]
push ebx
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov esi, eax
test esi, esi
je 0x4016a1
lea eax, [ebp - 0x18]
push eax
push dword [ebp - 0x18]
push esi
push 2
push dword [ebp - 0x14]
call edi
test eax, eax
je 0x40169a
lea eax, [ebp - 0x1c]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x220
push 0x20
push 2
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x40169a
cmp dword [esi], ebx
jbe 0x401691
lea edi, [esi + 4]
push dword [ebp - 0x1c]
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
jne 0x401686
inc ebx
add edi, 8
cmp ebx, dword [esi]
jb 0x40166d
jmp 0x401691
xor eax, eax
inc eax
mov dword [0x407140], eax
mov dword [ebp - 0x10], eax
push dword [ebp - 0x1c]
call dword [sym.imp.ADVAPI32.dll_FreeSid]
push esi
call dword [sym.imp.KERNEL32.dll_LocalFree]
pop esi
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
pop edi
jmp 0x4016c2
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x4016c2
mov dword [0x407140], 1
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.004068a6
leave
ret
Function at 0x401bf6
Capabilities:
Shutdown system

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
push edi
lea eax, [ebp - 0x18]
push eax
push 0x28
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
xor edi, edi
test eax, eax
jne 0x401c36
push edi
push 0x10
push edi
push edi
push 0x4f5
push edi
call fcn.004040e2
xor eax, eax
jmp 0x401c9d
push esi
lea eax, [ebp - 0x10]
push eax
push 0x4010c8
push edi
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
push edi
push edi
push edi
lea eax, [ebp - 0x14]
push eax
push edi
push dword [ebp - 0x18]
mov dword [ebp - 0x14], 1
mov dword [ebp - 8], 2
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
push dword [ebp - 0x18]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test esi, esi
pop esi
push edi
jne 0x401c82
push 0x10
push edi
push edi
push 0x4f6
jmp 0x401c2c
push 2
call dword [sym.imp.USER32.dll_ExitWindowsEx]
test eax, eax
jne 0x401c9a
push edi
push 0x10
push edi
push edi
push 0x4f7
jmp 0x401c2c
xor eax, eax
inc eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop edi
call fcn.004068a6
leave
ret

Function at 0x401caf
Capabilities:
Shutdown system

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
test byte [ebp + 8], 2
jne 0x401cc4
call fcn.00401bc4
cmp eax, 2
jne 0x401d01
test byte [ebp + 8], 4
jne 0x401ce6
push 4
push 0x40
push 0
push 0x401044
push 0x522
push 0
call fcn.004040e2
cmp eax, 6
jne 0x401d01
cmp word [0x408b60], 0
jne 0x401cfc
push 0
push 2
call dword [sym.imp.USER32.dll_ExitWindowsEx]
jmp 0x401d01
call fcn.00401bf6
pop ebp
ret 4

Function at 0x401d0a
Capabilities:
Delete registry value
Persist via run registry key

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
cmp byte [0x407658], 0
je 0x401d4f
lea eax, [ebp - 4]
push eax
push 0x20006
push 0
push str.SoftwareMicrosoftWindowsCurrentVersionRunOnce
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x401d4f
push 0x407658
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
leave
ret
Function at 0x401f9e
Capabilities:
Get common file path
Persist via run registry key
Query or enumerate registry value
Set registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x348
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
cmp byte [0x407658], 0
je 0x4020c2
push ebx
lea eax, [ebp - 0x344]
push eax
push 0x2001f
xor ebx, ebx
push ebx
push str.SoftwareMicrosoftWindowsCurrentVersionRunOnce
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x4020c1
push edi
lea eax, [ebp - 0x348]
push eax
lea eax, [ebp - 0x340]
push eax
push ebx
push ebx
push 0x407658
push dword [ebp - 0x344]
mov edi, 0x238
mov dword [ebp - 0x348], edi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4020b4
push esi
push 0x103
lea eax, [ebp - 0x107]
push ebx
push eax
mov byte [ebp - 0x108], bl
call sub.msvcrt.dll_memset
add esp, 0xc
mov esi, 0x104
push esi
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x402061
push esi
mov eax, 0x401044
lea ecx, [ebp - 0x108]
call fcn.00406177
push 0x408304
lea eax, [ebp - 0x108]
push eax
push str.rundll32.exe__sadvpack.dll_DelNodeRunDLL32___s_
lea eax, [ebp - 0x340]
push edi
push eax
call fcn.00401425
add esp, 0x14
lea ecx, [ebp - 0x340]
lea edx, [ecx + 1]
pop esi
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40208c
sub ecx, edx
lea eax, [ecx + 1]
push eax
lea eax, [ebp - 0x340]
push eax
push 1
push ebx
push 0x407658
push dword [ebp - 0x344]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push dword [ebp - 0x344]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004068a6
leave
ret
Function at 0x4020d3
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Set file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x254
mov eax, dword [0x40700c]
xor eax, esp
mov dword [esp + 0x250], eax
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
test esi, esi
je 0x402205
cmp byte [esi], 0
je 0x402205
mov ebx, 0x104
mov edx, esi
mov eax, ebx
lea ecx, [esp + 0x150]
call fcn.0040148d
mov eax, ebx
push 0x4010f8
lea ebx, [esp + 0x154]
call fcn.004013c0
lea eax, [esp + 0x10]
push eax
mov eax, ebx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x402205
mov edx, esi
mov eax, 0x104
lea ecx, [esp + 0x150]
call fcn.0040148d
test byte [esp + 0x10], 0x10
lea eax, [esp + 0x3c]
je 0x4021ba
push 0x4010fc
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
je 0x4021e3
push 0x401100
lea eax, [esp + 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
je 0x4021e3
lea eax, [esp + 0x3c]
push eax
mov eax, 0x104
lea ebx, [esp + 0x154]
call fcn.004013c0
push 0x104
mov eax, 0x401044
mov ecx, ebx
call fcn.00406177
mov eax, ebx
push eax
call fcn.004020d3
jmp 0x4021e3
push eax
mov eax, 0x104
lea ebx, [esp + 0x154]
call fcn.004013c0
push 0x80
mov eax, ebx
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov eax, ebx
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea eax, [esp + 0x10]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x402147
push edi
call dword [sym.imp.KERNEL32.dll_FindClose]
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
mov ecx, dword [esp + 0x25c]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.004068a6
mov esp, ebp
pop ebp
ret 4

Function at 0x402221
Capabilities:
Get common file path

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov edi, 0x104
push edi
lea eax, [ebp - 0x108]
push eax
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
test eax, eax
je 0x40229b
push edi
mov eax, 0x401104
lea ecx, [ebp - 0x108]
call fcn.00406177
lea eax, [ebp - 0x108]
push eax
push esi
push esi
push esi
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
push 0x40
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll__lopen]
mov edi, eax
cmp edi, 0xffffffff
je 0x40229b
push 2
push esi
push edi
call dword [sym.imp.KERNEL32.dll__llseek]
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll__lclose]
mov ecx, dword [ebp - 4]
pop edi
mov eax, esi
xor ecx, ebp
pop esi
call fcn.004068a6
leave
ret
Function at 0x4022b0
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
movzx eax, ax
push esi
xor esi, esi
test eax, eax
je 0x40235b
cmp eax, 1
je 0x402321
add eax, 0xfffffffe
cmp eax, 1
ja 0x402362
lea eax, [ebp - 8]
push eax
push 0x20019
push esi
push str.SystemCurrentControlSetControlSession_Manager
push 0x80000002
mov dword [ebp - 4], esi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40231c
lea eax, [ebp - 4]
push eax
push esi
push esi
push esi
push str.PendingFileRenameOperations
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x402313
mov dword [ebp - 4], esi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, dword [ebp - 4]
jmp 0x402362
lea eax, [ebp - 8]
push eax
push 0x20019
push esi
push str.SystemCurrentControlSetControlSession_ManagerFileRenameOperations
push 0x80000002
mov dword [ebp - 4], esi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40231c
push esi
push esi
push esi
push esi
lea eax, [ebp - 4]
push eax
push esi
push esi
push esi
push esi
push esi
push esi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyA]
jmp 0x40230c
call fcn.00402221
mov esi, eax
mov eax, esi
pop esi
leave
ret
Function at 0x4024aa
Capabilities:
Get common file path
Query environment variable
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x11c
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
xor ebx, ebx
push esi
mov esi, ecx
mov byte [edi], bl
cmp byte [esi], 0x23
mov dword [ebp - 0x110], esi
jne 0x4025dd
inc esi
movsx eax, byte [esi]
push eax
call dword [sym.imp.USER32.dll_CharUpperA]
push esi
mov esi, dword [sym.imp.USER32.dll_CharNextA]
mov byte [ebp - 0x109], al
call esi
push eax
call esi
mov dword [ebp - 0x110], eax
mov al, byte [ebp - 0x109]
mov esi, 0x104
cmp al, 0x53
je 0x4025e2
cmp al, 0x57
je 0x4025d3
mov edx, 0x401114
mov eax, esi
lea ecx, [ebp - 0x108]
mov dword [ebp - 0x11c], esi
call fcn.0040148d
mov eax, dword [ebp - 0x110]
push esi
lea ecx, [ebp - 0x108]
call fcn.00406177
lea eax, [ebp - 0x118]
push eax
push 0x20019
push ebx
lea eax, [ebp - 0x108]
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x4025ee
lea eax, [ebp - 0x11c]
push eax
push edi
lea eax, [ebp - 0x114]
push eax
push ebx
push 0x401044
push dword [ebp - 0x118]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4025c5
mov eax, dword [ebp - 0x114]
cmp eax, 2
jne 0x4025bd
push esi
lea eax, [ebp - 0x108]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
test eax, eax
je 0x4025b7
lea edx, [ebp - 0x108]
mov ecx, edi
call fcn.00401395
jmp 0x4025c2
mov eax, dword [ebp - 0x114]
cmp eax, 1
jne 0x4025c5
xor ebx, ebx
inc ebx
push dword [ebp - 0x118]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x4025ea
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
jmp 0x4025ee
mov esi, 0x104
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test ebx, ebx
jne 0x4025fc
mov eax, dword [ebp - 0x110]
push esi
mov ecx, edi
call fcn.00406177
mov ecx, dword [ebp - 4]
xor eax, eax
pop esi
xor ecx, ebp
inc eax
pop ebx
call fcn.004068a6
leave
ret
Function at 0x402612
Capabilities:
Get file version info

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x30
push ebx
push esi
xor esi, esi
push edi
mov edi, dword [ebp + 8]
mov ebx, esi
mov eax, esi
mov dword [ebp - 4], esi
cmp dword [edi + 0x7c], esi
jle 0x4027a8
mov ecx, esi
mov dword [ebp - 8], esi
lea eax, [ecx + edi]
mov ecx, dword [edi + 0x80]
mov eax, dword [eax + ecx + 0xbc]
mov dword [ebp - 0xc], ecx
lea ecx, [edi + 0x84]
mov edi, dword [ebp + 0xc]
add ecx, eax
call fcn.004024aa
test eax, eax
je 0x40274a
lea eax, [ebp - 0x14]
push eax
push edi
call dword [sym.imp.VERSION.dll_GetFileVersionInfoSizeA]
mov dword [ebp - 0x10], eax
test eax, eax
je 0x402772
push eax
push 0x42
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ebx, eax
test ebx, ebx
je 0x40274a
push ebx
call dword [sym.imp.KERNEL32.dll_GlobalLock]
mov edi, eax
test edi, edi
je 0x40274a
push edi
push dword [ebp - 0x10]
push dword [ebp - 0x14]
push dword [ebp + 0xc]
call dword [sym.imp.VERSION.dll_GetFileVersionInfoA]
test eax, eax
je 0x402766
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x1c]
push eax
push 0x401148
push edi
call dword [sym.imp.VERSION.dll_VerQueryValueA]
test eax, eax
je 0x402766
cmp dword [ebp - 0x18], 0
je 0x402766
mov eax, dword [ebp - 0x1c]
mov ecx, dword [eax + 0xc]
mov eax, dword [eax + 8]
mov edx, dword [ebp - 0xc]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 8]
add eax, dword [ebp + 8]
add edx, 0x94
mov edi, esi
mov esi, ecx
mov ecx, dword [ebp - 0x20]
add edx, eax
push dword [edx - 0xc]
mov eax, esi
push dword [edx - 0x10]
call fcn.004027b2
push dword [edx]
mov dword [ebp + edi - 0x28], eax
push dword [edx - 4]
mov eax, esi
call fcn.004027b2
mov dword [ebp + edi - 0x30], eax
add edi, 4
add edx, 0x18
cmp edi, 8
jl 0x4026fe
mov edi, dword [ebp + 8]
xor esi, esi
cmp dword [ebp - 0x28], esi
jl 0x402739
cmp dword [ebp - 0x30], esi
jle 0x402769
cmp dword [ebp - 0x24], esi
jl 0x402743
cmp dword [ebp - 0x2c], esi
jle 0x402769
push ebx
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
mov eax, dword [ebp - 4]
mov ecx, dword [ebp + 0x10]
mov dword [ecx], eax
test ebx, ebx
je 0x40275d
push ebx
call dword [sym.imp.KERNEL32.dll_GlobalFree]
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret 0xc
mov edi, dword [ebp + 8]
push ebx
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
jmp 0x40278f
mov edi, dword [ebp + 8]
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0xc]
add eax, edi
cmp dword [eax + ecx + 0x84], esi
jne 0x40274a
cmp dword [eax + ecx + 0x88], esi
jne 0x40274a
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 8]
inc eax
add ecx, 0x3c
mov dword [ebp - 4], eax
mov dword [ebp - 8], ecx
cmp eax, dword [edi + 0x7c]
jl 0x402637
xor esi, esi
inc esi
jmp 0x40274d
Function at 0x4029e2
Capabilities:
Check mutex on windows
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push edi
push 0x8fc
xor edi, edi
push edi
push 0x408260
mov ebx, ecx
mov dword [0x408244], esi
call sub.msvcrt.dll_memset
push 0x32c
push edi
push 0x407a20
call sub.msvcrt.dll_memset
push 0x104
push edi
push 0x408140
call sub.msvcrt.dll_memset
add esp, 0x24
push 0x7f
xor eax, eax
push 0x408274
inc eax
push 0x40117c
mov dword [0x40850c], eax
call fcn.004042f1
test eax, eax
je 0x402c30
cmp eax, 0x80
ja 0x402c30
push edi
xor eax, eax
inc eax
push eax
push eax
push edi
call dword [sym.imp.KERNEL32.dll_CreateEventA]
push eax
mov dword [0x4076b0], eax
call dword [sym.imp.KERNEL32.dll_SetEvent]
push 4
push 0x408b54
push 0x401184
call fcn.004042f1
test eax, eax
jne 0x402ab1
xor eax, eax
push eax
push 0x10
push eax
push eax
push 0x4b1
push eax
call fcn.004040e2
mov dword [0x408b68], 0x80070714
jmp 0x402c42
test byte [0x408b54], 0xc0
je 0x402b57
push 0x104
lea eax, [ebp - 0x108]
push eax
push 0x401190
call fcn.004042f1
test eax, eax
je 0x402a90
lea eax, [ebp - 0x108]
push eax
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov dword [0x4076ac], eax
test eax, eax
je 0x402b57
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x402b57
test byte [0x408b54], 0x80
je 0x402b20
xor eax, eax
push eax
push 0x10
push eax
push 0x408274
push 0x54b
push eax
call fcn.004040e2
jmp 0x402b3c
push 4
push 0x20
push 0
push 0x408274
push 0x524
push 0
call fcn.004040e2
cmp eax, 6
je 0x402b57
push dword [0x4076ac]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [0x408b68], 0x800700b7
jmp 0x402c42
and dword [0x408b64], edi
mov ecx, ebx
call fcn.00405847
test eax, eax
jne 0x402b77
push eax
push 0x10
push eax
push eax
push 0x520
jmp 0x402c3c
cmp byte [0x407a3a], 0
je 0x402b8f
push 0x407a3a
call fcn.004020d3
jmp 0x402c42
push 0xa
push 0x4011a0
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
je 0x402bab
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov edi, eax
cmp dword [0x4072d8], 0
je 0x402bba
call dword [sym.imp.COMCTL32.dll_InitCommonControls]
cmp dword [0x407a24], 0
je 0x402bc8
xor eax, eax
inc eax
jmp 0x402c44
mov ecx, edi
call fcn.004033d7
test eax, eax
je 0x402c42
mov ax, word [0x408b60]
xor ebx, ebx
inc ebx
cmp ax, bx
je 0x402bed
cmp ax, 2
je 0x402bed
cmp ax, 3
jne 0x402c2c
test dword [0x408b54], 0x100
je 0x402c2c
test byte [0x407a38], 1
jne 0x402c2c
call fcn.0040159b
test eax, eax
jne 0x402c2c
push 0x83e
push 0x547
push 0x4016d4
push eax
push 0x7d6
call fcn.0040606f
cmp eax, 0x83d
jne 0x402c42
mov eax, ebx
jmp 0x402c44
xor eax, eax
push eax
push 0x10
push eax
push eax
push 0x4b1
push eax
call fcn.004040e2
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop ebx
call fcn.004068a6
leave
ret
Function at 0x402c57
Capabilities:
Get common file path
Set current directory

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x10c
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
cmp word [0x407a38], 0
jne 0x402ca2
cmp dword [0x407a24], 0
jne 0x402c99
call fcn.00404ddf
test eax, eax
jne 0x402c8f
xor eax, eax
jmp 0x402dbd
cmp word [0x407a38], 0
jne 0x402ca2
call fcn.004036cc
test eax, eax
je 0x402c88
call fcn.00404d56
test eax, eax
je 0x402c88
call fcn.004051b0
test eax, eax
je 0x402c88
push ebx
push esi
push edi
mov esi, 0x105
push esi
lea eax, [ebp - 0x10c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
push esi
mov eax, 0x401048
lea ecx, [ebp - 0x10c]
call fcn.00406177
lea eax, [ebp - 0x10c]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov esi, eax
xor edi, edi
mov ebx, 0x408304
test esi, esi
je 0x402d09
push 0x4011ac
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x402d09
push edi
push ebx
call eax
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp dword [0x407a24], edi
jne 0x402d29
cmp dword [0x408b50], edi
jne 0x402d29
call fcn.00405d80
test eax, eax
je 0x402d9c
push ebx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
test eax, eax
jne 0x402d50
push edi
push 0x10
push edi
push edi
push 0x4bc
push edi
call fcn.004040e2
call fcn.00405de9
mov dword [0x408b68], eax
jmp 0x402d9c
cmp dword [0x407a2c], edi
jne 0x402d61
call fcn.004037af
test eax, eax
je 0x402d9c
test byte [0x407d48], 0xc0
jne 0x402d7c
mov ax, word [0x408b60]
call fcn.004022b0
mov dword [0x408b5c], eax
jmp 0x402d82
mov dword [0x408b5c], edi
mov eax, dword [0x407a24]
test eax, eax
jne 0x402da5
cmp dword [0x408b50], edi
jne 0x402da5
call fcn.0040382f
test eax, eax
jne 0x402da0
xor eax, eax
jmp 0x402dba
mov eax, dword [0x407a24]
cmp word [0x407a38], di
jne 0x402db7
test eax, eax
jne 0x402db7
call fcn.00403dd4
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004068a6
leave
ret
Function at 0x403c5a
Capabilities:
Create process on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x21c
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, edx
xor eax, eax
push edi
test esi, esi
je 0x403d72
lea edi, [ebp - 0x21c]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
lea eax, [ebp - 0x21c]
push eax
push ecx
xor edi, edi
push edi
push edi
push 0x20
push edi
push edi
push edi
push esi
push edi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x403d2c
push 0xffffffffffffffff
push dword [ebp - 0x21c]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [ebp - 0x20c]
push eax
push dword [ebp - 0x21c]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
mov ebx, dword [ebp - 0x20c]
cmp dword [0x407a28], edi
jne 0x403cf9
mov eax, dword [0x408b4c]
test al, 1
je 0x403cf9
test al, 2
jne 0x403cf9
mov eax, ebx
and eax, 0xff000000
cmp eax, 0xaa000000
jne 0x403cf9
mov dword [0x408b4c], ebx
call fcn.00403d86
push dword [ebp - 0x218]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x21c]
call esi
test dword [0x408b54], 0x400
je 0x403d6f
cmp dword [ebp - 0x20c], edi
jge 0x403d6f
mov eax, edi
jmp 0x403d72
call fcn.00405de9
push edi
mov dword [0x408b68], eax
push 0x200
lea eax, [ebp - 0x208]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
push 0x1000
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push edi
push 0x10
lea eax, [ebp - 0x208]
push eax
push esi
push 0x4c4
push edi
call fcn.004040e2
jmp 0x403d28
xor eax, eax
inc eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004068a6
leave
ret