joyce8/EMBER2024-capa huggingface dataset:
Function at 0x44bdd0
Capabilities:
Hash data using fnv

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
push ebx
mov ebx, ecx
mov ecx, dword [ebx + 8]
test ecx, ecx
je 0x44be78
mov eax, dword [ebx + 0x1c]
shr eax, 3
push esi
cmp eax, ecx
jbe 0x44bf20
mov eax, dword [ebx + 4]
mov dword [ebp - 4], eax
mov edx, dword [eax]
mov dword [ebp - 0x14], edx
cmp edx, eax
je 0x44be77
mov eax, dword [edx + 4]
mov esi, edx
mov dword [ebp - 8], eax
movzx eax, byte [edx + 8]
xor eax, 0x811c9dc5
imul ecx, eax, 0x1000193
movzx eax, byte [edx + 9]
push edi
mov edi, dword [ebx + 0xc]
mov dword [ebp - 0x1c], edi
xor ecx, eax
mov eax, dword [ebx + 0x18]
imul ecx, ecx, 0x1000193
and eax, ecx
mov ecx, dword [edi + eax*8]
mov dword [ebp - 0x10], ecx
lea eax, [edi + eax*8]
mov dword [ebp - 0xc], eax
mov eax, dword [eax + 4]
mov dword [ebp - 0x18], eax
mov eax, esi
mov edi, esi
mov esi, dword [esi]
push 0xc
push eax
call fcn.0046428d
dec dword [ebx + 8]
add esp, 8
cmp edi, dword [ebp - 0x18]
je 0x44be7d
cmp esi, dword [ebp - 4]
jne 0x44be43
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp - 0x14]
jne 0x44be6e
mov ecx, dword [ebp - 0xc]
mov dword [ecx], esi
mov eax, dword [ebp - 8]
pop edi
mov dword [eax], esi
mov dword [esi + 4], eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x10]
mov edx, dword [ebp - 4]
mov ecx, dword [ebp - 0xc]
cmp eax, dword [ebp - 0x14]
jne 0x44be91
mov dword [ecx], edx
mov eax, edx
jmp 0x44be94
mov eax, dword [ebp - 8]
mov dword [ecx + 4], eax
cmp esi, edx
je 0x44be6e
nop dword [eax + eax]
movzx eax, byte [esi + 8]
xor eax, 0x811c9dc5
imul ecx, eax, 0x1000193
movzx eax, byte [esi + 9]
xor ecx, eax
mov eax, dword [ebx + 0x18]
imul ecx, ecx, 0x1000193
and eax, ecx
mov ecx, dword [ebp - 0x1c]
lea eax, [ecx + eax*8]
mov dword [ebp - 0x14], eax
mov eax, dword [eax + 4]
mov dword [ebp - 0x18], eax
nop
mov eax, esi
mov edi, esi
mov esi, dword [esi]
push 0xc
push eax
call fcn.0046428d
dec dword [ebx + 8]
add esp, 8
cmp edi, dword [ebp - 0x18]
je 0x44bf02
cmp esi, dword [ebp - 4]
jne 0x44bed0
mov eax, dword [ebp - 0x14]
pop edi
mov dword [eax], esi
mov eax, dword [ebp - 8]
mov dword [eax], esi
mov dword [esi + 4], eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x14]
mov edx, dword [ebp - 4]
mov dword [eax], edx
mov dword [eax + 4], edx
cmp esi, edx
jne 0x44bea0
mov eax, dword [ebp - 8]
pop edi
mov dword [eax], esi
mov dword [esi + 4], eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebx + 4]
mov eax, dword [ecx + 4]
mov dword [eax], 0
mov eax, dword [ecx]
test eax, eax
je 0x44bf45
mov esi, dword [eax]
push 0xc
push eax
call fcn.0046428d
add esp, 8
mov eax, esi
test esi, esi
jne 0x44bf32
mov eax, dword [ebx + 4]
mov dword [eax], eax
mov eax, dword [ebx + 4]
mov dword [eax + 4], eax
mov dword [ebx + 8], 0
mov eax, dword [ebx + 4]
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x1c]
push eax
push dword [ebx + 0x10]
push dword [ebx + 0xc]
call fcn.00415da0
add esp, 0xc
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x44c373
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
push ecx
push 2
lea eax, [ebp - 4]
push eax
push 0x20000001
push str._x_sys_default_locale
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoEx]
xor ecx, ecx
test eax, eax
jne 0x44c39a
mov eax, ecx
mov dword [ebp - 4], eax
jmp 0x44c39d
mov eax, dword [ebp - 4]
push esi
mov esi, dword [ebp + 0xc]
push ecx
push ecx
push esi
push eax
push dword [ebp + 8]
push ecx
push 0x1300
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push eax
push dword [esi]
call fcn.0044c34f
pop esi
leave
ret 8

Function at 0x44fca9
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push dword [ebp + 0x1c]
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateThread]
pop ebp
ret

Function at 0x455ef3
Capabilities:
Encode data using xor
Hash data using fnv

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
mov edx, 0x811c9dc5
xor ecx, ecx
movzx eax, byte [esi + ecx]
xor eax, edx
imul edx, eax, 0x1000193
inc ecx
cmp ecx, 4
jb 0x455f01
mov eax, edx
xor edx, edx
div dword [ebp + 0xc]
pop esi
mov eax, edx
pop ebp
ret

Function at 0x45bf97
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x48b8c0
mov eax, dword fs:[0]
push eax
push ebx
push esi
push edi
mov eax, dword [0x4af280]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
xor eax, eax
mov ebx, str.advapi32.dll
push 0x800
push eax
push ebx
mov dword [esi], eax
mov dword [esi + 4], eax
mov dword [esi + 8], eax
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], eax
mov dword [esi + 0x14], eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
test edi, edi
jne 0x45c009
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x57
jne 0x45c091
push ebx
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov edi, eax
test edi, edi
je 0x45c091
push str.RegisterTraceGuidsW
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call fcn.00450019
mov dword [esp], str.UnregisterTraceGuids
push edi
mov dword [esi], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call fcn.00450019
mov dword [esp], str.TraceEvent
push edi
mov dword [esi + 4], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call fcn.00450019
mov dword [esp], str.GetTraceLoggerHandle
push edi
mov dword [esi + 8], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call fcn.00450019
mov dword [esp], str.GetTraceEnableLevel
push edi
mov dword [esi + 0xc], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call fcn.00450019
mov dword [esp], str.GetTraceEnableFlags
push edi
mov dword [esi + 0x10], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call fcn.00450019
pop ecx
mov dword [esi + 0x14], eax
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
leave
ret
Function at 0x465751
Capabilities:
Parse pe header

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

Function at 0x46efe9
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.004646c0
mov eax, dword [0x4af280]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push ebx
push dword [ebp + 8]
mov dword [ebp - 0x100c], eax
call fcn.0047ab91
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x46f02b
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x46f187
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.00464900
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1018], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x4b5238]
push dword [edi + eax + 0x24]
push dword [edi + eax + 0x20]
push ebx
call fcn.0047bcbf
mov ecx, dword [esi*4 + 0x4b5238]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [edi + ecx + 0x20]
jne 0x46f180
cmp eax, dword [edi + ecx + 0x24]
jne 0x46f180
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [edi + ecx + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x46f180
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.0047bcbf
add esp, 0x14
test edx, edx
jl 0x46f180
jg 0x46f0f6
test eax, eax
jb 0x46f180
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x46f180
jl 0x46f110
cmp dword [ebp - 0x1008], eax
ja 0x46f180
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x46f12e
test ebx, ebx
je 0x46f167
cmp ecx, edi
jae 0x46f167
mov al, byte [ecx]
cmp al, 0xd
jne 0x46f148
lea eax, [edi - 1]
cmp ecx, eax
jae 0x46f154
cmp byte [ecx + 1], 0xa
jne 0x46f154
inc ecx
jmp 0x46f154
movzx eax, al
movsx eax, byte [eax + 0x4af530]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x46f12e
cmp edx, ebx
jne 0x46f12e
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x46f185
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.0046429b
leave
ret
Function at 0x47adfc
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x4b5238]
mov dword [ebp - 0x10], ecx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x47ae3c
cmp byte [ebx], 0xa
jne 0x47ae3c
or byte [eax + edi + 0x28], 4
jmp 0x47ae41
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x47af3f
mov al, byte [edx]
cmp al, 0x1a
je 0x47af21
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x47ae70
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x47ae95
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x47ae9f
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add edx, eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov ecx, dword [ebp - 0xc]
inc esi
cmp edx, ecx
jb 0x47ae52
jmp 0x47af3f
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x47af1c
cmp dword [ebp - 0xc], 0
je 0x47af1c
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x4b5238]
test byte [eax + edi + 0x28], 0x48
je 0x47aef6
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x47aee1
mov byte [esi], dl
jmp 0x47aef2
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x4b5238]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x47af3f
cmp byte [ebp - 1], 0xa
jne 0x47af05
cmp esi, ebx
jne 0x47af05
mov byte [esi], 0xa
jmp 0x47af3e
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.0047bcdd
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x47af3f
mov byte [esi], 0xd
jmp 0x47af3e
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x4b5238]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x47af3b
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x47af3f
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x47af48
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [ebp + 0xc]
mov ebx, eax
and eax, 0x3f
sar ebx, 6
push edi
imul edi, eax, 0x38
push 0xa
mov eax, dword [ebx*4 + 0x4b5238]
pop edx
mov dword [ebp - 0x14], edx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x18], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x47af8b
cmp word [esi], dx
jne 0x47af8b
or byte [edi + eax + 0x28], 4
jmp 0x47af90
and byte [edi + eax + 0x28], 0xfb
lea edx, [esi + ecx*2]
mov eax, esi
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
cmp eax, edx
jae 0x47b0c9
mov dword [ebp - 0xc], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x10], edx
push 0x1a
pop edx
cmp cx, dx
mov edx, dword [ebp - 8]
je 0x47b0a9
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x47afd2
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x47b008
cmp eax, edx
jae 0x47b014
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x14]
mov edx, eax
push 0xa
sete cl
xor eax, eax
lea ecx, [ecx*2 + 2]
add dword [ebp - 4], ecx
pop ecx
cmp dx, cx
mov edx, dword [ebp - 8]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
add esi, 2
cmp eax, edx
jb 0x47afaa
jmp 0x47b0c9
push 0
lea eax, [ebp - 0x14]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x47b0a5
cmp dword [ebp - 0x14], 0
je 0x47b0a5
mov eax, dword [ebx*4 + 0x4b5238]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x47b07d
mov cx, word [ebp - 4]
pop eax
cmp cx, ax
je 0x47b0c3
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x4b5238]
push 0xa
mov byte [edi + eax + 0x2a], cl
mov eax, dword [ebx*4 + 0x4b5238]
shr cx, 8
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x4b5238]
pop ecx
mov byte [edi + eax + 0x2c], cl
jmp 0x47b0c6
pop ebx
cmp word [ebp - 4], bx
jne 0x47b08e
cmp esi, dword [ebp + 0xc]
jne 0x47b08e
mov word [esi], bx
jmp 0x47b0c6
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.0047bcdd
add esp, 0x10
cmp word [ebp - 4], bx
je 0x47b0c9
push 0xd
jmp 0x47b0c2
mov ecx, dword [ebx*4 + 0x4b5238]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x47b0c0
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x47b0c9
push 0x1a
pop eax
mov word [esi], ax
add esi, 2
sub esi, dword [ebp + 0xc]
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x47bac0
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0047b75b

Function at 0x47bacb
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0047b8ea

Function at 0x47d8da
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x49be24
push 0x49be1c
push str.FlsAlloc
push 0x1e
call fcn.0047d764
mov esi, eax
add esp, 0x10
test esi, esi
je 0x47d90e
push dword [ebp + 8]
mov ecx, esi
call dword [0x492388]
call esi
jmp 0x47d914
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x47d958
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x49be34
push 0x49be2c
push str.FlsGetValue
push 0x20
call fcn.0047d764
mov esi, eax
add esp, 0x10
test esi, esi
je 0x47d98f
push dword [ebp + 8]
mov ecx, esi
call dword [0x492388]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x481c33
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 0x481cd0
push ebx
push esi
call fcn.00481bfc
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.0047ff79
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x481c7d
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x481ccf
push edi
push eax
call fcn.0047bf2d
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x481c9d
call fcn.0047ab57
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x481cce
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.0047ff79
add esp, 0x20
test eax, eax
jne 0x481cbc
push edi
call fcn.0047ab57
jmp 0x481cc4
push ebx
call fcn.0047ab57
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 0x488425
Capabilities:
Clear file content

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push esi
push edi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.004883a1
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x48859d
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x48859d
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x48854c
jg 0x48847e
test eax, eax
je 0x488542
push 1
push 0x1000
call fcn.0047d466
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x4884a4
mov eax, dword [ebp + 0x14]
push 0xc
pop edi
mov byte [eax + 0x1c], 1
mov dword [eax + 0x18], edi
jmp 0x488539
push 0x8000
push ebx
call fcn.004780c1
mov edi, dword [ebp + 0x14]
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x4884d0
jg 0x4884cb
cmp ecx, 0x1000
jb 0x4884d0
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.0047e750
add esp, 0x10
cmp eax, 0xffffffff
je 0x488515
mov ecx, dword [ebp - 4]
cdq
sub ecx, eax
mov eax, dword [ebp - 8]
mov dword [ebp - 4], ecx
sbb eax, edx
mov dword [ebp - 8], eax
test eax, eax
jg 0x4884cb
jl 0x4884fc
test ecx, ecx
jne 0x4884bd
push dword [ebp - 0xc]
push ebx
call fcn.004780c1
push esi
call fcn.0047ab57
add esp, 0xc
xor edi, edi
jmp 0x4885ae
cmp byte [edi + 0x24], 0
je 0x48852c
cmp dword [edi + 0x20], 5
jne 0x48852c
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x488537
mov edi, dword [edi + 0x18]
jmp 0x488539
xor edi, edi
push esi
call fcn.0047ab57
pop ecx
jmp 0x4885ae
test ecx, ecx
jg 0x48850e
jl 0x48854c
test eax, eax
jae 0x48850e
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.0047bcdd
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x48856f
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x48850e
jmp 0x4885a6
push ebx
call fcn.00482241
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x48850e
mov esi, dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [esi + 0x24], 1
mov dword [esi + 0x20], eax
pop edi
mov byte [esi + 0x1c], 1
mov dword [esi + 0x18], edi
jmp 0x4885ae
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x4885ab
mov edi, dword [edi + 0x18]
jmp 0x4885ae
push 0x16
pop edi
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.0047bcdd
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret

Function at 0x4897b0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x4897dd
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4897dd
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x406a06
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x23c
push esi
mov esi, 0x104
lea eax, [ebp - 0x23c]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, esi
pop esi
jbe 0x406a2a
xor eax, eax
test eax, eax
je 0x406a3d
cmp word [ebp + eax*2 - 0x23e], 0x5c
je 0x406a3d
xor ecx, ecx
jmp 0x406a40
xor ecx, ecx
inc ecx
push dword [ebp + 8]
lea ecx, [ecx*2 + 0x40a014]
lea eax, [ebp + eax*2 - 0x23c]
push ecx
push str._s_S.dll
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea eax, [ebp - 0x23c]
push 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
leave
ret 4

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

Disassembly:
cmp dword [0x4275ec], 0
push esi
jne 0x406b9a
xor ecx, ecx
push 8
mov eax, ecx
pop esi
mov edx, eax
and dl, 1
neg dl
sbb edx, edx
and edx, 0xedb88320
shr eax, 1
xor eax, edx
dec esi
jne 0x406b74
mov dword [ecx*4 + 0x4275e8], eax
inc ecx
cmp ecx, 0x100
jl 0x406b6f
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
test edx, edx
not eax
jbe 0x406bcb
mov ecx, dword [esp + 0xc]
push edi
movzx edi, byte [ecx]
mov esi, eax
and esi, 0xff
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x4275e8]
xor eax, esi
inc ecx
dec edx
jne 0x406bad
pop edi
not eax
pop esi
ret 0xc

Function at 0x1000125c
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
mov dword [ebp - 0xc], 0
call sub.KERNEL32.DLL_GetEnvironmentStringsA
mov ebx, eax
mov dword [ebp - 0x10], ebx
jmp 0x10001299
cmp byte [ebx], 0x3d
je 0x10001285
inc dword [ebp - 0xc]
mov edi, ebx
xor eax, eax
stc
sbb ecx, ecx
repne scasb al, byte es:[edi]
neg ecx
lea eax, [ecx - 2]
mov edi, eax
inc edi
lea ebx, [ebx + edi]
cmp byte [ebx], 0
jne 0x10001278
mov edi, dword [ebp - 0xc]
inc edi
lea edi, [edi*4]
mov dword [ebp - 0x14], edi
push dword [ebp - 0x14]
call sub.CRTDLL.DLL_malloc
pop ecx
mov dword [ebp - 8], eax
mov dword [0x10003010], eax
cmp dword [ebp - 8], 0
jne 0x100012cc
xor eax, eax
jmp 0x10001342
mov ebx, dword [ebp - 0x10]
jmp 0x10001325
mov edi, ebx
xor eax, eax
stc
sbb ecx, ecx
repne scasb al, byte es:[edi]
neg ecx
lea eax, [ecx - 2]
mov edi, eax
inc edi
mov dword [ebp - 4], edi
cmp byte [ebx], 0x3d
je 0x1000131f
push dword [ebp - 4]
call sub.CRTDLL.DLL_malloc
pop ecx
mov esi, dword [ebp - 8]
mov dword [esi], eax
or eax, eax
jne 0x10001308
jmp 0x10001342
push ebx
mov edi, dword [ebp - 8]
push dword [edi]
call sub.CRTDLL.DLL_strcpy
add esp, 8
add dword [ebp - 8], 4
mov edx, dword [ebp - 4]
lea ebx, [ebx + edx]
cmp byte [ebx], 0
jne 0x100012d1
mov edx, dword [ebp - 8]
mov dword [edx], 0
mov eax, 1
pop edi
pop esi
pop ebx
leave
ret
Function at 0x402928
Capabilities:
Get common file path
Set current directory

Disassembly:
push ebx
push esi
add esp, 0xfffffdf0
mov esi, edx
mov ebx, eax
test bl, bl
je 0x402965
xor eax, eax
mov al, bl
add eax, 0x41
dec eax
mov byte [esp], al
mov byte [esp + 1], 0x3a
mov byte [esp + 2], 0
lea eax, [esp + 0x109]
push eax
push 0x105
call sub.kernel32.dll_GetCurrentDirectoryA
push esp
call sub.kernel32.dll_SetCurrentDirectoryA
lea eax, [esp + 4]
push eax
push 0x105
call sub.kernel32.dll_GetCurrentDirectoryA
test bl, bl
je 0x402985
lea eax, [esp + 0x109]
push eax
call sub.kernel32.dll_SetCurrentDirectoryA
mov eax, esi
lea edx, [esp + 4]
mov ecx, 0x105
call fcn.004047a4
add esp, 0x210
pop esi
pop ebx
ret

Function at 0x402aec
Capabilities:
Accept command line arguments

Disassembly:
push ebx
push esi
push edi
add esp, 0xfffffef8
mov ebx, edx
mov esi, eax
mov eax, ebx
call fcn.0040453c
test esi, esi
jne 0x402b22
push 0x105
lea eax, [esp + 4]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameA
mov ecx, eax
mov edx, esp
mov eax, ebx
call fcn.0040462c
jmp 0x402b40
call sub.kernel32.dll_GetCommandLineA
mov edi, eax
mov edx, ebx
mov eax, edi
call fcn.00402a00
mov edi, eax
test esi, esi
je 0x402b40
cmp dword [ebx], 0
je 0x402b40
dec esi
jmp 0x402b29
add esp, 0x108
pop edi
pop esi
pop ebx
ret

Function at 0x403068
Capabilities:
Generate random numbers using the delphi lcg

Disassembly:
push ebx
xor ebx, ebx
imul edx, dword [ebx + 0x47c008], 0x8088405
inc edx
mov dword [ebx + 0x47c008], edx
mul edx
mov eax, edx
pop ebx
ret

Function at 0x4035d4
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
movzx eax, word [0x47c010]
mov dword [ebp - 8], eax
lea eax, [ebp - 4]
push eax
push 1
push 0
push 0x40366c
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExA
test eax, eax
jne 0x40364c
xor eax, eax
push ebp
push 0x403645
push dword fs:[eax]
mov dword fs:[eax], esp
mov dword [ebp - 0xc], 4
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 8]
push eax
push 0
push 0
push 0x403688
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegQueryValueExA
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40364c
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegCloseKey
ret
mov ax, word [0x47c010]
and ax, 0xffc0
mov dx, word [ebp - 8]
and dx, 0x3f
or ax, dx
mov word [0x47c010], ax
mov esp, ebp
pop ebp
ret

Function at 0x40433c
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x47f048], 0
je 0x40439d
cmp word [0x47f21c], 0xd7b2
jne 0x404365
cmp dword [0x47f224], 0
jbe 0x404365
mov eax, 0x47f218
call dword [0x47f234]
push 0
lea eax, [esp + 4]
push eax
push 0x1e
push 0x47c058
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
push 0
lea eax, [esp + 4]
push eax
push 2
push 0x4043c4
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
pop edx
ret
cmp byte [0x47c020], 0
jne 0x4043b9
push 0
push 0x47c078
push 0x47c058
push 0
call sub.user32.dll_MessageBoxA
pop edx
ret