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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x90
push ebx
push esi
push edi
mov dword [ebp - 4], 0xffffffff
mov dword [ebp - 8], 0xffffffff
mov dword [ebp - 0xc], 0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x20], 0
push 0x200
call fcn.1001ef81
add esp, 4
mov dword [ebp - 0x38], eax
cmp dword [ebp - 0x38], 0
je 0x10016fd0
push 0
push 0x80
push 3
push 0
push 3
push 0x80000000
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0xffffffff
je 0x10016fd0
push 0
push 0x80
push 3
push 0
push 3
push 0xc0000000
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0xffffffff
je 0x10016fd0
cmp dword [0x10038c5c], 0
je 0x10016fa1
lea edx, [ebp - 0x14]
push edx
push 0x40
mov eax, dword [ebp + 0x14]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b760
add esp, 0x14
test eax, eax
je 0x10016fd0
cmp dword [0x10038c5c], 0
jne 0x10017056
lea eax, [ebp - 0xc]
push eax
push 0x40
mov ecx, dword [ebp + 0x14]
push ecx
mov edx, dword [ebp + 0x10]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000b5f0
add esp, 0x14
test eax, eax
jne 0x10017056
cmp dword [ebp - 0xc], 0
jne 0x10016fe0
mov ecx, dword [ebp - 0x14]
or ecx, dword [ebp - 0x10]
test ecx, ecx
je 0x1001700f
cmp dword [0x10038c5c], 0
je 0x10016fff
mov edx, dword [ebp - 0x10]
push edx
mov eax, dword [ebp - 0x14]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b9e0
add esp, 0xc
jmp 0x1001700f
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000b8f0
add esp, 8
cmp dword [ebp - 4], 0xffffffff
je 0x1001701f
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 8], 0xffffffff
je 0x1001702f
mov edx, dword [ebp - 8]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x38], 0
je 0x10017041
mov eax, dword [ebp - 0x38]
push eax
call fcn.1001ee98
add esp, 4
cmp dword [ebp + 0x24], 0
je 0x1001704f
push 0
call dword [ebp + 0x24]
add esp, 4
xor eax, eax
jmp 0x10017aa0
lea ecx, [ebp - 0x24]
push ecx
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0xffffffff
jne 0x100170d1
cmp dword [0x10038c5c], 0
je 0x1001708c
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b9e0
add esp, 0xc
jmp 0x1001709c
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b8f0
add esp, 8
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.1001ee98
add esp, 4
cmp dword [ebp + 0x24], 0
je 0x100170ca
push 0
call dword [ebp + 0x24]
add esp, 4
xor eax, eax
jmp 0x10017aa0
push 0
push 0x200
mov edx, dword [ebp - 0x24]
push edx
mov eax, dword [ebp - 0x28]
push eax
call fcn.1001e9b0
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x3c], edx
mov ecx, dword [ebp - 0x40]
or ecx, dword [ebp - 0x3c]
test ecx, ecx
je 0x1001714b
push 0
push 0x200
mov edx, dword [ebp - 0x24]
push edx
mov eax, dword [ebp - 0x28]
push eax
call fcn.100201b0
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x44], edx
mov ecx, dword [ebp - 0x48]
or ecx, dword [ebp - 0x44]
test ecx, ecx
jne 0x1001714b
push 0
push 0x200
mov edx, dword [ebp - 0x24]
push edx
mov eax, dword [ebp - 0x28]
push eax
call fcn.1001e9b0
push 0
push 0x200
push edx
push eax
call fcn.100201b0
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x4c], edx
mov ecx, dword [ebp - 0x50]
or ecx, dword [ebp - 0x4c]
test ecx, ecx
je 0x10017160
mov edx, dword [ebp - 0x28]
add edx, 0x200
mov eax, dword [ebp - 0x24]
adc eax, 0
mov dword [ebp - 0x28], edx
mov dword [ebp - 0x24], eax
push 0
push 0x200
mov ecx, dword [ebp - 0x24]
push ecx
mov edx, dword [ebp - 0x28]
push edx
call fcn.1001e9b0
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], edx
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x30], eax
mov ecx, dword [ebp - 0x24]
mov dword [ebp - 0x2c], ecx
mov dword [ebp - 0x34], 0x64
mov dword [ebp - 0x18], 0
push 0
lea edx, [ebp - 0x18]
push edx
push 0x200
mov eax, dword [ebp - 0x38]
push eax
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x10017215
cmp dword [0x10038c5c], 0
je 0x100171d0
mov edx, dword [ebp - 0x10]
push edx
mov eax, dword [ebp - 0x14]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b9e0
add esp, 0xc
jmp 0x100171e0
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000b8f0
add esp, 8
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 8]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x38]
push eax
call fcn.1001ee98
add esp, 4
cmp dword [ebp + 0x24], 0
je 0x1001720e
push 0
call dword [ebp + 0x24]
add esp, 4
xor eax, eax
jmp 0x10017aa0
cmp dword [ebp - 0x18], 0x200
jae 0x10017285
mov eax, dword [ebp - 0x18]
xor edx, edx
mov ecx, 0x10
div ecx
mov eax, 0x10
sub eax, edx
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
je 0x1001725c
mov ecx, dword [ebp - 0x20]
push ecx
mov edx, dword [ebp - 0x20]
push edx
mov eax, dword [ebp - 0x38]
add eax, dword [ebp - 0x18]
push eax
call fcn.1001ea50
add esp, 0xc
mov ecx, dword [ebp - 0x18]
add ecx, dword [ebp - 0x20]
mov dword [ebp - 0x18], ecx
jmp 0x10017283
mov dword [ebp - 0x20], 0x10
mov edx, dword [ebp - 0x20]
push edx
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [ebp - 0x38]
add ecx, dword [ebp - 0x18]
push ecx
call fcn.1001ea50
add esp, 0xc
mov edx, dword [ebp - 0x18]
add edx, dword [ebp - 0x20]
mov dword [ebp - 0x18], edx
jmp 0x1001728c
mov dword [ebp - 0x18], 0x200
cmp dword [0x10038c5c], 0
je 0x100172b5
mov eax, dword [ebp - 0x18]
push eax
mov ecx, dword [ebp - 0x38]
push ecx
mov edx, dword [ebp - 0x10]
push edx
mov eax, dword [ebp - 0x14]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000bbe0
add esp, 0x14
test eax, eax
je 0x10017305
cmp dword [0x10038c5c], 0
jne 0x100172da
mov edx, dword [ebp - 0x18]
push edx
mov eax, dword [ebp - 0x38]
push eax
mov ecx, dword [ebp - 0xc]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000bae0
add esp, 0x10
test eax, eax
je 0x10017305
mov dword [ebp - 0x1c], 0
push 0
lea eax, [ebp - 0x1c]
push eax
mov ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp - 0x38]
push edx
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x10017305
mov ecx, dword [ebp - 0x18]
cmp ecx, dword [ebp - 0x1c]
je 0x10017369
cmp dword [0x10038c5c], 0
je 0x10017324
mov edx, dword [ebp - 0x10]
push edx
mov eax, dword [ebp - 0x14]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b9e0
add esp, 0xc
jmp 0x10017334
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000b8f0
add esp, 8
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 8]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x38]
push eax
call fcn.1001ee98
add esp, 4
cmp dword [ebp + 0x24], 0
je 0x10017362
push 0
call dword [ebp + 0x24]
add esp, 4
xor eax, eax
jmp 0x10017aa0
cmp dword [ebp + 0x24], 0
je 0x10017453
mov ecx, dword [ebp - 0x30]
sub ecx, 1
mov edx, dword [ebp - 0x2c]
sbb edx, 0
push edx
push ecx
mov eax, dword [ebp - 0x24]
push eax
mov ecx, dword [ebp - 0x28]
push ecx
call fcn.10013580
add esp, 0x10
mov edx, dword [ebp - 0x34]
sub edx, eax
sub edx, 2
mov dword [ebp - 0x18], edx
cmp dword [ebp - 0x18], 0
jle 0x10017453
mov eax, dword [ebp - 0x34]
sub eax, dword [ebp - 0x18]
mov dword [ebp - 0x34], eax
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x18]
sub edx, 1
mov dword [ebp - 0x18], edx
test ecx, ecx
je 0x10017453
push 1
call dword [ebp + 0x24]
add esp, 4
test eax, eax
jne 0x1001744e
cmp dword [ebp - 0xc], 0
jne 0x100173df
mov eax, dword [ebp - 0x14]
or eax, dword [ebp - 0x10]
test eax, eax
je 0x1001740e
cmp dword [0x10038c5c], 0
je 0x100173fe
mov ecx, dword [ebp - 0x10]
push ecx
mov edx, dword [ebp - 0x14]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000b9e0
add esp, 0xc
jmp 0x1001740e
mov ecx, dword [ebp - 0xc]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b8f0
add esp, 8
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x38]
push edx
call fcn.1001ee98
add esp, 4
cmp dword [ebp + 0x24], 0
je 0x1001743c
push 0
call dword [ebp + 0x24]
add esp, 4
push 0x3e3
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x10017aa0
jmp 0x100173af
cmp dword [ebp - 0x20], 0
je 0x1001745b
jmp 0x1001747b
mov eax, dword [ebp - 0x30]
sub eax, 1
mov ecx, dword [ebp - 0x2c]
sbb ecx, 0
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], ecx
mov edx, dword [ebp - 0x30]
or edx, dword [ebp - 0x2c]
test edx, edx
jne 0x1001718d
cmp dword [0x10038c5c], 0
je 0x1001749a
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b9e0
add esp, 0xc
jmp 0x100174aa
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b8f0
add esp, 8
mov dword [ebp - 0x18], 0x10
mov edx, dword [ebp - 0x18]
push edx
push 0
mov eax, dword [ebp - 0x38]
push eax
call fcn.1001ea50
add esp, 0xc
cmp dword [0x10038c5c], 0
je 0x100174ee
lea ecx, [ebp - 0x14]
push ecx
push 0x40
mov edx, dword [ebp + 0x14]
push edx
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b760
add esp, 0x14
test eax, eax
je 0x1001758e
cmp dword [0x10038c5c], 0
jne 0x10017515
lea edx, [ebp - 0xc]
push edx
push 0x40
mov eax, dword [ebp + 0x14]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b5f0
add esp, 0x14
test eax, eax
je 0x1001758e
cmp dword [0x10038c5c], 0
je 0x1001753e
mov eax, dword [ebp - 0x18]
push eax
mov ecx, dword [ebp - 0x38]
push ecx
mov edx, dword [ebp - 0x10]
push edx
mov eax, dword [ebp - 0x14]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000bbe0
add esp, 0x14
test eax, eax
je 0x1001758e
cmp dword [0x10038c5c], 0
jne 0x10017563
mov edx, dword [ebp - 0x18]
push edx
mov eax, dword [ebp - 0x38]
push eax
mov ecx, dword [ebp - 0xc]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000bae0
add esp, 0x10
test eax, eax
je 0x1001758e
mov dword [ebp - 0x1c], 0
push 0
lea eax, [ebp - 0x1c]
push eax
mov ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp - 0x38]
push edx
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1001758e
mov ecx, dword [ebp - 0x18]
cmp ecx, dword [ebp - 0x1c]
je 0x10017602
cmp dword [ebp - 0xc], 0
jne 0x1001759e
mov edx, dword [ebp - 0x14]
or edx, dword [ebp - 0x10]
test edx, edx
je 0x100175cd
cmp dword [0x10038c5c], 0
je 0x100175bd
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b9e0
add esp, 0xc
jmp 0x100175cd
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b8f0
add esp, 8
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.1001ee98
add esp, 4
cmp dword [ebp + 0x24], 0
je 0x100175fb
push 0
call dword [ebp + 0x24]
add esp, 4
xor eax, eax
jmp 0x10017aa0
cmp dword [0x10038c5c], 0
je 0x10017621
mov edx, dword [ebp - 0x10]
push edx
mov eax, dword [ebp - 0x14]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b9e0
add esp, 0xc
jmp 0x10017631
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000b8f0
add esp, 8
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp + 0x24], 0
je 0x1001766d
push 1
call dword [ebp + 0x24]
add esp, 4
test eax, eax
jne 0x1001766d
cmp dword [ebp + 0x24], 0
je 0x1001765b
push 0
call dword [ebp + 0x24]
add esp, 4
push 0x3e3
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x10017aa0
cmp dword [ebp + 0x20], 0
je 0x100176d5
mov dword [ebp - 0x18], 0x100
mov dword [ebp - 0x1c], 0
push 0
lea edx, [ebp - 0x1c]
push edx
mov eax, dword [ebp - 0x18]
push eax
mov ecx, dword [ebp + 0x20]
push ecx
mov edx, dword [ebp - 8]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x100176a5
mov eax, dword [ebp - 0x18]
cmp eax, dword [ebp - 0x1c]
je 0x100176d0
mov ecx, dword [ebp - 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x38]
push edx
call fcn.1001ee98
add esp, 4
cmp dword [ebp + 0x24], 0
je 0x100176c9
push 0
call dword [ebp + 0x24]
add esp, 4
xor eax, eax
jmp 0x10017aa0
jmp 0x10017a56
push 0x200
push 0
mov eax, dword [ebp - 0x38]
push eax
call fcn.1001ea50
add esp, 0xc
push 0x40
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp - 0x38]
push edx
call fcn.1001e4a0
add esp, 0xc
push 0x40
mov eax, dword [ebp + 0x14]
push eax
mov ecx, dword [ebp - 0x38]
add ecx, 0x40
push ecx
call fcn.1001e4a0
add esp, 0xc
mov dword [ebp - 0x18], 0x80
cmp dword [0x10038c5c], 0
je 0x10017744
lea edx, [ebp - 0x14]
push edx
push 0x40
mov eax, dword [ebp - 0x38]
add eax, dword [ebp - 0x18]
push eax
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b760
add esp, 0x14
test eax, eax
je 0x1001782d
cmp dword [0x10038c5c], 0
jne 0x10017772
lea eax, [ebp - 0xc]
push eax
push 0x40
mov ecx, dword [ebp - 0x38]
add ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp + 0x18]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000b5f0
add esp, 0x14
test eax, eax
je 0x1001782d
cmp dword [0x10038c5c], 0
je 0x1001779f
mov ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp - 0x38]
push edx
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000bbe0
add esp, 0x14
test eax, eax
je 0x1001782d
cmp dword [0x10038c5c], 0
jne 0x100177c4
mov eax, dword [ebp - 0x18]
push eax
mov ecx, dword [ebp - 0x38]
push ecx
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000bae0
add esp, 0x10
test eax, eax
je 0x1001782d
mov dword [ebp - 0x1c], 0
push 0
lea ecx, [ebp - 0x1c]
push ecx
mov edx, dword [ebp - 0x18]
push edx
mov eax, dword [ebp - 0x38]
push eax
mov ecx, dword [ebp - 8]
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1001782d
mov edx, dword [ebp - 0x18]
cmp edx, dword [ebp - 0x1c]
jne 0x1001782d
cmp dword [0x10038c5c], 0
je 0x10017810
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b9e0
add esp, 0xc
test eax, eax
je 0x1001782d
cmp dword [0x10038c5c], 0
jne 0x10017897
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b8f0
add esp, 8
test eax, eax
jne 0x10017897
cmp dword [ebp - 0xc], 0
jne 0x1001783d
mov edx, dword [ebp - 0x14]
or edx, dword [ebp - 0x10]
test edx, edx
je 0x1001786c
cmp dword [0x10038c5c], 0
je 0x1001785c
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b9e0
add esp, 0xc
jmp 0x1001786c
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b8f0
add esp, 8
mov edx, dword [ebp - 8]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x38]
push eax
call fcn.1001ee98
add esp, 4
cmp dword [ebp + 0x24], 0
je 0x10017890
push 0
call dword [ebp + 0x24]
add esp, 4
xor eax, eax
jmp 0x10017aa0
push 0x200
push 0
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.1001ea50
add esp, 0xc
push 0x40
mov edx, dword [ebp + 0x10]
push edx
mov eax, dword [ebp - 0x38]
push eax
call fcn.1001e4a0
add esp, 0xc
push 0x40
mov ecx, dword [ebp + 0x14]
push ecx
mov edx, dword [ebp - 0x38]
add edx, 0x40
push edx
call fcn.1001e4a0
add esp, 0xc
mov dword [ebp - 0x18], 0x80
cmp dword [0x10038c5c], 0
je 0x10017906
lea eax, [ebp - 0x14]
push eax
push 0x40
mov ecx, dword [ebp - 0x38]
add ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp + 0x1c]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000b760
add esp, 0x14
test eax, eax
je 0x100179ef
cmp dword [0x10038c5c], 0
jne 0x10017934
lea ecx, [ebp - 0xc]
push ecx
push 0x40
mov edx, dword [ebp - 0x38]
add edx, dword [ebp - 0x18]
push edx
mov eax, dword [ebp + 0x1c]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000b5f0
add esp, 0x14
test eax, eax
je 0x100179ef
cmp dword [0x10038c5c], 0
je 0x10017961
mov edx, dword [ebp - 0x18]
push edx
mov eax, dword [ebp - 0x38]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
mov edx, dword [ebp - 0x14]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000bbe0
add esp, 0x14
test eax, eax
je 0x100179ef
cmp dword [0x10038c5c], 0
jne 0x10017986
mov ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp - 0x38]
push edx
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1000bae0
add esp, 0x10
test eax, eax
je 0x100179ef
mov dword [ebp - 0x1c], 0
push 0
lea edx, [ebp - 0x1c]
push edx
mov eax, dword [ebp - 0x18]
push eax
mov ecx, dword [ebp - 0x38]
push ecx
mov edx, dword [ebp - 8]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x100179ef
mov eax, dword [ebp - 0x18]
cmp eax, dword [ebp - 0x1c]
jne 0x100179ef
cmp dword [0x10038c5c], 0
je 0x100179d2
mov ecx, dword [ebp - 0x10]
push ecx
mov edx, dword [ebp - 0x14]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000b9e0
add esp, 0xc
test eax, eax
je 0x100179ef
cmp dword [0x10038c5c], 0
jne 0x10017a56
mov ecx, dword [ebp - 0xc]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b8f0
add esp, 8
test eax, eax
jne 0x10017a56
cmp dword [ebp - 0xc], 0
jne 0x100179ff
mov eax, dword [ebp - 0x14]
or eax, dword [ebp - 0x10]
test eax, eax
je 0x10017a2e
cmp dword [0x10038c5c], 0
je 0x10017a1e
mov ecx, dword [ebp - 0x10]
push ecx
mov edx, dword [ebp - 0x14]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1000b9e0
add esp, 0xc
jmp 0x10017a2e
mov ecx, dword [ebp - 0xc]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.1000b8f0
add esp, 8
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.1001ee98
add esp, 4
cmp dword [ebp + 0x24], 0
je 0x10017a52
push 0
call dword [ebp + 0x24]
add esp, 4
xor eax, eax
jmp 0x10017aa0
mov edx, dword [ebp - 8]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x38]
push eax
call fcn.1001ee98
add esp, 4
cmp dword [ebp + 0x24], 0
je 0x10017a9b
push 1
call dword [ebp + 0x24]
add esp, 4
test eax, eax
jne 0x10017a9b
cmp dword [ebp + 0x24], 0
je 0x10017a8c
push 0
call dword [ebp + 0x24]
add esp, 4
push 0x3e3
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x10017aa0
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret