Function at 0x41d978
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x338
push ebx
push esi
mov esi, ecx
push edi
mov edi, dword [ebp + 0xc]
cmp dword [esi + 4], 0xffffffff
je 0x41d996
mov ecx, dword [esi]
call fcn.0041d2a5
mov eax, dword [esi]
or dword [esi + 4], 0xffffffff
mov ebx, dword [ebp + 8]
cmp ebx, dword [eax + 4]
jl 0x41d9ae
mov eax, 0x10000
jmp 0x41dbb4
cmp dword [eax + 0x10], ebx
jle 0x41d9c8
mov ecx, eax
call fcn.0041cce5
jmp 0x41d9c3
mov ecx, dword [esi]
call fcn.0041cd1c
mov eax, dword [esi]
cmp dword [eax + 0x10], ebx
jl 0x41d9bc
lea eax, [ebp - 0x234]
mov ecx, esi
push eax
push ebx
call fcn.0041d384
test byte [ebp - 0x12c], 0x10
mov al, byte [edi]
je 0x41da17
cmp al, 0x2f
je 0x41d9fa
cmp al, 0x5c
je 0x41d9fa
test al, al
je 0x41d9f6
cmp byte [edi + 1], 0x3a
je 0x41d9fa
xor dl, dl
jmp 0x41d9fc
mov dl, 1
xor ecx, ecx
lea eax, [esi + 0x140]
test dl, dl
mov edx, edi
cmove ecx, eax
call fcn.0041d8b5
xor eax, eax
jmp 0x41dbb4
mov dword [ebp + 0xc], edi
mov ebx, edi
mov ecx, edi
test al, al
je 0x41da37
cmp al, 0x2f
je 0x41da2a
cmp al, 0x5c
jne 0x41da2d
lea ebx, [ecx + 1]
inc ecx
mov al, byte [ecx]
test al, al
jne 0x41da22
mov dword [ebp + 0xc], ebx
lea eax, [ebp - 0x108]
push edi
push eax
call fcn.004450b0
pop ecx
pop ecx
cmp ebx, edi
jne 0x41da54
xor ebx, ebx
mov byte [ebp - 0x108], bl
jmp 0x41da7c
mov eax, ebx
xor ebx, ebx
sub eax, edi
mov byte [ebp + eax - 0x108], bl
mov al, byte [ebp - 0x108]
cmp al, 0x2f
je 0x41daa4
cmp al, 0x5c
je 0x41daa4
test al, al
je 0x41da7c
cmp byte [ebp - 0x107], 0x3a
je 0x41daa4
push dword [ebp + 0xc]
lea eax, [ebp - 0x108]
push eax
lea edi, [esi + 0x140]
push edi
lea eax, [ebp - 0x338]
push str._s_s_s
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x14
jmp 0x41dac5
push dword [ebp + 0xc]
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x338]
push 0x47a0b8
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
mov edi, ebx
lea edx, [ebp - 0x108]
mov ecx, edi
call fcn.0041d8b5
push ebx
push dword [ebp - 0x12c]
lea eax, [ebp - 0x338]
push 2
push ebx
push ebx
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp + 8], eax
cmp eax, 0xffffffff
jne 0x41db01
mov eax, 0x200
jmp 0x41dbb4
mov edx, dword [esi + 0x138]
mov ecx, dword [esi]
call fcn.0041cf00
cmp dword [esi + 0x13c], ebx
jne 0x41db27
push 0x4000
call fcn.0043da0b
pop ecx
mov dword [esi + 0x13c], eax
mov edx, dword [esi + 0x13c]
lea eax, [ebp + 0xf]
mov ecx, dword [esi]
push eax
push 0x4000
call fcn.0041d051
mov edi, eax
pop ecx
pop ecx
cmp edi, 0xffffff96
je 0x41db9d
test edi, edi
js 0x41db6f
jle 0x41db65
push ebx
lea eax, [ebp - 4]
push eax
push edi
push dword [esi + 0x13c]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x41db76
cmp byte [ebp + 0xf], 0
jne 0x41db7d
test edi, edi
jne 0x41db27
mov ebx, 0x5000000
jmp 0x41dba2
mov ebx, 0x400
jmp 0x41dba2
lea eax, [ebp - 0x118]
push eax
lea eax, [ebp - 0x128]
push eax
lea eax, [ebp - 0x120]
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileTime]
jmp 0x41dba2
mov ebx, 0x1000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [esi]
call fcn.0041d2a5
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret 0x10