Function at 0x517370
Capabilities:
Create udp socket
Receive data
Receive data on socket
Send data
Send data on socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x708
mov eax, dword [0x5a53f4]
xor eax, ebp
mov dword [ebp - 0xc], eax
push esi
push edi
mov dword [ebp - 0x708], ecx
cmp dword [ebp + 8], 0
je 0x51739d
cmp dword [ebp + 0xc], 0
je 0x51739d
cmp dword [ebp + 0x10], 0
jne 0x5173a4
xor eax, eax
jmp 0x51775d
push 0x11
push 2
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0xffffffff
jne 0x5173c0
xor eax, eax
jmp 0x51775d
mov dword [ebp - 8], 0
mov dword [ebp - 0x5e0], 0x320
push 4
lea eax, [ebp - 0x5e0]
push eax
push 0x1006
push 0xffff
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.WS2_32.dll_setsockopt]
mov dword [ebp - 0x5cc], eax
cmp dword [ebp - 0x5cc], 0xffffffff
jne 0x517402
jmp 0x517750
mov ecx, 0xc
mov esi, 0x57cc50
lea edi, [ebp - 0x1c4]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
push 0x10
push 0
lea edx, [ebp - 0x18c]
push edx
call fcn.00534b20
add esp, 0xc
mov eax, dword [ebp + 8]
mov dword [ebp - 0x188], eax
mov ecx, 2
mov word [ebp - 0x18c], cx
push 0x89
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x18a], ax
push 0x10
lea edx, [ebp - 0x18c]
push edx
push 0
push 0x32
lea eax, [ebp - 0x1c4]
push eax
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.WS2_32.dll_sendto]
mov dword [ebp - 0x5cc], eax
cmp dword [ebp - 0x5cc], 0xffffffff
jne 0x517483
jmp 0x517750
mov byte [ebp - 0x5c8], 0
push 0x3ff
push 0
lea edx, [ebp - 0x5c7]
push edx
call fcn.00534b20
add esp, 0xc
mov dword [ebp - 0x190], 0x10
lea eax, [ebp - 0x190]
push eax
lea ecx, [ebp - 0x5dc]
push ecx
push 0
push 0x400
lea edx, [ebp - 0x5c8]
push edx
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.WS2_32.dll_recvfrom]
mov dword [ebp - 0x5cc], eax
cmp dword [ebp - 0x5cc], 0xffffffff
je 0x5174e8
cmp dword [ebp - 0x5cc], 0
jne 0x5174ed
jmp 0x517750
mov ecx, dword [ebp - 0x188]
cmp ecx, dword [ebp - 0x5d8]
jne 0x51750d
movzx edx, word [ebp - 0x18a]
movzx eax, word [ebp - 0x5da]
cmp edx, eax
je 0x517512
jmp 0x517750
cmp dword [ebp - 0x5cc], 0x39
jg 0x517520
jmp 0x517750
mov dword [ebp - 0x17c], 0
push 1
lea ecx, [ebp - 0x590]
push ecx
lea edx, [ebp - 0x17c]
push edx
call fcn.00530500
add esp, 0xc
cmp dword [ebp - 0x17c], 0x14
jg 0x517554
cmp dword [ebp - 0x17c], 0
jg 0x517559
jmp 0x517750
mov eax, dword [ebp - 0x17c]
imul eax, eax, 0x12
mov dword [ebp - 0x1c8], eax
mov ecx, dword [ebp - 0x1c8]
add ecx, 0x39
cmp dword [ebp - 0x5cc], ecx
jg 0x51757e
jmp 0x517750
mov byte [ebp - 0x178], 0
xor edx, edx
mov dword [ebp - 0x177], edx
mov dword [ebp - 0x173], edx
mov dword [ebp - 0x16f], edx
mov word [ebp - 0x16b], dx
mov byte [ebp - 0x169], dl
push 0x158
push 0
lea eax, [ebp - 0x168]
push eax
call fcn.00534b20
add esp, 0xc
mov ecx, dword [ebp - 0x1c8]
push ecx
lea edx, [ebp - 0x58f]
push edx
lea eax, [ebp - 0x178]
push eax
call fcn.00530500
add esp, 0xc
mov dword [ebp - 0x5e4], 0
jmp 0x5175f4
mov ecx, dword [ebp - 0x5e4]
add ecx, 1
mov dword [ebp - 0x5e4], ecx
mov edx, dword [ebp - 0x5e4]
cmp edx, dword [ebp - 0x17c]
jge 0x517663
mov dword [ebp - 0x5e8], 0
jmp 0x51761d
mov eax, dword [ebp - 0x5e8]
add eax, 1
mov dword [ebp - 0x5e8], eax
cmp dword [ebp - 0x5e8], 0xf
jge 0x517661
mov ecx, dword [ebp - 0x5e4]
imul ecx, ecx, 0x12
lea edx, [ebp + ecx - 0x178]
mov eax, dword [ebp - 0x5e8]
movzx ecx, byte [edx + eax]
cmp ecx, 0x20
jne 0x51765f
mov edx, dword [ebp - 0x5e4]
imul edx, edx, 0x12
lea eax, [ebp + edx - 0x178]
mov ecx, dword [ebp - 0x5e8]
mov byte [eax + ecx], 0
jmp 0x51760e
jmp 0x5175e5
mov dword [ebp - 0x5ec], 0
jmp 0x51767e
mov edx, dword [ebp - 0x5ec]
add edx, 1
mov dword [ebp - 0x5ec], edx
mov eax, dword [ebp - 0x5ec]
cmp eax, dword [ebp - 0x17c]
jge 0x517741
mov ecx, dword [ebp - 0x5ec]
imul ecx, ecx, 0x12
movzx edx, byte [ebp + ecx - 0x169]
test edx, edx
jne 0x51773c
mov eax, dword [ebp - 0x5ec]
imul eax, eax, 0x12
movzx ecx, word [ebp + eax - 0x168]
and ecx, 0x80
jne 0x51773c
mov byte [ebp - 0x600], 0
xor edx, edx
mov dword [ebp - 0x5ff], edx
mov dword [ebp - 0x5fb], edx
mov dword [ebp - 0x5f7], edx
mov dword [ebp - 0x5f3], edx
push 0x10
mov eax, dword [ebp - 0x5ec]
imul eax, eax, 0x12
lea ecx, [ebp + eax - 0x178]
push ecx
lea edx, [ebp - 0x600]
push edx
call fcn.00530500
add esp, 0xc
lea eax, [ebp - 0x600]
push eax
lea ecx, [ebp - 0x704]
call fcn.00514610
mov ecx, eax
call fcn.00514670
push eax
mov ecx, dword [ebp + 0x10]
sub ecx, 1
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.00407af0
lea ecx, [ebp - 0x704]
call fcn.00514640
jmp 0x517741
jmp 0x51766f
mov dword [ebp - 8], 1
xor eax, eax
jne 0x5173c7
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [ebp - 8]
pop edi
pop esi
mov ecx, dword [ebp - 0xc]
xor ecx, ebp
call fcn.005308cb
mov esp, ebp
pop ebp
ret 0xc