joyce8/EMBER2024-capa huggingface dataset:
Function at 0x497dd0
Capabilities:
Get common file path
Set current directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x55cfc1
mov eax, dword fs:[0]
push eax
sub esp, 0x23c
mov eax, dword [0x5bf364]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
test esi, esi
je 0x497fba
cmp word [esi], 0
je 0x497fba
lea ecx, [ebp - 0x244]
call fcn.00405c90
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x228]
mov dword [ebp - 0x238], 0
test eax, eax
je 0x497e47
push eax
mov eax, dword [ebp - 0x234]
lea ecx, [ebp - 0x234]
call dword [eax + 0xc]
movzx eax, word [esi]
mov dword [ebp - 0x228], 0
mov dword [ebp - 0x220], 0
mov dword [ebp - 0x224], 0
cmp eax, 0x5c
je 0x497e80
test ax, ax
je 0x497eb2
cmp word [esi + 2], 0x3a
jne 0x497eb2
cmp word [esi + 4], 0x5c
jne 0x497eb2
push 0x5c
push esi
call fcn.0051078b
add esp, 8
test eax, eax
je 0x497eb2
cmp eax, esi
jbe 0x497e9e
cmp word [eax - 2], 0x3a
lea ecx, [eax - 2]
cmovne eax, ecx
sub eax, esi
lea ecx, [ebp - 0x244]
add eax, 2
sar eax, 1
push eax
push esi
call fcn.0049c620
mov edi, dword [ebp - 0x238]
test edi, edi
jne 0x497ed5
cmp dword [ebp - 0x220], edi
jne 0x497ecb
mov edi, 0x580994
jmp 0x497ed5
mov edi, dword [ebp - 0x228]
test edi, edi
je 0x497f20
cmp word [edi], 0
je 0x497f20
lea eax, [ebp - 0x218]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
test eax, eax
je 0x497f20
cmp word [edi], 0
je 0x497efe
push edi
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
cmp word [ebp - 0x218], 0
mov esi, eax
je 0x497f29
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
jmp 0x497f29
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov esi, eax
mov dword [ebp - 4], 1
lea eax, [ebp - 0x234]
mov dword [ebp - 0x248], eax
mov dword [ebp - method.CMStringArray.virtual_0], vtable.CVolMem.0
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x228]
test ecx, ecx
je 0x497f79
mov eax, dword [ebp - 0x234]
push ecx
mov eax, dword [eax + 0xc]
cmp eax, method.CMStringArray.virtual_12
jne 0x497f71
mov ecx, 0x5c6708
call fcn.0049a2e0
jmp 0x497f79
lea ecx, [ebp - 0x234]
call eax
mov dword [ebp - 0x228], 0
mov dword [ebp - 0x220], 0
mov dword [ebp - 0x224], 0
mov byte [ebp - 4], 1
mov dword [ebp - method.CMStringArray.virtual_0], vtable.CVolObject.0
mov dword [ebp - 4], 0xffffffff
mov eax, esi
mov dword [ebp - method.CMStringArray.virtual_0], vtable.CVolObject.0
jmp 0x497fbc
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0050ec8c
mov esp, ebp
pop ebp
ret
Function at 0x499a10
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
push esi
mov esi, ecx
test eax, eax
je 0x499adf
cmp word [eax], 0
je 0x499adf
push ebx
push edi
push 0x59390c
push eax
or ebx, 0xffffffff
call fcn.00522150
mov edi, eax
add esp, 8
test edi, edi
je 0x499ab2
push 2
push 0
push edi
call fcn.00521620
push edi
call fcn.00522c74
push 0
push 0
push edi
mov ebx, eax
call fcn.00521620
add esp, 0x1c
test ebx, ebx
jle 0x499aa2
push edi
push ebx
push 1
push ebx
mov ecx, esi
call fcn.00499280
push eax
call fcn.005224d0
push edi
mov ebx, eax
call fcn.00522cd0
add esp, 0x14
test eax, eax
jne 0x499aa6
push ebx
mov ecx, esi
call fcn.004992e0
push edi
call fcn.005212cd
add esp, 4
mov eax, ebx
pop edi
pop ebx
pop esi
pop ebp
ret 8
xor ebx, ebx
jmp 0x499aa9
or ebx, 0xffffffff
push edi
call fcn.005212cd
add esp, 4
mov ecx, dword [esi + 0xc]
test ecx, ecx
je 0x499ac1
mov edx, dword [esi]
push ecx
mov ecx, esi
call dword [edx + 0xc]
pop edi
mov eax, ebx
mov dword [esi + 0xc], 0
pop ebx
mov dword [esi + 0x14], 0
mov dword [esi + 0x10], 0
pop esi
pop ebp
ret 8
or eax, 0xffffffff
pop esi
pop ebp
ret 8

Function at 0x49a5c0
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x55d1ed
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
push edi
mov eax, dword [0x5bf364]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
lea esi, [ebx + 0x14]
push esi
mov dword [ebp - 0x10], esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov dword [ebp - 4], 0
push dword [ebx + 8]
mov edi, dword [sym.imp.KERNEL32.dll_ResetEvent]
mov dword [ebx + 0x2c], 0
mov dword [ebx + 0x30], 0
call edi
push dword [ebx + 0xc]
call edi
push dword [ebx + 0x10]
call edi
mov dword [ebp - 4], 0xffffffff
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
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 0x49a640
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, ecx
push edi
lea edi, [esi + 0x14]
push edi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esi + 0x38], 2
jne 0x49a6f1
mov eax, dword [ebp + 0x14]
push ebx
push dword [esi + 8]
mov ebx, dword [sym.imp.KERNEL32.dll_ResetEvent]
mov dword [esi + 4], eax
mov eax, dword [ebp + 0xc]
mov dword [esi + 0x3c], 0x491d50
mov dword [esi + 0x40], eax
mov dword [esi + 0x44], 0
mov dword [esi + 0x2c], 0
mov dword [esi + 0x30], 0
call ebx
push dword [esi + 0x10]
call ebx
push dword [esi + 0xc]
call dword [sym.imp.KERNEL32.dll_SetEvent]
push edi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
cmp dword [esi + 0x38], 2
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
jne 0x49a6bb
push 0xa
call edi
cmp dword [esi + 0x38], 2
je 0x49a6b1
push dword [esi + 8]
call ebx
push dword [esi + 0xc]
call ebx
push dword [esi + 0x10]
call dword [sym.imp.KERNEL32.dll_SetEvent]
cmp dword [esi + 0x38], 3
jne 0x49a6de
push 0xa
call edi
cmp dword [esi + 0x38], 3
je 0x49a6d4
push dword [esi + 0x10]
call ebx
pop ebx
pop edi
mov eax, 1
pop esi
mov esp, ebp
pop ebp
ret 0x10
push edi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
cmp dword [esi + 0x38], 1
je 0x49a742
mov ecx, esi
call fcn.0049a5c0
mov eax, dword [ebp + 0xc]
mov edi, dword [esi + 4]
mov dword [esi + 0x40], eax
mov eax, dword [ebp + 0x14]
mov dword [esi + 4], eax
lea eax, [ebp - 4]
push eax
push 0
push esi
push 0x49a780
push 0
push 0
mov dword [esi + 0x3c], 0x491d50
mov dword [esi + 0x44], 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
test eax, eax
jne 0x49a74c
mov dword [esi + 0x3c], eax
mov dword [esi + 4], edi
pop edi
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret 0x10
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [esi + 0x38], 0
jne 0x49a76a
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
nop
push 0xa
call edi
cmp dword [esi + 0x38], 0
je 0x49a760
pop edi
mov eax, 1
pop esi
mov esp, ebp
pop ebp
ret 0x10
Function at 0x4a1120
Capabilities:
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x55d9e0
mov eax, dword fs:[0]
push eax
sub esp, 0x228
mov eax, dword [0x5bf364]
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 eax, ecx
mov dword [ebp - 0x22c], eax
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x228], ecx
mov dword [ebp - 0x21c], 0
mov dword [ebp - 0x218], 0
mov dword [ebp - 0x214], 0
mov dword [ebp - 4], 0
lea edx, [ebp - 0x224]
mov edi, dword [eax + 4]
push edx
or edi, 0x2001f
mov dword [ebp - 0x224], 0
push edi
push 0
push ecx
push dword [eax]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, eax
test esi, esi
jne 0x4a12ab
mov eax, dword [ebp - 0x21c]
xor esi, esi
test eax, eax
je 0x4a11d5
push eax
call ebx
mov esi, eax
mov dword [ebp - 0x21c], 0
mov eax, dword [ebp - 0x224]
and edi, 0x300
mov dword [ebp - 0x218], 0
mov dword [ebp - 0x21c], eax
mov dword [ebp - 0x218], edi
test esi, esi
jne 0x4a12ab
mov edi, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
lea ecx, [ebp - 0x234]
push ecx
push esi
push esi
push esi
lea ecx, [ebp - 0x220]
mov dword [ebp - 0x220], 0x100
push ecx
lea ecx, [ebp - 0x210]
push ecx
push esi
push eax
call edi
test eax, eax
jne 0x4a1277
nop
lea eax, [ebp - 0x210]
push eax
lea ecx, [ebp - 0x21c]
call fcn.004a1120
mov esi, eax
test esi, esi
jne 0x4a12ab
lea eax, [ebp - 0x234]
mov dword [ebp - 0x220], 0x100
push eax
push esi
push esi
push esi
lea eax, [ebp - 0x220]
push eax
lea eax, [ebp - 0x210]
push eax
push esi
push dword [ebp - 0x21c]
call edi
test eax, eax
je 0x4a1230
mov eax, dword [ebp - 0x21c]
test eax, eax
je 0x4a128e
push eax
call ebx
mov dword [ebp - 0x21c], 0
push dword [ebp - 0x228]
mov ecx, dword [ebp - 0x22c]
mov dword [ebp - 0x218], 0
call fcn.004a1040
mov esi, eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x21c]
test eax, eax
je 0x4a12c9
push eax
call ebx
mov dword [ebp - 0x21c], 0
mov eax, esi
mov dword [ebp - 0x218], 0
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.0050ec8c
mov esp, ebp
pop ebp
ret 4
Function at 0x4a1920
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x55db4b
mov eax, dword fs:[0]
push eax
sub esp, 0x42c
mov eax, dword [0x5bf364]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov edi, dword [ebp + 8]
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x420], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x41c], eax
mov dword [ebp - 0x430], 0
mov dword [ebp - 4], 0
mov dword [ebp - 0x428], ecx
mov dword [ebp - 0x42c], 0
mov dword [ebp - 0x418], 0
mov byte [ebp - 4], 1
push 0x60
push 0
push edi
mov ebx, dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
call ebx
mov esi, eax
mov dword [ebp - 0x424], esi
test esi, esi
jne 0x4a19cc
push 2
push eax
push edi
call ebx
mov esi, eax
mov dword [ebp - 0x424], eax
test esi, esi
jne 0x4a19cc
call fcn.004a0dc0
mov edi, eax
jmp 0x4a1b01
push dword [ebp - 0x41c]
push dword [ebp - 0x420]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov edi, eax
test edi, edi
jne 0x4a19ef
call fcn.004a0dc0
jmp 0x4a1af4
push edi
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, eax
mov dword [ebp - 0x420], ebx
test ebx, ebx
jne 0x4a1a0d
call fcn.004a0dc0
jmp 0x4a1af4
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov edi, eax
mov dword [ebp - 0x41c], edi
lea eax, [edi + 1]
cmp eax, edi
jae 0x4a1a2e
mov edi, 0x8007000e
jmp 0x4a1af6
mov byte [ebp - 4], 2
mov ecx, 2
mul ecx
mov dword [ebp - 0x438], eax
mov dword [ebp - 0x434], edx
test edx, edx
ja 0x4a1b45
jb 0x4a1a58
cmp eax, 0xffffffff
ja 0x4a1b45
cmp eax, 0x400
jbe 0x4a1a74
push eax
lea ecx, [ebp - 0x418]
call fcn.004a3fc0
mov dword [ebp - 4], 1
jmp 0x4a1aa8
lea eax, [ebp - 0x414]
mov dword [ebp - 0x418], eax
mov dword [ebp - 4], 1
jmp 0x4a1aa8
mov eax, dword [ebp - 0x418]
test eax, eax
jne 0x4a1ab9
mov edi, 0x8007000e
jmp 0x4a1af6
push edi
push eax
push edi
push ebx
push 0
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ecx, eax
test ecx, ecx
jne 0x4a1ad4
call fcn.004a0dc0
jmp 0x4a1af4
xor edx, edx
mov eax, dword [ebp - 0x418]
mov word [eax + ecx*2], dx
push dword [ebp + 0x14]
push dword [ebp - 0x418]
lea ecx, [ebp - 0x42c]
call fcn.004a2750
mov edi, eax
test esi, esi
je 0x4a1b01
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov byte [ebp - 4], 0
lea eax, [ebp - 0x414]
cmp dword [ebp - 0x418], eax
je 0x4a1b1e
lea ecx, [ebp - 0x418]
call fcn.004a3fb0
mov dword [ebp - 4], 0xffffffff
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 - 0x14]
xor ecx, ebp
call fcn.0050ec8c
mov esp, ebp
pop ebp
ret 0x10
push 0x80070216
call fcn.0044f360
int3
Function at 0x4a6170
Capabilities:
Access peb ldr_data
Get ntdll base address

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x55e349
mov eax, dword fs:[0]
push eax
sub esp, 8
mov eax, dword [0x5bf364]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], ecx
lea eax, [ecx + 8]
mov dword [ecx + 4], 0
mov dword [ebp - 0x14], eax
mov dword [eax + 0xc], 0
mov dword [ebp - 4], 1
mov dword [ecx + 0x18], 0
mov dword [ecx + 0x1c], 0
mov dword [ebp - 4], 2
mov eax, dword [sym.imp.USER32.dll_DefWindowProcW]
mov dword [ecx + 0x20], eax
mov dword [ebp - 4], 4
mov dword [ecx], vtable.CVWnd_Container.0
mov dword [ecx + 0x24], 0
mov dword [ecx + 0x28], 0xffffffff
mov dword [ecx + 0x2c], vtable.CVolWindowProcFilters.0
mov dword [ecx + 0x30], 0
mov byte [ebp - 4], 5
mov dword [ecx + 0x48], 0
mov byte [ebp - 4], 6
mov dword [ecx + 0x38], 0xff000000
mov dword [ecx + 0x3c], 0
mov dword [ecx + 0x40], 1
mov dword [ecx + 0x4c], 0
mov dword [ecx + 0x44], 0
mov dword [ebp - 4], 0xffffffff
mov eax, ecx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov esp, ebp
pop ebp
ret
Function at 0x508b39
Capabilities:
Set file attributes

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
cmp dword [eax + 0x10], 0
jne 0x508b49
xor al, al
pop ebp
ret
cmp dword [eax + 0x14], 8
jb 0x508b51
mov eax, dword [eax]
push dword [ebp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
setne al
pop ebp
ret

Function at 0x519b42
Capabilities:
Parse pe header

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

Function at 0x51faf7
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 + 0x5c5c30]
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 0x51fb37
cmp byte [ebx], 0xa
jne 0x51fb37
or byte [edi + eax + 0x28], 4
jmp 0x51fb3c
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 0x51fc3b
mov dl, byte [eax]
cmp dl, 0x1a
je 0x51fc1e
inc eax
cmp dl, 0xd
je 0x51fb68
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x51fb8e
cmp eax, ecx
jae 0x51fb9c
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 0x51fb50
jmp 0x51fc3b
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 0x51fc19
cmp dword [ebp - 0x10], 0
je 0x51fc19
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x5c5c30]
test byte [eax + edi + 0x28], 0x48
je 0x51fbf3
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x51fbde
mov byte [esi], dl
jmp 0x51fbef
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x5c5c30]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x51fc3b
cmp byte [ebp - 1], 0xa
jne 0x51fc02
cmp esi, ebx
jne 0x51fc02
mov byte [esi], 0xa
jmp 0x51fc3a
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.00520adf
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x51fc3b
mov byte [esi], 0xd
jmp 0x51fc3a
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x5c5c30]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x51fc38
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x51fc3b
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x51fc44
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 + 0x5c5c30]
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 0x51fc8a
cmp word [ebx], dx
jne 0x51fc8a
or byte [eax + edi + 0x28], 4
jmp 0x51fc8f
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 0x51fdf2
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 0x51fdd2
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x51fcd0
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x51fd06
cmp eax, edx
jae 0x51fd14
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 0x51fcab
jmp 0x51fdf2
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 0x51fdcd
cmp dword [ebp - 0x18], 0
je 0x51fdcd
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x5c5c30]
test byte [eax + edi + 0x28], 0x48
je 0x51fda3
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 0x51fd67
mov word [esi], cx
jmp 0x51fd9e
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x5c5c30]
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 + 0x5c5c30]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x5c5c30]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x51fdf2
pop eax
cmp word [ebp - 4], ax
jne 0x51fdb3
cmp esi, ebx
jne 0x51fdb3
mov word [esi], ax
jmp 0x51fdef
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.00520adf
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x51fdf2
push 0xd
pop eax
jmp 0x51fdae
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x5c5c30]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x51fdec
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x51fdf2
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 0x522a37
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.0050f7f0
mov eax, dword [0x5bf364]
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.0052eddc
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x522a79
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x522bd5
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.0050f740
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 + 0x5c5c30]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.00520ac1
mov ecx, dword [esi*4 + 0x5c5c30]
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 0x522bce
cmp eax, dword [ecx + edi + 0x24]
jne 0x522bce
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 0x522bce
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.00520ac1
add esp, 0x14
test edx, edx
jl 0x522bce
jg 0x522b44
test eax, eax
jb 0x522bce
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x522bce
jl 0x522b5e
cmp dword [ebp - 0x1008], eax
ja 0x522bce
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x522b7c
test ebx, ebx
je 0x522bb5
cmp ecx, edi
jae 0x522bb5
mov al, byte [ecx]
cmp al, 0xd
jne 0x522b96
lea eax, [edi - 1]
cmp ecx, eax
jae 0x522ba2
cmp byte [ecx + 1], 0xa
jne 0x522ba2
inc ecx
jmp 0x522ba2
movzx eax, al
movsx eax, byte [eax + 0x5bf4c8]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x522b7c
cmp edx, ebx
jne 0x522b7c
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x522bd3
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.0050ec8c
leave
ret
Function at 0x5262f8
Capabilities:
Get disk information

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x5bf364]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
push 0x575dd4
push esi
call fcn.00530ec5
pop ecx
pop ecx
test eax, eax
jne 0x526326
xor al, al
jmp 0x5263a3
push ebx
lea eax, [ebp - 0x210]
xor ebx, ebx
push eax
push 0x104
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x210], ebx
push esi
push eax
call fcn.0052602d
mov edx, eax
add esp, 0x10
test edx, edx
jne 0x526360
push dword [ebp - 0x210]
call fcn.00513d93
xor al, al
jmp 0x5263a1
mov ecx, edx
push edi
lea edi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, bx
jne 0x526366
sub ecx, edi
sar ecx, 1
pop edi
cmp ecx, 3
je 0x526386
push edx
call fcn.0052622f
pop ecx
test al, al
je 0x526351
push esi
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 1
jbe 0x526394
mov bl, 1
push dword [ebp - 0x210]
call fcn.00513d93
mov al, bl
pop ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.0050ec8c
leave
ret

Function at 0x527d1f
Capabilities:
Get disk information

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x5bf364]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
cmp eax, 0x1a
jbe 0x527d62
call fcn.00519dc5
mov dword [eax], 0xf
call fcn.00519dd8
mov dword [eax], 0xd
call fcn.0051935e
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0050ec8c
leave
ret
test eax, eax
jne 0x527d69
inc eax
jmp 0x527d56
add eax, 0x40
push 0x3a
mov word [ebp - 0xc], ax
pop eax
mov word [ebp - 0xa], ax
push 0x5c
pop eax
mov word [ebp - 8], ax
xor eax, eax
mov word [ebp - 6], ax
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
mov ecx, eax
test ecx, ecx
je 0x527d54
xor eax, eax
cmp ecx, 1
setne al
jmp 0x527d56
Function at 0x52cff9
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x5779b8
push 0x5779b0
push str.FlsAlloc
push 0x1f
call fcn.0052ce24
mov esi, eax
add esp, 0x10
test esi, esi
je 0x52d02d
push dword [ebp + 8]
mov ecx, esi
call dword [0x5647a8]
call esi
jmp 0x52d033
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x52d077
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x5779c8
push 0x5779c0
push str.FlsGetValue
push 0x21
call fcn.0052ce24
mov esi, eax
add esp, 0x10
test esi, esi
je 0x52d0ae
push dword [ebp + 8]
mov ecx, esi
call dword [0x5647a8]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x52d0b6
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x5779d0
push 0x5779c8
push str.FlsSetValue
push 0x22
call fcn.0052ce24
mov esi, eax
add esp, 0x10
test esi, esi
je 0x52d0f0
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x5647a8]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]