Function at 0x10019050
Capabilities:
Create udp socket
Set socket configuration

Disassembly:
sub esp, 0x2c
mov eax, dword [0x100638a4]
xor eax, esp
mov dword [esp + 0x28], eax
push esi
push 0x11
push 2
push 2
mov esi, ecx
call dword [sym.imp.WS2_32.dll_socket]
mov dword [esi + 4], eax
cmp eax, 0xffffffff
jne 0x100190a4
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.socket___failed._errorno:_d
push 1
push 0x10069158
call fcn.10017d90
add esp, 0x10
xor al, al
pop esi
mov ecx, dword [esp + 0x28]
xor ecx, esp
call fcn.10038723
add esp, 0x2c
ret 8
push ebx
push ebp
xor ebp, ebp
push ebp
push ebp
lea ecx, [esp + 0x28]
push ecx
push ebp
push ebp
push 4
lea edx, [esp + 0x30]
push edx
push 0x9800000c
push eax
mov dword [esp + 0x44], ebp
mov dword [esp + 0x3c], ebp
call dword [sym.imp.WS2_32.dll_WSAIoctl]
mov ecx, dword [esi + 4]
mov ebx, dword [sym.imp.WS2_32.dll_setsockopt]
push 4
lea eax, [esp + 0x14]
push eax
push 0x20
push 0xffff
push ecx
mov dword [esp + 0x24], 1
call ebx
cmp eax, 0xffffffff
jne 0x1001914c
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.setsockopt_failed._errorno:_d
push 1
push 0x10069158
call fcn.10017d90
mov eax, dword [esi + 4]
add esp, 0x10
cmp eax, 0xffffffff
je 0x10019136
mov edx, dword [esi + 0x14]
push ebp
push edx
push eax
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
mov eax, dword [esi + 4]
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [esi + 4], 0xffffffff
mov dword [esi + 8], ebp
pop ebp
pop ebx
xor al, al
pop esi
mov ecx, dword [esp + 0x28]
xor ecx, esp
call fcn.10038723
add esp, 0x2c
ret 8
push edi
mov edi, dword [esp + 0x40]
cmp di, bp
je 0x10019239
mov edx, dword [esi + 4]
push 4
lea ecx, [esp + 0x1c]
push ecx
push 0x1002
mov eax, 0x20000
push 0xffff
push edx
mov dword [esp + 0x2c], eax
mov dword [esp + 0x34], eax
call ebx
mov ecx, dword [esi + 4]
push 4
lea eax, [esp + 0x24]
push eax
push 0x1001
push 0xffff
push ecx
call ebx
mov edx, 2
push ebp
mov dword [esp + 0x14], ebp
mov ebp, dword [sym.imp.WS2_32.dll_htonl]
mov word [esp + 0x2c], dx
call ebp
mov ebx, dword [sym.imp.WS2_32.dll_htons]
push edi
mov dword [esp + 0x30], eax
call ebx
mov ecx, dword [esi + 4]
mov word [esp + 0x2a], ax
push 0x10
lea eax, [esp + 0x2c]
push eax
push ecx
call dword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
jne 0x10019218
mov eax, dword [esp + 0x10]
inc eax
inc edi
cmp eax, dword [esp + 0x44]
mov dword [esp + 0x10], eax
jge 0x10019287
mov edx, 2
push 0
mov word [esp + 0x2c], dx
call ebp
push edi
mov dword [esp + 0x30], eax
call ebx
mov ecx, dword [esi + 4]
mov word [esp + 0x2a], ax
push 0x10
lea eax, [esp + 0x2c]
push eax
push ecx
call dword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
je 0x100191d4
push edi
call ebx
movzx edx, ax
movzx eax, di
push eax
push str.bind_port:_u
push 1
push 0x10069158
mov dword [esi + 0xc], edx
call fcn.10017d90
add esp, 0x10
mov ecx, dword [esi + 0x14]
mov edx, dword [esi + 4]
push 1
push ecx
push edx
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
cmp eax, 0xffffffff
jne 0x10019295
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.WSAEventSelect_failed__error:_d
push 1
push 0x10069158
call fcn.10017d90
add esp, 0x10
mov ecx, esi
call fcn.10018ce0
pop edi
pop ebp
pop ebx
xor al, al
pop esi
mov ecx, dword [esp + 0x28]
xor ecx, esp
call fcn.10038723
add esp, 0x2c
ret 8
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.bind_failed_errorno:_d
jmp 0x1001925a
mov ecx, dword [esp + 0x38]
pop edi
pop ebp
pop ebx
pop esi
xor ecx, esp
mov al, 1
call fcn.10038723
add esp, 0x2c
ret 8