Function at 0x473c0c
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov dword [ebp - 0xc], edi
mov dword [ebp - 8], esi
mov dword [ebp - 0x10], ebx
mov edi, eax
movsx eax, word [ebp + 0x1c]
mov dword [ebp - 4], edx
movsx edx, word [ebp + 0x18]
push eax
movsx esi, cx
movsx ecx, word [ebp + 0x14]
push edx
push ecx
push esi
push edi
call fcn.0047e72c
push eax
call fcn.0048b682
add esp, 0x18
mov ebx, eax
test ebx, ebx
je 0x473e47
movsx eax, word [ebp + 0x1c]
movsx edx, word [ebp + 0x18]
movsx ecx, word [ebp + 0x14]
push ebx
push eax
push edx
push ecx
push esi
push edi
call fcn.0047ece0
add esp, 0x18
call fcn.0047308c
movsx eax, ax
test eax, eax
je 0x473c8c
push 0xfffffffffffffff1
call fcn.0047307c
pop ecx
mov ebx, dword [ebp - 0x10]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 0xc]
mov eax, 0xffffffff
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp - 4]
mov eax, dword [ebx + 0xa]
mov dword [ebp - 0x24], 0xc
lea edi, [ebx + 0xe]
lea edx, [ebp - 0x24]
add eax, ebx
mov dword [ebp - 0x14], eax
xor ecx, ecx
mov dword [ebp - 0x20], ecx
push ecx
mov dword [ebp - 0x1c], ecx
push 0x80
push 2
push edx
push ecx
push 0xc0000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x473e3e
lea eax, [ebp - 0x18]
push 0
push eax
push 0xe
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x473e24
mov eax, dword [ebp - 0x18]
cmp eax, 0xe
je 0x473d00
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0xffffffffffffffef
call fcn.0047307c
jmp 0x473e2b
lea eax, [ebp - 0x18]
push 0
push eax
push 0x28
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x473e1b
mov eax, dword [ebp - 0x18]
cmp eax, 0x28
jne 0x473e0b
movzx ecx, word [edi + 0xe]
cmp ecx, 0x20
jae 0x473d8e
mov eax, 1
shl eax, cl
test eax, 0x112
je 0x473d8e
mov eax, 1
shl eax, cl
mov dword [ebp - 4], eax
test eax, eax
je 0x473da4
mov edx, eax
lea eax, [ebp - 0x18]
push 0
shl edx, 2
lea ecx, [ebx + 0x36]
mov dword [ebp - 4], edx
push eax
push edx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x473d82
mov eax, dword [ebp - 4]
cmp eax, dword [ebp - 0x18]
je 0x473da4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0xffffffffffffffef
call fcn.0047307c
jmp 0x473e2b
push 0xffffffffffffffef
call fcn.0047307c
jmp 0x473e2b
add ecx, 0xfffffff0
cmp ecx, 0x20
jae 0x473dfa
mov eax, 1
shl eax, cl
test eax, 0x10101
je 0x473dfa
mov edx, dword [ebp - 0x14]
lea eax, [ebp - 0x18]
push 0
push eax
push dword [edi + 0x14]
push edx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x473df1
mov eax, dword [ebp - 0x18]
cmp eax, dword [edi + 0x14]
je 0x473dd4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0xffffffffffffffef
call fcn.0047307c
jmp 0x473e2b
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call fcn.0048b5a5
pop ecx
mov ebx, dword [ebp - 0x10]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 0xc]
xor eax, eax
mov esp, ebp
pop ebp
ret
push 0xffffffffffffffef
call fcn.0047307c
jmp 0x473e2b
push 0xfffffffffffffffd
call fcn.0047307c
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x473e2c
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0xffffffffffffffef
call fcn.0047307c
jmp 0x473e2b
push 0xffffffffffffffef
call fcn.0047307c
jmp 0x473e2b
push 0xffffffffffffffef
call fcn.0047307c
pop ecx
mov ebx, dword [ebp - 0x10]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 0xc]
mov eax, 0xffffffff
mov esp, ebp
pop ebp
ret
push 0xfffffffffffffff0
call fcn.0047307c
jmp 0x473e2b
push 0xfffffffffffffff8
call fcn.0047307c
pop ecx
mov ebx, dword [ebp - 0x10]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 0xc]
mov eax, 0xffffffff
mov esp, ebp
pop ebp
ret