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

Disassembly:
mov eax, dword [esp + 0x10]
sub esp, 0x1c
test eax, eax
je 0x1003e3f6
mov edx, dword [esp + 0x20]
push ebx
mov ebx, dword [esp + 0x2c]
push esi
mov esi, dword [esp + 0x2c]
push edi
cmp eax, 4
jb 0x1003e2f3
mov edi, eax
shr edi, 2
mov ecx, dword [esi]
sub eax, 4
xor ecx, dword [ebx]
add esi, 4
mov dword [edx], ecx
add ebx, 4
add edx, 4
sub edi, 1
jne 0x1003e2d8
mov dword [esp + 0x38], eax
push ebp
xor ebp, ebp
mov dword [esp + 0x10], edx
mov dword [esp + 0x14], ebx
test eax, eax
je 0x1003e3f2
cmp eax, 0x40
jb 0x1003e3cf
lea ecx, [ebx - 1]
lea edi, [edx - 1]
add ecx, eax
add edi, eax
cmp edx, ecx
ja 0x1003e325
cmp edi, ebx
jae 0x1003e3cf
lea ecx, [esi - 1]
add ecx, eax
cmp edx, ecx
ja 0x1003e336
cmp edi, esi
jae 0x1003e3cf
mov ecx, eax
lea edi, [edx + 0x10]
mov eax, edx
mov dword [esp + 0x18], edi
sub eax, ebx
and ecx, 0xffffffc0
mov dword [esp + 0x20], eax
mov edi, esi
sub edi, ebx
mov dword [esp + 0x28], ecx
mov eax, esi
mov dword [esp + 0x1c], edi
mov edi, dword [esp + 0x18]
sub eax, edx
mov edx, dword [esp + 0x20]
mov ecx, ebx
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x1c]
mov ebx, dword [esp + 0x24]
movups xmm0, xmmword [ecx]
lea ecx, [ecx + 0x40]
movups xmm1, xmmword [eax + ecx - 0x40]
lea edi, [edi + 0x40]
pxor xmm1, xmm0
movups xmm0, xmmword [ecx - 0x30]
movups xmmword [edx + ecx - 0x40], xmm1
movups xmm1, xmmword [ebx + edi - 0x40]
pxor xmm1, xmm0
movups xmm0, xmmword [ecx - 0x20]
movups xmmword [edi - 0x40], xmm1
movups xmm1, xmmword [esi + ebp + 0x20]
pxor xmm1, xmm0
movups xmm0, xmmword [ecx - 0x10]
movups xmmword [edi - 0x30], xmm1
movups xmm1, xmmword [esi + ebp + 0x30]
add ebp, 0x40
pxor xmm1, xmm0
movups xmmword [edi - 0x20], xmm1
cmp ebp, dword [esp + 0x28]
jb 0x1003e370
mov eax, dword [esp + 0x3c]
mov edx, dword [esp + 0x10]
mov ebx, dword [esp + 0x14]
cmp ebp, eax
jae 0x1003e3f2
sub esi, ebx
lea edi, [ebx + ebp]
sub edx, ebx
sub eax, ebp
nop dword [eax]
mov cl, byte [edi + esi]
lea edi, [edi + 1]
xor cl, byte [edi - 1]
mov byte [edi + edx - 1], cl
sub eax, 1
jne 0x1003e3e0
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x1c
ret
Function at 0x1003e400
Capabilities:
Encode data using xor

Disassembly:
mov eax, dword [esp + 0xc]
test eax, eax
je 0x1003e4d1
mov edx, dword [esp + 8]
push esi
mov esi, dword [esp + 8]
push edi
cmp eax, 4
jb 0x1003e432
mov edi, eax
shr edi, 2
mov ecx, dword [edx]
sub eax, 4
xor dword [esi], ecx
add edx, 4
add esi, 4
sub edi, 1
jne 0x1003e420
push ebx
xor ebx, ebx
test eax, eax
je 0x1003e4ce
cmp eax, 0x40
jb 0x1003e4ae
lea ecx, [edx - 1]
lea edi, [esi - 1]
add ecx, eax
add edi, eax
cmp esi, ecx
ja 0x1003e454
cmp edi, edx
jae 0x1003e4ae
push ebp
mov edi, eax
mov ebp, edx
and edi, 0xffffffc0
mov ecx, esi
sub ebp, esi
movups xmm0, xmmword [ecx]
lea ecx, [ecx + 0x40]
movups xmm1, xmmword [ecx + ebp - 0x40]
pxor xmm1, xmm0
movups xmmword [ecx - 0x40], xmm1
movups xmm0, xmmword [ecx - 0x30]
movups xmm1, xmmword [edx + ebx + 0x10]
pxor xmm1, xmm0
movups xmmword [ecx - 0x30], xmm1
movups xmm0, xmmword [ecx - 0x20]
movups xmm1, xmmword [edx + ebx + 0x20]
pxor xmm1, xmm0
movups xmmword [ecx - 0x20], xmm1
movups xmm0, xmmword [ecx - 0x10]
movups xmm1, xmmword [edx + ebx + 0x30]
add ebx, 0x40
pxor xmm1, xmm0
movups xmmword [ecx - 0x10], xmm1
cmp ebx, edi
jb 0x1003e460
pop ebp
cmp ebx, eax
jae 0x1003e4ce
sub edx, esi
lea edi, [ebx + esi]
sub eax, ebx
nop dword [eax]
mov cl, byte [edi + edx]
lea edi, [edi + 1]
xor byte [edi - 1], cl
sub eax, 1
jne 0x1003e4c0
pop ebx
pop edi
pop esi
ret

Function at 0x10044130
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [ebp + 0xc]
sub eax, 0x10000
push eax
call fcn.100442d0
add esp, 4
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
cmp ecx, dword [ebp + 8]
jbe 0x100441f4
cmp dword [ebp - 4], 0x50000000
jb 0x10044171
cmp dword [ebp - 4], 0x80000000
ja 0x10044171
mov dword [ebp - 4], 0x4fff0000
jmp 0x1004414a
push 0x1c
push 0
lea edx, [ebp - 0x24]
push edx
call fcn.100491f0
add esp, 0xc
push 0x1c
lea eax, [ebp - 0x24]
push eax
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
jne 0x10044197
jmp 0x100441f4
cmp dword [ebp - 0x14], 0x10000
jne 0x100441da
cmp dword [ebp - 0x18], 0x10000
jb 0x100441da
push 0x40
push 0x3000
push 0x10000
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x100441cd
mov eax, dword [ebp - 8]
jmp 0x100441f6
mov eax, dword [ebp - 4]
sub eax, 0x10000
mov dword [ebp - 4], eax
jmp 0x100441ef
mov ecx, dword [ebp - 0x20]
sub ecx, 0x10000
push ecx
call fcn.100442d0
add esp, 4
mov dword [ebp - 4], eax
jmp 0x1004414a
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x10044200
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [ebp + 8]
push eax
call fcn.10044300
add esp, 4
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
cmp ecx, dword [ebp + 0xc]
jae 0x100442bc
cmp dword [ebp - 4], 0x50000000
jb 0x1004423c
cmp dword [ebp - 4], 0x80000000
ja 0x1004423c
mov dword [ebp - 4], 0x80010000
jmp 0x10044215
push 0x1c
push 0
lea edx, [ebp - 0x24]
push edx
call fcn.100491f0
add esp, 0xc
push 0x1c
lea eax, [ebp - 0x24]
push eax
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
jne 0x10044262
jmp 0x100442bc
cmp dword [ebp - 0x14], 0x10000
jne 0x100442a5
cmp dword [ebp - 0x18], 0x10000
jb 0x100442a5
push 0x40
push 0x3000
push 0x10000
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x10044298
mov eax, dword [ebp - 8]
jmp 0x100442be
mov eax, dword [ebp - 4]
add eax, 0x10000
mov dword [ebp - 4], eax
jmp 0x100442b7
mov ecx, dword [ebp - 0x24]
add ecx, dword [ebp - 0x18]
push ecx
call fcn.10044300
add esp, 4
mov dword [ebp - 4], eax
jmp 0x10044215
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x10044c80
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0x100a1a40]
mov dword [ebp - 4], eax
jmp 0x10044c99
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 4]
mov dword [ebp - 4], edx
cmp dword [ebp - 4], 0
je 0x10044cb6
lea eax, [ebp - 8]
push eax
push 0x40
push 0x10000
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
jmp 0x10044c90
mov esp, ebp
pop ebp
ret
Function at 0x1004de0b
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.10046410
mov eax, dword [0x1008c880]
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.100578ab
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x1004de4d
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x1004dfa9
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.10046810
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 + 0x100a2168]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.10059115
mov ecx, dword [esi*4 + 0x100a2168]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [ecx + edi + 0x20]
jne 0x1004dfa2
cmp eax, dword [ecx + edi + 0x24]
jne 0x1004dfa2
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [ecx + edi + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1004dfa2
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.10059115
add esp, 0x14
test edx, edx
jl 0x1004dfa2
jg 0x1004df18
test eax, eax
jb 0x1004dfa2
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x1004dfa2
jl 0x1004df32
cmp dword [ebp - 0x1008], eax
ja 0x1004dfa2
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x1004df50
test ebx, ebx
je 0x1004df89
cmp ecx, edi
jae 0x1004df89
mov al, byte [ecx]
cmp al, 0xd
jne 0x1004df6a
lea eax, [edi - 1]
cmp ecx, eax
jae 0x1004df76
cmp byte [ecx + 1], 0xa
jne 0x1004df76
inc ecx
jmp 0x1004df76
movzx eax, al
movsx eax, byte [eax + 0x1008cb18]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x1004df50
cmp edx, ebx
jne 0x1004df50
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x1004dfa7
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.100463c8
leave
ret

Function at 0x10054bb1
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x10054bf0
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x10054bf0
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x10054bf0
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x10054bf0
cmp dword [ecx + 0x74], 0xe
jbe 0x10054bf0
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x10058251
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
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 + 0x100a2168]
mov dword [ebp - 0xc], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x10058291
cmp byte [ebx], 0xa
jne 0x10058291
or byte [edi + eax + 0x28], 4
jmp 0x10058296
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
mov dword [ebp - 8], eax
cmp ebx, ecx
jae 0x10058395
mov dl, byte [eax]
cmp dl, 0x1a
je 0x10058378
inc eax
cmp dl, 0xd
je 0x100582c2
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x100582e8
cmp eax, ecx
jae 0x100582f6
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add dword [ebp - 8], eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x10]
xor edx, edx
inc edx
add esi, edx
cmp eax, ecx
jb 0x100582aa
jmp 0x10058395
push 0
lea eax, [ebp - 0x10]
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 0x10058373
cmp dword [ebp - 0x10], 0
je 0x10058373
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x100a2168]
test byte [eax + edi + 0x28], 0x48
je 0x1005834d
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x10058338
mov byte [esi], dl
jmp 0x10058349
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x100a2168]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x10058395
cmp byte [ebp - 1], 0xa
jne 0x1005835c
cmp esi, ebx
jne 0x1005835c
mov byte [esi], 0xa
jmp 0x10058394
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.10059133
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x10058395
mov byte [esi], 0xd
jmp 0x10058394
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x100a2168]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x10058392
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x10058395
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x1005839e
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
push esi
sar ecx, 6
push edi
imul edi, eax, 0x38
mov dword [ebp - 8], ecx
mov eax, dword [ecx*4 + 0x100a2168]
push 0xa
pop edx
mov dword [ebp - 0x18], edx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x100583e4
cmp word [ebx], dx
jne 0x100583e4
or byte [eax + edi + 0x28], 4
jmp 0x100583e9
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + ecx*2]
mov eax, ebx
mov dword [ebp - 0xc], edx
mov esi, ebx
mov dword [ebp - 4], eax
cmp ebx, edx
jae 0x1005854c
mov dword [ebp - 0x10], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x14], edx
mov edx, dword [ebp - 0xc]
cmp ecx, 0x1a
je 0x1005852c
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x1005842a
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x10058460
cmp eax, edx
jae 0x1005846e
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x18]
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 - 0xc]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
push 2
pop ecx
add esi, ecx
cmp eax, edx
jb 0x10058405
jmp 0x1005854c
push 0
lea eax, [ebp - 0x18]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x10058527
cmp dword [ebp - 0x18], 0
je 0x10058527
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x100a2168]
test byte [eax + edi + 0x28], 0x48
je 0x100584fd
lea eax, [esi + 2]
mov dword [ebp - 0x1c], eax
mov ax, word [ebp - 4]
pop ecx
mov word [ebp - 2], ax
cmp ax, cx
jne 0x100584c1
mov word [esi], cx
jmp 0x100584f8
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x100a2168]
mov dx, word [ebp - 2]
shr ecx, 8
push 0xa
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x100a2168]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x100a2168]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x1005854c
pop eax
cmp word [ebp - 4], ax
jne 0x1005850d
cmp esi, ebx
jne 0x1005850d
mov word [esi], ax
jmp 0x10058549
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.10059133
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x1005854c
push 0xd
pop eax
jmp 0x10058508
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x100a2168]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x10058546
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x1005854c
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x1005a18a
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10078c00
push 0x10078bf8
push str.FlsAlloc
push 0x1f
call fcn.1005a049
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1005a1be
push dword [ebp + 8]
mov ecx, esi
call dword [0x10068220]
call esi
jmp 0x1005a1c4
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x1005a208
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10078c10
push 0x10078c08
push str.FlsGetValue
push 0x21
call fcn.1005a049
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1005a23f
push dword [ebp + 8]
mov ecx, esi
call dword [0x10068220]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x1005a247
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10078c18
push 0x10078c10
push str.FlsSetValue
push 0x22
call fcn.1005a049
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1005a281
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x10068220]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x1006048a
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 0x10060527
push ebx
push esi
call fcn.10060453
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.1005d66a
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x100604d4
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x10060526
push edi
push eax
call fcn.100569ab
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x100604f4
call fcn.10056971
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x10060525
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.1005d66a
add esp, 0x20
test eax, eax
jne 0x10060513
push edi
call fcn.10056971
jmp 0x1006051b
push ebx
call fcn.10056971
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 0x1006052a
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x1006053b
pop esi
ret
push ebx
push edi
push esi
call fcn.10060453
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.100569ab
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x10060563
push ebx
push esi
push edi
call fcn.10048a90
add esp, 0xc
push 0
call fcn.10056971
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x10060933
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.10060578
Function at 0x10063ff1
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]
mov edi, dword [ebp + 0x14]
push dword [ebp + 0xc]
push ebx
call fcn.10063f6d
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x10064160
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x10064160
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x10064115
jg 0x1006404d
test eax, eax
je 0x1006410b
push 1
push 0x1000
call fcn.1005a517
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x10064070
push 0xc
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x10064102
push 0x8000
push ebx
call fcn.10063e9e
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x10064099
jg 0x10064094
cmp ecx, 0x1000
jb 0x10064099
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.1005b028
add esp, 0x10
cmp eax, 0xffffffff
je 0x100640de
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 0x10064094
jl 0x100640c5
test ecx, ecx
jne 0x10064086
push dword [ebp - 0xc]
push ebx
call fcn.10063e9e
push esi
call fcn.10056971
add esp, 0xc
xor ebx, ebx
jmp 0x1006416e
cmp byte [edi + 0x24], 0
je 0x100640f5
cmp dword [edi + 0x20], 5
jne 0x100640f5
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x10064100
mov ebx, dword [edi + 0x18]
jmp 0x10064102
xor ebx, ebx
push esi
call fcn.10056971
pop ecx
jmp 0x1006416e
test ecx, ecx
jg 0x100640d7
jl 0x10064115
test eax, eax
jae 0x100640d7
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.10059133
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x10064135
cmp byte [edi + 0x1c], 0
je 0x100640d7
jmp 0x10064166
push ebx
call fcn.1006167b
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x100640d7
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [edi + 0x24], 1
mov dword [edi + 0x20], eax
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x1006416e
cmp byte [edi + 0x1c], 0
je 0x1006416b
mov ebx, dword [edi + 0x18]
jmp 0x1006416e
push 0x16
pop ebx
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.10059133
add esp, 0x10
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4035ac
Capabilities:
Generate random numbers using the delphi lcg

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

Function at 0x41cf00
Capabilities:
Decompress data using aplib

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push ebp
mov esi, dword [ebp - 4]
mov edi, dword [ebp - 8]
cld
mov dl, 0x80
mov al, byte [esi]
add esi, 1
mov byte [edi], al
add edi, 1
mov ebx, 2
add dl, dl
jne 0x41cf31
mov dl, byte [esi]
inc esi
adc dl, dl
jae 0x41cf19
add dl, dl
jne 0x41cf3c
mov dl, byte [esi]
inc esi
adc dl, dl
jae 0x41cf8d
xor eax, eax
add dl, dl
jne 0x41cf49
mov dl, byte [esi]
inc esi
adc dl, dl
jae 0x41d02a
add dl, dl
jne 0x41cf58
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x41cf63
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x41cf6e
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x41cf79
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
je 0x41cf83
mov ebx, edi
sub ebx, eax
mov al, byte [ebx]
mov byte [edi], al
inc edi
mov ebx, 2
jmp 0x41cf28
mov eax, 1
add dl, dl
jne 0x41cf9b
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x41cfa6
mov dl, byte [esi]
inc esi
adc dl, dl
jb 0x41cf92
sub eax, ebx
mov ebx, 1
jne 0x41cfd9
mov ecx, 1
add dl, dl
jne 0x41cfbf
mov dl, byte [esi]
inc esi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x41cfca
mov dl, byte [esi]
inc esi
adc dl, dl
jb 0x41cfb6
push esi
mov esi, edi
sub esi, ebp
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x41cf28
dec eax
shl eax, 8
mov al, byte [esi]
inc esi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x41cff0
mov dl, byte [esi]
inc esi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x41cffb
mov dl, byte [esi]
inc esi
adc dl, dl
jb 0x41cfe7
cmp eax, 0x7d00
sbb ecx, 0xffffffff
cmp eax, 0x500
sbb ecx, 0xffffffff
cmp eax, 0x80
adc ecx, 0
cmp eax, 0x80
adc ecx, 0
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x41cf28
mov al, byte [esi]
inc esi
xor ecx, ecx
shr al, 1
je 0x41d04b
adc ecx, 2
mov ebp, eax
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
mov ebx, 1
jmp 0x41cf28
pop ebp
sub edi, dword [ebp - 8]
mov dword [ebp - 0xc], edi
pop edi
pop esi
pop ebx
mov eax, dword [ebp - 0xc]
mov esp, ebp
pop ebp
ret
Function at 0x41f05c
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
push ebx
push esi
push edi
mov dword [ebp - 4], ecx
mov ebx, edx
xor edx, edx
push ebp
push 0x45954a
push dword fs:[edx]
mov dword fs:[edx], esp
xor edx, edx
mov dword [ebp - 8], edx
mov esi, ebx
xor ecx, ecx
cmp byte [eax + 0x6a], 0
je 0x41f0ab
mov eax, ebx
xor edx, edx
push edx
push eax
mov eax, dword [esi + 0x3c]
cdq
add eax, dword [esp]
adc edx, dword [esp + 4]
add esp, 8
mov edx, dword [eax + 0x88]
test edx, edx
je 0x41f0ca
mov ecx, edx
add ecx, ebx
jmp 0x41f0ca
mov eax, ebx
xor edx, edx
push edx
push eax
mov eax, dword [esi + 0x3c]
cdq
add eax, dword [esp]
adc edx, dword [esp + 4]
add esp, 8
mov edx, dword [eax + 0x78]
test edx, edx
je 0x41f0ca
mov ecx, edx
add ecx, ebx
test ecx, ecx
je 0x41f13c
mov esi, dword [ecx + 0x18]
mov eax, dword [ecx + 0x1c]
add eax, ebx
mov dword [ebp - 0x10], eax
mov edi, dword [ecx + 0x20]
add edi, ebx
mov eax, dword [ecx + 0x24]
add eax, ebx
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 4]
cmp eax, 0xffff
jbe 0x41f125
test esi, esi
jbe 0x41f13c
mov eax, dword [edi]
add eax, ebx
mov edx, dword [ebp - 4]
call fcn.004088ec
test eax, eax
jne 0x41f117
mov eax, dword [ebp - 0xc]
movzx eax, word [eax]
shl eax, 2
add eax, dword [ebp - 0x10]
mov eax, dword [eax]
mov dword [ebp - 8], eax
jmp 0x41f13c
add dword [ebp - 0xc], 2
add edi, 4
dec esi
test esi, esi
ja 0x41f0f4
jmp 0x41f13c
mov edx, eax
sub edx, dword [ecx + 0x10]
cmp edx, dword [ecx + 0x14]
jae 0x41f13c
mov eax, edx
shl eax, 2
add eax, dword [ebp - 0x10]
mov eax, dword [eax]
mov dword [ebp - 8], eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x459551
ret