joyce8/EMBER2024-capa huggingface dataset:
Function at 0x468bb0
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
mov ecx, dword [esp + 8]
test ecx, ecx
jne 0x468bbb
xor eax, eax
ret
mov eax, dword [esp + 4]
push ebx
push esi
mov esi, dword [esp + 0x14]
cmp esi, 8
not eax
jb 0x468cbe
push edi
mov edi, esi
shr edi, 3
mov edx, eax
xor ebx, ebx
mov bl, byte [ecx]
and edx, 0xff
xor edx, ebx
mov ebx, eax
shr ebx, 8
mov eax, dword [edx*4 + 0x577244]
sub esi, 8
xor eax, ebx
inc ecx
mov edx, eax
xor ebx, ebx
mov bl, byte [ecx]
and edx, 0xff
xor edx, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov edx, dword [edx*4 + 0x577244]
shr eax, 8
xor edx, eax
inc ecx
mov eax, edx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov eax, dword [eax*4 + 0x577244]
shr edx, 8
xor eax, edx
inc ecx
mov edx, eax
and edx, 0xff
xor edx, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov edx, dword [edx*4 + 0x577244]
shr eax, 8
xor edx, eax
inc ecx
mov eax, edx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov eax, dword [eax*4 + 0x577244]
shr edx, 8
xor eax, edx
inc ecx
mov edx, eax
and edx, 0xff
xor edx, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov edx, dword [edx*4 + 0x577244]
shr eax, 8
xor edx, eax
inc ecx
mov eax, edx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov eax, dword [eax*4 + 0x577244]
shr edx, 8
xor eax, edx
inc ecx
mov edx, eax
and edx, 0xff
xor edx, ebx
shr eax, 8
mov edx, dword [edx*4 + 0x577244]
xor eax, edx
inc ecx
dec edi
jne 0x468bd6
pop edi
test esi, esi
je 0x468ce0
mov edx, eax
xor ebx, ebx
mov bl, byte [ecx]
and edx, 0xff
xor edx, ebx
shr eax, 8
mov edx, dword [edx*4 + 0x577244]
xor eax, edx
inc ecx
dec esi
jne 0x468cc2
pop esi
pop ebx
not eax
ret

Function at 0x469660
Capabilities:
Read file on windows

Disassembly:
push ebx
mov ebx, dword [esp + 0x14]
push ebp
mov ebp, dword [esp + 0x10]
mov cl, byte [ebx]
mov eax, ebp
imul eax, dword [esp + 0x14]
test cl, cl
je 0x4696a1
mov edx, dword [esp + 0xc]
lea ecx, [esp + 0xc]
push 0
push ecx
push eax
mov eax, dword [ebx + 4]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x469696
mov byte [ebx + 8], 1
mov eax, dword [esp + 0xc]
xor edx, edx
div ebp
pop ebp
pop ebx
ret
mov edx, dword [ebx + 0x18]
mov ecx, dword [ebx + 0x14]
push esi
push edi
lea esi, [edx + eax]
cmp esi, ecx
jbe 0x4696b4
sub ecx, edx
mov eax, ecx
mov esi, dword [ebx + 0x10]
mov edi, dword [esp + 0x14]
mov ecx, eax
add esi, edx
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
xor edx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebx + 0x18]
pop edi
add ecx, eax
pop esi
div ebp
mov dword [ebx + 0x18], ecx
pop ebp
pop ebx
ret
Function at 0x46a5f0
Capabilities:
Get common file path

Disassembly:
push ecx
push ebp
mov ebp, ecx
push esi
push edi
cmp dword [ebp], 0
jne 0x46a6a5
cmp dword [ebp + 4], 0xffffffff
jne 0x46a6a5
push ebx
lea ebx, [ebp + 0x138]
push ebx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov edi, 0x59286c
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, ebx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
pop ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x1c]
mov edi, dword [esp + 0x14]
cmp esi, 1
jne 0x46a66d
push edi
call dword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 1
je 0x46a66d
pop edi
pop esi
mov eax, 0x2000000
pop ebp
pop ecx
ret 0xc
mov ecx, dword [esp + 0x18]
lea eax, [esp + 0xc]
push eax
push esi
push ecx
push edi
call fcn.004693f0
add esp, 0x10
test eax, eax
jne 0x46a690
mov eax, dword [esp + 0xc]
pop edi
pop esi
pop ebp
pop ecx
ret 0xc
push eax
call fcn.00469930
add esp, 4
mov dword [ebp], eax
xor eax, eax
pop edi
pop esi
pop ebp
pop ecx
ret 0xc
pop edi
pop esi
mov eax, 0x1000000
pop ebp
pop ecx
ret 0xc

Function at 0x46ab00
Capabilities:
Create directory

Disassembly:
mov ecx, dword [esp + 8]
sub esp, 0x208
test ecx, ecx
je 0x46abc8
mov al, byte [ecx]
test al, al
je 0x46abc8
push ebx
push esi
push edi
mov ebx, ecx
mov esi, ecx
cmp al, 0x2f
je 0x46ab2b
cmp al, 0x5c
jne 0x46ab2d
mov ebx, esi
mov al, byte [esi + 1]
inc esi
test al, al
jne 0x46ab23
mov edi, dword [esp + 0x218]
cmp ebx, ecx
je 0x46ab64
mov esi, ebx
lea eax, [esp + 0xc]
sub esi, ecx
push esi
push ecx
push eax
call fcn.00471b7e
lea ecx, [esp + 0x18]
mov byte [esp + esi + 0x18], 0
push ecx
push edi
call fcn.0046ab00
add esp, 0x14
inc ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x110]
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x110]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
mov edi, ebx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea eax, [esp + 0x114]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
pop edi
pop esi
pop ebx
add esp, 0x208
ret
Function at 0x46b260
Capabilities:
Check for time delay via gettickcount

Disassembly:
sub esp, 0xa0
push ebx
push ebp
mov ebp, dword [esp + 0xac]
push esi
push edi
push ebp
call sub.RASAPI32.dll_RasHangUpA
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, 0x28
xor eax, eax
lea edi, [esp + 0x10]
rep stosd dword es:[edi], eax
mov dword [esp + 0x10], 0xa0
call esi
mov edi, eax
call esi
sub eax, edi
cmp eax, 0xbb8
jae 0x46b2c6
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
lea eax, [esp + 0x10]
push eax
push ebp
call sub.RASAPI32.dll_RasGetConnectStatusA
cmp eax, 6
je 0x46b2c6
push 0
call ebx
call esi
sub eax, edi
cmp eax, 0xbb8
jb 0x46b2a7
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xa0
ret

Function at 0x46b650
Capabilities:
Create http request

Disassembly:
push esi
mov esi, ecx
cmp dword [esi], 0
jne 0x46b688
mov edx, dword [esi + 4]
xor eax, eax
push 0
push 0
mov ecx, dword [edx - 8]
test ecx, ecx
setne al
mov ecx, eax
neg ecx
sbb ecx, ecx
and ecx, edx
neg eax
sbb eax, eax
push ecx
and eax, 2
inc eax
push eax
push str.Mozilla_4.0__compatible__MSIE_6.0__Windows_NT_5.0_
call dword [sym.imp.WININET.dll_InternetOpenA]
mov dword [esi], eax
mov ecx, dword [esi]
xor eax, eax
test ecx, ecx
setne al
pop esi
ret
Function at 0x46c310
Capabilities:
Get socket status

Disassembly:
sub esp, 0x10c
mov eax, dword [ecx]
lea ecx, [esp]
push ecx
push 0
lea edx, [esp + 0x10]
push 0
push edx
push 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x20], eax
mov dword [esp + 0x1c], 1
call sub.WS2_32.dll_select
cmp eax, 0xffffffff
jne 0x46c359
xor eax, eax
add esp, 0x10c
ret 4
mov edx, dword [esp + 0x110]
xor ecx, ecx
test eax, eax
setne cl
mov dword [edx], ecx
mov eax, 1
add esp, 0x10c
ret 4

Function at 0x46c7d0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x48f880
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
push esi
mov esi, ecx
lea ecx, [esp + 4]
call fcn.0046c380
lea eax, [esp + 4]
lea ecx, [esi + 4]
push eax
mov dword [esp + 0x18], 0
call fcn.0046c400
lea ecx, [esp + 4]
push ecx
lea ecx, [esi + 0x14]
call fcn.0046c400
lea ecx, [esi + 0xc]
call fcn.00480968
lea ecx, [esi + 0x10]
call fcn.00480968
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x1c]
call fcn.0046d990
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x30]
call fcn.0046d990
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x44]
call fcn.0046d990
lea ecx, [esp + 8]
mov dword [esp + 0x14], 1
call fcn.004809dd
lea ecx, [esp + 4]
mov dword [esp + 0x14], 0xffffffff
call fcn.004809dd
mov ecx, dword [esp + 0xc]
pop esi
mov dword fs:[0], ecx
add esp, 0x14
ret
Function at 0x4718f4
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x471914
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0047126a
pop ecx
or eax, 0xffffffff
ret
test al, 1
je 0x471937
test byte [esp + 8], 2
je 0x471937
call fcn.004712dd
mov dword [eax], 0xd
call fcn.004712e6
mov dword [eax], 5
jmp 0x471910
xor eax, eax
ret

Function at 0x482d81
Capabilities:
Get graphical window text

Disassembly:
push esi
mov esi, ecx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x482db9
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
lea ecx, [eax + 1]
push ecx
mov ecx, dword [esp + 0xc]
push eax
call fcn.00480e38
push eax
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov ecx, dword [esp + 8]
push 0xffffffffffffffff
call fcn.00480e10
jmp 0x482dc5
mov eax, dword [ecx]
push dword [esp + 8]
call dword [eax + 0x88]
pop esi
ret 4

Function at 0x484472
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push esi
push edi
xor edi, edi
cmp dword [esp + 0x10], edi
mov ebx, ecx
je 0x4844b4
call fcn.0048a1ec
mov esi, dword [eax + 0xc]
push 0xf0
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x4844b4
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x4844ab
xor eax, eax
jmp 0x4844bc
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.004844c2
pop edi
pop esi
pop ebx
ret 4

Function at 0x48a71c
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, ecx
lea ebx, [esi + 0x1c]
push ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esp + 0x10], 0
jne 0x48a74a
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x48a768
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.0048a682
jmp 0x48a768
mov eax, dword [esi + 0x14]
test eax, eax
je 0x48a768
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
mov ecx, esi
push eax
call fcn.0048a682
test edi, edi
mov eax, edi
jne 0x48a752
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8
Function at 0x409e0c
Capabilities:
Delete file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffe0
push ebx
push esi
push edi
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x14]
call fcn.00403520
mov eax, dword [ebp - 0x18]
call fcn.00403520
mov eax, dword [ebp - 0x1c]
call fcn.00403520
xor eax, eax
push ebp
push 0x409f10
push dword fs:[eax]
mov dword fs:[eax], esp
push ebp
mov eax, dword [ebp - 0x14]
call fcn.00403530
push eax
mov eax, dword [ebp - 0x18]
call fcn.00403530
mov edx, eax
mov eax, dword [0x40c650]
pop ecx
call fcn.00409d94
pop ecx
test al, al
je 0x409ef5
mov eax, dword [ebp - 0x1c]
call fcn.004048ec
test al, al
je 0x409e86
mov eax, dword [ebp - 0x1c]
call fcn.00403530
push eax
call sub.kernel32.dll_DeleteFileA
xor eax, eax
push ebp
push 0x409eda
push dword fs:[eax]
mov dword fs:[eax], esp
push 0
push 0x80
push 2
push 0
push 0
push 0xc0000000
mov eax, dword [ebp - 0x1c]
call fcn.00403530
push eax
call sub.kernel32.dll_CreateFileA
mov ebx, eax
push 0
lea eax, [ebp - 0x20]
push eax
mov eax, dword [ebp - 8]
push eax
mov eax, dword [ebp - 4]
push eax
push ebx
call sub.kernel32.dll_WriteFile_1
push ebx
call sub.kernel32.dll_CloseHandle
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x409ee4
mov eax, dword [ebp - 0x10]
call fcn.00404520
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FreeResource
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x409f17
lea eax, [ebp - 0x1c]
mov edx, 3
call fcn.00403140
ret

Function at 0x503b67
Capabilities:
Accept command line arguments
Hide graphical window

Disassembly:
mov ecx, ebp
push ebp
mov ebp, esp
mov dword [0x505076], ecx
call dword [sym.imp.kernel32.dll_GetCommandLineA]
mov dword [0x505298], eax
mov dword [0x505220], 0x5032dd
mov dword [0x50521c], 2
jmp 0x503b97
mov dword [0x505224], 0
mov dword [0x505228], 0
mov dword [0x505218], 0x30
push 0
call dword [sym.imp.kernel32.dll_GetModuleHandleA]
mov dword [0x50522c], eax
mov dword [0x505240], 0x504088
mov dword [0x505238], 0xf
mov dword [0x50506e], eax
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadIconA]
mov dword [0x505230], eax
mov dword [0x505244], eax
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadCursorA]
mov dword [0x505234], eax
push 0x505218
call dword [sym.imp.user32.dll_RegisterClassExA]
push 0
push dword [0x50506e]
push 0
push 0
push 0x1e5
push 0x21e
push 0xffffe52a
push 0xfffff588
push 0x40000
push str.wait
push str.aroka
push 0
call dword [sym.imp.user32.dll_CreateWindowExA]
mov dword [0x505290], eax
push 5
push dword [0x505290]
call dword [sym.imp.user32.dll_ShowWindow]
push dword [0x505290]
call dword [sym.imp.user32.dll_UpdateWindow]
jmp 0x503c6a
push 0
push 0
push 0
push 0x505248
call dword [sym.imp.user32.dll_GetMessageA]
or eax, eax
je 0x503c97
push 0x505248
call dword [sym.imp.user32.dll_TranslateMessage]
push 0x505248
call dword [sym.imp.user32.dll_DispatchMessageA]
jmp 0x503c6a
mov eax, dword [0x505250]
jmp 0x503ca4
call 0x502b16
ret
Function at 0x4cbf70
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 4]
push eax
push dword [ebp + 0xc]
mov ecx, dword [esi + 4]
call fcn.00420f9f
push 0xfffffffffffffff0
push dword [ebp - 4]
call dword [sym.imp.USER32.dll_GetWindowLongW]
push dword [ebp + 0xc]
and eax, 3
mov ecx, esi
cmp al, 3
je 0x4cbfac
call fcn.004cc18f
mov dword [esi + 0xc], 1
jmp 0x4cbfb1
call fcn.004cc18f
cmp dword [esi], 0
je 0x4cbffa
push dword [ebp - 4]
call dword [sym.imp.USER32.dll_GetWindowTextLengthW]
mov esi, dword [ebp + 0x10]
test eax, eax
jle 0x4cbfd4
lea ecx, [eax + 1]
push ecx
push eax
mov ecx, esi
call fcn.0041c8f6
jmp 0x4cbfe5
push 0xff
mov ecx, esi
call fcn.0040fe36
push 0x100
push eax
push dword [ebp - 4]
call dword [sym.imp.USER32.dll_GetWindowTextW]
push 0xffffffffffffffff
mov ecx, esi
call fcn.00418f7e
jmp 0x4cc01e
mov esi, dword [ebp + 0x10]
push dword [esi]
push 0xffffffffffffffff
push 0x14d
push dword [ebp - 4]
call dword [sym.imp.USER32.dll_SendMessageW]
cmp eax, 0xffffffff
jne 0x4cc01e
push dword [esi]
push dword [ebp - 4]
call fcn.0042433b
pop esi
mov esp, ebp
pop ebp
ret 0xc

Function at 0x4cc0e4
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
mov ecx, esi
push edi
push dword [ebp + 0xc]
call fcn.004cc18f
cmp dword [esi], 0
mov edi, eax
mov dword [esi + 0xc], 1
je 0x4cc12c
push edi
call dword [sym.imp.USER32.dll_GetWindowTextLengthW]
lea ecx, [eax + 1]
push ecx
mov ecx, dword [ebp + 0x10]
push eax
call fcn.0041c8f6
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowTextW]
mov ecx, dword [ebp + 0x10]
push 0xffffffffffffffff
call fcn.00418f7e
jmp 0x4cc137
mov eax, dword [ebp + 0x10]
push dword [eax]
push edi
call fcn.0042433b
pop edi
pop esi
pop ebp
ret 0xc
Function at 0x402473
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push edi
push 0x41b3f0
push dword [ebp + 8]
lea eax, [ebp - 4]
xor edi, edi
push eax
mov dword [ebp - 4], edi
call fcn.0040924e
add esp, 0xc
test eax, eax
je 0x40249d
xor eax, eax
jmp 0x402520
push ebx
push esi
push 2
push edi
push dword [ebp - 4]
call fcn.0040931f
push dword [ebp - 4]
call fcn.0040952f
push edi
push edi
push dword [ebp - 4]
mov esi, eax
call fcn.0040931f
lea eax, [esi + 0x32]
push eax
mov dword [ebp - 8], eax
call fcn.004090c2
push dword [ebp - 4]
mov edi, eax
push 1
push esi
push edi
call fcn.004097de
push dword [ebp - 4]
call fcn.00409868
push 0x32
lea ebx, [edi + esi]
call fcn.0040302d
push 0x41b3f8
push dword [ebp + 0xc]
lea eax, [ebp - 4]
push eax
call fcn.0040924e
add esp, 0x44
pop esi
pop ebx
test eax, eax
jne 0x402496
push dword [ebp - 4]
push 1
push dword [ebp - 8]
push edi
call fcn.00409a33
push dword [ebp - 4]
call fcn.00409868
xor eax, eax
add esp, 0x14
inc eax
pop edi
leave
ret

Function at 0x404599
Capabilities:
Hash data using sha1

Disassembly:
and dword [eax + 4], 0
and dword [eax], 0
mov dword [eax + 8], 0x67452301
mov dword [eax + 0xc], 0xefcdab89
mov dword [eax + 0x10], 0x98badcfe
mov dword [eax + 0x14], 0x10325476
mov dword [eax + 0x18], 0xc3d2e1f0
ret

Function at 0x40472b
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1070
call fcn.00412d30
mov eax, dword [0x41f044]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push esi
push edi
push 0x41b3f0
push eax
lea eax, [ebp - 0x1064]
mov esi, ecx
xor edi, edi
push eax
mov dword [ebp - 0x106c], esi
mov dword [ebp - 0x1064], edi
mov dword [ebp - 0x1068], edi
call fcn.0040924e
add esp, 0xc
cmp dword [ebp - 0x1064], edi
jne 0x40478a
mov edi, esi
xor eax, eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
xor eax, eax
jmp 0x404850
push ebx
push 2
push edi
push dword [ebp - 0x1064]
call fcn.0040931f
push dword [ebp - 0x1064]
call fcn.0040952f
push edi
push edi
push dword [ebp - 0x1064]
mov dword [ebp - 0x1070], eax
call fcn.0040931f
lea eax, [ebp - 0x1060]
call fcn.00404599
push dword [ebp - 0x1064]
mov esi, 0x1000
push esi
lea eax, [ebp - 0x1004]
push 1
push eax
call fcn.004097de
mov ebx, eax
add esp, 0x2c
cmp ebx, edi
jbe 0x40481b
push ebx
lea edi, [ebp - 0x1060]
lea ecx, [ebp - 0x1004]
call fcn.004045c4
push dword [ebp - 0x1064]
add dword [ebp - 0x1068], ebx
push esi
lea eax, [ebp - 0x1004]
push 1
push eax
call fcn.004097de
mov ebx, eax
add esp, 0x14
test ebx, ebx
jne 0x4047e5
mov edi, dword [ebp - 0x106c]
push edi
lea esi, [ebp - 0x1060]
call fcn.0040465a
push dword [ebp - 0x1064]
call fcn.00409868
mov eax, dword [ebp - 0x1068]
pop ecx
pop ecx
pop ebx
cmp eax, dword [ebp - 0x1070]
jb 0x40477c
xor eax, eax
inc eax
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.00408f0f
leave
ret
Function at 0x404fd3
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1010
call fcn.00412d30
mov eax, dword [0x41f044]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [0x4191ec]
xor ebx, ebx
push ebx
mov dword [ebp - 0x100c], eax
push 4
lea eax, [ebp - 0x1008]
push eax
push dword [edi]
call esi
cmp eax, 4
je 0x405014
xor eax, eax
jmp 0x40507d
cmp dword [ebp - 0x1008], ebx
jbe 0x405066
push 0
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [edi]
call esi
mov dword [ebp - 0x1010], eax
test eax, eax
je 0x405066
mov ecx, dword [ebp - 0x100c]
push dword [ecx]
push eax
lea eax, [ebp - 0x1004]
push 1
push eax
call fcn.00409a33
add ebx, dword [ebp - 0x1010]
add esp, 0x10
mov dword [0x4217d8], ebx
cmp ebx, dword [ebp - 0x1008]
jb 0x40501c
mov eax, dword [ebp - 0x100c]
push dword [eax]
call fcn.00409868
cmp ebx, dword [ebp - 0x1008]
pop ecx
sbb eax, eax
inc eax
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.00408f0f
leave
ret

Function at 0x405505
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x41f044]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x20c], ax
lea eax, [ebp - 0x20a]
push eax
xor esi, esi
call fcn.0040cf40
add esp, 0xc
test edi, edi
je 0x4055af
and dword [ebp - 0x210], esi
lea eax, [ebp - 0x20c]
push eax
mov esi, 0x104
push esi
call dword [0x419090]
push str.golfinfo.ini
lea eax, [ebp - 0x20c]
push esi
push eax
call fcn.00408f1e
push 0x41b3f8
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x210]
push eax
call fcn.0040924e
xor esi, esi
add esp, 0x18
inc esi
cmp dword [ebp - 0x210], 0
je 0x4055af
push dword [ebp - 0x210]
push esi
push 0x200
push edi
call fcn.00409a33
push dword [ebp - 0x210]
call fcn.00409868
add esp, 0x14
mov ecx, dword [ebp - 4]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.00408f0f
leave
ret

Function at 0x4055be
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x41f044]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
xor eax, eax
push 0x206
xor ebx, ebx
mov word [ebp - 0x20c], ax
lea eax, [ebp - 0x20a]
push ebx
push eax
call fcn.0040cf40
add esp, 0xc
mov dword [ebp - 0x210], ebx
cmp edi, ebx
je 0x405695
cmp dword [0x41ff10], 3
push esi
mov esi, 0x104
lea eax, [ebp - 0x20c]
jne 0x405634
push esi
push eax
call dword [0x419020]
push 0x41b284
lea eax, [ebp - 0x20c]
push esi
push eax
call fcn.00408f1e
add esp, 0xc
jmp 0x40563c
push eax
push esi
call dword [0x419090]
push str.golfset.ini
lea eax, [ebp - 0x20c]
push esi
push eax
call fcn.00408f1e
push 0x41b3f0
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x210]
push eax
call fcn.0040924e
add esp, 0x18
pop esi
cmp dword [ebp - 0x210], ebx
je 0x405695
push dword [ebp - 0x210]
xor ebx, ebx
inc ebx
push ebx
push 0x200
push edi
call fcn.004097de
push dword [ebp - 0x210]
call fcn.00409868
add esp, 0x14
mov ecx, dword [ebp - 4]
mov eax, ebx
xor ecx, ebp
pop ebx
call fcn.00408f0f
leave
ret
Function at 0x4056a4
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x41f044]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
xor eax, eax
push 0x206
xor ebx, ebx
mov word [ebp - 0x20c], ax
lea eax, [ebp - 0x20a]
push ebx
push eax
call fcn.0040cf40
add esp, 0xc
mov dword [ebp - 0x210], ebx
cmp edi, ebx
je 0x40574d
push esi
lea eax, [ebp - 0x20c]
push eax
mov esi, 0x104
push esi
call dword [0x419090]
push str.golfinfo.ini
lea eax, [ebp - 0x20c]
push esi
push eax
call fcn.00408f1e
push 0x41b3f0
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x210]
push eax
call fcn.0040924e
add esp, 0x18
pop esi
cmp dword [ebp - 0x210], ebx
je 0x40574d
push dword [ebp - 0x210]
inc ebx
push ebx
push 0x200
push edi
call fcn.004097de
push dword [ebp - 0x210]
call fcn.00409868
add esp, 0x14
mov ecx, dword [ebp - 4]
mov eax, ebx
xor ecx, ebp
pop ebx
call fcn.00408f0f
leave
ret

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

Disassembly:
push edi
mov edi, edx
test ecx, ecx
jne 0x407259
xor eax, eax
pop edi
ret
push esi
not eax
mov edx, 0xff
cmp edi, 8
jb 0x40730d
mov esi, edi
shr esi, 3
push ebx
movzx ebx, byte [ecx]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41cf98]
movzx ebx, byte [ecx + 1]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41cf98]
movzx ebx, byte [ecx + 2]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41cf98]
movzx ebx, byte [ecx + 3]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41cf98]
movzx ebx, byte [ecx + 4]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41cf98]
movzx ebx, byte [ecx + 5]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41cf98]
movzx ebx, byte [ecx + 6]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41cf98]
movzx ebx, byte [ecx + 7]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41cf98]
add ecx, 8
sub edi, 8
dec esi
jne 0x407270
pop ebx
test edi, edi
je 0x407326
movzx esi, byte [ecx]
xor esi, eax
and esi, edx
shr eax, 8
xor eax, dword [esi*4 + 0x41cf98]
inc ecx
dec edi
jne 0x407311
pop esi
not eax
pop edi
ret

Function at 0x40732b
Capabilities:
Generate random numbers using the delphi lcg
Hash data with crc32

Disassembly:
mov eax, dword [ecx]
movsx edx, dl
xor edx, eax
push esi
mov esi, 0xff
and edx, esi
mov edx, dword [edx*4 + 0x41cf98]
shr eax, 8
xor edx, eax
mov eax, dword [ecx + 8]
mov dword [ecx], edx
movzx edx, dl
add edx, dword [ecx + 4]
imul edx, edx, 0x8088405
inc edx
mov dword [ecx + 4], edx
shr edx, 0x18
xor edx, eax
and edx, esi
shr eax, 8
xor eax, dword [edx*4 + 0x41cf98]
pop esi
mov dword [ecx + 8], eax
ret