Function at 0x502a70
Capabilities:
Send data
Send data on socket

Disassembly:
sub esp, 0x1c
mov eax, dword [0x5d7050]
xor eax, esp
mov dword [esp + 0x14], eax
push ebx
push ebp
push esi
push edi
mov edi, ecx
lea eax, [edi + 0x1108]
lea edx, [eax + 1]
lea ecx, [ecx]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x502a90
sub eax, edx
mov word [edi + 0x1340], ax
mov eax, dword [edi]
movzx ecx, word [eax]
push ecx
lea edx, [esp + 0x20]
push 0x5a7c30
push edx
mov dword [esp + 0x24], 0xffffffff
call dword [sym.imp.MSVCR80.dll_sprintf]
lea eax, [esp + 0x28]
add esp, 0xc
push eax
call fcn.005079e0
add esp, 4
mov ebp, eax
xor bl, bl
mov dword [esp + 0x14], ebp
mov byte [esp + 0x13], bl
lea esp, [esp]
movzx esi, bl
imul esi, esi, 0x110
movzx eax, word [esi + 0x5f0138]
test ax, ax
je 0x502d8a
cmp word [edi + 0x1340], ax
jne 0x502b1d
lea ecx, [esi + 0x5f0038]
push ecx
lea eax, [edi + 0x1108]
push eax
call dword [sym.imp.MSVCR80.dll__stricmp]
add esp, 8
test eax, eax
je 0x502b61
movzx eax, word [edi + 0x1340]
movzx ecx, word [esi + 0x5f0138]
cmp ax, cx
jbe 0x502b68
movzx edx, ax
movzx eax, cx
sub edx, eax
cmp byte [edx + edi + 0x1107], 0x2e
lea eax, [edx + edi + 0x1107]
jne 0x502b68
lea ecx, [esi + 0x5f0038]
push ecx
add eax, 1
push eax
call dword [sym.imp.MSVCR80.dll__stricmp]
add esp, 8
test eax, eax
jne 0x502b68
mov byte [edi + 0x1346], 0x23
cmp byte [edi + 0x1346], 0x23
je 0x502b86
add bl, 1
cmp bl, 0x7d
mov byte [esp + 0x13], bl
jb 0x502ae0
jmp 0x502d8a
test ebp, ebp
je 0x502baa
movzx eax, bl
imul eax, eax, 0x110
cmp dword [eax + 0x5f0140], 0
je 0x502baa
mov dl, 1
sub dl, byte [eax + 0x5f0144]
mov byte [eax + 0x5f0144], dl
mov ecx, dword [edi + 0x1328]
movzx eax, bl
mov ebp, eax
imul ebp, ebp, 0x110
mov esi, eax
shl esi, 4
add esi, eax
movzx eax, byte [ebp + 0x5f0144]
add esi, esi
add esi, esi
add eax, esi
cmp ecx, dword [eax*4 + 0x5f013c]
je 0x502d86
lea ebx, [edi + 0x1314]
mov word [ebx], 2
movzx edx, byte [ebp + 0x5f0144]
add edx, esi
mov eax, dword [edx*4 + 0x5f013c]
push 0x35
mov dword [edi + 0x1318], eax
call sub.WS2_32.dll_htons
mov word [edi + 0x1316], ax
call dword [sym.imp.MSVCR80.dll__errno]
push 0x10
push ebx
mov dword [eax], 0
mov ecx, dword [edi + 0x133c]
mov eax, dword [0x5ec9b8]
push 0
push ecx
lea edx, [edi + 8]
push edx
push eax
call dword [sym.imp.WS2_32.dll_sendto]
mov dword [esp + 0x18], eax
call dword [sym.imp.MSVCR80.dll__errno]
mov ebx, eax
call sub.WS2_32.dll_WSAGetLastError
cmp dword [esp + 0x18], 0
mov dword [ebx], eax
jg 0x502d01
cmp byte [0x617f23], 0
je 0x502cd4
mov eax, dword [edi + 0x1318]
mov esi, dword [sym.imp.MSVCR80.dll_sprintf]
mov ecx, eax
shr ecx, 0x18
push ecx
mov edx, eax
shr edx, 0x10
movzx ecx, dl
push ecx
mov edx, eax
shr edx, 8
movzx ecx, dl
push ecx
movzx edx, al
push edx
push str._u._u._u._u
push 0x5e7b78
call esi
push 0x5e7b78
push str.Error_Forwarding_UDP_DNS_Message_to_Conditional_Forwarder__s
push 0x5e7878
call esi
add esp, 0x24
cmp byte [0x617f22], 1
jb 0x502cbd
push 0x5e7878
push 0x6180b8
call fcn.00435820
add esp, 8
mov eax, edi
call fcn.004fed60
mov edi, dword [edi]
mov eax, dword [edi]
and eax, 0xf2ffffff
or eax, 0x2000000
mov dword [edi], eax
cmp dword [ebp + 0x5f0140], 0
je 0x502ceb
mov cl, 1
sub cl, byte [ebp + 0x5f0144]
mov byte [ebp + 0x5f0144], cl
xor ax, ax
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x14]
xor ecx, esp
call fcn.00569ed6
add esp, 0x1c
ret
cmp byte [0x617f23], 2
jb 0x502d82
movzx edx, byte [ebp + 0x5f0144]
mov ebx, dword [sym.imp.MSVCR80.dll_sprintf]
add edx, esi
mov eax, dword [edx*4 + 0x5f013c]
mov ecx, eax
shr ecx, 0x18
push ecx
mov edx, eax
shr edx, 0x10
movzx ecx, dl
push ecx
mov edx, eax
shr edx, 8
movzx ecx, dl
push ecx
movzx edx, al
push edx
push str._u._u._u._u
push 0x5e7b78
call ebx
add esp, 0x18
push 0x5e7b78
mov esi, edi
call fcn.00506f00
push eax
push str._s_forwarded_to_Conditional_Forwarder__s
push 0x5e7878
call ebx
add esp, 0x10
cmp byte [0x617f22], 2
jb 0x502d82
push 0x5e7878
push 0x6180b8
call fcn.00435820
add esp, 8
mov bl, byte [esp + 0x13]
mov ebp, dword [esp + 0x14]
mov al, byte [edi + 0x1346]
cmp al, 0x23
je 0x5031a2
cmp al, 0x1a
jne 0x502ddb
mov cl, byte [0x5eede0]
movzx eax, word [edi + 0x1340]
movzx dx, cl
cmp ax, dx
jbe 0x502ddb
movzx eax, ax
movzx ecx, cl
sub eax, ecx
lea eax, [eax + edi + 0x1108]
push 0x5eece0
push eax
call dword [sym.imp.MSVCR80.dll__stricmp]
add esp, 8
test eax, eax
jne 0x502ddb
mov byte [edi + 0x1346], 0x21
cmp byte [0x617f24], 0
je 0x502eda
mov al, byte [edi + 0x1346]
cmp al, 0x1c
je 0x502dfe
cmp al, 0x21
je 0x502dfe
cmp al, 0x1f
jne 0x502eda
cmp byte [0x617f23], 2
jb 0x502e3d
mov esi, edi
call fcn.00506f00
push eax
push str._s_not_found
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 0xc
cmp byte [0x617f22], 2
jb 0x502e3d
push 0x5e7878
push 0x6180b8
call fcn.00435820
add esp, 8
movzx eax, word [edi + 0x1342]
sub eax, 2
je 0x502eae
sub eax, 4
mov eax, edi
je 0x502e84
call fcn.004fed60
mov eax, edi
call fcn.00500540
mov edi, dword [edi]
mov edx, dword [edi]
and edx, 0xf3ffffff
or edx, 0x3000000
mov dword [edi], edx
xor ax, ax
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x14]
xor ecx, esp
call fcn.00569ed6
add esp, 0x1c
ret
call fcn.004fed60
mov esi, edi
call fcn.00500380
mov edi, dword [edi]
and dword [edi], 0xf0ffffff
xor ax, ax
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x14]
xor ecx, esp
call fcn.00569ed6
add esp, 0x1c
ret
mov eax, edi
call fcn.004fed60
mov eax, edi
call fcn.00500540
mov edi, dword [edi]
and dword [edi], 0xf0ffffff
xor ax, ax
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x14]
xor ecx, esp
call fcn.00569ed6
add esp, 0x1c
ret
mov eax, dword [edi]
test byte [eax + 2], 1
jne 0x502f8f
xor ecx, ecx
cmp dword [0x5ee950], ecx
je 0x502ef8
or dword [eax], 0x80000000
jmp 0x502efe
and dword [eax], 0x7fffffff
mov eax, dword [edi]
and dword [eax], 0xdfffffff
mov eax, dword [edi]
and dword [eax], 0xfffbffff
mov eax, dword [edi]
or dword [eax], 0x800000
mov eax, dword [edi]
mov word [eax + 6], cx
mov edx, dword [edi]
mov word [edx + 8], cx
mov eax, dword [edi]
mov word [eax + 0xa], cx
mov eax, dword [edi]
mov ecx, dword [eax]
and ecx, 0xf3ffffff
or ecx, 0x3000000
mov dword [eax], ecx
cmp byte [0x617f23], 0
je 0x502f79
mov esi, edi
call fcn.00506f00
push eax
push str._s_is_not_found__recursion_not_desired_
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 0xc
cmp byte [0x617f22], 2
jb 0x502f79
push 0x5e7878
push 0x6180b8
call fcn.00435820
add esp, 8
xor ax, ax
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x14]
xor ecx, esp
call fcn.00569ed6
add esp, 0x1c
ret
cmp dword [0x5ee950], 0
jne 0x502fd4
mov eax, edi
call fcn.004fed60
mov eax, dword [edi]
mov edx, dword [eax]
and edx, 0xf3ffffff
or edx, 0x3000000
mov dword [eax], edx
mov eax, dword [edi]
and dword [eax], 0x7fffffff
cmp byte [0x617f23], 0
je 0x502f79
mov esi, edi
call fcn.00506f00
push eax
push str._s_not_found__recursion_not_available_
jmp 0x502f50
test ebp, ebp
je 0x503013
cmp dword [0x5ee954], 0
je 0x503013
mov cl, byte [ebp + 0x13]
cmp cl, 0x7d
jae 0x503013
mov al, byte [0x5eeb48]
cmp al, cl
jne 0x503018
add al, 1
cmp al, 0x7d
mov byte [0x5eeb48], al
jae 0x50300a
movzx ecx, al
cmp dword [ecx*4 + 0x5ee950], 0
jne 0x503018
xor al, al
mov byte [0x5eeb48], al
jmp 0x503018
mov al, byte [0x5eeb48]
movzx edx, al
mov eax, dword [edi + 0x1328]
cmp eax, dword [edx*4 + 0x5ee950]
je 0x5031a2
lea esi, [edi + 0x1314]
mov word [esi], 2
movzx ecx, byte [0x5eeb48]
mov edx, dword [ecx*4 + 0x5ee950]
push 0x35
mov dword [edi + 0x1318], edx
call sub.WS2_32.dll_htons
mov ebx, dword [sym.imp.MSVCR80.dll__errno]
mov word [edi + 0x1316], ax
call ebx
push 0x10
push esi
mov dword [eax], 0
mov eax, dword [edi + 0x133c]
mov edx, dword [0x5ec9b8]
push 0
push eax
lea ecx, [edi + 8]
push ecx
push edx
call dword [sym.imp.WS2_32.dll_sendto]
mov ebp, eax
mov dword [esp + 0x18], ebp
call ebx
mov esi, eax
call sub.WS2_32.dll_WSAGetLastError
test ebp, ebp
mov dword [esi], eax
jg 0x503142
cmp byte [0x617f23], 0
je 0x503108
movzx eax, byte [0x5eeb48]
mov eax, dword [eax*4 + 0x5ee950]
mov esi, 0x5e7b78
call fcn.00507470
push eax
push str.Error_forwarding_UDP_DNS_Message_to_Forwarding_Server__s
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 0xc
cmp byte [0x617f22], 1
jb 0x5030ef
push 0x5e7878
push 0x6180b8
call fcn.00435820
add esp, 8
mov eax, edi
call fcn.004fed60
mov edi, dword [edi]
mov ecx, dword [edi]
and ecx, 0xf2ffffff
or ecx, 0x2000000
mov dword [edi], ecx
cmp dword [0x5ee954], 0
je 0x502f79
mov al, byte [0x5eeb48]
add al, 1
cmp al, 0x7d
mov byte [0x5eeb48], al
jae 0x503136
movzx edx, al
cmp dword [edx*4 + 0x5ee950], 0
jne 0x502f79
mov byte [0x5eeb48], 0
jmp 0x502f79
cmp byte [0x617f23], 2
jb 0x50319a
movzx eax, byte [0x5eeb48]
mov eax, dword [eax*4 + 0x5ee950]
mov esi, 0x5e7b78
call fcn.00507470
push eax
mov esi, edi
call fcn.00506f00
push eax
push str._s_forwarded_to_Forwarding_Server__s
push 0x5e7878
call dword [sym.imp.MSVCR80.dll_sprintf]
add esp, 0x10
cmp byte [0x617f22], 2
jb 0x50319a
push 0x5e7878
push 0x6180b8
call fcn.00435820
add esp, 8
mov ebp, dword [esp + 0x14]
mov bl, byte [esp + 0x13]
test ebp, ebp
je 0x503200
mov edx, dword [ebp + 0x20]
lea ecx, [edi + 0x1008]
push ecx
push edx
call dword [sym.imp.MSVCR80.dll__stricmp]
add esp, 8
test eax, eax
jne 0x503200
mov eax, dword [0x619728]
mov ecx, dword [0x61972c]
add eax, 2
mov dword [ebp + 8], eax
mov eax, dword [ebp + 0x1c]
adc ecx, 0
mov dword [ebp + 0xc], ecx
mov edx, dword [edi + 0x1324]
mov dword [eax], edx
mov ecx, dword [edi + 0x1328]
mov dword [eax + 4], ecx
mov edx, dword [edi + 0x132c]
mov dword [eax + 8], edx
mov ecx, dword [edi + 0x1330]
mov dword [eax + 0xc], ecx
jmp 0x503298
xor eax, eax
mov dword [0x5e753c], eax
mov dword [0x5e7548], eax
mov dword [0x5e754c], eax
mov dword [0x5e755c], eax
mov dword [0x5e7540], eax
mov dword [0x5e7544], eax
mov dword [0x5e7550], eax
mov dword [0x5e7554], eax
mov dword [0x5e7558], eax
lea eax, [edi + 0x1324]
lea edx, [esp + 0x1c]
mov dword [0x5e754c], eax
lea ecx, [edi + 0x1008]
mov eax, 0x5e753c
mov byte [0x5e755c], 0x16
mov dword [0x5e753c], edx
mov dword [0x5e7548], ecx
call fcn.005098a0
test eax, eax
mov dword [esp + 0x14], eax
je 0x503294
mov edx, dword [0x619728]
mov eax, dword [0x61972c]
mov ecx, dword [esp + 0x14]
add edx, 2
mov dword [ecx + 8], edx
movzx edx, byte [0x5e96e9]
adc eax, 0
push edx
mov dword [ecx + 0xc], eax
call fcn.00507cb0
add esp, 4
mov ebp, dword [esp + 0x14]
mov al, byte [edi + 0x1347]
mov byte [ebp + 0x12], al
cmp byte [edi + 0x1346], 0x23
jne 0x5032c7
movzx eax, bl
mov ecx, eax
shl ecx, 4
add ecx, eax
shl ecx, 4
add bl, bl
add bl, byte [ecx + 0x5f0144]
add bl, 0x80
mov byte [ebp + 0x13], bl
jmp 0x5032d0
mov dl, byte [0x5eeb48]
mov byte [ebp + 0x13], dl
mov ecx, dword [esp + 0x24]
mov ax, word [esp + 0x18]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00569ed6
add esp, 0x1c
ret