Function at 0x100a0270
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Receive data
Receive data on socket
Resolve dns
Send data
Send data on socket
Send http request
Set socket configuration

Disassembly:
push ebp
lea ebp, [esp - 0x6c]
sub esp, 0x6c
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x1024c01e
push eax
mov eax, 0x2078
mov dword fs:[0], esp
call fcn.1006fb30
push ebx
push esi
push edi
mov edi, dword [ebp + 0x74]
push 0x800
push 0
mov eax, dword [edi + 4]
mov ebx, dword [edi]
mov esi, dword [edi + 0xc]
mov dword [ebp + 0x48], eax
mov eax, dword [edi + 8]
mov dword [ebp + 0x44], eax
mov eax, dword [edi + 0x10]
mov dword [ebp + 0x40], eax
mov eax, dword [edi + 0x18]
mov dword [ebp + 0x34], eax
lea eax, [ebp - 0x884]
push eax
mov dword [ebp + 0x64], ebx
mov dword [ebp + 0x4c], esi
mov dword [edi + 0x34], 0xe0000007
call sub.VCRUNTIME140.dll_memset
push 0x800
lea eax, [ebp - 0x2084]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0x18
mov dword [ebp + 0x5c], 0x50
lea eax, [edi + 0x1c]
lea ecx, [ebp - 0x3c]
push eax
call fcn.1001a380
lea ecx, [ebp - 0x2084]
mov dword [ebp - 4], 0
cmp dword [ebp - 0x28], 8
lea eax, [ebp - 0x3c]
push ecx
cmovae eax, dword [ebp - 0x3c]
lea ecx, [ebp + 0x5c]
push ecx
lea ecx, [ebp - 0x884]
push ecx
push eax
call sym.WMCommon.dll_private:_static_bool___cdecl_WM::GMHttpDownload::ParseUrl_wchar_t_const___wchar_t___unsigned_short_int___wchar_t__
add esp, 0x10
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov dword [esi + 0x10], eax
cmp eax, 0xffffffff
je 0x100a08dd
xor eax, eax
mov dword [ebp + 0x28], 0
lea ecx, [ebp - 0x884]
mov dword [ebp + 0x2c], 7
mov word [ebp + 0x18], ax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x100a0365
sub ecx, edx
lea eax, [ebp - 0x884]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp + 0x18]
call fcn.1001a600
push 0
lea eax, [ebp + 0x18]
mov byte [ebp - 4], 1
push eax
lea eax, [ebp - 0x24]
push eax
call sym.WMCommon.dll_public:_static_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char_____cdecl_WM::GMStringConvert::UnicodeStringToMultiByte_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const___unsigned_int_
add esp, 0xc
cmp dword [eax + 0x14], 0x10
jb 0x100a03a2
mov eax, dword [eax]
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
mov ecx, eax
test ecx, ecx
jne 0x100a03b6
xor esi, esi
mov dword [ebp + 0x54], esi
jmp 0x100a03da
movsx eax, word [ecx + 0xa]
push eax
mov eax, dword [ecx + 0xc]
push dword [eax]
lea eax, [ebp + 4]
push eax
call sub.VCRUNTIME140.dll_memcpy
add esp, 0xc
push dword [ebp + 4]
call dword [sym.imp.WS2_32.dll_inet_ntoa]
mov esi, eax
mov dword [ebp + 0x54], eax
mov edx, dword [ebp - 0x10]
cmp edx, 0x10
jb 0x100a0410
mov ecx, dword [ebp - 0x24]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x100a0406
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x100a0406
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push edx
push ecx
call fcn.1006e6d7
add esp, 8
lea ecx, [ebp + 0x18]
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x10], 0xf
mov byte [ebp - 0x24], 0
mov byte [ebp - 4], 0
call fcn.1001a5a0
test esi, esi
je 0x100a08dd
mov esi, dword [sym.imp.WS2_32.dll_setsockopt]
lea eax, [ebp + 0x50]
push 4
push eax
mov eax, dword [ebp + 0x4c]
push 0x1005
push 0xffff
mov dword [ebp + 0x50], 0x1d4c0
push dword [eax + 0x10]
call esi
push 4
lea eax, [ebp + 0x50]
push eax
mov eax, dword [ebp + 0x4c]
push 0x1006
push 0xffff
push dword [eax + 0x10]
call esi
mov esi, dword [ebp + 0x4c]
mov eax, 2
push dword [ebp + 0x5c]
mov dword [edi + 0x38], 2
mov word [esi], ax
call dword [sym.imp.WS2_32.dll_htons]
push dword [ebp + 0x54]
mov word [esi + 2], ax
call dword [sym.imp.WS2_32.dll_inet_addr]
push 0x10
push esi
push dword [esi + 0x10]
mov dword [esi + 4], eax
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
jne 0x100a08dd
lea eax, [ebx + 0x2210]
push eax
lea ecx, [ebp + 0x18]
call fcn.1001a2f0
mov ecx, dword [ebp + 0x48]
lea eax, [ebp + 0x18]
push 0x80
push 3
push 3
push 0x40000000
push eax
mov byte [ebp - 4], 2
call sym.WMCommon.dll_public:_bool___thiscall_WM::GMFile::Create_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const___unsigned_int__unsigned_int__unsigned_int__unsigned_int_
lea ecx, [ebp + 0x18]
mov byte [ebp - 4], 0
mov bl, al
call fcn.1001a5a0
test bl, bl
je 0x100a0524
mov ebx, dword [ebp + 0x48]
mov esi, dword [ebp + 0x64]
mov eax, dword [ebx]
mov edx, dword [eax + 0x18]
mov eax, dword [ebp + 0x40]
lea ecx, [eax + eax*4]
shl ecx, 3
lea eax, [ebp - 0x44]
push eax
mov eax, dword [esi + 0x268c]
push 0
mov dword [ebp + 0x54], ecx
push dword [ecx + eax + 0x14]
push dword [ecx + eax + 0x10]
mov ecx, ebx
call edx
test al, al
jne 0x100a0530
mov dword [edi + 0x34], 0x80004005
jmp 0x100a08dd
lea eax, [esi + 0x2418]
push eax
lea ecx, [ebp + 0x18]
call fcn.1001a2f0
mov ecx, dword [ebp + 0x44]
lea eax, [ebp + 0x18]
push 0x80
push 3
push 3
push 0x40000000
push eax
mov byte [ebp - 4], 3
call sym.WMCommon.dll_public:_bool___thiscall_WM::GMFile::Create_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const___unsigned_int__unsigned_int__unsigned_int__unsigned_int_
lea ecx, [ebp + 0x18]
mov byte [ebp - 4], 0
mov bl, al
call fcn.1001a5a0
test bl, bl
je 0x100a0524
mov ebx, dword [ebp + 0x64]
mov dword [edi + 0x38], 3
mov edi, dword [ebp + 0x54]
mov eax, dword [ebx + 0x268c]
mov esi, dword [edi + eax + 0x10]
mov ecx, dword [edi + eax + 0x18]
mov edx, dword [edi + eax + 0x14]
add ecx, esi
mov eax, dword [edi + eax + 0x1c]
adc eax, edx
sub ecx, 1
sbb eax, 0
push eax
push ecx
push edx
push esi
lea eax, [ebp - 0x84]
push str._I64d__I64d
push eax
call fcn.1002eba0
mov eax, dword [ebx + 0x268c]
push 0x1000
push 0
mov esi, dword [edi + eax + 8]
sub esi, dword [edi + eax + 0x18]
mov ecx, dword [edi + eax + 0xc]
sbb ecx, dword [edi + eax + 0x1c]
lea eax, [ebp - 0x1884]
push eax
mov dword [ebp + 0x64], esi
mov dword [ebp + 0x60], ecx
call sub.VCRUNTIME140.dll_memset
lea eax, [ebp - 0x84]
push eax
lea eax, [ebp - 0x2084]
push eax
push dword [ebp + 0x5c]
lea eax, [ebp - 0x884]
push eax
lea eax, [ebp - 0x1884]
push eax
call sym.WMCommon.dll_private:_static_void___cdecl_WM::GMHttpDownload::SetRequest_char___wchar_t_const___unsigned_short_int__wchar_t_const___char_const__
lea ecx, [ebp - 0x1884]
add esp, 0x38
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x100a0610
push 0
sub ecx, edx
lea eax, [ebp - 0x1884]
push ecx
push eax
mov eax, dword [ebp + 0x4c]
push dword [eax + 0x10]
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
je 0x100a08dd
mov eax, dword [ebp + 0x60]
xorps xmm0, xmm0
movlpd qword [ebp + 0x38], xmm0
mov dword [ebp + 0x10], esi
mov dword [ebp + 0x14], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [ebp + 0x3c]
mov dword [ebp + 0x30], eax
mov eax, dword [ebp + 0x38]
mov byte [ebp + 0x6b], 1
mov dword [ebp + 0x5c], ecx
mov dword [ebp + 0x50], eax
push 0x1000
lea eax, [ebp - 0x1884]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
lea eax, [ebp - 0x1884]
push 0
push 0x1000
push eax
mov eax, dword [ebp + 0x4c]
push dword [eax + 0x10]
call dword [sym.imp.WS2_32.dll_recv]
mov esi, eax
cmp esi, 0xffffffff
je 0x100a08a6
test esi, esi
je 0x100a08a6
cmp byte [ebp + 0x6b], 0
je 0x100a0793
push 4
lea eax, [ebp - 0x1884]
mov byte [ebp + 0x6b], 0
push str.HTTP
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncmp]
add esp, 0xc
test eax, eax
jne 0x100a08f7
lea eax, [ebp - 0x1884]
push 0x10266f10
push eax
call dword [sym.imp.VCRUNTIME140.dll_strstr]
mov edi, eax
add esp, 8
test edi, edi
je 0x100a08f7
inc edi
push 0x10266f10
push edi
call dword [sym.imp.VCRUNTIME140.dll_strstr]
add esp, 8
test eax, eax
je 0x100a08f7
sub eax, edi
cmp eax, 8
jg 0x100a08f7
push eax
lea eax, [ebp + 4]
mov word [ebp + 0xc], 0
xorps xmm0, xmm0
push edi
push eax
movq qword [ebp + 4], xmm0
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy]
lea eax, [ebp + 4]
push eax
call dword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll__atoi64]
add esp, 0x10
cmp eax, 0xc8
je 0x100a074d
cmp eax, 0xce
jne 0x100a08f7
lea eax, [ebp - 0x1884]
push str._r_n_r_n
push eax
call dword [sym.imp.VCRUNTIME140.dll_strstr]
add esp, 8
test eax, eax
je 0x100a0883
add eax, 4
lea ecx, [ebp - 0x1884]
sub ecx, eax
add esi, ecx
push esi
push eax
lea eax, [ebp - 0x1884]
push eax
call sub.VCRUNTIME140.dll_memmove
add esp, 0xc
test esi, esi
je 0x100a0883
mov edi, dword [ebp + 0x54]
mov eax, dword [ebx + 0x268c]
mov ecx, dword [ebp + 0x48]
mov edi, dword [edi + eax + 8]
mov eax, dword [ecx]
sub edi, dword [ebp + 0x64]
cmp edi, esi
mov edx, dword [eax + 8]
cmovge edi, esi
lea eax, [ebp + 0x3c]
push eax
push edi
lea eax, [ebp - 0x1884]
push eax
call edx
test al, al
je 0x100a090f
cmp dword [ebp + 0x3c], edi
jne 0x100a090f
mov ecx, dword [ebx + 0x2690]
mov eax, edi
mov edi, dword [ebp + 0x50]
cdq
mov esi, eax
add dword [ebp + 0x64], esi
mov eax, dword [ecx]
adc dword [ebp + 0x60], edx
add edi, esi
push 1
adc dword [ebp + 0x5c], edx
push edx
push esi
mov dword [ebp + 0x50], edi
call dword [eax + 4]
mov ecx, dword [ebx + 0x2690]
mov eax, dword [ecx]
call dword [eax + 0xc]
mov ecx, dword [ebp + 0x5c]
test eax, eax
setne al
mov byte [ebp + 0x5b], al
test ecx, ecx
jg 0x100a0819
jl 0x100a0815
cmp edi, 0x100000
jae 0x100a0819
test al, al
je 0x100a085f
push dword [ebp + 0x44]
mov esi, dword [ebp + 0x60]
mov ecx, ebx
push esi
push dword [ebp + 0x64]
push dword [ebp + 0x40]
call sym.WMCommon.dll_private:_bool___thiscall_WM::GMHttpDownload::WriteLogBlock_unsigned_int__long_long___int64___class_WM::GMFile__
mov eax, dword [ebp + 0x5c]
test eax, eax
jl 0x100a084d
jg 0x100a083e
cmp edi, 0x100000
jb 0x100a084d
add edi, 0xfff00000
mov dword [ebp + 0x50], edi
adc eax, 0xffffffff
mov dword [ebp + 0x5c], eax
cmp byte [ebp + 0x5b], 0
je 0x100a0862
mov edi, dword [ebp + 0x74]
mov dword [edi + 0x34], 0xe000000a
jmp 0x100a08a9
mov esi, dword [ebp + 0x60]
mov eax, dword [ebp + 0x34]
cmp byte [eax], 0
jne 0x100a0903
lea eax, [ebp + 0x30]
mov ecx, ebx
push eax
push esi
push dword [ebp + 0x64]
lea eax, [ebp + 0x10]
push eax
call sym.WMCommon.dll_private:_bool___thiscall_WM::GMHttpDownload::SpeedLimit_long_long___int64____long_long___int64___unsigned_int__
jmp 0x100a0886
mov esi, dword [ebp + 0x60]
mov eax, dword [ebx + 0x268c]
mov edi, dword [ebp + 0x54]
mov ecx, dword [ebp + 0x64]
cmp ecx, dword [edi + eax + 8]
jne 0x100a0662
cmp esi, dword [edi + eax + 0xc]
jne 0x100a0662
mov edi, dword [ebp + 0x74]
push dword [ebp + 0x44]
mov eax, dword [ebp + 0x60]
mov ecx, ebx
mov esi, dword [ebp + 0x64]
push eax
push esi
push dword [ebp + 0x40]
call sym.WMCommon.dll_private:_bool___thiscall_WM::GMHttpDownload::WriteLogBlock_unsigned_int__long_long___int64___class_WM::GMFile__
mov edx, dword [ebx + 0x268c]
mov ecx, dword [ebp + 0x54]
cmp esi, dword [ecx + edx + 8]
jne 0x100a08dd
mov eax, dword [ebp + 0x60]
cmp eax, dword [ecx + edx + 0xc]
jne 0x100a08dd
mov dword [edi + 0x34], 0
lea ecx, [ebp - 0x3c]
call fcn.1001a5a0
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
lea esp, [ebp + 0x6c]
pop ebp
ret
mov edi, dword [ebp + 0x74]
mov dword [edi + 0x34], 0xe0000005
jmp 0x100a08a9
mov edi, dword [ebp + 0x74]
mov dword [edi + 0x34], 0x80004004
jmp 0x100a08a9
mov edi, dword [ebp + 0x74]
mov dword [edi + 0x34], 0x80004005
jmp 0x100a08a9