Function at 0x41cde2
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
mov dword [ebp - 0x3c], ecx
mov byte [ebp - 0x18], 1
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0xffffffff
jne 0x41ce47
cmp dword [ebp + 0x28], 0
je 0x41ce40
mov ecx, dword [ebp + 8]
push ecx
push 0xef8d
push 1
mov edx, dword [ebp + 0x28]
push edx
call fcn.00471dc5
add esp, 0x10
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov ecx, dword [ebp + 0x28]
call fcn.00471f57
xor al, al
jmp 0x41d22b
cmp dword [ebp + 0xc], 0
jne 0x41ce64
cmp dword [ebp + 0x10], 0
jne 0x41ce64
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
jmp 0x41d22b
mov byte [ebp - 0x2c], 0
mov dword [ebp - 0x30], 0
cmp dword [ebp + 0x14], 0
je 0x41ceb1
mov ecx, dword [ebp + 0x14]
xor edx, edx
mov dx, word [ecx + 0xa]
mov eax, dword [ebp + 0x14]
add eax, edx
mov dword [ebp - 0x30], eax
mov ecx, dword [ebp - 0x30]
cmp ecx, dword [ebp + 0x18]
ja 0x41cea0
mov edx, dword [ebp + 0x14]
xor eax, eax
mov al, byte [edx + 9]
mov ecx, dword [ebp - 0x30]
add ecx, eax
cmp ecx, dword [ebp + 0x18]
jbe 0x41ceb1
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor al, al
jmp 0x41d22b
mov dword [ebp - 0x14], 0
cmp dword [ebp + 0x10], 0
jl 0x41ced0
jg 0x41cec9
cmp dword [ebp + 0xc], 0xfffffff
jbe 0x41ced0
mov dword [ebp - 0x14], 8
mov ecx, dword [ebp - 0x14]
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
call fcn.004aa560
push eax
push 0
mov eax, dword [ebp + 0x24]
mov ecx, dword [eax + 8]
call fcn.004214c0
cmp dword [ebp + 0x14], 0
je 0x41ceff
mov ecx, dword [ebp + 0x14]
xor edx, edx
mov dl, byte [ecx + 9]
mov dword [ebp - 0x40], edx
jmp 0x41cf05
mov eax, dword [ebp + 0x20]
mov dword [ebp - 0x40], eax
cmp dword [ebp - 0x30], 0
je 0x41cf13
mov ecx, dword [ebp - 0x30]
mov dword [ebp - 0x44], ecx
jmp 0x41cf19
mov edx, dword [ebp + 0x1c]
mov dword [ebp - 0x44], edx
cmp dword [ebp + 0x14], 0
je 0x41cf29
mov eax, dword [ebp + 0x14]
mov ecx, dword [eax]
mov dword [ebp - 0x48], ecx
jmp 0x41cf30
mov dword [ebp - 0x48], 0x80
mov edx, dword [ebp - 0x14]
push edx
mov eax, dword [ebp + 0x24]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 0x28]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
lea edx, [ebp - 0x2c]
push edx
mov eax, dword [ebp - 0x40]
push eax
mov ecx, dword [ebp - 0x44]
push ecx
mov edx, dword [ebp - 0x48]
push edx
mov ecx, dword [ebp - 0x3c]
call fcn.0041eb3f
mov byte [ebp - 0x28], al
mov eax, dword [ebp - 0x28]
and eax, 0xff
test eax, eax
je 0x41cf80
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
jmp 0x41d22b
mov edx, dword [ebp - 0x28]
and edx, 0xff
test edx, edx
jne 0x41cfaa
mov eax, dword [ebp - 0x2c]
and eax, 0xff
test eax, eax
jne 0x41cfaa
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor al, al
jmp 0x41d22b
mov dword [ebp - 0x24], 0x10000
mov eax, dword [ebp - 0x24]
cdq
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x4c], edx
mov edx, dword [ebp - 0x4c]
cmp edx, dword [ebp + 0x10]
jl 0x41cfd3
jg 0x41cfcd
mov eax, dword [ebp - 0x50]
cmp eax, dword [ebp + 0xc]
jbe 0x41cfd3
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x24], ecx
mov edx, dword [ebp - 0x24]
push edx
call fcn.004d333d
add esp, 4
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x41d01c
cmp dword [ebp + 0x28], 0
je 0x41d00b
mov ecx, dword [ebp + 8]
push ecx
push 0xef8d
push 1
mov edx, dword [ebp + 0x28]
push edx
call fcn.00471dc5
add esp, 0x10
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor al, al
jmp 0x41d22b
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0
mov ecx, dword [ebp + 0xc]
or ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x41d20c
mov edx, dword [ebp + 0x24]
mov eax, dword [edx]
xor ecx, ecx
mov cl, byte [eax]
test ecx, ecx
je 0x41d04e
mov byte [ebp - 0x18], 1
jmp 0x41d20c
mov eax, dword [ebp - 0x24]
cdq
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x54], edx
mov edx, dword [ebp + 0x10]
cmp edx, dword [ebp - 0x54]
jl 0x41d122
jg 0x41d072
mov eax, dword [ebp + 0xc]
cmp eax, dword [ebp - 0x58]
jbe 0x41d122
cmp dword [ebp + 0x14], 0
je 0x41d0b4
mov ecx, dword [ebp + 0x28]
push ecx
lea edx, [ebp - 8]
push edx
mov eax, dword [ebp - 0x24]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
mov edx, dword [ebp - 0x20]
push edx
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp + 0x14]
push edx
mov ecx, dword [ebp - 0x3c]
call fcn.0041bd6c
and eax, 0xff
test eax, eax
jne 0x41d0b2
mov byte [ebp - 0x18], 0
jmp 0x41d20c
jmp 0x41d0f3
mov eax, dword [ebp + 0x28]
push eax
lea ecx, [ebp - 8]
push ecx
mov edx, dword [ebp - 0x24]
push edx
mov eax, dword [ebp - 0x1c]
push eax
mov ecx, dword [ebp - 0x20]
push ecx
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp + 0x20]
push eax
mov ecx, dword [ebp + 0x1c]
push ecx
push 0x80
mov ecx, dword [ebp - 0x3c]
call fcn.0041ba64
and eax, 0xff
test eax, eax
jne 0x41d0f3
mov byte [ebp - 0x18], 0
jmp 0x41d20c
mov edx, dword [ebp - 8]
xor eax, eax
mov ecx, dword [ebp + 0xc]
sub ecx, edx
mov edx, dword [ebp + 0x10]
sbb edx, eax
mov dword [ebp + 0xc], ecx
mov dword [ebp + 0x10], edx
mov eax, dword [ebp - 8]
xor ecx, ecx
mov edx, dword [ebp - 0x20]
add edx, eax
mov eax, dword [ebp - 0x1c]
adc eax, ecx
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x1c], eax
jmp 0x41d1ae
cmp dword [ebp + 0x14], 0
je 0x41d164
mov ecx, dword [ebp + 0x28]
push ecx
lea edx, [ebp - 8]
push edx
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
mov edx, dword [ebp - 0x20]
push edx
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp + 0x14]
push edx
mov ecx, dword [ebp - 0x3c]
call fcn.0041bd6c
and eax, 0xff
test eax, eax
jne 0x41d162
mov byte [ebp - 0x18], 0
jmp 0x41d20c
jmp 0x41d1a0
mov eax, dword [ebp + 0x28]
push eax
lea ecx, [ebp - 8]
push ecx
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp - 0x1c]
push eax
mov ecx, dword [ebp - 0x20]
push ecx
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp + 0x20]
push eax
mov ecx, dword [ebp + 0x1c]
push ecx
push 0x80
mov ecx, dword [ebp - 0x3c]
call fcn.0041ba64
and eax, 0xff
test eax, eax
jne 0x41d1a0
mov byte [ebp - 0x18], 0
jmp 0x41d20c
mov dword [ebp + 0xc], 0
mov dword [ebp + 0x10], 0
push 0
lea edx, [ebp - 4]
push edx
mov eax, dword [ebp - 8]
push eax
mov ecx, dword [ebp - 0xc]
push ecx
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x41d1d2
mov eax, dword [ebp - 4]
cmp eax, dword [ebp - 8]
je 0x41d1ed
cmp dword [ebp + 0x28], 0
je 0x41d1e7
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov ecx, dword [ebp + 0x28]
call fcn.00471f57
mov byte [ebp - 0x18], 0
jmp 0x41d20c
mov ecx, dword [ebp - 0x14]
mov eax, dword [ebp - 0x20]
mov edx, dword [ebp - 0x1c]
call fcn.004aa560
push eax
mov ecx, dword [ebp + 0x24]
mov ecx, dword [ecx + 8]
call fcn.004214f0
jmp 0x41d02a
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x38], eax
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.004d3366
add esp, 4
mov al, byte [ebp - 0x18]
mov esp, ebp
pop ebp
ret 0x24