Function at 0x1000372b
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [0x10010008]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push 6
mov esi, ecx
mov bx, dx
push 1
push 2
mov word [ebp - 0x1a], bx
call dword [esi + 0x1ac]
mov ecx, eax
lea eax, [esi + 0x1a4]
push 4
push eax
push 0x1006
push 0xffff
push ecx
mov dword [esi + 0x190], ecx
call dword [esi + 0x1b0]
mov ecx, dword [esi + 0x190]
cmp ecx, 0xffffffff
je 0x10003997
push 0x10
lea eax, [esi + 0x194]
push eax
push ecx
call dword [esi + 0x1c0]
test eax, eax
jne 0x1000397a
mov al, byte [ebp + 8]
lea ecx, [ebp - 0x18]
and dword [ebp - 0x18], 0
mov byte [ebp - 5], al
lea eax, [ebp - 8]
push 4
push eax
mov byte [ebp - 8], 1
mov word [ebp - 7], bx
call fcn.10004bce
xor ecx, ecx
call fcn.10003185
lea edi, [eax + 8]
push edi
call fcn.1000b4f5
mov ebx, eax
mov ecx, ebx
call fcn.10003185
mov ecx, eax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x20], ecx
push 4
mov dword [ecx + ebx], eax
lea eax, [ecx + 4]
lea ecx, [ebp - 8]
add eax, ebx
push ecx
push eax
call dword [sym.imp.VCRUNTIME140.dll_memcpy]
add esp, 0x10
push 0
push edi
push ebx
push dword [esi + 0x190]
call dword [esi + 0x1c8]
test eax, eax
jle 0x10003963
push 0
push edi
push ebx
push dword [esi + 0x190]
call dword [esi + 0x1cc]
cmp eax, edi
jne 0x1000395f
mov ecx, ebx
call fcn.100031e6
test al, al
je 0x1000395b
mov eax, dword [ebp - 0x20]
lea ecx, [ebp - 0x18]
and dword [ebp - 0x18], 0
sub edi, eax
sub edi, 4
push edi
lea edi, [eax + 4]
add edi, ebx
push edi
call fcn.10004bce
mov ecx, dword [ebp - 0x20]
mov eax, dword [ecx + ebx]
cmp eax, dword [ebp - 0x18]
jne 0x10003957
mov eax, dword [edi]
mov dword [ebp - 8], eax
mov cl, byte [ebp - 8]
cmp cl, 0x7e
jne 0x1000394a
mov ecx, eax
shr ecx, 8
cmp cx, word [ebp - 0x1a]
jne 0x10003946
shr eax, 0x18
cmp al, byte [ebp + 8]
jne 0x10003942
push 0xfffffffffffffffe
pop ecx
call fcn.1000322c
push eax
call fcn.10002e1e
push ebx
call fcn.1000b4f0
push 0x401
call fcn.1000b4f5
mov ebx, 0x200
mov edi, eax
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
push ebx
push 0
push eax
call dword [sym.imp.VCRUNTIME140.dll_memset]
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x14], 0xd373f151
mov dword [ebp - 0x10], 0xb33a5371
mov word [ebp - 0xc], 0x32d2
mov byte [ebp - 0xa], 0xff
call fcn.10001e95
push 0xb
mov eax, ecx
mov ebx, 0x10010ba4
push eax
push ebx
call dword [sym.imp.VCRUNTIME140.dll_memcpy]
push 0x1000d6c0
push ebx
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
add esp, 0x30
mov ebx, eax
jmp 0x10003911
push eax
push 1
push edi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
push 0
push 0x400
push edi
push dword [esi + 0x190]
call dword [esi + 0x1cc]
push ebx
test eax, eax
jg 0x10003904
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
pop ecx
push dword [esi + 0x190]
call dword [esi + 0x1b4]
xor eax, eax
inc eax
jmp 0x100039a8
push 9
jmp 0x10003965
push 8
jmp 0x10003965
cmp cl, 0xff
jne 0x10003953
push 0xa
jmp 0x10003965
push 7
jmp 0x10003965
push 6
jmp 0x10003965
push 5
jmp 0x10003965
push 4
jmp 0x10003965
push 3
pop ecx
call fcn.1000322c
push eax
call fcn.10002e1e
pop ecx
push ebx
call fcn.1000b4f0
jmp 0x10003988
push 2
pop ecx
call fcn.1000322c
push eax
call fcn.10002e1e
pop ecx
push dword [esi + 0x190]
call dword [esi + 0x1b4]
jmp 0x100039a6
xor ecx, ecx
inc ecx
call fcn.1000322c
push eax
call fcn.10002e1e
pop ecx
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1000b214
leave
ret