Function at 0x5019b0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebx
push ebp
push esi
push edi
push 0x134c
mov edi, eax
push 0
push edi
call sub.MSVCR80.dll_memset
mov ebx, dword [sym.imp.MSVCR80.dll__errno]
lea ebp, [edi + 0x1334]
add esp, 0xc
mov dword [ebp], 0x10
call ebx
movzx ecx, byte [esp + 0x14]
push ebp
imul ecx, ecx, 0x2c
mov dword [eax], 0
mov edx, dword [ecx + 0x5eb43c]
lea eax, [edi + 0x1324]
push eax
push 0
push 0x800
lea esi, [edi + 8]
push esi
push edx
call dword [sym.imp.WS2_32.dll_recvfrom]
mov dword [edi + 0x133c], eax
call ebx
mov ebx, eax
call sub.WS2_32.dll_WSAGetLastError
mov dword [ebx], eax
cmp dword [edi + 0x133c], 0
jle 0x501d72
mov al, byte [esp + 0x14]
mov byte [edi + 0x1347], al
mov dword [edi], esi
mov eax, dword [esi]
test eax, 0x800000
jne 0x501d72
shr eax, 0x13
and eax, 0xf
je 0x501b0c
cmp byte [0x617f23], 1
jb 0x501aeb
lea ecx, [eax - 1]
cmp ecx, 4
ja case.0x501a61.3
jmp dword [ecx*4 + 0x501d7c]
push str.Inverse_query_not_supported
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 8
jmp 0x501ad0
push str.Server_Status_Request_not_supported
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 8
jmp 0x501ad0
push str.Notify_not_supported
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 8
jmp 0x501ad0
push str.Dynamic_Update_not_needed_supported_by_Dual_Server
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 8
jmp 0x501ad0
push eax
push str.OpCode__d_not_supported
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 0xc
cmp byte [0x617f22], 1
jb 0x501aeb
push 0x5e7878
push 0x6180b8
call fcn.00435820
add esp, 8
mov eax, edi
call fcn.004fed10
mov edi, dword [edi]
mov ecx, dword [edi]
and ecx, 0xf4ffffff
or ecx, 0x4000000
mov dword [edi], ecx
xor ax, ax
pop edi
pop esi
pop ebp
pop ebx
ret
movzx edx, word [esi + 4]
push edx
call sub.WS2_32.dll_ntohs
cmp ax, 1
jne 0x501d36
mov eax, dword [edi]
movzx ecx, word [eax + 6]
push ecx
call sub.WS2_32.dll_ntohs
test ax, ax
jne 0x501d36
mov eax, dword [edi]
lea edx, [eax + 0xc]
mov dword [edi + 4], edx
movzx eax, word [eax + 4]
push eax
mov esi, 1
call sub.WS2_32.dll_ntohs
cmp ax, si
jb 0x501bb7
lea ebp, [edi + 0x1008]
lea ebx, [esi + 1]
lea ebx, [ebx]
mov ecx, dword [edi]
push ecx
mov ecx, dword [edi + 4]
push ebp
call fcn.004feb60
movzx edx, ax
add dword [edi + 4], edx
mov eax, dword [edi + 4]
movzx eax, word [eax]
add esp, 8
push eax
call sub.WS2_32.dll_ntohs
add dword [edi + 4], ebx
mov word [edi + 0x1342], ax
mov eax, dword [edi + 4]
movzx ecx, word [eax]
push ecx
call sub.WS2_32.dll_ntohs
add dword [edi + 4], ebx
mov word [edi + 0x1344], ax
mov edx, dword [edi]
movzx eax, word [edx + 4]
push eax
add esi, 1
call sub.WS2_32.dll_ntohs
movzx ecx, ax
cmp esi, ecx
jle 0x501b60
movzx eax, word [edi + 0x1344]
cmp ax, 1
je 0x501c0a
cmp byte [0x617f23], 1
jb 0x501beb
movzx edx, ax
push edx
push str.DNS_Class__d_not_supported
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 0xc
mov al, 1
call fcn.00509880
mov eax, edi
call fcn.004fed60
mov edi, dword [edi]
mov eax, dword [edi]
and eax, 0xf4ffffff
or eax, 0x4000000
mov dword [edi], eax
xor ax, ax
pop edi
pop esi
pop ebp
pop ebx
ret
cmp word [edi + 0x1342], 0
jne 0x501c43
cmp byte [0x617f23], 1
jb 0x501c37
push str.missing_query_type
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 8
mov al, 1
call fcn.00509880
mov eax, edi
call fcn.004fed60
jmp 0x501d60
mov ebp, dword [edi + 0x1328]
push ebp
call sub.WS2_32.dll_ntohl
mov ebx, eax
mov eax, 0x6003fc
mov ecx, dword [eax]
test ecx, ecx
je 0x501c6f
cmp ebx, ecx
jb 0x501c65
cmp ebx, dword [eax + 4]
jbe 0x501cda
add eax, 8
cmp eax, 0x6004fc
jl 0x501c56
cmp dword [0x617df4], 0
je 0x501c94
push ebp
call sub.WS2_32.dll_htonl
cmp eax, dword [0x617df4]
jb 0x501c94
push ebp
call sub.WS2_32.dll_htonl
cmp eax, dword [0x617df8]
jbe 0x501cda
mov eax, ebp
call fcn.00506270
test al, al
jge 0x501cda
lea esi, [edi + 0x1108]
mov eax, ebx
call fcn.00507470
push eax
call fcn.00507b00
add esp, 4
test eax, eax
jne 0x501cda
test ebp, ebp
je 0x501cf4
xor al, al
nop
movzx edx, al
mov ecx, dword [edx*4 + 0x5edf8c]
test ecx, ecx
je 0x501cf4
cmp ecx, ebp
je 0x501ce6
add al, 1
cmp al, 0x7d
jb 0x501cc0
jmp 0x501cf4
mov ax, word [edi + 0x133c]
pop edi
pop esi
pop ebp
pop ebx
ret
movzx eax, al
lea eax, [eax*4 + 0x5edf8c]
test eax, eax
jne 0x501cda
mov eax, edi
call fcn.004fed60
mov edi, dword [edi]
mov eax, dword [edi]
and eax, 0xf5ffffff
or eax, 0x5000000
mov dword [edi], eax
cmp byte [0x617f23], 1
jb 0x501d72
push str.DNS_UDP_Query__Access_Denied
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 8
mov al, 1
call fcn.00509880
xor ax, ax
pop edi
pop esi
pop ebp
pop ebx
ret
cmp byte [0x617f23], 1
jb 0x501d59
push str.DNS_Query_Format_Error
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 8
mov al, 1
call fcn.00509880
mov eax, edi
call fcn.004fed10
mov edi, dword [edi]
mov ecx, dword [edi]
and ecx, 0xf1ffffff
or ecx, 0x1000000
mov dword [edi], ecx
pop edi
pop esi
pop ebp
xor ax, ax
pop ebx
ret