Function at 0x437530
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x46fb68
mov eax, dword fs:[0]
push eax
sub esp, 0x6c
mov eax, dword [0x491d58]
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, dword [ebp + 8]
xor ebx, ebx
push ebx
push ebx
push ebx
push ebx
mov esi, ecx
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x5c], ebx
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov edi, eax
mov dword [ebp - 0x78], edi
mov dword [ebp - 4], ebx
cmp edi, ebx
jne 0x4375f4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x58], eax
mov eax, 7
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x20], eax
xor ecx, ecx
xor edx, edx
mov eax, 1
mov dword [ebp - 0x54], vtable.LogItem.0
mov dword [ebp - 0x40], ebx
mov word [ebp - 0x50], cx
mov dword [ebp - 0x24], ebx
mov word [ebp - 0x34], dx
mov dword [ebp - 0x18], eax
mov byte [ebp - 4], al
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x58]
push eax
push str.Cannot_create_write_event._Error:
lea ecx, [ebp - 0x54]
call fcn.00403090
mov ecx, eax
call fcn.00402eb0
lea ecx, [ebp - 0x54]
mov byte [ebp - 4], bl
call fcn.00402d10
mov edx, dword [esi]
mov eax, dword [edx + 8]
mov ecx, esi
call eax
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or eax, 0xffffffff
jmp 0x43779d
mov eax, dword [ebp + 0xc]
lea ecx, [ebp - 0x74]
push ecx
mov ecx, dword [ebp - 0x58]
lea edx, [ebp - 0x5c]
push edx
mov edx, dword [esi + 0x20]
push eax
push ecx
push edx
mov dword [ebp - 0x64], edi
mov dword [ebp - 0x6c], ebx
mov dword [ebp - 0x68], ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x58], eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x60], eax
cmp dword [ebp - 0x58], ebx
jne 0x4376c1
cmp eax, 0x3e5
je 0x4376c1
mov eax, 7
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x20], eax
xor ecx, ecx
xor edx, edx
mov eax, 1
mov dword [ebp - 0x54], vtable.LogItem.0
mov dword [ebp - 0x40], ebx
mov word [ebp - 0x50], cx
mov dword [ebp - 0x24], ebx
mov word [ebp - 0x34], dx
mov dword [ebp - 0x18], eax
mov byte [ebp - 4], 2
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x60]
push eax
push str._Error:
lea ecx, [ebp - 0x58]
push ecx
push str.Write_to_device_failed._Return_code:
lea ecx, [ebp - 0x54]
call fcn.00403090
mov ecx, eax
call fcn.00402fa0
mov ecx, eax
call fcn.00403090
mov ecx, eax
call fcn.00402eb0
lea ecx, [ebp - 0x54]
mov byte [ebp - 4], bl
call fcn.00402d10
mov edx, dword [esi]
mov eax, dword [edx + 8]
mov ecx, esi
call eax
cmp edi, 0xffffffff
je 0x4376b9
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or eax, 0xffffffff
jmp 0x43779d
mov ecx, dword [esi + 0x24]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x437728
mov eax, 7
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x20], eax
xor eax, eax
mov word [ebp - 0x34], ax
xor edx, edx
mov eax, 1
mov dword [ebp - 0x54], vtable.LogItem.0
mov dword [ebp - 0x40], ebx
mov word [ebp - 0x50], dx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x18], eax
mov byte [ebp - 4], 3
push str.Timeout_occured_while_writing_to_heci_device.
lea ecx, [ebp - 0x54]
mov dword [ebp - 0x14], eax
call fcn.00403090
lea ecx, [ebp - 0x54]
mov byte [ebp - 4], bl
call fcn.00402d10
push esi
mov ecx, edi
call fcn.00436240
jmp 0x4376ad
mov eax, dword [esi + 0x20]
push ebx
lea ecx, [ebp - 0x5c]
push ecx
lea edx, [ebp - 0x74]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetOverlappedResult]
cmp eax, ebx
jne 0x43778c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x58], eax
mov eax, 7
xor ecx, ecx
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x20], eax
xor edx, edx
mov eax, 1
mov dword [ebp - 0x54], vtable.LogItem.0
mov dword [ebp - 0x40], ebx
mov word [ebp - 0x50], cx
mov dword [ebp - 0x24], ebx
mov word [ebp - 0x34], dx
mov dword [ebp - 0x18], eax
mov byte [ebp - 4], 4
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x58]
push eax
push str.Write_function_fail_to_finish._Error:
lea ecx, [ebp - 0x54]
jmp 0x43768d
mov esi, dword [ebp - 0x5c]
cmp edi, 0xffffffff
je 0x43779b
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
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.0044ce4c
mov esp, ebp
pop ebp
ret 8