Function at 0x100194ed
Capabilities:
Write file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x10023230]
xor eax, ebp
mov dword [ebp - 4], eax
or dword [ebp - 0xc], 0xffffffff
push ebx
push esi
mov ebx, ecx
xor ecx, ecx
mov esi, ebx
mov dword [ebp - 8], ecx
neg esi
mov dword [ebp - 0x14], ecx
push edi
lea eax, [ebx + 8]
mov dword [ebp - 0x10], ecx
sbb esi, esi
mov edi, ecx
and esi, eax
je 0x1001952e
lea eax, [esi + 4]
push eax
call dword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_EnterCriticalSection]
xor ecx, ecx
cmp dword [ebx + 0x98], ecx
jne 0x10019540
mov edi, 0x802a0035
jmp 0x100196c5
mov eax, dword [ebx + 0x94]
test eax, eax
jne 0x10019554
mov edi, 0x80004005
jmp 0x100196ce
cmp dword [ebx + 0x9c], ecx
jne 0x100196c5
push ecx
push 0x80
push 2
push ecx
push 1
push 0xc0000000
push eax
call dword [sym.imp.api_ms_win_core_file_l1_1_0.dll_CreateFileW]
mov dword [ebp - 0xc], eax
cmp eax, 0xffffffff
jne 0x100195b1
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
test eax, eax
je 0x100195a7
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov edi, eax
test edi, edi
jle 0x100196c5
movzx edi, di
or edi, 0x80070000
jmp 0x100196c5
mov edi, 0x8000ffff
jmp 0x100196c5
mov eax, dword [ebx]
lea ecx, [ebp - 0x10]
push ecx
push ebx
mov edi, dword [eax + 0x14]
mov ecx, edi
call dword [0x100241f0]
call edi
push 1
mov ecx, ebx
call fcn.10019ccf
mov edi, eax
test edi, edi
js 0x100196c5
jmp 0x10019627
push 0
lea ecx, [ebp - 0x14]
push ecx
push eax
mov eax, dword [ebx + 0x78]
add eax, dword [ebx + 0x80]
push eax
push dword [ebp - 0xc]
call dword [sym.imp.api_ms_win_core_file_l1_1_0.dll_WriteFile]
test eax, eax
jne 0x10019615
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov edi, eax
test edi, edi
jle 0x1001960f
movzx edi, di
or edi, 0x80070000
test edi, edi
js 0x100196c5
mov eax, dword [ebp - 8]
add dword [ebx + 0x84], eax
mov eax, dword [ebp - 0x14]
add dword [ebx + 0x80], eax
lea eax, [ebp - 8]
mov ecx, ebx
push eax
call fcn.10019bc8
mov eax, dword [ebp - 8]
test eax, eax
jne 0x100195da
mov eax, dword [ebx + 0x84]
mov edi, eax
sub edi, dword [ebx + 0x30]
neg edi
sbb edi, edi
and edi, 0x802a0021
cmp eax, dword [ebx + 0x30]
jne 0x100196c5
push 0
mov ecx, ebx
call fcn.10019ccf
mov edi, eax
test edi, edi
js 0x100196c5
push dword [ebp - 0xc]
call dword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
lea edx, [ebx + 0x90]
mov ecx, dword [ebx + 0x94]
or dword [ebp - 0xc], 0xffffffff
mov dword [ebp - 0x18], eax
call fcn.1001557a
mov edi, eax
test edi, edi
js 0x100196c5
mov eax, dword [ebx + 0x90]
lea edx, [ebp - 0x18]
push edx
push eax
mov ecx, dword [eax]
mov edi, dword [ecx + 0x10]
mov ecx, edi
call dword [0x100241f0]
call edi
mov edi, eax
test edi, edi
js 0x100196c5
mov eax, dword [ebp - 0x18]
cmp eax, dword [ebp - 0x10]
je 0x100196bb
mov edi, 0x80004005
jmp 0x100196c5
mov dword [ebx + 0x9c], 1
push dword [ebp - 0xc]
call dword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
test esi, esi
je 0x100196dc
add esi, 4
push esi
call dword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_LeaveCriticalSection]
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1001fd10
mov esp, ebp
pop ebp
ret