joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4166f0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5d1c5d
mov eax, dword fs:[0]
push eax
sub esp, 0x21c
mov eax, dword [0x64c00c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x224], edi
mov dword [ebp - 4], 0
mov dword [ebp - 0x228], edi
mov dword [ebp - 0x21c], 0
call fcn.00405800
mov ecx, eax
test ecx, ecx
je 0x41692c
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [edi], eax
push 0x208
lea eax, [ebp - 0x218]
mov dword [ebp - 4], 0
push 0
push eax
mov dword [ebp - 0x21c], 1
call fcn.005a52f0
add esp, 0xc
lea eax, [ebp - 0x218]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4167a0
sub ecx, edx
lea eax, [ebp - 0x218]
sar ecx, 1
push ecx
push eax
mov ecx, edi
call fcn.00406ed0
call fcn.00405800
mov ecx, eax
test ecx, ecx
je 0x416936
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x224], eax
mov dword [ebp - 4], 1
mov eax, dword [edi]
mov esi, dword [eax - 0xc]
lea ecx, [eax - 0x10]
cmp esi, 1
jg 0x4167ff
call fcn.00406d70
lea esi, [eax + 0x10]
mov dword [ebp - 0x220], esi
jmp 0x416837
mov ecx, dword [ecx]
test ecx, ecx
je 0x41680e
mov eax, dword [ecx]
call dword [eax + 0x10]
test eax, eax
jne 0x41681a
call fcn.00405800
mov ecx, eax
mov edx, dword [eax]
call dword [edx + 0x10]
mov ecx, dword [edi]
push eax
push 1
lea ecx, [ecx + esi*2]
add ecx, 0xfffffffe
push ecx
lea ecx, [ebp - 0x220]
call fcn.00406cf0
mov esi, dword [ebp - 0x220]
mov dword [ebp - 0x21c], 3
lea eax, [ebp - 0x220]
mov byte [ebp - 4], 2
push eax
lea ecx, [ebp - 0x224]
call fcn.00406a90
or ebx, 0xffffffff
mov byte [ebp - 4], 1
add esi, 0xfffffff0
mov eax, ebx
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x416875
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov esi, dword [ebp - 0x224]
mov ecx, 0x635b40
mov eax, esi
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x4168a8
test dx, dx
je 0x4168a4
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x4168a8
add eax, 4
add ecx, 4
test dx, dx
jne 0x416882
xor eax, eax
jmp 0x4168ad
sbb eax, eax
or eax, 1
test eax, eax
je 0x4168f5
mov ecx, 0x635b60
mov eax, esi
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x4168de
test dx, dx
je 0x4168da
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x4168de
add eax, 4
add ecx, 4
test dx, dx
jne 0x4168b8
xor eax, eax
jmp 0x4168e3
sbb eax, eax
or eax, 1
test eax, eax
je 0x4168f5
push 1
push 0x635b40
mov ecx, edi
call fcn.004089b0
mov byte [ebp - 4], 0
add esi, 0xfffffff0
lock xadd dword [esi + 0xc], ebx
dec ebx
test ebx, ebx
jg 0x41690e
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00483ab6
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.00405600
push 0x80004005
call fcn.00405600
int3
Function at 0x417980
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5d1cf8
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
push edi
mov eax, dword [0x64c00c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x10], esi
mov dword [esi + 8], 0xffffffff
mov dword [esi + 4], 0xffffffff
mov dword [esi + 0xc], 0
mov dword [esi + 0x20], 0
mov dword [esi + 0x30], 0
mov dword [esi + 0x34], 0xf
mov byte [esi + 0x20], 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 1
mov dword [esi + 0x38], 0
mov dword [esi + 0x3c], 0
mov dword [ebp - 4], 0
lea ecx, [esi + 0x40]
mov dword [esi], vtable.TiXmlElement.0
call fcn.00417090
mov dword [ecx + 0x48], ecx
mov dword [ecx + 0x44], ecx
mov ecx, dword [ebp + 8]
mov eax, ecx
mov byte [ebp - 4], 1
mov dword [esi + 0x1c], 0
mov dword [esi + 0x18], 0
lea ebx, [eax + 1]
nop word [eax + eax]
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x417a30
sub eax, ebx
push eax
push ecx
lea ecx, [esi + 0x20]
call fcn.00409200
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4

Function at 0x418040
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5d1de8
mov eax, dword fs:[0]
push eax
push ecx
push esi
mov eax, dword [0x64c00c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x10], esi
mov dword [esi + 8], 0xffffffff
mov dword [esi + 4], 0xffffffff
mov dword [esi + 0xc], 0
mov dword [esi + 0x20], 0
mov dword [esi + 0x30], 0
mov dword [esi + 0x34], 0xf
mov byte [esi + 0x20], 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 0
mov dword [esi + 0x18], 0
mov dword [esi + 0x1c], 0
mov dword [esi + 0x38], 0
mov dword [esi + 0x3c], 0
mov dword [ebp - 4], 0
lea ecx, [esi + 0x48]
mov dword [esi], vtable.TiXmlDocument.0
mov dword [ecx], 0
mov dword [ecx + 0x10], 0
mov dword [ecx + 0x14], 0xf
mov byte [ecx], 0
mov byte [ebp - 4], 1
mov dword [esi + 0x68], 0xffffffff
mov dword [esi + 0x64], 0xffffffff
push 0
push 0x6365b4
mov dword [esi + 0x60], 4
mov byte [esi + 0x6c], 0
mov byte [esi + 0x40], 0
mov dword [esi + 0x44], 0
call fcn.00409200
mov dword [esi + 0x68], 0
mov eax, esi
mov dword [esi + 0x64], 0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x41e480
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
test edx, edx
jne 0x41e48b
xor eax, eax
pop ebp
ret
push esi
mov esi, dword [ebp + 8]
not ecx
cmp esi, 8
jb 0x41e547
push edi
mov edi, esi
shr edi, 3
movzx eax, byte [edx]
sub esi, 8
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
movzx eax, byte [edx + 1]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
movzx eax, byte [edx + 2]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
movzx eax, byte [edx + 3]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
movzx eax, byte [edx + 4]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
movzx eax, byte [edx + 5]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
movzx eax, byte [edx + 6]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
movzx eax, byte [edx + 7]
add edx, 8
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
sub edi, 1
jne 0x41e4a0
pop edi
test esi, esi
je 0x41e56a
nop dword [eax + eax]
movzx eax, byte [edx]
lea edx, [edx + 1]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
sub esi, 1
jne 0x41e550
not ecx
mov eax, ecx
pop esi
pop ebp
ret

Function at 0x41ed50
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
push edi
mov edi, dword [ebp + 0xc]
mov esi, edx
mov ebx, esi
mov dword [ebp - 8], esi
imul ebx, dword [ebp + 8]
mov eax, ecx
mov dword [ebp - 4], eax
cmp byte [edi], 0
je 0x41ed98
push 0
lea ecx, [ebp + 8]
push ecx
push ebx
push eax
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x41ed8a
mov byte [edi + 8], 1
mov eax, dword [ebp + 8]
xor edx, edx
pop edi
div esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [edi + 0x1c]
mov esi, dword [edi + 0x18]
mov ecx, dword [edi + 0x14]
sub esi, edx
lea eax, [edx + ebx]
cmp eax, dword [edi + 0x18]
cmovbe esi, ebx
add ecx, edx
push esi
push ecx
push dword [ebp - 4]
call fcn.005a5500
add dword [edi + 0x1c], esi
add esp, 0xc
mov eax, esi
xor edx, edx
div dword [ebp - 8]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41edd0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
mov esi, ecx
mov ebx, edx
push edi
mov dword [ebp - 8], ebx
mov edi, 1
cmp byte [esi], 0
je 0x41ee0b
push 0
lea eax, [ebp - 8]
push eax
push edi
lea eax, [ebp - 1]
push eax
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x41ee06
mov byte [esi + 8], 1
mov edi, dword [ebp - 8]
jmp 0x41ee38
mov ebx, dword [esi + 0x1c]
mov ecx, dword [esi + 0x18]
lea eax, [ebx + 1]
cmp eax, ecx
jbe 0x41ee1c
mov edi, ecx
sub edi, ebx
mov eax, dword [esi + 0x14]
add eax, ebx
push edi
push eax
lea eax, [ebp - 1]
push eax
call fcn.005a5500
lea eax, [ebx + edi]
add esp, 0xc
mov ebx, dword [ebp - 8]
mov dword [esi + 0x1c], eax
cmp edi, 1
jne 0x41ee4c
movzx eax, byte [ebp - 1]
mov dword [ebx], eax
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
cmp byte [esi], 0
je 0x41ee43
cmp byte [esi + 8], 0
je 0x41ee43
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41f960
Capabilities:
Generate random numbers using the delphi lcg
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push edi
mov edi, ecx
mov ebx, edx
test edi, edi
je 0x41fb4d
cmp dword [edi + 0x18], 0
je 0x41fb4d
push esi
mov esi, dword [edi + 0x7c]
test esi, esi
je 0x41f9c0
mov eax, dword [esi]
test eax, eax
je 0x41f995
push eax
call fcn.005a8164
add esp, 4
cmp dword [esi + 0x40], 0
mov dword [esi], 0
je 0x41f9a9
lea ecx, [esi + 4]
call fcn.0041e6e0
push esi
mov dword [esi + 0x40], 0
call fcn.005a8164
add esp, 4
mov dword [edi + 0x7c], 0
lea eax, [ebp - 8]
mov ecx, edi
push eax
lea eax, [ebp - 4]
push eax
lea edx, [ebp - 0xc]
call fcn.0041f700
add esp, 8
test eax, eax
je 0x41f9e5
pop esi
pop edi
mov eax, 0xffffff99
pop ebx
mov esp, ebp
pop ebp
ret
push 0x84
call fcn.005a817f
mov esi, eax
add esp, 4
test esi, esi
je 0x41fa27
push 0x4000
call fcn.005a817f
mov ecx, dword [ebp - 4]
add esp, 4
mov dword [esi + 0x44], ecx
mov ecx, dword [ebp - 8]
mov dword [esi], eax
mov dword [esi + 0x48], ecx
mov dword [esi + 0x4c], 0
test eax, eax
jne 0x41fa33
push esi
call fcn.005a8164
add esp, 4
pop esi
pop edi
mov eax, 0xffffff98
pop ebx
mov esp, ebp
pop ebp
ret
mov dword [esi + 0x40], 0
mov ecx, dword [edi + 0x34]
mov eax, dword [edi + 0x3c]
mov dword [esi + 0x54], eax
mov dword [esi + 0x50], 0
mov eax, dword [edi + 0x34]
mov dword [esi + 0x64], eax
mov eax, dword [edi]
mov dword [esi + 0x60], eax
mov eax, dword [edi + 0xc]
mov dword [esi + 0x68], eax
mov dword [esi + 0x18], 0
test ecx, ecx
je 0x41fa8e
lea ecx, [esi + 4]
mov dword [esi + 0x24], 0
mov dword [esi + 0x28], 0
mov dword [esi + 0x2c], 0
call fcn.0041e7c0
test eax, eax
jne 0x41fa8e
mov dword [esi + 0x40], 1
mov eax, dword [edi + 0x40]
mov dword [esi + 0x58], eax
mov eax, dword [edi + 0x44]
mov dword [esi + 0x5c], eax
mov cl, byte [edi + 0x30]
and cl, 1
mov byte [esi + 0x6c], cl
mov eax, dword [edi + 0x30]
shr eax, 3
test al, 1
je 0x41fab2
mov al, byte [edi + 0x39]
jmp 0x41fab5
mov al, byte [edi + 0x3f]
mov byte [esi + 0x80], al
mov edx, 0xc
xor eax, eax
mov dword [esi + 0x70], 0x12345678
test cl, cl
mov dword [esi + 0x74], 0x23456789
mov dword [esi + 0x78], 0x34567890
cmovne eax, edx
mov dword [esi + 0x7c], eax
test ebx, ebx
je 0x41fb2e
mov al, byte [ebx]
test al, al
je 0x41fb2e
mov ecx, dword [esi + 0x70]
movsx eax, al
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
movzx eax, cl
add eax, dword [esi + 0x74]
imul eax, eax, 0x8088405
mov dword [esi + 0x70], ecx
mov ecx, dword [esi + 0x78]
inc eax
mov dword [esi + 0x74], eax
shr eax, 0x18
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x6339d8]
mov dword [esi + 0x78], ecx
add ebx, 1
jne 0x41fae3
mov eax, dword [ebp - 0xc]
add eax, 0x1e
add eax, dword [edi + 0x78]
mov dword [esi + 0x3c], eax
xor eax, eax
mov dword [esi + 8], 0
mov dword [edi + 0x7c], esi
pop esi
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
mov eax, 0xffffff9a
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4205a0
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov eax, dword [0x64c00c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, ecx
push edi
mov edi, edx
test ebx, ebx
je 0x420641
push 0x104
lea eax, [ebp - 0x20c]
push ebx
push eax
call fcn.005ad781
lea ecx, [ebp - 0x20c]
add esp, 0xc
lea edx, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4205e0
sub ecx, edx
sar ecx, 1
je 0x420620
movzx eax, word [ebp + ecx*2 - 0x20e]
cmp eax, 0x2f
je 0x420603
cmp eax, 0x5c
jne 0x420620
lea ecx, [ecx*2 - 2]
cmp ecx, 0x208
jae 0x420746
xor eax, eax
mov word [ebp + ecx - 0x20c], ax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x420641
push 0
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
movzx eax, word [edi]
test ax, ax
je 0x420736
push esi
mov esi, edi
mov ecx, edi
mov edx, eax
cmp dx, 0x2f
je 0x420660
cmp dx, 0x5c
jne 0x420662
mov esi, ecx
movzx eax, word [ecx + 2]
add ecx, 2
mov edx, eax
test ax, ax
jne 0x420654
cmp esi, edi
je 0x4206ad
sub esi, edi
lea eax, [ebp - 0x20c]
and esi, 0xfffffffe
push esi
push edi
push eax
call fcn.005a5500
add esp, 0xc
cmp esi, 0x208
jae 0x420746
xor eax, eax
lea edx, [ebp - 0x20c]
mov ecx, ebx
mov word [ebp + esi - 0x20c], ax
call fcn.004205a0
xor eax, eax
mov word [ebp - 0x414], ax
pop esi
test ebx, ebx
je 0x4206d0
push 0x104
lea eax, [ebp - 0x414]
push ebx
push eax
call fcn.005ad781
add esp, 0xc
xor eax, eax
lea ecx, [ebp - 0x414]
mov word [ebp - 0x20e], ax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4206e2
sub ecx, edx
mov eax, 0x104
sar ecx, 1
sub eax, ecx
push eax
lea eax, [ebp - 0x414]
lea eax, [eax + ecx*2]
push edi
push eax
call fcn.005ad781
xor eax, eax
add esp, 0xc
mov word [ebp - 0x20e], ax
lea eax, [ebp - 0x414]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x420736
push 0
lea eax, [ebp - 0x414]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop ebx
call fcn.00483ab6
mov esp, ebp
pop ebp
ret
call fcn.004841c9
int3
Function at 0x420b40
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5d2267
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push esi
push edi
mov eax, dword [0x64c00c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
push 0x44c
call fcn.00483d03
mov edi, eax
add esp, 4
mov dword [ebp - 0x14], edi
lea esi, [edi + 0x244]
mov dword [edi], 0
push esi
push 0x103
mov dword [edi + 4], 0xffffffff
mov dword [edi + 0x238], 0xffffffff
mov dword [edi + 0x23c], 0
mov dword [edi + 0x240], 0
mov dword [ebp - 4], 0xffffffff
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x420bc3
sub esi, ecx
sar esi, 1
movzx eax, word [edi + esi*2 + 0x242]
cmp eax, 0x5c
je 0x420bef
cmp eax, 0x2f
je 0x420bef
mov dword [edi + esi*2 + 0x244], 0x2f
push 0
push 0x80
push 3
push 0
push 1
push closesocket
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x14], eax
cmp eax, 0xffffffff
je 0x420ca7
push 1
push 0
push 0
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov esi, eax
cmp esi, 0xffffffff
push 0x20
setne bl
call fcn.00483d03
mov ecx, dword [ebp - 0x14]
add esp, 4
mov dword [ebp - 0x10], eax
mov byte [eax], 1
mov byte [eax + 0x10], 1
mov byte [eax + 1], bl
mov dword [eax + 4], ecx
mov byte [eax + 8], 0
mov dword [eax + 0xc], 0
cmp esi, 0xffffffff
je 0x420c6b
push 1
push 0
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ecx, dword [ebp - 0x10]
mov dword [ecx + 0xc], eax
mov eax, ecx
mov ecx, eax
call fcn.0041f080
mov dword [edi], eax
test eax, eax
je 0x420ca7
push 8
mov dword [0x65c9d0], 0
call fcn.00483d03
add esp, 4
mov dword [eax], 1
mov dword [eax + 4], edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [edi + 0x23c]
mov dword [0x65c9d0], 0x200
test eax, eax
je 0x420cc4
push eax
call fcn.00484099
add esp, 4
mov eax, dword [edi + 0x240]
mov dword [edi + 0x23c], 0
test eax, eax
je 0x420ce1
push eax
call fcn.00484099
add esp, 4
push 0x44c
push edi
mov dword [edi + 0x240], 0
call fcn.00483ac4
add esp, 8
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x421080
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5d22a5
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push esi
push edi
mov eax, dword [0x64c00c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x14], edi
xor ebx, ebx
call fcn.00405800
mov ecx, eax
test ecx, ecx
je 0x42122c
mov eax, dword [ecx]
call dword [eax + 0xc]
lea esi, [eax + 0x10]
mov dword [ebp - 0x10], esi
mov dword [ebp - 4], ebx
mov ecx, dword [edi]
test ecx, ecx
je 0x4210e9
cmp dword [ecx], 1
jne 0x4210de
call fcn.00420da0
jmp 0x4210e3
call fcn.00421a80
mov dword [edi], 0
mov edi, dword [ebp + 8]
or eax, 0xffffffff
test edi, edi
je 0x4211fa
push edi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x4211f7
sub esp, 8
mov ecx, edi
call fcn.00420b40
mov ecx, dword [ebp - 0x14]
add esp, 8
mov dword [ecx], eax
test eax, eax
je 0x4211f7
mov ecx, edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x421125
sub ecx, edx
sar ecx, 1
push ecx
push edi
lea ecx, [ebp - 0x10]
call fcn.00406ed0
mov esi, dword [ebp - 0x10]
push 0x5c
push esi
call fcn.005a4e4b
add esp, 8
test eax, eax
je 0x421159
sub eax, esi
sar eax, 1
cmp eax, 0xffffffff
jne 0x421171
push 0x2f
push esi
call fcn.005a4e4b
add esp, 8
test eax, eax
jne 0x42116d
or eax, 0xffffffff
jmp 0x421171
sub eax, esi
sar eax, 1
xor edi, edi
test eax, eax
cmovns edi, eax
cmp edi, dword [esi - 0xc]
jl 0x42118d
lea ecx, [esi - 0x10]
call fcn.00406d70
lea esi, [eax + 0x10]
mov dword [ebp + 8], esi
jmp 0x4211b7
mov ecx, dword [esi - 0x10]
test ecx, ecx
je 0x42119d
mov eax, dword [ecx]
call dword [eax + 0x10]
test eax, eax
jne 0x4211a9
call fcn.00405800
mov ecx, eax
mov edx, dword [eax]
call dword [edx + 0x10]
push eax
push edi
push esi
lea ecx, [ebp + 8]
call fcn.00406cf0
mov esi, dword [ebp + 8]
lea eax, [ebp + 8]
mov byte [ebp - 4], 1
push eax
lea ecx, [ebp - 0x10]
call fcn.00406a90
mov byte [ebp - 4], 0
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x4211e3
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x14]
mov esi, dword [ebp - 0x10]
mov edx, esi
mov ecx, dword [eax]
call fcn.00420d10
mov ebx, 1
or eax, 0xffffffff
mov dword [ebp - 4], 0xffffffff
add esi, 0xfffffff0
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x421216
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
push 0x80004005
call fcn.00405600
int3
Function at 0x421800
Capabilities:
Encode data using xor
Generate random numbers using the delphi lcg
Hash data with crc32
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov esi, ecx
push edi
mov edi, dword [ebp + 8]
cmp byte [esi + 0x2d], 0
je 0x4218d5
mov ecx, dword [esi + 0x3c]
mov eax, ecx
mov ebx, dword [ebp + 0xc]
test ecx, ecx
je 0x421838
cmp dword [esi + 0x40], ebx
jae 0x421838
push ecx
call fcn.00484099
add esp, 4
mov dword [esi + 0x3c], 0
jmp 0x42183c
test eax, eax
jne 0x42184e
lea eax, [ebx + ebx]
push eax
call fcn.0048409e
add esp, 4
mov dword [esi + 0x3c], eax
mov dword [esi + 0x40], ebx
push ebx
push edi
push eax
call fcn.005a5500
xor edx, edx
add esp, 0xc
mov dword [ebp + 8], edx
test ebx, ebx
je 0x4218d2
mov eax, dword [esi + 0x3c]
mov ecx, dword [esi + 0x30]
mov bl, byte [edx + eax]
mov edx, dword [esi + 0x38]
mov edi, edx
movsx eax, bl
and edi, 0xfffd
xor eax, ecx
or edi, 2
movzx eax, al
shr ecx, 8
xor ecx, dword [eax*4 + 0x635160]
movzx eax, cl
add eax, dword [esi + 0x34]
imul eax, eax, 0x8088405
mov dword [esi + 0x30], ecx
mov ecx, edi
xor ecx, 1
imul ecx, edi
inc eax
mov dword [esi + 0x34], eax
shr eax, 0x18
xor eax, edx
shr ecx, 8
movzx eax, al
xor cl, bl
shr edx, 8
xor edx, dword [eax*4 + 0x635160]
mov dword [esi + 0x38], edx
mov edx, dword [ebp + 8]
mov eax, dword [esi + 0x3c]
mov byte [edx + eax], cl
inc edx
mov dword [ebp + 8], edx
cmp edx, dword [ebp + 0xc]
jb 0x421862
mov edi, dword [esi + 0x3c]
mov ecx, dword [esi + 0x20]
test ecx, ecx
je 0x421913
mov edx, dword [esi + 0x24]
mov ebx, dword [ebp + 0xc]
lea eax, [edx + ebx]
cmp eax, dword [esi + 0x28]
jb 0x4218fa
pop edi
mov dword [esi + 0x14], 0x30000
xor eax, eax
pop esi
pop ebx
pop ebp
ret 8
push ebx
add ecx, edx
push edi
push ecx
call fcn.005a5500
add esp, 0xc
mov eax, ebx
add dword [esi + 0x24], ebx
pop edi
pop esi
pop ebx
pop ebp
ret 8
mov eax, dword [esi + 4]
test eax, eax
je 0x421935
push 0
lea ecx, [ebp + 8]
push ecx
push dword [ebp + 0xc]
push edi
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp + 8]
pop edi
pop esi
pop ebx
pop ebp
ret 8
pop edi
mov dword [esi + 0x14], 0x1000000
xor eax, eax
pop esi
pop ebx
pop ebp
ret 8
Function at 0x4221f0
Capabilities:
Check if file exists
Delete file
Get file attributes
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5d2320
mov eax, dword fs:[0]
push eax
sub esp, 0x4a8
mov eax, dword [0x64c00c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
call fcn.004223e0
test al, al
je 0x4223c1
call fcn.004225c0
push 0x250
lea eax, [ebp - 0x4b0]
push 0
push eax
call fcn.005a52f0
add esp, 0xc
lea ecx, [ebp - 0x4b0]
cmp dword [0x65caa8], 8
mov eax, 0x65ca94
cmovae eax, dword [0x65ca94]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, dword [sym.imp.KERNEL32.dll_FindClose]
cmp eax, 0xffffffff
je 0x42232b
cmp dword [ebp - 0x490], 0x500000
push eax
jb 0x422329
call esi
cmp dword [0x65caa8], 8
lea ecx, [ebp - 0x4b4]
mov eax, 0x65ca94
cmovae eax, dword [0x65ca94]
push eax
call fcn.00406b20
push 2
push 0x6372a0
lea ecx, [ebp - 0x4b4]
mov dword [ebp - 4], 0
call fcn.004089b0
push dword [ebp - 0x4b4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x4222e0
test al, 0x10
jne 0x4222e0
push dword [ebp - 0x4b4]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp dword [0x65caa8], 8
mov eax, 0x65ca94
push dword [ebp - 0x4b4]
cmovae eax, dword [0x65ca94]
push eax
call fcn.005b7704
mov dword [ebp - 4], 0xffffffff
add esp, 8
mov edx, dword [ebp - 0x4b4]
or eax, 0xffffffff
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x42232b
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x42232b
call esi
push 0x250
lea eax, [ebp - 0x260]
push 0
push eax
call fcn.005a52f0
add esp, 0xc
lea ecx, [ebp - 0x260]
cmp dword [0x65caa8], 8
mov eax, 0x65ca94
cmovae eax, dword [0x65ca94]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
je 0x422386
push eax
call esi
cmp dword [ebp - 0x240], 0x500000
ja 0x42237f
cmp dword [ebp - 0x244], 0
je 0x422386
mov ecx, str.w__ccsUTF_8
jmp 0x42238b
mov ecx, str.a__ccsUTF_8
cmp dword [0x65caa8], 8
mov eax, 0x65ca94
push 0x40
cmovae eax, dword [0x65ca94]
push ecx
push eax
call fcn.005b3c42
add esp, 0xc
mov dword [0x65ca90], eax
test eax, eax
je 0x4223c1
push str._n_n
push eax
call fcn.00421b80
add esp, 8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00483ab6
mov esp, ebp
pop ebp
ret