Function at 0x100ae3da
Capabilities:
Write file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100cc9ae
mov eax, dword fs:[0]
push eax
sub esp, 0x78
mov eax, dword [0x100dcd6c]
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 + 0xc]
mov ecx, eax
mov edx, dword [ebp + 0x10]
and eax, 0x3f
mov ebx, dword [ebp + 0x18]
imul esi, eax, 0x38
sar ecx, 6
mov dword [ebp - 0x64], edx
mov dword [ebp - 0x3c], ebx
mov dword [ebp - 0x4c], ecx
mov eax, dword [ecx*4 + 0x100dd0b8]
mov dword [ebp - 0x54], esi
mov eax, dword [esi + eax + 0x18]
mov dword [ebp - 0x68], eax
mov eax, dword [ebp + 0x14]
add eax, edx
mov dword [ebp - 0x50], eax
call dword [sym.imp.KERNEL32.dll_GetConsoleOutputCP]
cmp byte [ebx + 0x14], 0
mov dword [ebp - 0x78], eax
jne 0x100ae453
mov ecx, ebx
call fcn.100a0c80
mov eax, dword [ebx + 0xc]
mov ebx, dword [ebp + 8]
mov edi, ebx
mov ecx, dword [eax + 8]
xor eax, eax
stosd dword es:[edi], eax
mov dword [ebp - 0x7c], ecx
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov eax, dword [ebp - 0x64]
mov edi, eax
mov dword [ebp - 0x44], edi
cmp eax, dword [ebp - 0x50]
jae 0x100ae797
xor edx, edx
mov dword [ebp - 0x48], edx
mov dword [ebp - 0x2c], edx
mov al, byte [edi]
mov byte [ebp - 0x2d], al
mov eax, dword [ebp - 0x4c]
mov dword [ebp - 0x40], edx
mov dword [ebp - 0x34], 1
cmp ecx, 0xfde9
jne 0x100ae5c6
mov eax, dword [eax*4 + 0x100dd0b8]
mov ecx, edx
add eax, 0x2e
add eax, esi
mov dword [ebp - 0x2c], eax
cmp byte [eax], 0
je 0x100ae4ba
inc ecx
inc eax
cmp ecx, 5
jl 0x100ae4ae
mov esi, dword [ebp - 0x50]
sub esi, edi
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x6c], esi
test ecx, ecx
jle 0x100ae56c
mov eax, dword [ebp - 0x2c]
movzx eax, byte [eax]
movsx eax, byte [eax + 0x100dcc50]
inc eax
mov dword [ebp - 0x38], eax
sub eax, ecx
mov dword [ebp - 0x58], eax
cmp eax, esi
jg 0x100ae709
mov esi, edx
mov edx, dword [ebp - 0x2c]
mov al, byte [edx]
mov byte [ebp + esi - 0x18], al
inc esi
inc edx
cmp esi, ecx
jl 0x100ae4f0
mov ebx, dword [ebp - 0x58]
xor edx, edx
test ebx, ebx
jle 0x100ae517
push ebx
lea eax, [ebp - 0x18]
add eax, ecx
push edi
push eax
call fcn.100b49e0
add esp, 0xc
xor edx, edx
mov esi, dword [ebp - 0x34]
mov edi, edx
mov ebx, dword [ebp - 0x54]
mov dword [ebp - 0x2c], edx
mov eax, dword [ebp - 0x4c]
lea ecx, [ebx + edi]
inc edi
mov eax, dword [eax*4 + 0x100dd0b8]
mov byte [ecx + eax + 0x2e], dl
cmp edi, esi
jl 0x100ae522
push dword [ebp - 0x3c]
mov ebx, dword [ebp + 8]
lea eax, [ebp - 0x18]
mov edi, dword [ebp - 0x44]
lea ecx, [ebp - 0x84]
mov dword [ebp - 0x74], eax
xorps xmm0, xmm0
xor eax, eax
movlpd qword [ebp - 0x84], xmm0
cmp dword [ebp - 0x38], 4
push ecx
sete al
inc eax
mov dword [ebp - 0x34], eax
push eax
lea eax, [ebp - 0x74]
jmp 0x100ae5a4
movzx eax, byte [edi]
movsx eax, byte [eax + 0x100dcc50]
inc eax
mov dword [ebp - 0x58], eax
cmp eax, esi
jg 0x100ae744
push dword [ebp - 0x3c]
xor ecx, ecx
mov dword [ebp - 0x38], edi
cmp eax, 4
xorps xmm0, xmm0
lea eax, [ebp - 0x70]
movlpd qword [ebp - 0x70], xmm0
sete cl
inc ecx
push eax
mov dword [ebp - 0x34], ecx
lea eax, [ebp - 0x38]
push ecx
push eax
lea eax, [ebp - 0x40]
push eax
call fcn.100aaba0
add esp, 0x14
cmp eax, 0xffffffff
je 0x100ae797
add edi, dword [ebp - 0x58]
mov esi, dword [ebp - 0x54]
dec edi
jmp 0x100ae652
mov ecx, dword [eax*4 + 0x100dd0b8]
mov dword [ebp - 0x6c], ecx
mov ah, byte [esi + ecx + 0x2d]
test ah, 4
je 0x100ae5f7
mov al, byte [esi + ecx + 0x2e]
and ah, 0xfb
push dword [ebp - 0x3c]
mov byte [ebp - 0x20], al
mov al, byte [edi]
mov byte [ebp - 0x1f], al
mov byte [esi + ecx + 0x2d], ah
lea eax, [ebp - 0x20]
push 2
push eax
jmp 0x100ae63d
mov eax, dword [ebp - 0x3c]
movzx ecx, byte [edi]
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
cmp word [eax + ecx*2], dx
jge 0x100ae637
lea eax, [edi + 1]
mov dword [ebp - 0x38], eax
cmp eax, dword [ebp - 0x50]
jae 0x100ae76e
push dword [ebp - 0x3c]
lea eax, [ebp - 0x40]
push 2
push edi
push eax
call fcn.100a411b
add esp, 0x10
cmp eax, 0xffffffff
je 0x100ae797
mov edi, dword [ebp - 0x38]
jmp 0x100ae652
push dword [ebp - 0x3c]
push 1
push edi
lea eax, [ebp - 0x40]
push eax
call fcn.100a411b
add esp, 0x10
cmp eax, 0xffffffff
je 0x100ae797
inc edi
lea eax, [ebp - 0x28]
mov dword [ebp - 0x44], edi
xor edi, edi
push edi
push edi
push 5
push eax
push dword [ebp - 0x34]
lea eax, [ebp - 0x40]
push eax
push edi
push dword [ebp - 0x78]
call fcn.100aaa1c
add esp, 0x20
mov dword [ebp - 0x38], eax
test eax, eax
je 0x100ae797
push edi
lea ecx, [ebp - 0x60]
push ecx
push eax
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 0x68]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x100ae78f
mov eax, dword [ebx + 8]
sub eax, dword [ebp - 0x64]
add eax, dword [ebp - 0x44]
mov dword [ebp - 0x2c], eax
mov dword [ebx + 4], eax
mov eax, dword [ebp - 0x38]
cmp dword [ebp - 0x60], eax
jb 0x100ae797
cmp byte [ebp - 0x2d], 0xa
jne 0x100ae6f3
push 0xd
pop eax
push edi
mov word [ebp - 0x5c], ax
lea eax, [ebp - 0x60]
push eax
push 1
lea eax, [ebp - 0x5c]
push eax
push dword [ebp - 0x68]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x100ae78f
cmp dword [ebp - 0x60], 1
jb 0x100ae797
inc dword [ebx + 8]
inc dword [ebx + 4]
mov eax, dword [ebx + 4]
mov dword [ebp - 0x2c], eax
mov edi, dword [ebp - 0x44]
cmp edi, dword [ebp - 0x50]
jae 0x100ae797
mov ecx, dword [ebp - 0x7c]
xor edx, edx
jmp 0x100ae47f
test esi, esi
jle 0x100ae73f
mov eax, dword [ebp - 0x44]
mov ebx, dword [ebp - 0x54]
mov edi, dword [ebp - 0x48]
lea esi, [ebx + edx]
add esi, ecx
mov ecx, dword [ebp - 0x4c]
mov edx, dword [ecx*4 + 0x100dd0b8]
mov cl, byte [edi + eax]
mov byte [esi + edx + 0x2e], cl
mov edx, edi
mov esi, dword [ebp - 0x6c]
inc edx
mov ecx, dword [ebp - 0x34]
mov dword [ebp - 0x48], edx
cmp edx, esi
jl 0x100ae713
mov ebx, dword [ebp + 8]
add dword [ebx + 4], esi
jmp 0x100ae797
test esi, esi
jle 0x100ae73f
mov ebx, dword [ebp - 0x44]
mov eax, dword [ebp - 0x4c]
mov edi, dword [ebp - 0x48]
add edx, dword [ebp - 0x54]
mov ecx, dword [eax*4 + 0x100dd0b8]
mov al, byte [edi + ebx]
mov byte [edx + ecx + 0x2e], al
mov edx, edi
inc edx
mov dword [ebp - 0x48], edx
cmp edx, esi
jl 0x100ae74b
jmp 0x100ae73c
mov eax, dword [ebp - 0x6c]
mov cl, byte [edi]
mov byte [esi + eax + 0x2e], cl
mov eax, dword [ebp - 0x4c]
mov eax, dword [eax*4 + 0x100dd0b8]
or byte [esi + eax + 0x2d], 4
mov eax, dword [ebp - 0x2c]
inc eax
mov dword [ebx + 4], eax
jmp 0x100ae797
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebx], eax
mov eax, ebx
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.100b2d85
leave
ret