Function at 0x10004c40
Capabilities:
Connect socket
Connect udp socket
Create udp socket
Get common file path
Get socket status
Receive data
Receive data on socket
Resolve function by parsing pe exports
Send data
Send data on socket
Send http request
Send http request with host header
Set file attributes
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x10096399
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, 0x1288
call fcn.10076300
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0x48], esi
call fcn.1008cdb1
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [esp + 0x18], eax
lea eax, [esp + 0x18]
push eax
mov dword [esp + 0x12a8], 0
call fcn.10003cf0
mov ebp, dword [esp + 0x1c]
mov eax, dword [ebp - 0xc]
add esp, 4
test eax, eax
jne 0x10004ce5
lea eax, [ebp - 0x10]
mov dword [esp + 0x12a4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x10004ccb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
xor eax, eax
mov ecx, dword [esp + 0x129c]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret 4
call fcn.1008cdb1
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [esp + 0x14], eax
lea eax, [esp + 0x4c]
push eax
mov ecx, esi
mov edi, 1
mov byte [esp + 0x12a8], 1
call fcn.10003ad0
mov ecx, dword [eax]
push ebp
push ecx
lea edx, [esp + 0x1c]
push str.GET__pubwin__s_HTTP_1.1_r_nUser_Agent:_PubwinClient_r_nAccept:___r_nHost:__s:8444_r_n_r_n
push edx
mov byte [esp + 0x12b4], 2
call fcn.10002d50
mov eax, dword [esp + 0x5c]
add eax, 0xfffffff0
or ebx, 0xffffffff
add esp, 0x10
mov byte [esp + 0x12a4], 1
lea ecx, [eax + 0xc]
mov edx, ebx
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x10004d57
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
push 0
push edi
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov esi, eax
cmp esi, ebx
mov dword [esp + 0x44], esi
jne 0x10004dcf
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x12a4], 0
lea ecx, [eax + 0xc]
mov edx, ebx
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x10004d91
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [ebp - 0x10]
mov dword [esp + 0x12a4], ebx
lea ecx, [eax + 0xc]
mov edx, ebx
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x10004e56
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, ebx
mov ecx, dword [esp + 0x129c]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret 4
push 0x20fc
mov word [esp + 0x7c], 2
call dword [sym.imp.WS2_32.dll_htons]
push ebp
mov word [esp + 0x7e], ax
call dword [sym.imp.WS2_32.dll_inet_addr]
mov dword [esp + 0x7c], eax
lea eax, [esp + 0x6c]
push eax
push 0x8004667e
push esi
mov dword [esp + 0x78], edi
call dword [sym.imp.WS2_32.dll_ioctlsocket]
cmp eax, ebx
jne 0x10004e70
push esi
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x12a4], 0
lea ecx, [eax + 0xc]
mov edx, ebx
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x10004e36
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [ebp - 0x10]
mov dword [esp + 0x12a4], ebx
lea ecx, [eax + 0xc]
mov edx, ebx
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x10004e56
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, ebx
mov ecx, dword [esp + 0x129c]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret 4
mov ebx, dword [sym.imp.WS2_32.dll_select]
mov dword [esp + 0x24], 3
mov edi, edi
mov eax, dword [esp + 0x24]
mov ecx, eax
dec eax
test ecx, ecx
mov dword [esp + 0x24], eax
je 0x100055c4
push 0x10
lea edx, [esp + 0x7c]
push edx
push esi
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
je 0x10004ef9
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x10004e80
lea eax, [esp + 0x4c]
push eax
push 0
lea ecx, [esp + 0x90]
push ecx
push 0
push 0
mov dword [esp + 0xa0], esi
mov dword [esp + 0x9c], edi
mov dword [esp + 0x60], edi
mov dword [esp + 0x64], 0
call ebx
test eax, eax
jl 0x10004e80
je 0x10004e80
lea edx, [esp + 0x88]
push edx
push esi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x10004e80
push 4
lea eax, [esp + 0x6c]
push eax
push edi
mov ebx, 6
push ebx
push esi
mov dword [esp + 0x7c], edi
call dword [sym.imp.WS2_32.dll_setsockopt]
mov edi, dword [esp + 0x14]
mov eax, dword [edi - 0xc]
push 0
push eax
push edi
push esi
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
jne 0x10004f38
push esi
call dword [sym.imp.WS2_32.dll_closesocket]
lea eax, [edi - 0x10]
jmp 0x100055d2
lea ecx, [esp + 0x34]
call fcn.1008d9e5
mov ecx, dword [esp + 0x48]
lea eax, [esp + 0x10]
push eax
mov byte [esp + 0x12a8], 3
call fcn.10003b00
mov esi, dword [esp + 0x10]
push 0x5c
push esi
mov byte [esp + 0x12ac], 4
call fcn.10075b6a
add esp, 8
test eax, eax
jne 0x10004f77
or eax, 0xffffffff
jmp 0x10004f79
sub eax, esi
push eax
lea ecx, [esp + 0x20]
push ecx
lea ecx, [esp + 0x18]
call fcn.10003b90
mov edx, dword [esp + 0x1c]
push 0x80
push edx
mov byte [esp + 0x12ac], 5
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push 0
push 0x1041
push esi
lea ecx, [esp + 0x40]
call fcn.1008dc7d
test eax, eax
jne 0x100051ba
push 0x5c
push esi
call fcn.10075b6a
add esp, 8
test eax, eax
jne 0x10004fcd
or eax, 0xffffffff
jmp 0x10004fcf
sub eax, esi
push eax
lea eax, [esp + 0x50]
push eax
lea ecx, [esp + 0x18]
call fcn.10003c10
push 0x104
lea ecx, [esp + 0x8c]
push ecx
mov byte [esp + 0x12ac], bl
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov edi, dword [esp + 0x4c]
push edi
lea edx, [esp + 0x8c]
push edx
lea eax, [esp + 0x18]
push 0x1009cd14
push eax
call fcn.10002d50
add esp, 0x10
lea ecx, [esp + 0x54]
call fcn.1008cd4f
mov esi, vtable.CFileException.0
mov dword [esp + 0x54], esi
call fcn.1008cdb1
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [esp + 0x64], eax
lea ecx, [esp + 0x64]
mov dword [esp + 0x5c], 0
mov dword [esp + 0x60], 0xffffffff
call fcn.10001950
mov ebp, dword [esp + 0x10]
lea eax, [esp + 0x54]
push eax
push 0x1041
push ebp
lea ecx, [esp + 0x40]
mov byte [esp + 0x12b0], 8
call fcn.1008dc7d
test eax, eax
jne 0x1000515e
mov ecx, dword [esp + 0x44]
push ecx
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [esp + 0x64]
add eax, 0xfffffff0
mov byte [esp + 0x12a4], bl
mov dword [esp + 0x54], esi
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x100050b1
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [edi - 0x10]
mov byte [esp + 0x12a4], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x100050d3
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
mov byte [esp + 0x12a4], 4
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x100050f9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [ebp - 0x10]
mov byte [esp + 0x12a4], 3
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x1000511b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea ecx, [esp + 0x34]
mov byte [esp + 0x12a4], 1
call fcn.1008da24
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x12a4], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x10005152
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
jmp 0x100055f4
mov ecx, dword [esp + 0x48]
lea eax, [esp + 0x10]
add ecx, 0x38
push eax
call fcn.100029e0
mov eax, dword [esp + 0x64]
add eax, 0xfffffff0
mov byte [esp + 0x12a4], bl
mov dword [esp + 0x54], esi
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x10005198
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [edi - 0x10]
mov byte [esp + 0x12a4], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x100051ba
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
xor esi, esi
xor ebx, ebx
mov ecx, 0x400
xor eax, eax
lea edi, [esp + 0x298]
mov dword [esp + 0x24], esi
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], esi
rep stosd dword es:[edi], eax
mov dword [esp + 0x70], 2
mov dword [esp + 0x74], esi
mov dword [esp + 0x4c], esi
lea ebx, [ebx]
mov ebp, dword [esp + 0x44]
lea eax, [esp + 0x70]
push eax
push 0
push 0
lea ecx, [esp + 0x19c]
push ecx
push 0
mov dword [esp + 0x1a8], ebp
mov dword [esp + 0x1a4], 1
call dword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
je 0x10005477
test eax, eax
jne 0x10005235
inc dword [esp + 0x24]
jmp 0x10005457
push 0
mov edx, 0x1000
sub edx, ebx
push edx
lea edi, [esp + ebx + 0x2a0]
push edi
push ebp
call dword [sym.imp.WS2_32.dll_recv]
mov ebx, eax
cmp ebx, 0xffffffff
mov dword [esp + 0x2c], ebx
je 0x10005477
test ebx, ebx
je 0x10005562
mov eax, dword [esp + 0x4c]
test eax, eax
jne 0x100053c9
push ebx
push edi
lea ecx, [esp + 0x28]
call fcn.10003860
mov edi, dword [esp + 0x20]
mov eax, dword [edi - 0xc]
test eax, eax
mov byte [esp + 0x12a4], 9
jl 0x10005489
push 0x1009cc38
push edi
call fcn.10076a37
add esp, 8
test eax, eax
je 0x10005489
sub eax, edi
cmp eax, 0xffffffff
je 0x10005489
push eax
lea eax, [esp + 0x34]
push eax
lea ecx, [esp + 0x28]
call fcn.10003b90
mov esi, dword [esp + 0x30]
mov eax, dword [esi - 0xc]
test eax, eax
mov byte [esp + 0x12a4], 0xa
jl 0x100054d7
push str.HTTP
push esi
call fcn.10076a37
add esp, 8
test eax, eax
je 0x100054d7
sub eax, esi
cmp eax, 0xffffffff
je 0x100054d7
mov eax, dword [esi - 0xc]
test eax, eax
jl 0x100054d7
push 0x1009cc28
push esi
call fcn.10076a37
add esp, 8
test eax, eax
je 0x100054d7
sub eax, esi
cmp eax, 0xffffffff
je 0x100054d7
mov eax, dword [edi - 0xc]
test eax, eax
jl 0x100054d7
push 0x1009cc20
push edi
call fcn.10076a37
add esp, 8
test eax, eax
je 0x100054d7
sub eax, edi
cmp eax, 0xffffffff
je 0x100054d7
jle 0x1000535d
mov dword [esp + 0x4c], 1
mov esi, ebx
sub esi, eax
sub esi, 4
test esi, esi
jle 0x1000538e
lea ecx, [esp + eax + 0x29c]
push esi
push ecx
lea ecx, [esp + 0x3c]
call fcn.1008d738
xor eax, eax
mov ecx, 0x400
lea edi, [esp + 0x298]
rep stosd dword es:[edi], eax
mov dword [esp + 0x28], eax
mov ebx, dword [esp + 0x48]
mov ecx, dword [ebx + 0x24]
mov edi, dword [ebx + 0x20]
mov eax, esi
cdq
cmp edx, ecx
ja 0x1000549b
jb 0x100053ad
cmp eax, edi
jae 0x1000549b
lea ecx, [esp + 0x30]
call fcn.10002010
lea ecx, [esp + 0x20]
mov byte [esp + 0x12a4], 5
call fcn.10002010
jmp 0x10005430
mov ebx, dword [esp + 0x48]
mov ecx, dword [ebx + 0x24]
mov ebp, dword [ebx + 0x20]
mov eax, esi
cdq
cmp edx, ecx
ja 0x10005415
jb 0x100053e0
cmp eax, ebp
jae 0x10005415
mov edx, dword [esp + 0x2c]
test edx, edx
jle 0x100053f7
push edx
push edi
lea ecx, [esp + 0x3c]
call fcn.1008d738
mov edx, dword [esp + 0x2c]
cmp edx, 0x1000
jb 0x10005413
xor eax, eax
mov ecx, 0x400
lea edi, [esp + 0x298]
rep stosd dword es:[edi], eax
mov dword [esp + 0x28], eax
add esi, edx
mov ecx, dword [ebx + 0x24]
mov edi, dword [ebx + 0x20]
mov eax, esi
cdq
cmp edx, ecx
ja 0x10005533
jb 0x10005430
cmp eax, edi
jae 0x10005533
mov eax, dword [esp + 0x28]
add eax, dword [esp + 0x2c]
cmp eax, 0x1000
mov dword [esp + 0x28], eax
jb 0x10005457
xor eax, eax
mov ecx, 0x400
lea edi, [esp + 0x298]
rep stosd dword es:[edi], eax
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x2c]
test eax, eax
jl 0x1000555e
cmp dword [esp + 0x24], 0x64
jge 0x1000555e
mov ebx, dword [esp + 0x28]
jmp 0x100051f0
push ebp
call dword [sym.imp.WS2_32.dll_closesocket]
lea ecx, [esp + 0x34]
call fcn.1008d983
jmp 0x100054f9
lea ecx, [esp + 0x34]
call fcn.1008d983
push ebp
call dword [sym.imp.WS2_32.dll_closesocket]
jmp 0x100054f0
lea ecx, [esp + 0x34]
call fcn.1008d983
push ebp
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [ebx + 0x1050]
test eax, eax
je 0x100054c0
mov ecx, eax
mov eax, dword [ecx]
push 0
push 0
call dword [eax + 0xc]
lea ecx, [esp + 0x30]
call fcn.10002010
lea ecx, [esp + 0x20]
call fcn.10002010
jmp 0x10005572
lea ecx, [esp + 0x34]
call fcn.1008d983
push ebp
call dword [sym.imp.WS2_32.dll_closesocket]
lea ecx, [esp + 0x30]
call fcn.10002010
lea ecx, [esp + 0x20]
call fcn.10002010
lea ecx, [esp + 0x1c]
call fcn.10002010
lea ecx, [esp + 0x10]
call fcn.10002010
lea ecx, [esp + 0x34]
mov byte [esp + 0x12a4], 1
call fcn.1008da24
lea ecx, [esp + 0x14]
call fcn.10002010
lea ecx, [esp + 0x18]
call fcn.10002010
jmp 0x10005616
lea ecx, [esp + 0x34]
call fcn.1008d983
mov ecx, dword [esp + 0x44]
push ecx
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [ebx + 0x1050]
test eax, eax
je 0x10005572
mov ecx, eax
mov edx, dword [ecx]
push 0
push 0
call dword [edx + 0xc]
jmp 0x10005572
mov ebp, dword [esp + 0x44]
lea ecx, [esp + 0x34]
call fcn.1008d983
push ebp
call dword [sym.imp.WS2_32.dll_closesocket]
lea ecx, [esp + 0x1c]
call fcn.10002010
lea ecx, [esp + 0x10]
call fcn.10002010
lea ecx, [esp + 0x34]
mov byte [esp + 0x12a4], 1
call fcn.1008da24
lea ecx, [esp + 0x14]
call fcn.10002010
lea ecx, [esp + 0x18]
call fcn.10002010
mov eax, 1
mov ecx, dword [esp + 0x129c]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret 4
push esi
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x12a4], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x100055f1
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [ebp - 0x10]
mov dword [esp + 0x12a4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x10005616
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov ecx, dword [esp + 0x129c]
pop edi
or eax, 0xffffffff
mov dword fs:[0], ecx
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret 4