joyce8/EMBER2024-capa huggingface dataset:
Function at 0x412e6f
Capabilities:
Create process on windows
Query or enumerate registry value

Disassembly:
push 0x46c
mov eax, 0x46b380
call fcn.004437b0
lea eax, [ebp - 0x430]
push eax
lea eax, [ebp - 0x428]
push eax
lea eax, [ebp - 0x42c]
push eax
push str.IsInstalled
push str.SOFTWAREMicrosoftActive_SetupInstalled_ComponentsEF289A85_8E57_408d_BE47_73B55609861A
xor edi, edi
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [ebp - 0x42c], edi
mov dword [ebp - 0x428], edi
mov dword [ebp - 0x430], 4
call dword [sym.imp.SHLWAPI.dll_SHGetValueW]
cmp dword [ebp - 0x428], edi
je 0x412ed1
xor eax, eax
inc eax
call fcn.00443833
ret
mov dword [ebp - method.CResourceUnpack.virtual_0], vtable.CResourceUnpack.0
mov dword [ebp - 0x438], edi
mov dword [ebp - 0x434], edi
push str.ROOTSUPD
push 0x104
push edi
lea esi, [ebp - 0x43c]
mov dword [ebp - 4], edi
call fcn.0040b6af
test eax, eax
jne 0x412f08
xor eax, eax
jmp 0x412ecb
mov ecx, 0x485f6c
lea esi, [ebp - 0x424]
call fcn.00402b4a
push 1
mov eax, esi
push eax
lea eax, [ebp - 0x43c]
push eax
mov byte [ebp - 4], 1
call fcn.0040b871
test eax, eax
jne 0x412f41
mov eax, dword [ebp - 0x424]
add eax, 0xfffffff0
call fcn.004031f6
jmp 0x412f04
xor eax, eax
push 0x40e
mov word [ebp - 0x420], ax
lea eax, [ebp - 0x41e]
push edi
push eax
call fcn.0043e1d0
mov esi, dword [ebp - 0x424]
add esp, 0xc
push str.rootsupd.exe
push esi
lea eax, [ebp - 0x420]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
test eax, eax
jne 0x412f8b
lea eax, [esi - 0x10]
call fcn.004031f6
mov eax, edi
jmp 0x412ecb
push 0x38
lea eax, [ebp - 0x474]
push edi
push eax
call fcn.0043e1d0
lea eax, [ebp - 0x420]
mov dword [ebp - 0x468], eax
add esp, 0xc
lea eax, [ebp - 0x478]
push eax
mov dword [ebp - 0x478], 0x3c
mov dword [ebp - 0x474], 0x440
mov dword [ebp - 0x46c], 0x4769f0
mov dword [ebp - 0x464], 0x4769e0
mov dword [ebp - 0x45c], edi
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
je 0x412f7c
cmp dword [ebp - 0x458], 0x20
jle 0x412f7c
xor edi, edi
inc edi
jmp 0x412f7c

Function at 0x413dbc
Capabilities:
Set file attributes

Disassembly:
push dword [esp + 8]
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
setne al
ret

Function at 0x414352
Capabilities:
Get common file path

Disassembly:
mov eax, dword [esp + 0xc]
push esi
mov ecx, 0x105
call fcn.00414507
push eax
push 0
push dword [esp + 0x14]
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
mov edx, dword [esp + 0x10]
mov esi, eax
call fcn.00414523
mov eax, esi
pop esi
ret

Function at 0x414b4a
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
push edi
lea eax, [ebp + 8]
push eax
mov eax, dword [ebp + 8]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
cmp edi, 0xffffffff
jne 0x414b72
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x414b72
xor al, al
jmp 0x414b8d
push 1
push 0
push 0
push dword [ebp + 8]
call fcn.0045cc30
xor ecx, ecx
add eax, edi
adc edx, ecx
mov dword [esi], eax
mov dword [esi + 4], edx
mov al, 1
pop edi
pop ebp
ret 4
Function at 0x41c196
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x483260]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, 0x207
push esi
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
test eax, eax
je 0x41c22d
cmp eax, esi
ja 0x41c22d
lea eax, [ebp - 0x20c]
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
test cx, cx
jne 0x41c1ce
sub eax, edx
sar eax, 1
cmp word [ebp + eax*2 - 0x20e], 0x5c
je 0x41c202
push edi
lea edi, [ebp - 0x20c]
dec edi
dec edi
mov ax, word [edi + 2]
inc edi
inc edi
test ax, ax
jne 0x41c1f0
mov esi, 0x474fcc
movsd dword es:[edi], dword [esi]
pop edi
push str.wininit.ini
lea eax, [ebp - 0x20c]
push eax
push str._s_s
push 0x208
push ebx
call fcn.0043f423
xor eax, eax
add esp, 0x14
mov word [ebx + 0x40e], ax
inc eax
jmp 0x41c22f
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.0043b155
leave
ret

Function at 0x41c442
Capabilities:
Delete file
Move file

Disassembly:
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp eax, 1
jne 0x41c451
xor eax, eax
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
je 0x41c465
cmp eax, 0x20
je 0x41c465
xor eax, eax
inc eax
ret
xor eax, eax
cmp dword [0x4881b8], eax
je 0x41c483
push eax
push esi
call fcn.0041c23c
pop ecx
pop ecx
xor ecx, ecx
test eax, eax
setne cl
inc ecx
mov eax, ecx
ret
push 4
push eax
push esi
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
push 2
pop eax
ret
Function at 0x41c491
Capabilities:
Delete file

Disassembly:
push ebp
lea ebp, [esp - 0x1604]
mov eax, 0x1684
call fcn.0045fdc0
mov eax, dword [0x483260]
xor eax, ebp
mov dword [ebp + 0x1600], eax
mov eax, dword [ebp + 0x160c]
push ebx
push esi
mov dword [ebp - 0x60], eax
mov esi, ecx
xor ebx, ebx
xor eax, eax
cmp esi, ebx
je 0x41c5d2
push edi
push 0x144e
mov word [ebp - 0x58], ax
lea eax, [ebp - 0x56]
push ebx
push eax
call fcn.0043e1d0
lea eax, [ebp - 0x5c]
push eax
push esi
mov dword [ebp - 0x5c], 0x7c
call fcn.00441d0b
mov esi, eax
add esp, 0x14
cmp esi, ebx
je 0x41c59a
xor eax, eax
push 0x206
push eax
mov word [ebp + 0x13f8], ax
lea eax, [ebp + 0x13fa]
push eax
call fcn.0043e1d0
push esi
push dword [ebp - 0x60]
lea eax, [ebp + 0x13f8]
push 0x477d6c
push 0x103
push eax
call fcn.0043f423
lea eax, [ebp + 0x13f8]
add esp, 0x20
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
test cx, cx
jne 0x41c53c
sub eax, edx
lea ecx, [ebp + 0x13f8]
sar eax, 1
mov esi, ecx
mov dx, word [ecx]
inc ecx
inc ecx
test dx, dx
jne 0x41c552
sub ecx, esi
lea edi, [ebp + ebx*2 - 0x58]
dec edi
mov edx, ecx
dec edi
mov cx, word [edi + 2]
inc edi
inc edi
test cx, cx
jne 0x41c566
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
lea ebx, [ebx + eax + 1]
lea eax, [ebp - 0x5c]
mov ecx, edx
push eax
and ecx, 3
push 0
rep movsb byte es:[edi], byte [esi]
call fcn.00441d0b
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x41c4fb
xor eax, eax
push 7
pop ecx
lea edi, [ebp - 0x80]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
xor eax, eax
mov dword [ebp - 0x6a], eax
mov dword [ebp - 0x80], eax
mov dword [ebp - 0x66], eax
lea eax, [ebp - 0x58]
mov dword [ebp - 0x78], eax
mov eax, 0x454
mov word [ebp - 0x70], ax
lea eax, [ebp - 0x80]
push eax
mov dword [ebp - 0x7c], 3
call dword [sym.imp.SHELL32.dll_SHFileOperationW]
pop edi
mov ecx, dword [ebp + 0x1600]
pop esi
xor ecx, ebp
pop ebx
call fcn.0043b155
add ebp, 0x1604
leave
ret

Function at 0x41c9e1
Capabilities:
Get common file path
Get program files directory

Disassembly:
xor eax, eax
push ebx
mov ebx, 0x4895f8
cmp ax, word [0x4895f8]
jne 0x41ca1a
push esi
push edi
push eax
push 0x26
push ebx
push eax
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
mov edi, ebx
dec edi
dec edi
mov ax, word [edi + 2]
inc edi
inc edi
test ax, ax
jne 0x41ca03
push 0x10
pop ecx
mov esi, str.internet_exploreriexplore.exe
rep movsd dword es:[edi], dword [esi]
pop edi
pop esi
mov eax, ebx
pop ebx
ret
Function at 0x41d033
Capabilities:
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push edi
xor edi, edi
xor ebx, ebx
mov dword [ebp - 4], edi
cmp dword [ebp + 0xc], edi
je 0x41d12a
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
lea eax, [ebp - 4]
push eax
push 0x40000
push edi
push dword [ebp + 0xc]
push dword [ebp + 8]
call esi
test eax, eax
jne 0x41d11b
push dword [ebp + 0x10]
push 4
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegSetKeySecurity]
test eax, eax
jne 0x41d11b
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 4]
push eax
push 0x20019
push edi
push dword [ebp + 0xc]
mov dword [ebp - 4], edi
push dword [ebp + 8]
call esi
test eax, eax
jne 0x41d11b
push edi
push edi
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x14]
push eax
push edi
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 8]
push eax
push edi
push edi
push edi
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyW]
test eax, eax
jne 0x41d11b
push 0x20a
call fcn.0043afbf
pop ecx
mov esi, eax
cmp dword [ebp - 8], edi
jbe 0x41d111
push 0x105
push esi
push ebx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
cmp eax, edi
jne 0x41d104
push 1
push dword [ebp + 0x10]
push esi
push dword [ebp - 4]
call fcn.0041d033
add esp, 0x10
jmp 0x41d10b
cmp eax, 0x103
je 0x41d111
inc ebx
cmp ebx, dword [ebp - 8]
jb 0x41d0dd
push esi
call fcn.0043e082
xor ebx, ebx
pop ecx
inc ebx
pop esi
cmp dword [ebp - 4], edi
je 0x41d12a
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
mov eax, ebx
pop ebx
leave
ret
Function at 0x41dd07
Capabilities:
Get file size
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x2714]
mov eax, 0x2714
call fcn.0045fdc0
push 0xffffffffffffffff
push 0x46b22e
mov eax, dword fs:[0]
push eax
sub esp, 0xc
mov eax, dword [0x483260]
xor eax, ebp
mov dword [ebp + 0x2710], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0x271c]
mov ebx, ecx
mov ecx, 0x485f6c
lea esi, [ebp - 0x14]
mov dword [ebp - 0x10], eax
call fcn.00402b4a
mov esi, 0x2710
xor edi, edi
push esi
lea eax, [ebp]
push edi
push eax
mov dword [ebp - 4], edi
call fcn.0043e1d0
add esp, 0xc
push ebx
lea eax, [ebp - 0x14]
push eax
call fcn.00402c33
lea eax, [ebp - 0x14]
call fcn.0041ef53
push dword [ebp - 0x10]
lea eax, [ebp - 0x14]
push eax
call fcn.0040bcbf
push edi
push 0x80
push 3
push edi
push 3
push 0x40000000
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x10], eax
cmp eax, 0xffffffff
jne 0x41dde3
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
call fcn.004031f6
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 + 0x2710]
xor ecx, ebp
call fcn.0043b155
add ebp, 0x2714
leave
ret
push edi
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push edi
push edi
push 0x40
push dword [ebp - 0x10]
mov ebx, eax
sub ebx, 0x40
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp ebx, edi
jbe 0x41de29
lea eax, [ebp - 0x18]
push edi
push eax
lea eax, [ebp]
cmp ebx, esi
jbe 0x41de1e
push esi
push eax
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_WriteFile]
sub ebx, esi
jne 0x41de01
jmp 0x41de29
push ebx
push eax
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor edi, edi
inc edi
jmp 0x41ddb3

Function at 0x41df9a
Capabilities:
Get file version info

Disassembly:
push ebp
lea ebp, [esp - 0x3f90]
mov eax, 0x4010
call fcn.0045fdc0
mov eax, dword [0x483260]
xor eax, ebp
mov dword [ebp + 0x3f8c], eax
xor eax, eax
push 0x3ffe
push eax
mov word [ebp - 0x74], ax
lea eax, [ebp - 0x72]
push eax
call fcn.0043e1d0
add esp, 0xc
lea eax, [ebp - 0x7c]
push eax
push esi
call sub.VERSION.dll_GetFileVersionInfoSizeW
test eax, eax
je 0x41e041
cmp eax, 0x3fff
ja 0x41e041
lea ecx, [ebp - 0x74]
push ecx
push eax
push 0
push esi
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
je 0x41e041
lea eax, [ebp - 0x80]
push eax
lea eax, [ebp - 0x78]
push eax
push 0x474fcc
lea eax, [ebp - 0x74]
push eax
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x41e041
mov eax, dword [ebp - 0x78]
movzx ecx, word [eax + 0xc]
push ecx
movzx ecx, word [eax + 0xe]
push ecx
movzx ecx, word [eax + 8]
movzx eax, word [eax + 0xa]
push ecx
push eax
push str._d._d._d._d
push ebx
push edi
call fcn.0043f423
xor eax, eax
add esp, 0x1c
mov word [edi + ebx*2 - 2], ax
inc eax
jmp 0x41e043
xor eax, eax
mov ecx, dword [ebp + 0x3f8c]
xor ecx, ebp
call fcn.0043b155
add ebp, 0x3f90
leave
ret
Function at 0x41e235
Capabilities:
Create directory

Disassembly:
push ebp
lea ebp, [esp - 0x398]
sub esp, 0x418
mov eax, dword [0x483260]
xor eax, ebp
mov dword [ebp + 0x394], eax
push ebx
call dword [sym.imp.SHLWAPI.dll_PathIsRootW]
test eax, eax
je 0x41e263
xor eax, eax
inc eax
jmp 0x41e305
and dword [ebp - 0x80], 0
mov eax, ebx
push esi
mov esi, ebx
lea ecx, [eax + 2]
mov dx, word [eax]
inc eax
inc eax
test dx, dx
jne 0x41e26f
sub eax, ecx
sar eax, 1
cmp eax, 0x104
jbe 0x41e288
xor eax, eax
jmp 0x41e304
xor eax, eax
push edi
cmp ax, word [ebx]
je 0x41e300
push 0x474fcc
push esi
call fcn.0043f7f8
mov edi, eax
pop ecx
pop ecx
test edi, edi
jne 0x41e2b6
push 0x477f38
push esi
call fcn.0043f7f8
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x41e300
mov esi, edi
sub esi, ebx
sar esi, 1
test esi, esi
jle 0x41e2f6
push 0x410
lea eax, [ebp - 0x7c]
push 0
push eax
call fcn.0043e1d0
push esi
lea eax, [ebp - 0x7c]
push ebx
push eax
call fcn.0043e95d
add esp, 0x18
push 0
lea eax, [ebp - 0x7c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x41e2f3
call fcn.0041e224
mov dword [ebp - 0x80], eax
lea esi, [edi + 2]
xor eax, eax
cmp ax, word [esi]
jne 0x41e290
mov eax, dword [ebp - 0x80]
pop edi
pop esi
mov ecx, dword [ebp + 0x394]
xor ecx, ebp
call fcn.0043b155
add ebp, 0x398
leave
ret
Function at 0x41ed3a
Capabilities:
Check if file exists

Disassembly:
push ebp
lea ebp, [esp - 0x7fc]
sub esp, 0x87c
mov eax, dword [0x483260]
xor eax, ebp
mov dword [ebp + 0x7f8], eax
mov eax, dword [ebp + 0x808]
push esi
mov dword [ebp - 0x7c], eax
mov eax, dword [ebp + 0x80c]
push edi
mov edi, dword [ebp + 0x804]
mov dword [ebp - 0x78], eax
xor eax, eax
mov esi, 0x206
push esi
push eax
mov word [ebp + 0x1e0], ax
lea eax, [ebp + 0x1e2]
push eax
mov dword [ebp - 0x80], edi
call fcn.0043e1d0
add esp, 0xc
push dword [ebp - 0x7c]
lea eax, [ebp + 0x1e0]
push edi
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea eax, [ebp + 0x1e0]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x41edd4
mov eax, dword [ebp + 0x810]
push edi
push 0x475100
dec eax
push eax
push dword [ebp - 0x78]
call fcn.0043f423
add esp, 0x10
xor eax, eax
inc eax
jmp 0x41ef0e
xor eax, eax
push esi
push eax
mov word [ebp + 0x3e8], ax
lea eax, [ebp + 0x3ea]
push eax
call fcn.0043e1d0
push edi
push str._s.
mov edi, 0x103
lea eax, [ebp + 0x3e8]
push edi
push eax
call fcn.0043f423
add esp, 0x1c
lea eax, [ebp - 0x70]
push eax
lea eax, [ebp + 0x3e8]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x74], eax
cmp eax, 0xffffffff
je 0x41ef0c
cmp dword [ebp - 0x70], 0x10
jne 0x41eeee
mov ecx, 0x4768b0
lea eax, [ebp - 0x44]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x41ee5b
test dx, dx
je 0x41ee57
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x41ee5b
add eax, 4
add ecx, 4
test dx, dx
jne 0x41ee35
xor eax, eax
jmp 0x41ee60
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x41eeee
mov ecx, 0x476048
lea eax, [ebp - 0x44]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x41ee96
test dx, dx
je 0x41ee92
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x41ee96
add eax, 4
add ecx, 4
test dx, dx
jne 0x41ee70
xor eax, eax
jmp 0x41ee9b
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x41eeee
xor eax, eax
push esi
push eax
mov word [ebp + 0x5f0], ax
lea eax, [ebp + 0x5f2]
push eax
call fcn.0043e1d0
lea eax, [ebp - 0x44]
push eax
push dword [ebp - 0x80]
lea eax, [ebp + 0x5f0]
push str._s_s_
push edi
push eax
call fcn.0043f423
push dword [ebp + 0x810]
lea eax, [ebp + 0x5f0]
push dword [ebp - 0x78]
push dword [ebp - 0x7c]
push eax
call fcn.0041ed3a
add esp, 0x30
test eax, eax
jne 0x41ef25
lea eax, [ebp - 0x70]
push eax
push dword [ebp - 0x74]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x41ee23
push dword [ebp - 0x74]
call dword [sym.imp.KERNEL32.dll_FindClose]
xor eax, eax
mov ecx, dword [ebp + 0x7f8]
pop edi
xor ecx, ebp
pop esi
call fcn.0043b155
add ebp, 0x7fc
leave
ret
push dword [ebp - 0x74]
call dword [sym.imp.KERNEL32.dll_FindClose]
jmp 0x41edcc
Function at 0x42a790
Capabilities:
Write file on windows

Disassembly:
push ecx
push 0
lea eax, [esp + 4]
push eax
push esi
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x42a7bb
push 0x474f2c
mov eax, 0x474f2c
call fcn.0042f3a0
add esp, 4
xor eax, eax
pop ecx
ret
mov eax, 1
cmp esi, dword [esp]
je 0x42a7d4
push 0x474f2c
call fcn.0042f650
add esp, 4
xor eax, eax
pop ecx
ret

Function at 0x42a850
Capabilities:
Clear file content

Disassembly:
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x42a870
push 0x474f2c
mov eax, 0x474f2c
call fcn.0042f3a0
add esp, 4
xor eax, eax
ret
mov eax, 1
ret

Function at 0x42a880
Capabilities:
Get file size
Read file on windows
Write file on windows

Disassembly:
mov ecx, dword [esp + 4]
sub esp, 0x20
push ebx
push ebp
push esi
push edi
lea eax, [esp + 0x28]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x42a8b7
push 0x474f2c
mov eax, 0x474f2c
call fcn.0042f3a0
add esp, 4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x20
ret
mov esi, dword [esp + 0x3c]
mov edi, dword [esp + 0x2c]
cmp esi, edi
ja 0x42a9de
mov ecx, dword [esp + 0x38]
mov edx, dword [esp + 0x28]
jb 0x42a8d9
cmp ecx, edx
jae 0x42a9de
mov eax, edx
sub eax, ecx
mov ecx, edi
sbb ecx, esi
mov ebx, eax
shrd ebx, ecx, 0xf
shr ecx, 0xf
and eax, 0x7fff
mov dword [esp + 0x10], ebx
mov esi, eax
jne 0x42a8fe
mov esi, 0x8000
jmp 0x42a903
inc ebx
mov dword [esp + 0x10], ebx
xor eax, eax
sub edx, esi
sbb edi, eax
mov eax, dword [esp + 0x40]
mov ebp, edi
xor edi, edi
mov ebx, edx
add eax, ebx
adc edi, ebp
cmp dword [esp + 0x10], 0
mov dword [esp + 0x20], eax
mov dword [esp + 0x14], 0
jbe 0x42a9de
mov edi, edi
mov ecx, dword [esp + 0x34]
push 0
push 0
push ebp
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x42a89b
mov eax, dword [esp + 0x44]
mov ecx, dword [esp + 0x34]
push 0
lea edx, [esp + 0x1c]
push edx
push esi
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x42a89b
cmp esi, dword [esp + 0x18]
jne 0x42a9eb
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x34]
push 0
push 0
push edi
push edx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x42a89b
mov edx, dword [esp + 0x44]
mov eax, dword [esp + 0x34]
push 0
lea ecx, [esp + 0x20]
push ecx
push esi
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x42a89b
cmp esi, dword [esp + 0x1c]
jne 0x42a9eb
mov eax, dword [esp + 0x14]
add ebx, 0xffff8000
adc ebp, 0xffffffff
add dword [esp + 0x20], 0xffff8000
mov esi, 0x8000
adc edi, 0xffffffff
inc eax
mov dword [esp + 0x14], eax
cmp eax, dword [esp + 0x10]
jb 0x42a930
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x20
ret
push 0x474f2c
mov eax, 1
call fcn.0042f650
add esp, 4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x20
ret
Function at 0x42abc0
Capabilities:
Write file on windows

Disassembly:
push ecx
mov ecx, dword [esp + 8]
push ebp
mov ebp, dword [esp + 0x10]
push esi
push edi
mov edi, eax
mov eax, dword [esp + 0x20]
lea esi, [edi + 7]
shr esi, 3
add esi, esi
push eax
add esi, esi
add esi, esi
push esi
push ebp
push ecx
push ebx
call fcn.0042a880
add esp, 0x14
test eax, eax
je 0x42ac94
mov edx, dword [esp + 0x14]
push 0
push 0
push ebp
push edx
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x42ac6c
mov ecx, dword [esp + 0x1c]
push 0
lea eax, [esp + 0x10]
push eax
push edi
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x42ac6c
cmp edi, dword [esp + 0xc]
je 0x42ac3f
push 0x474f2c
mov eax, 1
call fcn.0042f650
add esp, 4
pop edi
pop esi
xor eax, eax
pop ebp
pop ecx
ret
sub esi, edi
je 0x42ac9b
mov edx, dword [esp + 0x20]
push esi
push 0
push edx
call fcn.0043e1d0
add esp, 0xc
xor eax, eax
add edi, dword [esp + 0x14]
push 0
push 0
adc eax, ebp
push eax
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
jne 0x42ac85
push 0x474f2c
mov eax, 0x474f2c
call fcn.0042f3a0
add esp, 4
pop edi
pop esi
xor eax, eax
pop ebp
pop ecx
ret
mov ecx, dword [esp + 0x20]
mov edx, ebx
call fcn.0042a790
test eax, eax
jne 0x42ac9b
pop edi
pop esi
xor eax, eax
pop ebp
pop ecx
ret
pop edi
pop esi
mov eax, 1
pop ebp
pop ecx
ret
Function at 0x42bc80
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x10
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
push ebp
push esi
push edi
mov edi, eax
mov eax, dword [edi + 0x10]
mov esi, dword [edi]
mov dword [esp + 0x1c], ecx
xor ecx, ecx
push ecx
push ecx
mov dword [esp + 0x20], eax
mov eax, dword [edi + 8]
push ecx
push eax
push esi
call ebx
test eax, eax
jne 0x42bcc8
push 0x474f2c
mov eax, 0x474f2c
call fcn.0042f3a0
add esp, 4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x10
ret
mov ebp, dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea edx, [esp + 0x14]
push edx
push 8
lea eax, [esp + 0x24]
push eax
push esi
call ebp
test eax, eax
je 0x42bcac
cmp dword [esp + 0x10], 8
jne 0x42bd2d
lea ecx, [esp + 0x14]
push ecx
lea ecx, [esp + 0x14]
mov eax, edi
call fcn.0042cae0
add esp, 4
test eax, eax
je 0x42bd3f
mov edi, dword [edi + 4]
xor eax, eax
push eax
push eax
push eax
push edi
push esi
call ebx
test eax, eax
je 0x42bcac
push 0
lea edx, [esp + 0x14]
push edx
push 4
lea eax, [esp + 0x20]
push eax
push esi
call ebp
test eax, eax
je 0x42bcac
cmp dword [esp + 0x10], 4
je 0x42bd49
push 0x474f2c
mov eax, 1
call fcn.0042f650
add esp, 4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x10
ret
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x10
ret

Function at 0x42c400
Capabilities:
Get file size

Disassembly:
sub esp, 8
push ebx
push ebp
push esi
push edi
mov esi, eax
mov eax, dword [esi]
mov edi, dword [esi + 0x18]
lea ecx, [esp + 0x10]
push ecx
xor ebp, ebp
push eax
xor ebx, ebx
mov dword [esp + 0x18], ebp
mov dword [esp + 0x1c], ebp
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x42c446
push 0x474f2c
mov eax, 0x474f2c
call fcn.0042f3a0
add esp, 4
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
add esp, 8
ret
mov ebx, dword [esp + 0x10]
mov ecx, dword [esi + 0xb4]
xor edx, edx
sub ebx, edi
mov edi, dword [esp + 0x14]
sbb edi, edx
sub ebx, 0x298
sbb edi, ebp
xor eax, eax
cmp edi, eax
jl 0x42c4d8
jg 0x42c46e
cmp ebx, ecx
jb 0x42c4d8
mov ebp, dword [esi]
push 0
push 0
push edi
push ebx
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
jne 0x42c49d
push 0x474f2c
mov eax, 0x474f2c
call fcn.0042f3a0
add esp, 4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
mov ecx, dword [esp + 0x1c]
mov esi, 0x298
mov edx, ebp
call fcn.0042a740
test eax, eax
je 0x42c493
mov eax, dword [esp + 0x20]
test eax, eax
je 0x42c4be
mov dword [eax], ebx
mov dword [eax + 4], edi
mov eax, dword [esp + 0x24]
test eax, eax
je 0x42c4e5
pop edi
pop esi
mov ecx, 1
pop ebp
mov word [eax], cx
mov eax, ecx
pop ebx
add esp, 8
ret
mov eax, dword [esp + 0x24]
cmp eax, ebp
je 0x42c4e5
xor edx, edx
mov word [eax], dx
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 8
ret