joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10018a8
Capabilities:
Persist via default file association registry key
Set registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x214
mov eax, dword [0x10060b0]
push esi
mov dword [ebp - 4], eax
lea eax, [ebp - 0x214]
push eax
xor esi, esi
lea eax, [ebp - 0x210]
push eax
push esi
push 0xf003f
push esi
push esi
push esi
push 0x1001260
push 0x80000000
mov dword [ebp - 0x210], esi
mov dword [ebp - 0x214], esi
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x1001a38
cmp dword [ebp - 0x214], 1
jne 0x1001a38
push ebx
push edi
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ebx, 0x1001268
push ebx
call edi
push eax
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push 1
push esi
push esi
push dword [ebp - 0x210]
call ebx
test eax, eax
jne 0x1001a36
push dword [ebp - 0x210]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x214]
push eax
lea eax, [ebp - 0x210]
push eax
push esi
push 0xf003f
push esi
push esi
push esi
push 0x1001278
push 0x80000000
mov dword [ebp - 0x210], esi
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x1001a36
push 0x1001288
call edi
push eax
push 0x1001288
push 1
push esi
push esi
push dword [ebp - 0x210]
call ebx
test eax, eax
jne 0x1001a36
push dword [ebp - 0x210]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x214]
push eax
lea eax, [ebp - 0x210]
push eax
push esi
push 0xf003f
push esi
push esi
push esi
push 0x1001294
push 0x80000000
mov dword [ebp - 0x210], esi
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x1001a36
push 0x104
lea eax, [ebp - 0x20c]
push eax
call fcn.0100185d
lea eax, [ebp - 0x20c]
push eax
push 0x10012b8
lea eax, [ebp - 0x108]
push 0x104
push eax
call dword [sym.imp.SHLWAPI.dll_wnsprintfA]
add esp, 0x10
lea eax, [ebp - 0x108]
push eax
call edi
push eax
lea eax, [ebp - 0x108]
push eax
push 1
push esi
push esi
push dword [ebp - 0x210]
call ebx
test eax, eax
jne 0x1001a36
push dword [ebp - 0x210]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 0x210], esi
pop edi
pop ebx
cmp dword [ebp - 0x210], esi
pop esi
je 0x1001a4d
push dword [ebp - 0x210]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 4]
call fcn.01004a37
leave
ret
Function at 0x10026e0
Capabilities:
Check if file exists
Get file attributes
Query environment variable
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x114
mov eax, dword [0x10060b0]
push ebx
xor ebx, ebx
push esi
mov esi, dword [ebp + 8]
cmp esi, ebx
mov dword [ebp - 4], eax
mov dword [ebp - 0x110], ebx
mov dword [ebp - 0x10c], ebx
je 0x10027b9
lea eax, [ebp - 0x10c]
push eax
push 0x20019
push ebx
push 0x1001418
push 0x80000002
mov byte [esi], bl
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x10027a5
lea eax, [ebp - 0x114]
push eax
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x110]
push eax
push ebx
push 0x1001417
push dword [ebp - 0x10c]
mov dword [ebp - 0x114], 0x104
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x10027a5
cmp dword [ebp - 0x110], 2
lea eax, [ebp - 0x108]
jne 0x1002788
push dword [ebp + 0xc]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
mov dword [ebp - 0x114], eax
jmp 0x10027a5
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x10027a5
push dword [ebp + 0xc]
lea eax, [ebp - 0x108]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_lstrcpynA]
cmp dword [ebp - 0x10c], ebx
je 0x10027b9
push dword [ebp - 0x10c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 4]
pop esi
pop ebx
call fcn.01004a37
leave
ret 8
Function at 0x100335b
Capabilities:
Accept command line arguments
Terminate process

Disassembly:
call fcn.010049c4
jmp fcn.010032d7

Function at 0x1004350
Capabilities:
Get file size
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
mov dword [ebp - 4], ebx
je 0x1004411
cmp dword [ebp + 0x10], ebx
je 0x1004411
push ebx
push ebx
push 3
push ebx
push 3
push 0x80000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [ebp + 8], eax
jne 0x1004395
mov dword [ebp - 4], 0x80040116
jmp 0x1004405
push esi
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp esi, 0xffffffff
jne 0x10043ae
mov dword [ebp - 4], 0x80040116
jmp 0x10043fd
push edi
push esi
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edi, eax
cmp edi, ebx
jne 0x10043c7
mov dword [ebp - 4], 0x8007000e
jmp 0x10043fc
push ebx
lea eax, [ebp - 8]
push eax
push esi
push edi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x10043e4
mov dword [ebp - 4], 0x80040116
jmp 0x10043fc
cmp esi, dword [ebp - 8]
je 0x10043f2
mov dword [ebp - 4], 0x80004005
jmp 0x10043fc
mov eax, dword [ebp + 0xc]
mov dword [eax], edi
mov eax, dword [ebp + 0x10]
mov dword [eax], esi
pop edi
mov eax, dword [ebp + 8]
cmp eax, ebx
pop esi
je 0x100440c
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 4]
jmp 0x1004416
mov eax, 0x80070057
pop ebx
leave
ret 0xc
Function at 0x4011e6
Capabilities:
Print debug messages
Terminate process

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, ecx
call fcn.00401a7b
test al, al
je 0x401215
cmp dword [esi + 0x10], 0
je 0x4012e7
push str.Calling_Terminate...
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push 0
push dword [esi + 0x10]
jmp 0x4012e1
push ebx
lea eax, [ebp - 4]
push edi
mov ebx, 0x1f4
push eax
push ebx
push 2
push 0
push 0
push 0x10
mov ecx, esi
call fcn.00401b3a
mov edi, dword [sym.imp.USER32.dll_SendMessageTimeoutA]
push eax
call edi
push 0x7d0
mov ecx, esi
call fcn.004011b6
mov ecx, esi
call fcn.0040116e
test al, al
je 0x401279
lea eax, [ebp - 4]
mov ecx, esi
push eax
push ebx
push 2
push 0
push 0xf060
push 0x112
call fcn.00401b3a
push eax
call edi
push 0x3e8
mov ecx, esi
call fcn.004011b6
mov ecx, esi
call fcn.0040116e
test al, al
je 0x4012a7
lea eax, [ebp - 4]
mov ecx, esi
push eax
push ebx
push 2
push 0
push 0
push 0x12
call fcn.00401b3a
push eax
call edi
push 0x3e8
mov ecx, esi
call fcn.004011b6
mov ecx, esi
call fcn.0040116e
test al, al
je 0x4012d5
lea eax, [ebp - 4]
mov ecx, esi
push eax
push ebx
push 2
push 0
push 0
push 2
call fcn.00401b3a
push eax
call edi
push 0x3e8
mov ecx, esi
call fcn.004011b6
mov esi, dword [esi + 0x10]
pop edi
test esi, esi
pop ebx
je 0x4012e7
push 0xffffffffffffffff
push esi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
pop esi
leave
ret

Function at 0x401c5b
Capabilities:
Enumerate processes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x128
push ebx
mov ebx, dword [ebp + 0xc]
push edi
push 0
and dword [ebx + 4], 0
push 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov edi, eax
cmp edi, 0xffffffff
je 0x401cd7
lea eax, [ebp - 0x128]
mov dword [ebp - 0x128], 0x128
push eax
push edi
call sub.KERNEL32.dll_Process32First
jmp 0x401cb8
mov eax, dword [ebp - 0x110]
cmp eax, dword [ebp + 8]
je 0x401cbe
lea eax, [ebp - 0x128]
mov dword [ebp - 0x128], 0x128
push eax
push edi
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x401c96
jmp 0x401ccc
lea eax, [ebp - 0x120]
mov ecx, ebx
push eax
call fcn.00402718
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
jmp 0x401cd9
xor al, al
pop edi
pop ebx
leave
ret
Function at 0x401d0b
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x940
push ebx
push esi
push edi
mov esi, ecx
call fcn.004027ab
xor eax, eax
mov ebx, 0x104
mov dword [esi + 0x130], eax
mov dword [esi + 8], eax
mov dword [esi + 0xc], eax
lea eax, [esi + 0x134]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
call fcn.00401e50
mov ecx, esi
call fcn.004025bf
lea edi, [esi + 0x24]
push ebx
push edi
call fcn.00401e36
mov ebx, 0x42e510
push ebx
push edi
call fcn.004170f0
add esp, 0x10
jmp 0x401d7f
push ebx
push edi
call fcn.004170f0
inc eax
push eax
push edi
call fcn.00417890
push ebx
push edi
call fcn.004170f0
add esp, 0x18
test eax, eax
jne 0x401d66
mov ebx, 0x42e50c
push ebx
push edi
call fcn.004170f0
pop ecx
pop ecx
jmp 0x401dac
push ebx
push edi
call fcn.004170f0
inc eax
push eax
push edi
call fcn.00417890
push ebx
push edi
call fcn.004170f0
add esp, 0x18
test eax, eax
jne 0x401d93
push edi
call fcn.00417810
lea eax, [eax + esi + 0x21]
mov dword [esp], 0x42e508
push eax
call fcn.00417890
pop ecx
lea eax, [ebp - 0x140]
pop ecx
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x401deb
push str.RAW_001.exe
push edi
call fcn.00417890
pop ecx
pop ecx
push ebx
call dword [sym.imp.KERNEL32.dll_FindClose]
lea eax, [ebp - 0x940]
push 0x800
push eax
call fcn.00401e36
pop ecx
lea eax, [ebp - 0x940]
pop ecx
push eax
mov ecx, esi
call fcn.004027c6
lea eax, [esi + 0x128]
mov ecx, esi
push eax
call fcn.004027c2
push eax
push esi
push str.ReflexiveArcadeRAW_002.wdt
mov ecx, esi
call fcn.00401091
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret
Function at 0x402157
Capabilities:
Create process on windows
Create process suspended
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc48
push ebx
push esi
push edi
push 0x44
pop esi
xor ebx, ebx
push esi
lea eax, [ebp - 0x48]
push ebx
push eax
mov edi, ecx
call fcn.004179d0
push dword [edi + 0x130]
lea eax, [ebp - 0xc48]
mov dword [ebp - 0x48], esi
push dword [ebp + 8]
push str.__s___s
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x1c
lea eax, [edi + 0x10]
push eax
lea eax, [ebp - 0x48]
push eax
lea eax, [edi + 0x134]
push eax
push ebx
push 4
push ebx
push ebx
lea eax, [ebp - 0xc48]
push ebx
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov ecx, edi
call fcn.004026cd
test al, al
jne 0x4022a6
mov esi, dword [ebp + 0xc]
cmp dword [esi], ebx
je 0x4022a6
push dword [edi + 0x18]
push ebx
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
cmp eax, ebx
mov dword [ebp + 8], eax
je 0x4022a6
push dword [edi + 0x128]
lea ecx, [ebp - 0x448]
call fcn.00412762
lea eax, [ebp + 0xc]
mov dword [ebp + 0xc], ebx
push eax
push dword [esi]
push dword [esi + 8]
push dword [esi + 4]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_ReadProcessMemory]
test eax, eax
je 0x4022ad
cmp dword [esi], ebx
jbe 0x40223b
lea ecx, [ebp - 0x448]
call fcn.00401142
mov ecx, dword [esi + 8]
add ecx, ebx
sub byte [ecx], al
inc ebx
cmp ebx, dword [esi]
jb 0x402224
xor ebx, ebx
lea eax, [ebp - 4]
mov dword [ebp - 4], ebx
push eax
push dword [esi]
push dword [esi + 8]
push dword [esi + 4]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
jne 0x40226f
push 0xffffffffffffffff
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push str.Could_not_Write_encrypted_EXE.
call fcn.0040300a
pop ecx
cmp dword [0x436e88], ebx
je 0x40229d
mov ecx, edi
call fcn.00402355
push str.The_integration_header_was_not_valid._The_process_memory_was_mapped_incorrectly.
push dword [edi + 0x18]
call fcn.004022c8
pop ecx
push eax
call fcn.004126f4
push dword [edi + 0x18]
call fcn.0040203c
add esp, 0xc
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebx
leave
ret 8
push 0xffffffffffffffff
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push str.Could_not_Read_encrypted_EXE.
call fcn.0040300a
pop ecx
jmp 0x40223d

Function at 0x402337
Capabilities:
Suspend thread

Disassembly:
mov eax, dword [ecx + 0x14]
test eax, eax
je 0x402345
push eax
call dword [sym.imp.KERNEL32.dll_SuspendThread]
ret

Function at 0x402346
Capabilities:
Resume thread

Disassembly:
mov eax, dword [ecx + 0x14]
test eax, eax
je 0x402354
push eax
call dword [sym.imp.KERNEL32.dll_ResumeThread]
ret
Function at 0x402355
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x808
push ebx
mov ebx, ecx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
lea edi, [ebx + 8]
mov eax, dword [edi]
test eax, eax
je 0x402378
push eax
call esi
and dword [edi], 0
mov eax, dword [ebx + 0xc]
test eax, eax
je 0x402386
push eax
call esi
and dword [ebx + 0xc], 0
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 8]
push eax
call fcn.00405d34
mov ecx, eax
call fcn.00405dbc
push dword [ebp - 8]
mov esi, dword [sym.imp.KERNEL32.dll_ResetEvent]
call esi
push dword [ebp - 4]
call esi
push 2
push 0
push 2
push edi
mov ecx, ebx
call fcn.00415b0a
mov esi, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
push dword [ebp - 8]
call esi
mov edi, dword [sym.imp.KERNEL32.dll_DuplicateHandle]
push eax
call edi
test eax, eax
jne 0x4023f9
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x808]
push str.GameWrapper:_Duplicate_Pause_Event_failed__last_error__x_n
push eax
call fcn.00417a28
add esp, 0xc
lea eax, [ebp - 0x808]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push 2
push 0
lea eax, [ebx + 0xc]
push 2
push eax
mov ecx, ebx
call fcn.00415b0a
push eax
push dword [ebp - 4]
call esi
push eax
call edi
pop edi
pop esi
test eax, eax
pop ebx
jne 0x402442
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x808]
push str.GameWrapper:_Duplicate_Timeout_Event_failed__last_error__x_n
push eax
call fcn.00417a28
add esp, 0xc
lea eax, [ebp - 0x808]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
leave
ret

Function at 0x4024e4
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov edi, dword [ebx + 8]
mov esi, dword [ebx + 0xc]
push pe_nt_image_headers32
mov dword [ebp + 8], edi
push dword [ebx + 0x2c]
call fcn.00401000
push eax
push edi
call fcn.00401fdf
add esp, 0x10
test eax, eax
jne 0x402519
xor al, al
jmp 0x4025ba
movzx ecx, word [esi + 0x14]
mov edi, eax
sub edi, dword [ebp + 8]
and dword [ebp + 8], 0
lea edx, [ecx + esi + 0x18]
movzx ecx, word [esi + 6]
test ecx, ecx
mov dword [ebp - 4], ecx
jle 0x402553
mov ecx, dword [edx + 0x14]
cmp edi, ecx
jb 0x402545
mov esi, dword [edx + 0x10]
add esi, ecx
cmp edi, esi
jb 0x402553
add edx, 0x28
inc dword [ebp + 8]
mov ecx, dword [ebp + 8]
cmp ecx, dword [ebp - 4]
jl 0x402535
mov ecx, dword [edx + 0xc]
sub ecx, dword [edx + 0x14]
mov edx, dword [ebx + 0xc]
add ecx, dword [edx + 0x34]
add ecx, edi
mov dword [0x436e84], ecx
cmp dword [eax + 0x100], 0x100
jne 0x402594
cmp byte [eax + 0x105], 0
jne 0x402594
add ecx, 0x100
mov dword [0x436e8c], 0xc
mov dword [0x436e88], ecx
jmp 0x4025b8
add ecx, 0x104
push 0x18
mov dword [0x436e88], ecx
mov eax, dword [eax + 0x100]
pop ecx
mov dword [0x436e8c], eax
cmp eax, ecx
jb 0x4025b8
mov dword [0x436e8c], ecx
mov al, 1
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4025ec
Capabilities:
Enumerate processes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x130
and byte [ebp - 1], 0
push ebx
push edi
push 0
push 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov ebx, eax
or edi, 0xffffffff
cmp ebx, edi
je 0x4026c4
push esi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
mov dword [ebp - 8], eax
lea eax, [ebp - 0x130]
mov esi, 0x128
push eax
push ebx
mov dword [ebp - 0x130], esi
call sub.KERNEL32.dll_Process32First
jmp 0x402653
mov eax, dword [ebp - 8]
cmp dword [ebp - 0x128], eax
je 0x402659
lea eax, [ebp - 0x130]
mov dword [ebp - 0x130], esi
push eax
push ebx
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x402635
jmp 0x40265f
mov edi, dword [ebp - 0x118]
mov eax, dword [ebp + 8]
test eax, eax
je 0x402668
mov dword [eax], edi
cmp edi, 0xffffffff
je 0x4026bc
lea eax, [ebp - 0x130]
mov dword [ebp - 0x130], esi
push eax
push ebx
call sub.KERNEL32.dll_Process32First
jmp 0x40269d
cmp dword [ebp - 0x128], edi
je 0x4026a3
lea eax, [ebp - 0x130]
mov dword [ebp - 0x130], esi
push eax
push ebx
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x402682
jmp 0x4026bc
push dword [ebp + 0x10]
lea eax, [ebp - 0x10c]
push eax
push dword [ebp + 0xc]
call fcn.00417a80
add esp, 0xc
mov byte [ebp - 1], 1
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop esi
mov al, byte [ebp - 1]
pop edi
pop ebx
leave
ret 0xc

Function at 0x4028e6
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
mov edx, dword [esp + 0xc]
mov eax, dword [esp + 4]
test edx, edx
je 0x402912
mov ecx, dword [esp + 8]
push esi
push edi
movzx esi, byte [ecx]
movzx edi, al
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x42e6e0]
xor eax, esi
inc ecx
dec edx
jne 0x4028f8
pop edi
pop esi
ret

Function at 0x402913
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x100
push esi
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x402968
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push esi
mov dword [ebp + 0xc], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp + 0xc]
push 4
push eax
push dword [ebp + 8]
call fcn.004028e6
add esp, 0xc
mov dword [ebp + 8], eax
jmp 0x40298d
push dword [ebp + 0xc]
lea eax, [ebp - 0x100]
push str.file__s_missing_
push eax
call fcn.00417a28
lea eax, [ebp - 0x100]
push eax
push 0
call fcn.004126f4
add esp, 0x14
mov eax, dword [ebp + 8]
pop esi
leave
ret
Function at 0x402993
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x104
push ebx
push esi
push edi
xor edi, edi
push edi
push 0x80
push 3
push edi
push 1
push 0x80000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, dword [ebp + 0xc]
cmp eax, 0xffffffff
mov dword [esi], eax
jne 0x4029f1
push dword [ebp + 8]
lea eax, [ebp - 0x104]
push str.could_not_get_size_of_file__s
push eax
call fcn.00417a28
lea eax, [ebp - 0x104]
push eax
call fcn.0040300a
add esp, 0x10
push dword [esi]
call fcn.004174a5
pop ecx
mov dword [ebp + 0xc], eax
lea ecx, [ebp - 4]
push edi
push ecx
mov dword [ebp - 4], edi
push dword [esi]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x402a35
push dword [ebp + 8]
lea eax, [ebp - 0x104]
push str.could_not_read_file__s
push eax
call fcn.00417a28
lea eax, [ebp - 0x104]
push eax
call fcn.0040300a
add esp, 0x10
mov eax, dword [esi]
push str.There_was_an_error_in_reading_the_file_contents_into_memory.
cmp eax, dword [ebp - 4]
sete al
push eax
call fcn.004126f4
pop ecx
pop ecx
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp + 0xc]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x402ca5
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [eax + 0xc]
and dword [esi + 4], 0
or dword [esi], 0xffffffff
or dword [esi + 0x10], 0xffffffff
or dword [esi + 8], 0xffffffff
and dword [esi + 0x14], 0
mov dword [ebp - 4], ecx
call fcn.00402bb9
test al, al
jne 0x402e59
mov ecx, dword [ebp - 4]
call fcn.00402b4f
test al, al
je 0x402db8
lea eax, [edi + 0x78]
test eax, eax
je 0x402d75
mov ecx, dword [eax + 0x70]
test ecx, ecx
je 0x402d75
cmp dword [eax + 0x74], 0
je 0x402d75
mov eax, dword [ebp + 8]
push 0
push ecx
push dword [eax + 8]
push edi
call dword [sym.imp.IMAGEHLP.dll_ImageRvaToVa]
mov ebx, eax
test ebx, ebx
je 0x402d75
cmp dword [ebx], 0x48
push str.CLI_header_has_unexpected_size
sete al
push eax
call fcn.004126f4
mov eax, dword [ebx]
and dword [ebp + 8], 0
add eax, dword [edi + 0xe8]
pop ecx
pop ecx
mov dword [esi + 0xc], eax
movzx ecx, word [edi + 0x14]
movzx edx, word [edi + 6]
test edx, edx
lea ecx, [ecx + edi + 0x18]
mov dword [ebp + 0xc], edx
jbe 0x402d75
mov edx, dword [ecx + 0x10]
mov edi, dword [ecx + 8]
cmp edi, edx
jae 0x402d57
mov edx, edi
mov edi, dword [ecx + 0xc]
mov dword [ebp - 4], edx
cmp eax, edi
jb 0x402d67
add edx, edi
cmp eax, edx
jb 0x402d7f
inc dword [ebp + 8]
add ecx, 0x28
mov edx, dword [ebp + 8]
cmp edx, dword [ebp + 0xc]
jb 0x402d4b
push str.Error_finding_CLI_section_for_.NET_game__maybe_its_not_a_.NET_exe_
jmp 0x402e02
mov edx, dword [ebp + 8]
mov dword [esi + 4], ecx
mov dword [esi], edx
mov edx, eax
sub edx, edi
push str.CLI_header_has_unexpected_size
mov dword [esi + 8], edx
mov ecx, dword [ecx + 0x14]
add ecx, edx
mov dword [esi + 0x10], ecx
mov ecx, dword [ebx + 8]
sub ecx, eax
mov dword [esi + 0x14], ecx
add ecx, edx
cmp ecx, dword [ebp - 4]
setb al
push eax
call fcn.004126f4
pop ecx
pop ecx
jmp 0x402e59
mov edx, dword [edi + 0x28]
and dword [ebp + 8], 0
mov dword [esi + 0xc], edx
movzx eax, word [edi + 0x14]
movzx ecx, word [edi + 6]
test ecx, ecx
lea eax, [eax + edi + 0x18]
mov dword [ebp + 0xc], ecx
jbe 0x402dfd
mov ecx, dword [eax + 0x10]
mov edi, dword [eax + 8]
cmp edi, ecx
jae 0x402de1
mov ecx, edi
mov edi, dword [eax + 0xc]
cmp edx, edi
jb 0x402def
lea ebx, [edi + ecx]
cmp edx, ebx
jb 0x402e14
inc dword [ebp + 8]
add eax, 0x28
mov ecx, dword [ebp + 8]
cmp ecx, dword [ebp + 0xc]
jb 0x402dd5
push str.Error_calculating_file_offset__what_type_of_PE_file_is_this___
push 0
call fcn.004126f4
pop ecx
xor al, al
pop ecx
pop edi
pop esi
pop ebx
leave
ret 8
mov ebx, dword [ebp + 8]
sub edx, edi
mov dword [esi], ebx
mov dword [esi + 4], eax
mov dword [esi + 8], edx
mov eax, dword [eax + 0x14]
sub ecx, edx
add eax, edx
mov ebx, ecx
mov ecx, dword [ebp - 4]
mov dword [esi + 0x10], eax
call fcn.00402ae5
test al, al
je 0x402e56
mov edi, 0x80
push str.The_Code_Section_is_not_long_enough_to_encode.
cmp ebx, edi
sbb al, al
inc al
push eax
call fcn.004126f4
pop ecx
mov dword [esi + 0x14], edi
pop ecx
jmp 0x402e59
mov dword [esi + 0x14], ebx
mov al, 1
jmp 0x402e0d
Function at 0x402eeb
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
xor esi, esi
push edi
push esi
push 0x80
push 3
push esi
push 1
push 0x80000000
push str.ReflexiveArcadeRAW_004.wdt
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x402f45
push ebx
lea eax, [ebp - 4]
push esi
push eax
mov esi, 0x436eb4
push 8
push esi
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
push edi
setne bl
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test bl, bl
pop ebx
je 0x402f45
cmp dword [ebp - 4], 8
jne 0x402f45
mov eax, esi
jmp 0x402f47
xor eax, eax
pop edi
pop esi
leave
ret

Function at 0x402f4b
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push 0
push 0x80
push 2
push 0
push 2
push 0x40000000
push str.ReflexiveArcadeRAW_004.wdt
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x402fa8
lea eax, [ebp - 4]
push 0
push eax
push 8
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
push esi
setne byte [ebp + 0xb]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp byte [ebp + 0xb], 0
je 0x402fa4
cmp dword [ebp - 4], 8
jne 0x402fa4
xor eax, eax
inc eax
jmp 0x402faa
xor eax, eax
jmp 0x402faa
xor al, al
pop esi
leave
ret 4

Function at 0x403db7
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
push ebx
xor ebx, ebx
lea eax, [ebp + 0xc]
push ebx
push eax
push ebx
push 0x20006
push ebx
push ebx
push ebx
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x403e00
push dword [ebp + 0x1c]
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push ebx
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x403df7
mov bl, 1
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov al, bl
pop ebx
pop ebp
ret