joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4015fe
Capabilities:
Encode data using xor

Disassembly:
mov edx, dword [esp + 4]
push esi
mov esi, dword [esp + 0x10]
push edi
mov edi, dword [esp + 0x10]
test esi, esi
je 0x401628
movzx ecx, byte [edi]
movzx eax, dl
xor ecx, eax
shr edx, 8
xor edx, dword [ecx*4 + 0x434f00]
inc edi
sub esi, 1
jne 0x401610
pop edi
mov eax, edx
pop esi
ret 0xc

Function at 0x401ee0
Capabilities:
Check if file exists

Disassembly:
mov eax, 0x1050
call fcn.00415690
push ebx
mov ebx, dword [esp + 0x105c]
push ebp
push edi
mov edi, ecx
and dword [edi + 0x1034], 0
cmp byte [edi + 0x30], 0
jne 0x401f0c
test bl, 4
jne 0x401f0c
xor al, al
jmp 0x401f0e
mov al, 1
push esi
mov esi, ebx
shr esi, 1
not esi
and esi, 1
inc esi
shl esi, 0x1e
test bl, 1
je 0x401f27
or esi, 0x40000000
shr ebx, 3
not ebx
and ebx, 1
test al, al
je 0x401f36
or ebx, 2
lea ecx, [esp + 0x18]
call fcn.00401b85
cmp byte [edi + 0x24], 0
je 0x401f4b
or esi, 0x100
push 0
push 0x8000000
push 3
push 0
push ebx
push esi
push dword [esp + 0x107c]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebp, eax
cmp ebp, 0xffffffff
jne 0x401fbb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp + 0x10], eax
lea eax, [esp + 0x18]
push 0x800
push eax
push dword [esp + 0x106c]
call fcn.004035e5
test al, al
je 0x401fc8
push 0
push 0x8000000
push 3
push 0
push ebx
push esi
lea eax, [esp + 0x30]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebp, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
jne 0x401fc3
mov dword [esp + 0x10], eax
jmp 0x401fc3
mov eax, dword [esp + 0x10]
mov dword [esp + 0x10], eax
cmp ebp, 0xffffffff
jne 0x401fd9
cmp dword [esp + 0x10], 2
jne 0x401fd9
mov dword [edi + 0x1034], 1
cmp byte [edi + 0x24], 0
pop esi
je 0x401fff
cmp ebp, 0xffffffff
je 0x401fff
or dword [esp + 0xc], 0xffffffff
lea eax, [esp + 0xc]
or dword [esp + 0x10], 0xffffffff
push 0
push eax
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_SetFileTime]
xor eax, eax
cmp ebp, 0xffffffff
mov byte [edi + 0x1c], al
mov dword [edi + 0x10], eax
setne bl
mov byte [edi + 0x15], al
je 0x40202e
push 0x800
push dword [esp + 0x1064]
lea ecx, [edi + 0x32]
mov dword [edi + 8], ebp
push ecx
call fcn.0040695c
mov byte [edi + 0x25], 0
pop edi
pop ebp
mov al, bl
pop ebx
add esp, 0x1050
ret 8
Function at 0x40251a
Capabilities:
Write file on windows

Disassembly:
push ecx
push ecx
push ebp
push esi
mov esi, dword [esp + 0x18]
mov ebp, ecx
test esi, esi
jne 0x40252f
mov al, 1
jmp 0x40264a
cmp dword [ebp + 0x10], 1
lea ecx, [ebp + 8]
mov dword [esp + 0xc], ecx
jne 0x40254b
push 0xfffffffffffffff5
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
lea ecx, [ebp + 8]
mov dword [ecx], eax
jmp 0x40254f
mov dword [esp + 0xc], ecx
push ebx
push edi
and dword [esp + 0x10], 0
xor bl, bl
cmp dword [ebp + 0x10], 0
je 0x4025a3
xor edi, edi
test esi, esi
je 0x4025c4
mov eax, esi
sub eax, edi
cmp eax, 0x4000
jb 0x402574
mov eax, 0x4000
push 0
lea edx, [esp + 0x14]
push edx
push eax
mov eax, dword [esp + 0x28]
add eax, edi
push eax
push dword [ecx]
call dword [sym.imp.KERNEL32.dll_WriteFile]
cmp eax, 1
sete bl
jne 0x4025c0
mov ecx, dword [esp + 0x14]
add edi, 0x4000
cmp edi, esi
jb 0x402564
jmp 0x4025c0
push 0
lea eax, [esp + 0x14]
push eax
push esi
push dword [esp + 0x28]
push dword [ecx]
call dword [sym.imp.KERNEL32.dll_WriteFile]
lea ebx, [eax - 1]
neg ebx
sbb bl, bl
inc bl
test bl, bl
jne 0x402642
cmp byte [ebp + 0x1e], 0
je 0x402642
cmp dword [ebp + 0x10], 0
jne 0x402642
push 0
lea edi, [ebp + 0x32]
mov ecx, 0x45ad9c
push edi
call fcn.004017d2
test al, al
je 0x402635
mov ecx, dword [esp + 0x14]
cmp dword [esp + 0x10], esi
jae 0x402551
cmp dword [esp + 0x10], 0
jbe 0x402551
mov edi, dword [ebp]
push 0
mov esi, dword [edi + 0x14]
mov ecx, esi
call dword [0x42922c]
mov ecx, ebp
call esi
sub eax, dword [esp + 0x14]
mov ecx, dword [edi + 0x10]
sbb edx, 0
push edx
push eax
call dword [0x42922c]
mov ecx, ebp
call dword [edi + 0x10]
mov esi, dword [esp + 0x20]
mov ecx, dword [esp + 0x14]
jmp 0x402551
push edi
push 0
mov ecx, 0x45ad9c
call fcn.00401ac9
pop edi
mov al, bl
mov byte [ebp + 0xc], 1
pop ebx
pop esi
pop ebp
pop ecx
pop ecx
ret 8

Function at 0x402792
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1000
call fcn.00415690
push esi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4027d7
push 0x800
lea eax, [ebp - 0x1000]
push eax
push dword [ebp + 8]
call fcn.004035e5
test al, al
je 0x4027d7
lea eax, [ebp - 0x1000]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov esi, eax
mov eax, esi
pop esi
leave
ret 4
Function at 0x402810
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1000
call fcn.00415690
push esi
mov esi, dword [ebp + 8]
push esi
call fcn.004038fd
movzx eax, word [eax]
cmp eax, 0x2e
je 0x402841
cmp eax, 0x20
je 0x402841
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x402874
push esi
call fcn.00402780
test al, al
jne 0x402887
push 0x800
lea eax, [ebp - 0x1000]
push eax
push esi
call fcn.004035e5
test al, al
je 0x402887
push 0
lea eax, [ebp - 0x1000]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x402887
cmp byte [ebp + 0xc], 0
je 0x402883
push dword [ebp + 0x10]
push esi
call fcn.00402a4b
xor eax, eax
jmp 0x40289f
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
push 2
pop eax
cmp ecx, eax
je 0x40289f
xor eax, eax
cmp ecx, 3
sete al
inc eax
pop esi
leave
ret 0xc

Function at 0x402a4b
Capabilities:
Set file attributes

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1000
call fcn.00415690
push ebx
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
setne bl
test eax, eax
jne 0x402a9b
push 0x800
lea eax, [ebp - 0x1000]
push eax
push dword [ebp + 8]
call fcn.004035e5
test al, al
je 0x402a9b
push dword [ebp + 0xc]
lea eax, [ebp - 0x1000]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
setne bl
mov al, bl
pop ebx
leave
ret 8
Function at 0x402c15
Capabilities:
Check if file exists
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1250
call fcn.00415690
push ebx
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x250]
push edi
or edi, 0xffffffff
mov ebx, 0x800
push eax
cmp esi, edi
jne 0x402ca1
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, eax
cmp esi, edi
jne 0x402cbc
push ebx
lea eax, [ebp - 0x1250]
push eax
push dword [ebp + 0xc]
call fcn.004035e5
test al, al
je 0x402c78
lea eax, [ebp - 0x250]
push eax
lea eax, [ebp - 0x1250]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, eax
cmp esi, edi
jne 0x402cbc
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x402c91
cmp eax, 3
je 0x402c91
cmp eax, 0x12
je 0x402c91
mov al, 1
jmp 0x402c93
xor al, al
mov edi, dword [ebp + 0x10]
mov byte [edi + 0x1044], al
jmp 0x402d7e
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x402cbc
mov esi, edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
setne al
jmp 0x402c93
mov edi, dword [ebp + 0x10]
push ebx
push dword [ebp + 0xc]
push edi
call fcn.0040695c
push ebx
lea eax, [ebp - 0x224]
push eax
push edi
call fcn.004039d4
mov ecx, dword [ebp - 0x234]
xor eax, eax
add eax, dword [ebp - 0x230]
mov dword [edi + 0x1000], eax
mov eax, dword [ebp - 0x250]
adc ecx, 0
mov dword [edi + 0x1008], eax
mov eax, dword [ebp - 0x24c]
mov dword [edi + 0x1004], ecx
mov ecx, dword [ebp - 0x248]
mov dword [edi + 0x1028], eax
mov eax, dword [ebp - 0x244]
mov dword [edi + 0x102c], ecx
mov ecx, dword [ebp - 0x240]
mov dword [edi + 0x1030], eax
mov eax, dword [ebp - 0x23c]
mov dword [edi + 0x1034], ecx
mov ecx, dword [ebp - 0x238]
mov dword [edi + 0x1038], eax
lea eax, [ebp - 0x23c]
mov dword [edi + 0x103c], ecx
lea ecx, [edi + 0x1010]
push eax
call fcn.004073ad
lea eax, [ebp - 0x24c]
push eax
lea ecx, [edi + 0x1018]
call fcn.004073ad
lea eax, [ebp - 0x244]
push eax
lea ecx, [edi + 0x1020]
call fcn.004073ad
and dword [edi + 0x1040], 0
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x4035e5
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1000
call fcn.00415690
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
cmp word [esi], 0
je 0x403766
push esi
call fcn.0040376f
push esi
call fcn.0041a203
pop ecx
push esi
mov edi, eax
call fcn.0040379a
test al, al
je 0x40369a
push esi
call fcn.0040376f
test al, al
je 0x403654
lea eax, [edi + 4]
cmp dword [ebp + 0x10], eax
jbe 0x403766
push dword [ebp + 0x10]
push 0x4295e8
push dword [ebp + 0xc]
call fcn.0040695c
push dword [ebp + 0x10]
push esi
push dword [ebp + 0xc]
call fcn.00406934
mov al, 1
jmp 0x403768
push 0x5c
pop eax
cmp word [esi], ax
jne 0x403766
lea ebx, [esi + 2]
cmp word [ebx], ax
jne 0x403766
mov esi, dword [ebp + 0x10]
lea eax, [edi + 6]
cmp esi, eax
jbe 0x403766
push esi
push 0x4295e8
push dword [ebp + 0xc]
call fcn.0040695c
push esi
push 0x4295f4
push dword [ebp + 0xc]
call fcn.00406934
push esi
push ebx
jmp 0x403645
lea eax, [ebp - 0x1000]
mov ebx, 0x7ff
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
test eax, eax
je 0x403766
cmp eax, ebx
ja 0x403766
movzx eax, word [esi]
push eax
call fcn.004037cf
test al, al
je 0x403705
lea eax, [edi + 6]
mov edi, dword [ebp + 0x10]
cmp edi, eax
jbe 0x403766
push edi
push 0x4295e8
push dword [ebp + 0xc]
call fcn.0040695c
xor eax, eax
mov word [ebp - 0xffc], ax
lea eax, [ebp - 0x1000]
push edi
push eax
push dword [ebp + 0xc]
call fcn.00406934
push edi
jmp 0x403644
push 0x800
lea eax, [ebp - 0x1000]
push eax
call fcn.004031e2
lea eax, [ebp - 0x1000]
push eax
call fcn.0041a203
add edi, 4
add eax, edi
mov edi, dword [ebp + 0x10]
pop ecx
cmp edi, eax
jbe 0x403766
push edi
push 0x4295e8
push dword [ebp + 0xc]
call fcn.0040695c
push edi
lea eax, [ebp - 0x1000]
push eax
push dword [ebp + 0xc]
call fcn.00406934
cmp word [esi], 0x2e
jne 0x4036ff
movzx eax, word [esi + 2]
push eax
call fcn.004037cf
test al, al
je 0x4036ff
add esi, 4
jmp 0x4036ff
xor al, al
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x40537a
Capabilities:
Encrypt data using aes via x86 extensions

Disassembly:
push ecx
cmp dword [esp + 0xc], 0
movups xmm1, xmmword [ecx + 8]
push esi
mov esi, dword [esp + 0xc]
push edi
lea edi, [ecx + 0x18]
jbe 0x4053f5
mov edx, dword [esp + 0x18]
mov eax, esi
add esi, 0x10
cmp byte [ecx + 1], 0
movups xmm0, xmmword [eax]
je 0x4053a5
pxor xmm0, xmm1
movups xmm1, xmmword [edi]
mov eax, dword [ecx + 4]
pxor xmm1, xmm0
cmp eax, 1
jle 0x4053d7
lea edx, [edi + 0x10]
lea edi, [eax - 1]
mov dword [esp + 8], edi
lea edi, [ecx + 0x18]
sub dword [esp + 8], 1
movups xmm0, xmmword [edx]
lea edx, [edx + 0x10]
aesenc xmm1, xmm0
jne 0x4053c1
mov edx, dword [esp + 0x18]
add eax, eax
movups xmm0, xmmword [edi + eax*8]
mov eax, edx
add edx, 0x10
sub dword [esp + 0x14], 1
aesenclast xmm1, xmm0
mov dword [esp + 0x18], edx
movups xmmword [eax], xmm1
jne 0x405393
pop edi
movups xmmword [ecx + 8], xmm1
pop esi
pop ecx
ret 0xc

Function at 0x405429
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x20
push ebp
push edi
mov ebp, ecx
xor edi, edi
inc edi
mov dword [esp + 0x14], ebp
mov dword [esp + 8], edi
cmp dword [ebp + 4], edi
jle 0x4054d7
push ebx
lea ebx, [ebp + 0x28]
push esi
mov dword [esp + 0x14], ebx
lea eax, [ebx + 2]
xor esi, esi
mov dword [esp + 0x18], eax
lea edi, [esp + 0x20]
mov ebp, eax
push 4
add edi, esi
pop ebx
movzx eax, byte [ebp + 1]
movzx ecx, byte [ebp - 1]
mov dl, byte [esi + eax*4 + 0x43dc28]
movzx eax, byte [ebp - 2]
xor dl, byte [esi + ecx*4 + 0x43d428]
xor dl, byte [esi + eax*4 + 0x43d028]
movzx eax, byte [ebp]
lea ebp, [ebp + 4]
xor dl, byte [esi + eax*4 + 0x43d828]
mov byte [edi], dl
lea edi, [edi + 4]
sub ebx, 1
jne 0x405461
mov eax, dword [esp + 0x18]
inc esi
cmp esi, 4
jl 0x405456
mov ebx, dword [esp + 0x14]
lea eax, [esp + 0x20]
push 0x10
push eax
push ebx
call fcn.00416c90
mov edi, dword [esp + 0x1c]
add esp, 0xc
mov ebp, dword [esp + 0x1c]
inc edi
add ebx, 0x10
mov dword [esp + 0x10], edi
mov dword [esp + 0x14], ebx
cmp edi, dword [ebp + 4]
jl 0x40544d
pop esi
pop ebx
pop edi
pop ebp
add esp, 0x20
ret
Function at 0x4054dd
Capabilities:
Encode data using xor
Encrypt data using aes
Reference aes constants

Disassembly:
sub esp, 0x30
push ebx
push ebp
push esi
mov ebp, ecx
lea eax, [esp + 0x1c]
push edi
push 0x20
push dword [esp + 0x48]
mov esi, dword [ebp + 4]
sub esi, 6
mov dword [esp + 0x18], ebp
push eax
mov dword [esp + 0x24], esi
call fcn.00416c90
add esp, 0xc
xor ebx, ebx
xor edx, edx
xor edi, edi
test esi, esi
jle 0x40555d
cmp ebx, dword [ebp + 4]
jg 0x4056c1
cmp edi, esi
jge 0x40554a
lea ebp, [esp + 0x20]
lea ebp, [ebp + edi*4]
cmp edx, 4
jge 0x405546
mov esi, dword [esp + 0x10]
lea ecx, [edx + ebx*4]
mov eax, dword [ebp]
inc edi
add ebp, 4
inc edx
mov dword [esi + ecx*4 + 0x18], eax
mov esi, dword [esp + 0x18]
cmp edi, esi
jl 0x405526
mov ebp, dword [esp + 0x10]
cmp edx, 4
jne 0x405550
inc ebx
lea eax, [edx - 4]
neg eax
sbb eax, eax
and edx, eax
cmp edi, esi
jl 0x405511
cmp ebx, dword [ebp + 4]
jg 0x4056c1
mov edi, 0x434108
movzx eax, byte [esp + esi*4 + 0x1d]
mov cl, byte [esp + 0x20]
xor cl, byte [eax + str.cw]
mov byte [esp + 0x20], cl
movzx eax, byte [esp + esi*4 + 0x1e]
mov al, byte [eax + str.cw]
xor byte [esp + 0x21], al
movzx eax, byte [esp + esi*4 + 0x1f]
mov al, byte [eax + str.cw]
xor byte [esp + 0x22], al
movzx eax, byte [esp + esi*4 + 0x1c]
mov al, byte [eax + str.cw]
xor byte [esp + 0x23], al
mov al, byte [edi]
xor al, cl
inc edi
mov byte [esp + 0x20], al
mov dword [esp + 0x1c], edi
cmp esi, 8
je 0x4055ee
cmp esi, 1
jle 0x4055e2
lea eax, [esi - 1]
lea ecx, [esp + 0x24]
mov dword [esp + 0x14], eax
push 4
pop edi
mov al, byte [ecx - 4]
xor byte [ecx], al
inc ecx
sub edi, 1
jne 0x4055d0
sub dword [esp + 0x14], 1
jne 0x4055cd
xor edi, edi
test esi, esi
jle 0x4056b4
jmp 0x40566c
lea ecx, [esp + 0x24]
mov dword [esp + 0x14], 3
push 4
pop edi
mov al, byte [ecx - 4]
xor byte [ecx], al
inc ecx
sub edi, 1
jne 0x4055fd
sub dword [esp + 0x14], 1
jne 0x4055fa
movzx eax, byte [esp + 0x2c]
lea ecx, [esp + 0x34]
mov dword [esp + 0x14], 3
mov al, byte [eax + str.cw]
xor byte [esp + 0x30], al
movzx eax, byte [esp + 0x2d]
mov al, byte [eax + str.cw]
xor byte [esp + 0x31], al
movzx eax, byte [esp + 0x2e]
mov al, byte [eax + str.cw]
xor byte [esp + 0x32], al
movzx eax, byte [esp + 0x2f]
mov al, byte [eax + str.cw]
xor byte [esp + 0x33], al
push 4
pop edi
mov al, byte [ecx - 4]
xor byte [ecx], al
inc ecx
sub edi, 1
jne 0x40565a
sub dword [esp + 0x14], 1
jne 0x405657
cmp ebx, dword [ebp + 4]
jg 0x4056b7
cmp edi, esi
jge 0x4056a1
lea ebp, [esp + 0x20]
lea ebp, [ebp + edi*4]
cmp edx, 4
jge 0x40569d
mov esi, dword [esp + 0x10]
lea ecx, [edx + ebx*4]
mov eax, dword [ebp]
inc edi
add ebp, 4
inc edx
mov dword [esi + ecx*4 + 0x18], eax
mov esi, dword [esp + 0x18]
cmp edi, esi
jl 0x40567d
mov ebp, dword [esp + 0x10]
cmp edx, 4
jne 0x4056a7
inc ebx
lea eax, [edx - 4]
neg eax
sbb eax, eax
and edx, eax
cmp edi, esi
jl 0x40566c
cmp ebx, dword [ebp + 4]
mov edi, dword [esp + 0x1c]
jle 0x40556b
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x30
ret 4
Function at 0x405971
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [0x43e030]
test esi, esi
jne 0x40598f
mov ecx, 0x43e028
call fcn.004058fc
mov esi, dword [0x43e030]
mov eax, dword [ebp + 0xc]
movzx ecx, byte [ebp + 0x14]
and eax, 0xfffffff0
cmp byte [ebp + 0x10], 0
je 0x4059da
test esi, esi
je 0x4059fe
push ecx
push eax
push dword [ebp + 8]
mov ecx, esi
call dword [0x42922c]
call esi
test eax, eax
jne 0x405a22
push str.CryptProtectMemory_failed
mov esi, 0x45ad9c
push esi
call fcn.00401853
pop ecx
pop ecx
mov ecx, esi
call fcn.004019e9
push 2
mov ecx, esi
call fcn.0040184e
jmp 0x405a22
mov esi, dword [0x43e034]
test esi, esi
je 0x4059fe
push ecx
push eax
push dword [ebp + 8]
mov ecx, esi
call dword [0x42922c]
call esi
test eax, eax
jne 0x405a22
push str.CryptUnprotectMemory_failed
jmp 0x4059bb
push ebx
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
xor edx, edx
mov ebx, eax
cmp dword [ebp + 0xc], edx
jbe 0x405a21
mov esi, dword [ebp + 8]
lea eax, [ebx + 0x4b]
add al, dl
lea ecx, [edx + esi]
xor byte [ecx], al
inc edx
cmp edx, dword [ebp + 0xc]
jb 0x405a11
pop ebx
pop esi
pop ebp
ret 0x10
Function at 0x406438
Capabilities:
Hash data using sha1

Disassembly:
mov eax, dword [esp + 4]
and dword [eax + 0x18], 0
and dword [eax + 0x1c], 0
mov dword [eax], 0x67452301
mov dword [eax + 4], 0xefcdab89
mov dword [eax + 8], 0x98badcfe
mov dword [eax + 0xc], 0x10325476
mov dword [eax + 0x10], 0xc3d2e1f0
ret 4
Function at 0x40b2c5
Capabilities:
Encode data using xor

Disassembly:
cmp dword [0x44e6a0], 0
je 0x40b2d2
or eax, 0xffffffff
ret
mov eax, dword [0x43e57c]
push ebx
push ebp
xor ebp, ebp
cmp eax, ebp
jg 0x40b310
mov ecx, dword [0x43e578]
jl 0x40b2eb
cmp ecx, ebp
ja 0x40b310
or ebx, 0xffffffff
mov dword [0x44e5c0], ebp
add ecx, ebx
mov dword [0x44e5c4], ebp
mov dword [0x43e578], ecx
adc eax, ebx
mov dword [0x43e57c], eax
mov eax, ebx
jmp 0x40b41a
push esi
push edi
mov edi, dword [0x44e5c4]
or ebx, 0xffffffff
cmp edi, ebp
jg 0x40b375
jl 0x40b32b
mov esi, dword [0x44e5c0]
cmp esi, ebp
ja 0x40b37b
mov esi, 0x2000
push esi
push dword [0x44e5b4]
call fcn.0040b5f4
cdq
mov ecx, eax
mov dword [0x44e5c0], eax
or ecx, edx
mov dword [0x44e5c4], edx
je 0x40b3b7
and eax, edx
cmp eax, ebx
je 0x40b3a8
add dword [0x44e5f8], esi
mov eax, dword [0x44e5b4]
adc dword [0x44e5fc], ebp
mov dword [0x44e5b8], eax
call fcn.0040ad45
mov edi, dword [0x44e5c4]
mov esi, dword [0x44e5c0]
mov eax, dword [0x43e5a8]
test byte [eax + 0x70], 1
je 0x40b3fa
cmp byte [0x44f75d], 0
mov eax, esi
je 0x40b3c7
or eax, edi
je 0x40b3fa
push esi
push dword [0x44e5b8]
push 0x44f768
call fcn.0040eb2e
jmp 0x40b3ee
push 0x46500a
mov ecx, 0x45ad9c
call fcn.0040196a
mov dword [0x44e5c0], ebp
mov eax, ebx
mov dword [0x44e5c4], ebp
jmp 0x40b418
or eax, edi
mov ebp, dword [0x44e5b8]
je 0x40b3fa
add esi, ebx
adc edi, ebx
call fcn.0040e90f
xor byte [ebp], al
movzx eax, byte [ebp]
push eax
call fcn.0040ea20
mov eax, esi
inc ebp
or eax, edi
jne 0x40b3d1
mov esi, dword [0x44e5c0]
mov edi, dword [0x44e5c4]
mov eax, dword [0x44e5b8]
add esi, ebx
mov dword [0x44e5c0], esi
adc edi, ebx
mov dword [0x44e5c4], edi
movzx eax, byte [eax]
inc dword [0x44e5b8]
pop edi
pop esi
pop ebp
pop ebx
ret

Function at 0x40e970
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
push dword [ebp + 0xc]
call fcn.0040e92d
push 0xc
push dword [ebp + 8]
lea eax, [ebp - 0xc]
push eax
call fcn.00416c90
add esp, 0xc
xor esi, esi
call fcn.0040e90f
xor byte [ebp + esi - 0xc], al
movzx eax, byte [ebp + esi - 0xc]
push eax
call fcn.0040ea20
inc esi
cmp esi, 0xc
jl 0x40e992
mov eax, dword [0x43e5a8]
movzx edx, byte [ebp - 1]
movzx ecx, byte [0x44e617]
test byte [eax + 0x70], 2
jne 0x40e9c9
movzx ecx, byte [0x44e61f]
cmp edx, ecx
je 0x40e9d2
or eax, 0xffffffff
jmp 0x40ea1b
cmp byte [ebp + 0x10], 0
je 0x40ea19
mov ecx, dword [0x44e5c0]
mov eax, ecx
cdq
cmp edx, dword [0x43e57c]
jl 0x40e9f5
mov esi, dword [0x43e578]
jg 0x40e9f7
cmp eax, esi
ja 0x40e9f7
mov esi, ecx
push edi
mov edi, dword [0x44e5b8]
test esi, esi
je 0x40ea18
call fcn.0040e90f
xor byte [edi], al
movzx eax, byte [edi]
push eax
call fcn.0040ea20
inc edi
sub esi, 1
jne 0x40ea02
pop edi
xor eax, eax
pop esi
leave
ret 0xc
Function at 0x40ea20
Capabilities:
Generate random numbers using the delphi lcg

Disassembly:
mov ecx, dword [0x44f6e0]
mov eax, dword [esp + 4]
mov edx, dword [0x44f6e8]
xor eax, ecx
movzx eax, al
shr ecx, 8
xor ecx, dword [eax*4 + 0x43e150]
movzx eax, cl
add eax, dword [0x44f6e4]
mov dword [0x44f6e0], ecx
imul ecx, eax, 0x8088405
mov eax, dword [esp + 4]
inc ecx
mov dword [0x44f6e4], ecx
shr ecx, 0x18
xor ecx, edx
shr edx, 8
movzx ecx, cl
xor edx, dword [ecx*4 + 0x43e150]
mov dword [0x44f6e8], edx
ret 4

Function at 0x40ec42
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x14
lea eax, [esp]
push ebx
mov ebx, dword [esp + 0x1c]
push ebp
push esi
push edi
push eax
push ebx
call fcn.0040ef63
mov ebp, dword [esp + 0x34]
test ebp, ebp
je 0x40ec73
mov eax, dword [esp + 0x38]
cmp byte [eax], 0
je 0x40ec73
push 0x18
pop ecx
mov esi, ebp
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
jmp 0x40ec9b
lea esi, [ebx + 0x60]
push 0x40
mov eax, esi
pop ecx
xor byte [eax], 0x6a
inc eax
sub ecx, 1
jne 0x40ec7b
push ebx
call fcn.00406438
push 0x40
push esi
push ebx
call fcn.00406469
test ebp, ebp
je 0x40ecac
mov eax, dword [esp + 0x38]
cmp byte [eax], 0
jne 0x40ecac
push 0x18
pop ecx
mov esi, ebx
mov edi, ebp
rep movsd dword es:[edi], dword [esi]
mov byte [eax], 1
push 0x14
lea eax, [esp + 0x14]
push eax
push ebx
call fcn.00406469
lea eax, [esp + 0x10]
push eax
push ebx
call fcn.0040ef63
cmp dword [esp + 0x30], 0
pop edi
pop esi
pop ebp
pop ebx
jbe 0x40ece4
push dword [esp + 0x20]
lea eax, [esp + 4]
push eax
push dword [esp + 0x24]
call fcn.00416c90
add esp, 0xc
add esp, 0x14
ret 0x14

Function at 0x40ecea
Capabilities:
Encode data using xor

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0xc]
push edi
mov edi, dword [esp + 0x18]
lea ebx, [esi + 0x60]
cmp edi, 0x40
jbe 0x40ed1a
push esi
call fcn.00406438
push edi
push dword [esp + 0x18]
push esi
call fcn.00406469
push ebx
push esi
call fcn.0040ef63
push 0x14
pop edi
jmp 0x40ed28
push edi
push dword [esp + 0x18]
push ebx
call fcn.00416c90
add esp, 0xc
mov dword [esi + 0xa0], edi
test edi, edi
je 0x40ed4a
push 0xffffffffffffffa0
pop edx
mov ecx, ebx
sub edx, esi
xor byte [ecx], 0x36
inc ecx
mov edi, dword [esi + 0xa0]
lea eax, [edx + ecx]
cmp eax, edi
jb 0x40ed39
push 0x40
pop eax
sub eax, edi
push eax
lea eax, [esi + 0x60]
add eax, edi
push 0x36
push eax
call fcn.00416660
add esp, 0xc
push esi
call fcn.00406438
push 0x40
push ebx
push esi
call fcn.00406469
pop edi
pop esi
pop ebx
ret 0xc