Function at 0x4010f0
Capabilities:
Access peb ldr_data
Get kernel32 base address
Get process heap flags
Write file on windows

Disassembly:
lea ecx, [esp + 4]
and esp, 0xfffffff0
push dword [ecx - 4]
push ebp
mov ebp, esp
sub esp, 0x998
mov dword [ebp - 0xc], ebx
mov ebx, dword [section..bss]
mov dword [ebp - 0x10], ecx
mov dword [ebp - 8], esi
mov dword [ebp - 4], edi
test ebx, ebx
mov edi, dword [ecx]
je 0x401130
mov ecx, dword [ebp - 0x10]
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 4]
mov esp, ebp
pop ebp
lea esp, [ecx - 4]
ret
mov dword [esp], 0
lea esi, [ebp - 0x818]
mov ebx, ecx
call dword [sym.imp.kernelbase.dll_GetModuleHandleW]
mov ecx, 0x400
sub esp, 4
mov dword [esp + 0xc], ecx
mov dword [esp + 8], esi
mov dword [esp + 4], edi
mov dword [esp], eax
call sym._LoadStringW_16
sub esp, 0x10
test eax, eax
jne 0x4011b0
test byte [section..data], 1
je 0x40111b
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x34]
mov edx, section..data
mov dword [esp + 4], edx
mov dword [esp], 0
mov dword [esp + 0x10], eax
mov eax, str.LoadString_failed_with__ld_n
mov dword [esp + 0xc], eax
mov eax, str.output_write
mov dword [esp + 8], eax
call sym._wine_dbg_log.constprop.0
jmp 0x40111b
mov dword [esp + 4], esi
lea eax, [ebp - 0x94c]
add ebx, 4
mov dword [esp + 0x18], eax
xor eax, eax
mov dword [esp + 0x14], eax
lea eax, [ebp - 0x948]
mov dword [esp + 0x10], eax
xor eax, eax
mov dword [esp + 0xc], eax
xor eax, eax
mov dword [esp + 8], eax
mov dword [esp], 0x500
mov dword [ebp - 0x94c], ebx
call dword [sym.imp.kernelbase.dll_FormatMessageW]
sub esp, 0x1c
test eax, eax
mov ebx, eax
jne 0x401300
mov eax, dword fs:[0x18]
cmp dword [eax + 0x34], 0xeb
je 0x401300
test byte [section..data], 1
je 0x40111b
mov eax, esi
shr eax, 0x10
je 0x4015b7
mov dword [esp], esi
mov edi, 0xffffffff
mov dword [esp + 4], edi
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
sub esp, 8
test eax, eax
jne 0x4015d4
cmp word [ebp - 0x818], 0
je 0x4015db
lea esi, [esi]
lea edi, [edi]
mov edx, eax
cmp word [esi + edx*2 + 2], 0
lea eax, [eax + 1]
jne 0x401260
lea eax, [ebp - 0x822]
mov ecx, 0x224c
mov word [ebp - 0x944], cx
lea ecx, [ebp - 0x942]
mov dword [ebp - 0x95c], eax
jmp 0x4012c9
cmp eax, 9
je 0x401540
cmp eax, 0xa
jne 0x4014e2
mov word [ecx], 0x6e5c
add ecx, 2
lea esi, [esi]
lea eax, [edx - 1]
test edx, edx
jle 0x401550
cmp ecx, dword [ebp - 0x95c]
ja 0x401550
mov edx, eax
movzx eax, word [esi]
add esi, 2
cmp eax, 0xd
je 0x4014c8
jbe 0x401290
cmp eax, 0x22
je 0x401530
cmp eax, 0x5c
jne 0x4014d5
mov word [ecx], 0x5c5c
add ecx, 2
jmp 0x4012b0
mov dword [esp], 0xfffffff5
mov edx, dword [ebp - 0x948]
lea esi, [ebp - 0x944]
mov edi, dword [sym.imp.kernelbase.dll_GetStdHandle]
mov dword [ebp - 0x95c], edx
call edi
xor edx, edx
sub esp, 4
mov dword [esp + 0x10], edx
mov edx, dword [ebp - 0x95c]
mov dword [esp + 0xc], esi
mov dword [esp + 8], ebx
mov dword [esp], eax
mov dword [esp + 4], edx
call dword [sym.imp.kernelbase.dll_WriteConsoleW]
sub esp, 0x14
test eax, eax
je 0x401368
mov eax, dword [ebp - 0x948]
mov dword [esp], eax
call dword [sym.imp.kernelbase.dll_LocalFree]
sub esp, 4
jmp 0x40111b
mov edx, dword [ebp - 0x948]
mov eax, dword [sym.imp.kernelbase.dll_GetConsoleOutputCP]
mov dword [ebp - 0x95c], edx
mov dword [ebp - 0x960], eax
call eax
xor edx, edx
xor ecx, ecx
mov dword [esp + 0x1c], edx
xor edx, edx
mov dword [esp + 0x14], edx
mov edx, dword [ebp - 0x95c]
mov dword [esp + 0x18], ecx
xor ecx, ecx
mov dword [esp + 0x10], ecx
mov dword [esp + 0xc], ebx
mov dword [esp + 8], edx
xor edx, edx
mov dword [esp + 4], edx
mov edx, dword [sym.imp.kernelbase.dll_WideCharToMultiByte]
mov dword [esp], eax
mov dword [ebp - 0x964], edx
call edx
mov ecx, dword fs:[0x18]
mov dword [ebp - 0x96c], ecx
mov dword [ebp - 0x95c], eax
sub esp, 0x20
mov dword [esp + 8], eax
xor eax, eax
mov dword [esp + 4], eax
mov eax, dword [ecx + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernelbase.dll_HeapAlloc]
mov dword [ebp - 0x968], eax
sub esp, 0xc
test eax, eax
je 0x40134c
mov ecx, dword [ebp - 0x948]
mov dword [ebp - 0x970], ecx
mov ecx, dword [ebp - 0x960]
call ecx
xor edx, edx
xor ecx, ecx
mov dword [esp + 0x1c], edx
mov edx, dword [ebp - 0x95c]
mov dword [esp + 0x18], ecx
mov ecx, dword [ebp - 0x970]
mov dword [esp + 0xc], ebx
xor ebx, ebx
mov dword [esp + 4], ebx
mov ebx, dword [ebp - 0x964]
mov dword [esp + 0x14], edx
mov edx, dword [ebp - 0x968]
mov dword [esp + 8], ecx
mov dword [esp], eax
mov dword [esp + 0x10], edx
mov dword [ebp - 0x960], edx
call ebx
sub esp, 0x20
mov dword [esp], 0xfffffff5
call edi
mov edx, dword [ebp - 0x95c]
xor edi, edi
sub esp, 4
mov dword [esp + 8], edx
mov edx, dword [ebp - 0x960]
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], esi
mov dword [esp], eax
mov dword [esp + 4], edx
mov dword [ebp - 0x95c], edx
call dword [sym.imp.kernelbase.dll_WriteFile]
mov edx, dword [ebp - 0x95c]
xor eax, eax
mov ecx, dword [ebp - 0x96c]
sub esp, 0x14
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov eax, dword [ecx + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernelbase.dll_HeapFree]
sub esp, 0xc
jmp 0x40134c
mov word [ecx], 0x725c
add ecx, 2
jmp 0x4012b0
lea edi, [eax - 0x20]
cmp di, 0x5e
jbe 0x4015cc
mov byte [ecx], 0x5c
mov edi, eax
add ecx, 5
shr edi, 0xc
movzx ebx, byte [edi + str.0123456789abcdefreexec_self]
mov edi, eax
shr edi, 8
and edi, 0xf
mov byte [ecx - 4], bl
movzx ebx, byte [edi + str.0123456789abcdefreexec_self]
mov edi, eax
shr edi, 4
and eax, 0xf
and edi, 0xf
movzx eax, byte [eax + str.0123456789abcdefreexec_self]
mov byte [ecx - 3], bl
movzx ebx, byte [edi + str.0123456789abcdefreexec_self]
mov byte [ecx - 1], al
mov byte [ecx - 2], bl
jmp 0x4012b0
mov word [ecx], 0x225c
add ecx, 2
jmp 0x4012b0
mov word [ecx], 0x745c
add ecx, 2
jmp 0x4012b0
mov byte [ecx], 0x22
test eax, eax
jle 0x4015f4
mov word [ecx + 1], 0x2e2e
lea eax, [ecx + 4]
mov byte [ecx + 3], 0x2e
mov byte [eax], 0
lea eax, [ebp - 0x944]
mov dword [esp], eax
call sym.___wine_dbg_strdup
mov dword [esp + 0x14], eax
mov ecx, str.Could_not_format_string:_le_lu__fmt_s_n
mov ebx, str.output_write
mov edx, dword fs:[0x18]
mov eax, dword [edx + 0x34]
mov esi, section..data
mov dword [esp + 0xc], ecx
mov dword [esp + 8], ebx
mov dword [esp + 4], esi
mov dword [esp + 0x10], eax
mov dword [esp], 0
call sym._wine_dbg_log.constprop.0
jmp 0x40111b
mov dword [esp], str._04x
movzx esi, si
mov dword [esp + 4], esi
call sym._wine_dbg_sprintf.constprop.0
jmp 0x401579
mov byte [ecx], al
inc ecx
jmp 0x4012b0
mov eax, str._invalid_
jmp 0x401579
mov byte [ebp - 0x942], 0x22
lea ecx, [ebp - 0x942]
mov eax, 0x224c
mov word [ebp - 0x944], ax
lea eax, [ecx + 1]
jmp 0x401568