Function at 0x41a900
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Get file size
Read file on windows
Resolve dns

Disassembly:
push 0xffffffffffffffff
push 0x4405dc
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x9c
push ebx
push ebp
push edi
mov edi, dword [esp + 0xc0]
xor ebx, ebx
mov eax, dword [edi]
mov dword [esp + 0x2c], ebx
push eax
call dword [sym.imp.WSOCK32.dll_gethostbyname]
mov ebp, eax
cmp ebp, ebx
jne 0x41a941
xor eax, eax
jmp 0x41ae88
push 6
push 1
push 2
call dword [sym.imp.WSOCK32.dll_socket]
cmp eax, 0xffffffff
mov dword [esp + 0x24], eax
jne 0x41a95d
xor eax, eax
jmp 0x41ae88
push esi
mov esi, dword [esp + 0xbc]
cmp esi, ebx
mov dword [esp + 0x24], 0xffffffff
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x34], ebx
je 0x41a9ca
push ebx
push ebx
push 3
push ebx
push 1
push connect
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [esp + 0x24], eax
je 0x41ae68
mov ecx, dword [esp + 0x24]
lea eax, [esp + 0x34]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, ebx
mov dword [esp + 0x2c], eax
je 0x41ae68
cmp eax, 0xa000000
ja 0x41ae68
cmp dword [esp + 0x34], ebx
jne 0x41ae68
mov ebx, dword [esp + 0xc8]
mov edx, dword [edi]
mov ecx, dword [ebx]
mov eax, dword [edx - 8]
mov ecx, dword [ecx - 8]
lea edx, [ecx + eax + 0x1000]
push edx
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
mov edi, eax
add esp, 4
test edi, edi
mov dword [esp + 0x20], edi
je 0x41ae68
xor eax, eax
push 0x50
mov dword [esp + 0x3c], eax
mov word [esp + 0x3c], 2
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
call dword [sym.imp.WSOCK32.dll_htons]
mov word [esp + 0x3a], ax
mov ecx, dword [ebp + 0xc]
xor ebp, ebp
mov edx, dword [ecx]
mov eax, dword [edx]
mov dword [esp + 0x3c], eax
mov eax, dword [esp + 0xd8]
test eax, eax
jbe 0x41aa59
mov edx, dword [esp + 0x28]
lea ecx, [esp + 0x38]
push 0x10
push ecx
push edx
call dword [sym.imp.WSOCK32.dll_connect]
test eax, eax
je 0x41aa59
mov eax, dword [esp + 0xd8]
inc ebp
cmp ebp, eax
jb 0x41aa37
cmp ebp, dword [esp + 0xd8]
je 0x41ae5f
mov eax, dword [0x449b4c]
mov dword [esp + 0x14], eax
xor ebp, ebp
mov dword [esp + 0x1c], eax
mov dword [esp + 0xb4], ebp
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0xc4]
mov edx, dword [ebx]
mov ebx, dword [sym.imp.ntdll.dll_sprintf]
mov byte [esp + 0xb4], 2
mov ecx, dword [eax]
mov dword [esp + 0x10], ebp
push ecx
push edx
push 0x464744
push edi
call ebx
mov ecx, dword [esp + 0x20]
add esp, 0x10
add ecx, eax
test esi, esi
mov dword [esp + 0x10], ecx
je 0x41abdf
push ebp
call dword [sym.imp.MSVCRT.dll_time]
add esp, 4
push eax
push eax
push 0x464718
lea eax, [esp + 0x54]
push 0x64
push eax
call dword [sym.imp.ntdll.dll__snprintf]
mov edx, dword [esp + 0x24]
add esp, 0x14
lea ecx, [esp + 0x48]
add edx, edi
push ecx
push 0x4646e4
push edx
call ebx
mov ecx, dword [esp + 0x1c]
add esp, 0xc
add ecx, eax
lea eax, [esp + 0x48]
mov dword [esp + 0x10], ecx
push esi
push eax
lea ecx, [esp + 0x24]
push 0x464670
push ecx
call fcn.0041bb10
add esp, 0x10
lea edx, [esp + 0x48]
lea eax, [esp + 0x18]
push edx
push 0x464664
push eax
call fcn.0041bb10
mov ebp, dword [esp + 0xcc]
add esp, 0xc
mov eax, dword [ebp + 4]
mov esi, dword [eax]
cmp esi, eax
je 0x41abc7
mov ecx, dword [0x449b4c]
mov dword [esp + 0x20], ecx
mov eax, esi
mov esi, dword [esi]
lea ecx, [esp + 0x48]
mov byte [esp + 0xb4], 3
mov edx, dword [eax + 0xc]
mov eax, dword [eax + 8]
push edx
push eax
push ecx
lea edx, [esp + 0x2c]
push 0x46462c
push edx
call fcn.0041bb10
mov eax, dword [esp + 0x34]
add esp, 0x14
lea ecx, [esp + 0x14]
push eax
mov eax, dword [eax - 8]
push eax
call fcn.00406b60
mov eax, dword [esp + 0x20]
mov edx, dword [0x449b50]
mov byte [esp + 0xb4], 2
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x41abbe
add eax, 0xfffffff4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x41abbe
mov edx, dword [esp + 0x20]
add edx, 0xfffffff4
push edx
call fcn.0043fa08
add esp, 4
cmp esi, dword [ebp + 4]
jne 0x41ab40
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
mov ebp, dword [eax - 8]
mov edx, dword [ecx - 8]
mov eax, dword [esp + 0x2c]
add ebp, edx
add ebp, eax
jmp 0x41ac3b
mov edx, dword [esp + 0x10]
push 0x45fa74
add edx, edi
push edx
call ebx
mov edx, dword [esp + 0x18]
add esp, 8
add edx, eax
mov eax, dword [esp + 0xc0]
mov dword [esp + 0x10], edx
mov eax, dword [eax + 4]
mov esi, dword [eax]
cmp esi, eax
je 0x41ac3b
mov eax, esi
mov esi, dword [esi]
mov edi, dword [eax + 0xc]
test edi, edi
jne 0x41ac19
xor eax, eax
jmp 0x41ac20
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push edi
push eax
lea ecx, [esp + 0x1c]
call fcn.00406b60
mov ecx, dword [esp + 0xc0]
cmp esi, dword [ecx + 4]
jne 0x41ac0a
mov edi, dword [esp + 0x20]
mov edx, dword [esp + 0x14]
mov eax, dword [edx - 8]
add eax, ebp
push eax
mov eax, dword [esp + 0x14]
add eax, edi
push 0x4645b0
push eax
call ebx
mov ecx, dword [esp + 0x1c]
mov esi, dword [esp + 0xc8]
add esp, 0xc
add ecx, eax
test esi, esi
mov dword [esp + 0x10], ecx
je 0x41ac8b
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x10]
push ecx
add edx, edi
push 0x44ae40
push edx
call ebx
mov ecx, dword [esp + 0x1c]
add esp, 0xc
add ecx, eax
mov dword [esp + 0x10], ecx
mov eax, dword [esp + 0x10]
mov ebx, dword [esp + 0x28]
push eax
push edi
push ebx
call fcn.0041aeb0
add esp, 0xc
test eax, eax
je 0x41ace7
mov ebp, dword [sym.imp.KERNEL32.dll_ReadFile]
test esi, esi
je 0x41ad73
mov edx, dword [esp + 0x24]
lea ecx, [esp + 0x10]
push 0
push ecx
push 0x1000
push edi
push edx
call ebp
test eax, eax
je 0x41ad73
mov eax, dword [esp + 0x10]
test eax, eax
je 0x41ad73
push eax
push edi
push ebx
call fcn.0041aeb0
add esp, 0xc
test eax, eax
jne 0x41aca8
mov eax, dword [esp + 0x18]
mov edx, dword [0x449b50]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x41ad1a
mov esi, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
add eax, 0xfffffff4
push eax
call esi
test eax, eax
jg 0x41ad20
mov edx, dword [esp + 0x18]
add edx, 0xfffffff4
push edx
call fcn.0043fa08
add esp, 4
jmp 0x41ad20
mov esi, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
mov eax, dword [esp + 0x1c]
mov edx, dword [0x449b50]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x41ad4b
add eax, 0xfffffff4
push eax
call esi
test eax, eax
jg 0x41ad4b
mov edx, dword [esp + 0x1c]
add edx, 0xfffffff4
push edx
call fcn.0043fa08
add esp, 4
mov eax, dword [esp + 0x14]
mov edx, dword [0x449b50]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x41ae5f
add eax, 0xfffffff4
push eax
call esi
test eax, eax
jg 0x41ae5f
jmp 0x41ae4f
mov eax, dword [esp + 0x14]
mov ecx, dword [eax - 8]
push ecx
push eax
push ebx
call fcn.0041aeb0
add esp, 0xc
test esi, esi
je 0x41ad9b
mov eax, dword [esp + 0x18]
mov edx, dword [eax - 8]
push edx
push eax
push ebx
call fcn.0041aeb0
add esp, 0xc
mov esi, dword [esp + 0xcc]
test esi, esi
je 0x41add0
mov eax, dword [esp + 0xd0]
test eax, eax
je 0x41add0
push eax
push esi
push ebx
call fcn.0041af60
add esp, 0xc
mov dword [esp + 0x10], eax
test eax, eax
je 0x41add0
mov byte [eax + esi], 0
mov dword [esp + 0x30], 1
mov eax, dword [esp + 0x18]
mov edx, dword [0x449b50]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x41ae03
mov esi, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
add eax, 0xfffffff4
push eax
call esi
test eax, eax
jg 0x41ae09
mov edx, dword [esp + 0x18]
add edx, 0xfffffff4
push edx
call fcn.0043fa08
add esp, 4
jmp 0x41ae09
mov esi, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
mov eax, dword [esp + 0x1c]
mov edx, dword [0x449b50]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x41ae34
add eax, 0xfffffff4
push eax
call esi
test eax, eax
jg 0x41ae34
mov edx, dword [esp + 0x1c]
add edx, 0xfffffff4
push edx
call fcn.0043fa08
add esp, 4
mov eax, dword [esp + 0x14]
mov edx, dword [0x449b50]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x41ae5f
add eax, 0xfffffff4
push eax
call esi
test eax, eax
jg 0x41ae5f
mov edx, dword [esp + 0x14]
add edx, 0xfffffff4
push edx
call fcn.0043fa08
add esp, 4
push edi
call fcn.0043fa08
add esp, 4
mov eax, dword [esp + 0x28]
push eax
call dword [sym.imp.WSOCK32.dll_closesocket]
mov eax, dword [esp + 0x24]
pop esi
cmp eax, 0xffffffff
je 0x41ae84
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0xa8]
pop edi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0xa8
ret 0x20