Function at 0x1099014
Capabilities:
Write file on windows

Disassembly:
push 0x824
mov eax, 0x10bf4ad
call fcn.01074cf3
lea eax, [ebp - 0x414]
mov dword [ebp - 0x820], eax
mov edi, 0x200
xor ebx, ebx
mov dword [ebp - 0x824], ebx
mov dword [ebp - 0x81c], ebx
cmp dword [ebp + 8], ebx
jne 0x109904e
mov dword [ebp + 8], 0x101de4c
xor eax, eax
mov ecx, dword [ebp + 8]
cmp ax, word [ecx]
jne 0x10990b0
mov dword [ebp - 0x828], ebx
cmp dword [ebp - 0x820], 0
je 0x1099081
lea eax, [ebp - 0x414]
cmp eax, dword [ebp - 0x820]
je 0x1099081
push dword [ebp - 0x820]
call dword [sym.imp.KERNEL32.dll_LocalFree]
cmp dword [ebp - 0x824], 0
je 0x10990a4
lea eax, [ebp - 0x814]
cmp eax, dword [ebp - 0x824]
je 0x10990a4
push dword [ebp - 0x824]
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp - 0x828]
call fcn.01074d5e
ret
cmp dword [0x10d0934], ebx
jne 0x10990fc
push 0x101de38
mov esi, dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
call esi
test eax, eax
je 0x10990da
push 0x101de2c
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x10d0934], eax
xor ebx, ebx
cmp dword [0x10d0934], ebx
jne 0x10990fc
push 0x101de14
call esi
push 0x101de2c
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x10d0934], eax
push 0xfffffffffffffff5
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov dword [ebp - 0x818], eax
cmp eax, ebx
jne 0x1099129
or dword [ebp - 0x818], 0xffffffff
push 0x80004003
push 0x2ff01a1
push 0x101ddf0
call fcn.01089421
mov eax, dword [0x10d0934]
cmp eax, ebx
je 0x109913a
cmp dword [0x10d0930], ebx
je 0x1099141
or dword [ebp - 0x818], 0xffffffff
cmp dword [ebp - 0x818], 0xffffffff
je 0x1099241
lea ecx, [ebp + 0xc]
push ecx
push dword [ebp + 8]
push edi
lea ecx, [ebp - 0x414]
push ecx
call eax
add esp, 0x10
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x10991f0
mov esi, 0x10000
cmp edi, esi
jae 0x10991c9
lea eax, [ebp - 0x414]
cmp dword [ebp - 0x820], eax
je 0x1099190
push dword [ebp - 0x820]
call dword [sym.imp.KERNEL32.dll_LocalFree]
add edi, edi
cmp edi, esi
jbe 0x1099198
mov edi, esi
lea eax, [edi + edi]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [ebp - 0x820], eax
test eax, eax
je 0x10991da
lea ecx, [ebp + 0xc]
push ecx
push dword [ebp + 8]
push edi
push eax
call dword [0x10d0934]
add esp, 0x10
mov ebx, eax
cmp ebx, 0xffffffff
je 0x1099172
jmp 0x10991f0
push 0x8007006f
push 0x31701a1
call fcn.010893e6
jmp 0x109923a
push 0x8007000e
push 0x32701a1
call fcn.010893e6
or dword [ebp - 0x818], 0xffffffff
cmp dword [ebp - 0x818], 0xffffffff
je 0x1099241
push dword [ebp - 0x818]
call dword [sym.imp.KERNEL32.dll_GetFileType]
and eax, 0xffff7fff
sub eax, 0
je 0x109921f
dec eax
dec eax
je 0x1099241
mov dword [ebp - 0x81c], 1
jmp 0x1099241
mov eax, 0x8000ffff
push eax
push eax
push 0x34001a1
call fcn.01089403
mov dword [0x10d0930], 1
or dword [ebp - 0x818], 0xffffffff
xor edi, edi
mov dword [ebp - 0x828], edi
cmp dword [ebp - 0x818], 0xffffffff
je 0x1099405
cmp dword [ebp - 0x81c], edi
jne 0x109929b
push edi
lea eax, [ebp - 0x828]
push eax
push ebx
push dword [ebp - 0x820]
push dword [ebp - 0x818]
call dword [sym.imp.KERNEL32.dll_WriteConsoleW]
test eax, eax
jne 0x10993f8
call fcn.0108edc3
push 0x80070006
push eax
push 0x35201a1
call fcn.01089403
jmp 0x10993f1
lea esi, [ebx + ebx + 2]
cmp esi, 0x400
ja 0x10992b5
lea eax, [ebp - 0x814]
mov dword [ebp - 0x824], eax
jmp 0x10992dd
push esi
push edi
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [ebp - 0x824], eax
cmp eax, edi
jne 0x10992dd
push 0x8007000e
push 0x36801a1
call fcn.010893e6
or dword [ebp - 0x818], 0xffffffff
cmp dword [ebp - 0x818], 0xffffffff
je 0x1099405
mov edi, ebx
xor eax, eax
cmp ebx, eax
je 0x109934b
push eax
push eax
push esi
push dword [ebp - 0x824]
push ebx
push dword [ebp - 0x820]
push eax
mov esi, dword [sym.imp.KERNEL32.dll_GetACP]
call esi
push eax
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov edi, eax
test edi, edi
jne 0x1099352
call fcn.0108edc3
push eax
push 0x38401a1
call fcn.010893e6
call esi
push eax
push 0x38501a1
push dword [ebp - 0x820]
call fcn.01089421
push ebx
push 0x38601a1
push 0x101dde4
call fcn.01089421
or dword [ebp - 0x818], 0xffffffff
cmp dword [ebp - 0x818], 0xffffffff
je 0x1099405
mov esi, dword [ebp - 0x824]
mov dword [ebp - 0x828], ebx
and dword [ebp - 0x81c], 0
test edi, edi
jbe 0x10993ad
cmp byte [esi], 0xa
jne 0x109939e
lea ebx, [esi + 1]
mov eax, edi
sub eax, dword [ebp - 0x81c]
push eax
push esi
push ebx
call dword [sym.imp.msvcrt.dll_memmove]
add esp, 0xc
mov byte [esi], 0xd
mov esi, ebx
inc dword [ebp - 0x81c]
inc edi
inc dword [ebp - 0x81c]
inc esi
cmp dword [ebp - 0x81c], edi
jb 0x1099376
push 0
lea eax, [ebp - 0x82c]
push eax
push edi
push dword [ebp - 0x824]
push dword [ebp - 0x818]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x10993f8
call fcn.0108edc3
mov esi, eax
push esi
push 0x3ab01a1
call fcn.010893e6
cmp esi, 0x80070006
jne 0x10993f8
mov dword [0x10d0930], 1
or dword [ebp - 0x818], 0xffffffff
cmp dword [ebp - 0x818], 0xffffffff
jne 0x109905e
and dword [ebp - 4], 0
push 0x1032777
lea ecx, [ebp - 0x81c]
call fcn.0103215d
mov byte [ebp - 4], 1
lea eax, [ebp + 0xc]
push eax
push dword [ebp + 8]
call dword [sym.imp.msvcrt.dll___iob_func]
add eax, 0x20
push eax
call dword [sym.imp.msvcrt.dll_vfwprintf]
mov dword [ebp - 0x828], eax
mov byte [ebp - 4], 0
push dword [ebp - 0x81c]
call dword [sym.imp.msvcrt.dll_void____cdecl___unsigned_int__struct__EXCEPTION_POINTERS_____cdecl__set_se_translator_void____cdecl___unsigned_int__struct__EXCEPTION_POINTERS___]
add esp, 0x10
or dword [ebp - 4], 0xffffffff
jmp 0x109905e