joyce8/EMBER2024-capa huggingface dataset:
Function at 0x101ce490
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x103597e3
mov eax, dword fs:[0]
push eax
sub esp, 8
push esi
mov eax, dword [0x105be7d0]
xor eax, esp
push eax
lea eax, [esp + 0x10]
mov dword fs:[0], eax
mov esi, ecx
mov dword [esp + 0xc], esi
mov dword [esi], vtable.PageElement.0
mov dword [esp + 0x18], 0
mov dword [esi + 4], vtable.PageDestination.0
mov byte [esp + 0x18], 1
sub esp, 0x10
mov eax, dword [esp + 0x30]
lea ecx, [esi + 0x10]
movdqu xmm0, xmmword [esp + 0x40]
mov dword [esi + 8], eax
mov eax, dword [esp + 0x34]
mov dword [esi + 0xc], eax
mov eax, esp
mov dword [esi], vtable.PdfLink.1.0
mov dword [esi + 4], vtable.PdfLink.0
movdqu xmmword [eax], xmm0
call fcn.101ca090
mov eax, dword [esp + 0x38]
add esp, 0x10
mov dword [esi + 0x30], eax
xorps xmm0, xmm0
mov eax, dword [esp + 0x2c]
movups xmmword [esi + 0x38], xmm0
test eax, eax
je 0x101ce537
movss xmm1, dword [eax]
movss xmm0, dword [eax + 4]
cvtps2pd xmm1, xmm1
cvtps2pd xmm0, xmm0
unpcklpd xmm1, xmm0
movdqu xmmword [esi + 0x38], xmm1
mov dword [esp + 0x18], 0xffffffff
mov eax, esi
mov ecx, dword [esp + 0x10]
mov dword fs:[0], ecx
pop ecx
pop esi
add esp, 0x14
ret 0x20

Function at 0x101ce670
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push 0xffffffffffffffff
push 0x10359873
mov eax, dword fs:[0]
push eax
sub esp, 8
push esi
mov eax, dword [0x105be7d0]
xor eax, esp
push eax
lea eax, [esp + 0x10]
mov dword fs:[0], eax
mov esi, ecx
mov dword [esp + 0xc], esi
mov dword [esi], vtable.PageElement.0
mov dword [esp + 0x18], 0
movdqu xmm0, xmmword [esp + 0x24]
mov eax, dword [esp + 0x44]
mov dword [esi], vtable.PdfComment.0
mov dword [esi + 0xc], eax
movdqu xmmword [esi + 0x10], xmm0
mov dword [esp + 8], 0
mov eax, dword [esp + 8]
movdqu xmm0, xmmword [esp + 0x34]
mov dword [esi + 0x30], eax
mov eax, dword [esp + 0x20]
mov dword [esi + 8], 0
movdqu xmmword [esi + 0x20], xmm0
test eax, eax
je 0x101ce6f5
push eax
call dword [sym.imp.MSVCR120.dll__wcsdup]
add esp, 4
jmp 0x101ce6f7
xor eax, eax
mov dword [esi + 0x38], eax
mov dword [esp + 0x18], 0xffffffff
mov eax, esi
mov ecx, dword [esp + 0x10]
mov dword fs:[0], ecx
pop ecx
pop esi
add esp, 0x14
ret 0x28
Function at 0x101ce920
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push 0xffffffffffffffff
push 0x10359843
mov eax, dword fs:[0]
push eax
push ecx
mov eax, dword [0x105be7d0]
xor eax, esp
push eax
lea eax, [esp + 8]
mov dword fs:[0], eax
mov edx, ecx
mov dword [esp + 4], edx
mov dword [edx], vtable.PageElement.0
mov dword [esp + 0x10], 0
mov dword [edx + 4], vtable.PageDestination.0
mov byte [esp + 0x10], 1
mov ecx, dword [esp + 0x18]
mov dword [edx], vtable.PdfLink.1.0
mov dword [edx + 4], vtable.PdfLink.0
mov eax, dword [ecx + 8]
mov dword [edx + 8], eax
mov eax, dword [ecx + 0xc]
mov dword [edx + 0xc], eax
movdqu xmm0, xmmword [ecx + 0x10]
movdqu xmmword [edx + 0x10], xmm0
movdqu xmm0, xmmword [ecx + 0x20]
movdqu xmmword [edx + 0x20], xmm0
mov eax, dword [ecx + 0x30]
mov dword [edx + 0x30], eax
movdqu xmm0, xmmword [ecx + 0x38]
movdqu xmmword [edx + 0x38], xmm0
mov dword [esp + 0x10], 0xffffffff
mov eax, edx
mov ecx, dword [esp + 8]
mov dword fs:[0], ecx
pop ecx
add esp, 0x10
ret 4

Function at 0x101ce9c0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x10359968
mov eax, dword fs:[0]
push eax
push ecx
push esi
mov eax, dword [0x105be7d0]
xor eax, esp
push eax
lea eax, [esp + 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [esp + 8], esi
mov dword [esi], vtable.PageElement.0
mov dword [esp + 0x14], 0
sub esp, 0x10
mov eax, dword [esp + 0x2c]
lea ecx, [esi + 0x10]
movdqu xmm0, xmmword [esp + 0x38]
mov dword [esi + 4], eax
mov eax, dword [esp + 0x30]
mov dword [esi + 8], eax
mov eax, esp
mov dword [esi], vtable.PdfImage.0
movdqu xmmword [eax], xmm0
call fcn.101ca090
mov eax, dword [esp + 0x34]
add esp, 0x10
mov dword [esi + 0x30], eax
mov dword [esp + 0x14], 0xffffffff
mov eax, esi
mov ecx, dword [esp + 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
add esp, 0x10
ret 0x1c
Function at 0x101ceae0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x103599d1
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x105be7d0]
xor eax, esp
push eax
lea eax, [esp + 0x18]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [esp + 0x10], ebx
mov dword [ebx], vtable.BaseEngine.0
mov dword [esp + 0x20], 0
lea ecx, [ebx + 0x5c]
mov dword [ebx], vtable.PdfEngineImpl.0
lea eax, [ecx + 0x10]
mov dword [ebx + 4], 0
mov dword [ebx + 8], 0
mov byte [ebx + 0xc], 0
mov dword [ebx + 0x38], 0
mov dword [ebx + 0x54], 0
mov dword [ebx + 0x58], 0
mov dword [ecx + 8], 0
mov dword [ecx + 0x50], 0
mov dword [ecx + 0xc], eax
call fcn.10106230
mov byte [esp + 0x20], 1
lea esi, [ebx + 0xcc]
mov dword [ebx + 0xb0], 0
mov dword [ebx + 0xb4], 0
mov dword [ebx + 0xb8], 0
mov dword [ebx + 0xbc], 0
mov dword [ebx + 0xc0], 0
mov dword [ebx + 0xc4], 0
mov dword [ebx + 0xc8], 0
mov dword [esp + 0x14], esi
mov dword [esi], 0
mov dword [esi + 4], 0
call fcn.100d6910
mov dword [esi], eax
mov byte [esp + 0x20], 6
lea eax, [ebx + 0x3c]
mov esi, dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
push eax
mov word [ebx + 0xd4], 0
mov byte [ebx + 0xd6], 0
call esi
lea edi, [ebx + 0x10]
push edi
call esi
sub esp, 8
mov dword [ebx + 0x2c], edi
lea edx, [ebx + 0x2c]
mov dword [ebx + 0x30], 0x101cc250
mov dword [ebx + 0x34], 0x101cc270
call fcn.101fc4b0
add esp, 8
mov dword [ebx + 0x28], eax
test eax, eax
je 0x101cec2d
mov ecx, dword [eax + 0x14]
mov dword [ecx + 0xc], 0x101ef320
mov eax, dword [eax + 0x14]
mov dword [eax + 0x10], 0x101ef380
mov dword [esp + 0x20], 0xffffffff
mov eax, ebx
mov ecx, dword [esp + 0x18]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
add esp, 0x14
ret
Function at 0x101d7650
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x1035a528
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x105be7d0]
xor eax, esp
push eax
lea eax, [esp + 0x20]
mov dword fs:[0], eax
mov esi, ecx
mov edi, dword [ebp + 0x14]
test edi, edi
je 0x101d768b
mov dword [edi], 0
cmp byte [esi + 0xd6], 0
mov ebx, dword [ebp + 8]
jne 0x101d76bf
push dword [esi + 4]
push ebx
call dword [sym.imp.MSVCR120.dll__wcsicmp]
add esp, 8
test eax, eax
jne 0x101d76bf
xor al, al
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
mov eax, dword [esi]
lea ecx, [esp + 0x14]
push ecx
mov ecx, esi
call dword [eax + 0x28]
mov dword [esp + 0x18], eax
mov dword [esp + 0x28], 0
test eax, eax
je 0x101d76ef
push dword [esp + 0x14]
mov edx, eax
mov ecx, ebx
call fcn.10205c90
add esp, 4
test al, al
jne 0x101d7709
mov eax, dword [esi + 4]
test eax, eax
je 0x101d771f
push 0
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
setne al
test al, al
je 0x101d771f
cmp byte [ebp + 0xc], 0
je 0x101d7723
push edi
push dword [ebp + 0x10]
mov ecx, esi
push ebx
call fcn.101d7760
test al, al
jne 0x101d7723
xor bl, bl
jmp 0x101d7725
mov bl, 1
mov dword [esp + 0x28], 0xffffffff
push dword [esp + 0x18]
call dword [sym.imp.MSVCR120.dll_free]
add esp, 4
mov al, bl
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
Function at 0x101eeb20
Capabilities:
Check if file exists
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x57c
mov eax, dword [0x105be7d0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
lea eax, [ebp - 0x574]
mov edi, ecx
push eax
lea eax, [ebp - 0x318]
mov dword [ebp - 0x578], edi
push eax
push 0x104
push edx
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
lea eax, [ebp - 0x568]
push eax
lea eax, [ebp - 0x318]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, eax
mov dword [ebp - 0x56c], esi
cmp esi, 0xffffffff
jne 0x101eeb8f
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 2
je 0x101eecf5
jmp 0x101eed06
mov ebx, dword [sym.imp.MSVCR120.dll__stricmp]
jmp 0x101eeba0
test byte [ebp - 0x568], 0x10
jne 0x101eecd8
mov ecx, dword [ebp - 0x574]
lea eax, [ebp - 0x110]
sub eax, ecx
sar eax, 1
push eax
lea eax, [ebp - 0x53c]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
push 0
push 0
push 0x104
lea eax, [ebp - 0x110]
push eax
push 0xffffffffffffffff
lea eax, [ebp - 0x318]
push eax
push 0
push 0xfde9
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x101eec1a
lea eax, [ebp - 0x318]
push eax
push str.WideCharToMultiByte_failed_for__S
push 0x28d
push str...mupdf_sourcepdfpdf_fontfile.c
push edi
call fcn.101df520
add esp, 0x14
jmp 0x101eecd8
lea eax, [ebp - 0x110]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x101eec23
mov ecx, dword [edi + 0xc]
sub eax, edx
lea eax, [ebp + eax - 0x114]
mov dword [ebp - 0x570], eax
call fcn.101df6d0
test eax, eax
je 0x101eecd3
mov edx, dword [edi + 0xc]
push 0
mov eax, dword [edx]
mov ecx, eax
shl ecx, 4
add edx, 8
add eax, ecx
lea eax, [edx + eax*4]
push eax
call sub.MSVCR120.dll__setjmp3
mov edi, dword [ebp - 0x578]
add esp, 8
mov esi, dword [edi + 0xc]
mov edx, dword [esi]
shl edx, 4
add edx, dword [esi]
mov dword [esi + edx*4 + 4], eax
test eax, eax
jne 0x101eeccd
mov esi, dword [ebp - 0x570]
push str..ttc
push esi
call ebx
add esp, 8
test eax, eax
jne 0x101eeca2
lea edx, [ebp - 0x110]
mov ecx, edi
call fcn.101ee800
jmp 0x101eeccd
push str..ttf
push esi
call ebx
add esp, 8
test eax, eax
je 0x101eecc0
push str..otf
push esi
call ebx
add esp, 8
test eax, eax
jne 0x101eeccd
lea edx, [ebp - 0x110]
mov ecx, edi
call fcn.101ee710
mov esi, dword [ebp - 0x56c]
mov eax, dword [edi + 0xc]
dec dword [eax]
lea eax, [ebp - 0x568]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x101eeba0
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1033d458
mov esp, ebp
pop ebp
ret
call esi
push eax
push str.extend_system_font_list:_unknown_error__d
push 1
push 0x281
push str...mupdf_sourcepdfpdf_fontfile.c
push edi
call fcn.101df770
int3
Function at 0x101eed60
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x41c
mov eax, dword [0x105be7d0]
xor eax, esp
mov dword [esp + 0x418], eax
push esi
push 0xf8
lea eax, [esp + 0xc]
mov esi, ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
dec eax
cmp eax, 0xf6
ja 0x101eedb8
push str.Fonts._t_
lea eax, [esp + 0xc]
push 0x104
push eax
call dword [sym.imp.MSVCR120.dll_wcscat_s]
add esp, 0xc
lea edx, [esp + 8]
mov ecx, esi
call fcn.101eeb20
cmp dword [0x105e22b8], 0
jne 0x101eedd9
push str.couldnt_find_any_usable_system_fonts
push 0x2ba
push str...mupdf_sourcepdfpdf_fontfile.c
push esi
call fcn.101df520
add esp, 0x10
xor eax, eax
mov word [esp + 0x210], ax
lea eax, [esp + 8]
push 0x104
push eax
push 0x10000000
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
xor eax, eax
mov word [esp + 0x20e], ax
lea eax, [esp + 4]
push eax
lea eax, [esp + 0x214]
push eax
push 0x104
lea eax, [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
mov edx, dword [esp + 4]
lea eax, [esp + 0x418]
sub eax, edx
sar eax, 1
push eax
push str.DroidSansFallback.ttf
push edx
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
lea edx, [esp + 0x210]
mov ecx, esi
call fcn.101eeb20
push dword [sym.imp.MSVCR120.dll__stricmp]
push 0x188
push dword [0x105e22b8]
push dword [0x105e22b4]
call dword [sym.imp.MSVCR120.dll_qsort]
push 0x101eed30
call fcn.1033d620
mov ecx, dword [esp + 0x430]
add esp, 0x14
pop esi
xor ecx, esp
call fcn.1033d458
mov esp, ebp
pop ebp
ret
Function at 0x10201390
Capabilities:
Write file on windows

Disassembly:
sub esp, 8
mov eax, dword [ecx + 0x4c]
push ebx
mov ebx, edx
mov dword [esp + 4], eax
mov edx, dword [esp + 0x14]
push ebp
push esi
mov eax, dword [ebx + 0x34]
push edi
mov dword [esp + 0x14], ecx
mov esi, dword [eax + edx*4]
mov eax, dword [ebx + 0x38]
push dword [eax + edx*4]
push esi
push dword [esp + 0x2c]
call fcn.1020c420
mov ecx, dword [esp + 0x28]
add esp, 0xc
mov ebp, eax
call fcn.101dd430
cmp dword [ebx + 8], 0
mov edi, eax
je 0x10201461
mov ecx, ebp
call fcn.10200fd0
test eax, eax
je 0x10201461
push dword [ebp + 0xc]
mov edx, dword [ebp + 4]
mov ecx, dword [esp + 0x14]
call fcn.10201010
mov ecx, dword [esp + 0x14]
add esp, 4
mov edx, ebp
mov esi, eax
call fcn.101f3650
mov ecx, dword [esp + 0x14]
mov edx, edi
mov ebp, esi
call fcn.102010b0
mov edx, dword [esi + 0xc]
mov ecx, dword [esp + 0x14]
call fcn.101db810
mov esi, eax
mov edx, str.Length
push esi
mov ecx, edi
call fcn.101dd9e0
add esp, 4
test esi, esi
je 0x10201461
dec dword [esi]
jne 0x10201461
mov al, byte [esi + 4]
cmp al, 0x61
jne 0x10201445
mov ecx, esi
call fcn.101de120
jmp 0x10201461
cmp al, 0x64
jne 0x10201452
mov ecx, esi
call fcn.101de1a0
jmp 0x10201461
mov eax, dword [esi + 8]
push esi
push dword [eax + 0x4c]
call fcn.101f33d0
add esp, 8
push dword [esp + 0x24]
mov esi, dword [sym.imp.MSVCR120.dll_fprintf]
push dword [esp + 0x24]
push str._d__d_obj_n
push dword [ebx]
call esi
mov ecx, dword [ebx]
xor eax, eax
cmp dword [ebx + 0xc], eax
mov edx, edi
sete al
push eax
call fcn.101df1f0
add esp, 0x14
push str.stream_n
push dword [ebx]
call esi
push dword [ebx]
push dword [ebp + 0xc]
push 1
push dword [ebp + 4]
call dword [sym.imp.MSVCR120.dll_fwrite]
push str.endstream_nendobj_n_n
push dword [ebx]
call esi
mov ecx, dword [esp + 0x30]
add esp, 0x20
mov edx, ebp
call fcn.101f3650
test edi, edi
je 0x102014fb
dec dword [edi]
jne 0x102014fb
mov al, byte [edi + 4]
cmp al, 0x61
jne 0x102014da
mov ecx, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
jmp fcn.101de120
cmp al, 0x64
jne 0x102014ec
mov ecx, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
jmp fcn.101de1a0
mov eax, dword [edi + 8]
push edi
push dword [eax + 0x4c]
call fcn.101f33d0
add esp, 8
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
Function at 0x10201510
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x18
push ebx
push ebp
mov ebp, ecx
mov ebx, edx
mov edx, dword [esp + 0x28]
push esi
push edi
mov eax, dword [ebp + 0x4c]
xor edi, edi
cmp dword [ebx + 0x2c], edi
mov dword [esp + 0x18], eax
mov eax, dword [ebx + 0x34]
mov dword [esp + 0x14], ebp
mov esi, dword [eax + edx*4]
mov eax, dword [ebx + 0x38]
mov ecx, dword [eax + edx*4]
lea eax, [esp + 0x1c]
cmove eax, edi
mov dword [esp + 0x1c], 0
push eax
push edi
push ecx
push esi
push dword [esp + 0x44]
mov ecx, ebp
call fcn.1020c690
add esp, 0x14
mov ebp, eax
cmp dword [esp + 0x1c], edi
je 0x1020156d
mov ecx, dword [ebx + 0x30]
test ecx, ecx
je 0x1020156d
inc dword [ecx]
mov ecx, dword [esp + 0x2c]
call fcn.101dd430
mov edi, eax
mov edx, str.Filter
mov ecx, edi
call fcn.101ddfe0
mov edx, str.DecodeParms
mov ecx, edi
call fcn.101ddfe0
cmp dword [ebx + 8], 0
je 0x102015d1
mov ecx, ebp
call fcn.10200fd0
test eax, eax
je 0x102015d1
push dword [ebp + 0xc]
mov edx, dword [ebp + 4]
mov ecx, dword [esp + 0x1c]
call fcn.10201010
mov ecx, dword [esp + 0x1c]
add esp, 4
mov edx, ebp
mov esi, eax
call fcn.101f3650
mov ebp, esi
mov edx, edi
mov esi, dword [esp + 0x14]
mov ecx, esi
call fcn.102010b0
jmp 0x102015d5
mov esi, dword [esp + 0x14]
mov eax, dword [ebp + 0xc]
mov edx, 0x1c
mov dword [esp + 0x24], eax
mov eax, dword [esi + 0x4c]
mov ecx, eax
mov dword [esp + 0x20], eax
call fcn.101f3100
mov esi, eax
test esi, esi
je 0x102016fe
mov eax, dword [esp + 0x14]
mov edx, str.Length
mov dword [esi + 8], eax
mov ecx, edi
mov eax, dword [esp + 0x24]
push esi
mov dword [esi], 1
mov word [esi + 4], 0x69
mov dword [esi + 0xc], 0
mov dword [esi + 0x10], eax
call fcn.101dd9e0
add esp, 4
dec dword [esi]
jne 0x1020165a
mov al, byte [esi + 4]
cmp al, 0x61
jne 0x1020163e
mov ecx, esi
call fcn.101de120
jmp 0x1020165a
cmp al, 0x64
jne 0x1020164b
mov ecx, esi
call fcn.101de1a0
jmp 0x1020165a
mov eax, dword [esi + 8]
push esi
push dword [eax + 0x4c]
call fcn.101f33d0
add esp, 8
push dword [esp + 0x34]
mov esi, dword [sym.imp.MSVCR120.dll_fprintf]
push dword [esp + 0x34]
push str._d__d_obj_n
push dword [ebx]
call esi
mov ecx, dword [ebx]
xor eax, eax
cmp dword [ebx + 0xc], eax
mov edx, edi
sete al
push eax
call fcn.101df1f0
add esp, 0x14
push str.stream_n
push dword [ebx]
call esi
push dword [ebx]
push dword [ebp + 0xc]
push 1
push dword [ebp + 4]
call dword [sym.imp.MSVCR120.dll_fwrite]
push str.endstream_nendobj_n_n
push dword [ebx]
call esi
mov ecx, dword [esp + 0x38]
add esp, 0x20
mov edx, ebp
call fcn.101f3650
test edi, edi
je 0x102016f6
dec dword [edi]
jne 0x102016f6
mov al, byte [edi + 4]
cmp al, 0x61
jne 0x102016d4
mov ecx, edi
call fcn.101de120
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x18
ret
cmp al, 0x64
jne 0x102016e7
mov ecx, edi
call fcn.101de1a0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x18
ret
mov eax, dword [edi + 8]
push edi
push dword [eax + 0x4c]
call fcn.101f33d0
add esp, 8
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x18
ret
push 0x1c
push str.malloc_of__d_bytes_failed
push 1
push 0x40
push str...mupdf_source_fitzmemory.c
push dword [esp + 0x34]
call fcn.101df770
int3
Function at 0x10205ab0
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x1035a608
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x105be7d0]
xor eax, esp
push eax
lea eax, [esp + 0x20]
mov dword fs:[0], eax
test ecx, ecx
jne 0x10205af8
or eax, 0xffffffff
or edx, eax
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
mov dword [esp + 0x10], esi
mov dword [esp + 0x28], 0
cmp esi, 0xffffffff
je 0x10205b3e
lea eax, [esp + 0x14]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x10205b3e
mov edi, dword [esp + 0x14]
mov ebx, dword [esp + 0x18]
jmp 0x10205b43
or edi, 0xffffffff
or ebx, edi
mov dword [esp + 0x28], 0xffffffff
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
mov edx, ebx
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x10205bf0
Capabilities:
Read file on windows

Disassembly:
push 0xffffffffffffffff
push 0x1035a638
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x105be7d0]
xor eax, esp
push eax
lea eax, [esp + 0x18]
mov dword fs:[0], eax
mov ebx, edx
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
mov dword [esp + 0x14], esi
mov dword [esp + 0x20], 0
cmp esi, 0xffffffff
je 0x10205c66
mov edi, dword [esp + 0x28]
lea eax, [esp + 0x10]
push 0
push eax
push edi
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x10205c66
cmp dword [esp + 0x10], edi
jne 0x10205c66
mov bl, 1
jmp 0x10205c68
xor bl, bl
mov dword [esp + 0x20], 0xffffffff
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, bl
mov ecx, dword [esp + 0x18]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
add esp, 0x14
ret

Function at 0x10205c90
Capabilities:
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x1035a638
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x105be7d0]
xor eax, esp
push eax
lea eax, [esp + 0x18]
mov dword fs:[0], eax
mov ebx, edx
push 0
push 0x80
push 2
push 0
push 1
push 0x40000000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
mov dword [esp + 0x14], esi
mov dword [esp + 0x20], 0
cmp esi, 0xffffffff
je 0x10205d06
mov edi, dword [esp + 0x28]
lea eax, [esp + 0x10]
push 0
push eax
push edi
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x10205d06
cmp edi, dword [esp + 0x10]
jne 0x10205d06
mov bl, 1
jmp 0x10205d08
xor bl, bl
mov dword [esp + 0x20], 0xffffffff
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, bl
mov ecx, dword [esp + 0x18]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
add esp, 0x14
ret
Function at 0x10209660
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x8c
mov eax, dword [0x105be7d0]
xor eax, esp
mov dword [esp + 0x84], eax
mov eax, dword [esp + 0x94]
push ebx
mov ebx, dword [esp + 0x94]
push ebp
push esi
mov dword [esp + 0xc], eax
mov esi, 0x20
mov eax, dword [ecx + 8]
push edi
mov edi, edx
mov dword [esp + 0x14], ecx
cdq
and edx, 7
lea ebp, [edx + eax]
sar ebp, 3
lea eax, [esp + 0x74]
cmp ebx, esi
cmovg ebx, esi
push ebx
push edi
push eax
call sub.MSVCR120.dll_memcpy
sub esi, ebx
lea eax, [esp + 0x80]
push esi
add eax, ebx
push 0x10369394
push eax
call sub.MSVCR120.dll_memcpy
push 0x20
lea edx, [esp + 0x90]
mov dword [esp + 0x48], 0
lea ecx, [esp + 0x34]
mov dword [esp + 0x44], 0
mov dword [esp + 0x34], 0x67452301
mov dword [esp + 0x38], 0xefcdab89
mov dword [esp + 0x3c], 0x98badcfe
mov dword [esp + 0x40], 0x10325476
call fcn.101efd60
mov ebx, dword [esp + 0x30]
lea ecx, [esp + 0x34]
push 0x20
lea edx, [ebx + 0x24]
call fcn.101efd60
mov ecx, dword [ebx + 0xc4]
lea edx, [esp + 0x94]
mov eax, ecx
mov byte [esp + 0x94], cl
shr eax, 8
mov byte [esp + 0x95], al
mov eax, ecx
shr ecx, 0x18
shr eax, 0x10
mov byte [esp + 0x97], cl
lea ecx, [esp + 0x38]
push 4
mov byte [esp + 0x9a], al
call fcn.101efd60
mov eax, dword [ebx]
add esp, 0x24
test eax, eax
je 0x10209785
cmp byte [eax + 4], 0x72
jne 0x10209775
mov ecx, eax
call fcn.101e8f10
test eax, eax
je 0x10209785
cmp byte [eax + 4], 0x73
jne 0x10209785
movzx esi, word [eax + 0x10]
jmp 0x10209787
xor esi, esi
mov eax, dword [ebx]
test eax, eax
je 0x102097a7
cmp byte [eax + 4], 0x72
jne 0x1020979a
mov ecx, eax
call fcn.101e8f10
test eax, eax
je 0x102097a7
cmp byte [eax + 4], 0x73
lea edx, [eax + 0x12]
je 0x102097ac
mov edx, 0x10559f1c
push esi
lea ecx, [esp + 0x1c]
call fcn.101efd60
add esp, 4
cmp dword [ebx + 0x20], 4
jl 0x102097e2
cmp dword [ebx + 0xc8], 0
jne 0x102097e2
push 4
lea edx, [esp + 0x78]
mov dword [esp + 0x78], 0xffffffff
lea ecx, [esp + 0x1c]
call fcn.101efd60
add esp, 4
lea edx, [esp + 0x74]
lea ecx, [esp + 0x18]
call fcn.101efe10
cmp dword [ebx + 0x20], 3
jl 0x10209851
mov esi, 0x32
lea ebx, [ebx]
push ebp
lea edx, [esp + 0x78]
mov dword [esp + 0x30], 0
lea ecx, [esp + 0x1c]
mov dword [esp + 0x2c], 0
mov dword [esp + 0x1c], 0x67452301
mov dword [esp + 0x20], 0xefcdab89
mov dword [esp + 0x24], 0x98badcfe
mov dword [esp + 0x28], 0x10325476
call fcn.101efd60
add esp, 4
lea edx, [esp + 0x74]
lea ecx, [esp + 0x18]
call fcn.101efe10
dec esi
jne 0x10209800
push ebp
lea eax, [esp + 0x78]
push eax
push dword [esp + 0x18]
call sub.MSVCR120.dll_memcpy
mov ecx, dword [esp + 0xa0]
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.1033d458
add esp, 0x8c
ret