Function at 0x571b80
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x78
call fcn.006db7b0
mov dword [ebp - 4], 0
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
je 0x571bae
cmp dword [ebp - 0x20], 2
je 0x571bae
cmp dword [ebp - 0x20], 0x17
je 0x571bae
jmp 0x571bb0
jmp 0x571be4
call fcn.005798d0
push str.BIO_lookup_ex
push 0x29e
push str.crypto_bio_bio_addr.c
call fcn.00579920
add esp, 0xc
push 0
push 0x83
push 0x20
call fcn.00579970
add esp, 0xc
xor eax, eax
jmp 0x5720ed
call fcn.005b2530
cmp eax, 1
je 0x571bf5
xor eax, eax
jmp 0x5720ed
mov ecx, 1
test ecx, ecx
je 0x571d3b
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x24], 0
push 0x20
push 0
lea edx, [ebp - 0x78]
push edx
call fcn.006dca70
add esp, 0xc
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x74], eax
mov ecx, dword [ebp + 0x18]
mov dword [ebp - 0x70], ecx
mov edx, dword [ebp + 0x1c]
mov dword [ebp - 0x6c], edx
cmp dword [ebp + 8], 0
je 0x571c49
cmp dword [ebp + 0x14], 0
jne 0x571c49
mov eax, dword [ebp - 0x78]
or eax, 0x400
mov dword [ebp - 0x78], eax
cmp dword [ebp + 0x10], 1
jne 0x571c58
mov ecx, dword [ebp - 0x78]
or ecx, 1
mov dword [ebp - 0x78], ecx
mov edx, dword [ebp + 0x20]
push edx
lea eax, [ebp - 0x78]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.00572480
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x34], eax
cmp dword [ebp - 0x34], 0
je 0x571cb6
cmp dword [ebp - 0x34], 8
je 0x571c84
jmp 0x571cbf
call fcn.005798d0
push str.BIO_lookup_ex
push 0x2d3
push str.crypto_bio_bio_addr.c
call fcn.00579920
add esp, 0xc
push 0
push 0xc0100
push 0x20
call fcn.00579970
add esp, 0xc
jmp 0x571d36
mov dword [ebp - 4], 1
jmp 0x571d36
mov ecx, dword [ebp - 0x78]
and ecx, 0x400
je 0x571cea
mov edx, dword [ebp - 0x78]
and edx, 0xfffffbff
mov dword [ebp - 0x78], edx
mov eax, dword [ebp - 0x78]
or eax, 4
mov dword [ebp - 0x78], eax
mov ecx, dword [ebp - 0x10]
mov dword [ebp - 0x24], ecx
jmp 0x571c58
cmp dword [ebp - 0x24], 0
je 0x571cf8
mov edx, dword [ebp - 0x24]
mov dword [ebp - 0x38], edx
jmp 0x571cfe
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x38], eax
call fcn.005798d0
push str.BIO_lookup_ex
push 0x2e2
push str.crypto_bio_bio_addr.c
call fcn.00579920
add esp, 0xc
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.004a8380
add esp, 4
push eax
push 0x80002
push 0x20
call fcn.00579970
add esp, 0xc
jmp 0x5720ea
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x54], 0
xor edx, edx
mov word [ebp - 0x50], dx
mov dword [ebp - 0x4c], 0
push 0x5737c0
push 0x7ede04
call fcn.00575c70
add esp, 8
test eax, eax
je 0x571d76
mov eax, dword [0x7ede08]
mov dword [ebp - 0x3c], eax
jmp 0x571d7d
mov dword [ebp - 0x3c], 0
cmp dword [ebp - 0x3c], 0
jne 0x571dbc
call fcn.005798d0
push str.BIO_lookup_ex
push 0x30c
push str.crypto_bio_bio_addr.c
call fcn.00579920
add esp, 0xc
push 0
push 0xc0100
push 0x20
call fcn.00579970
add esp, 0xc
mov dword [ebp - 4], 0
jmp 0x5720db
mov ecx, dword [0x7f09e4]
push ecx
call fcn.00575d70
add esp, 4
test eax, eax
jne 0x571ddb
mov dword [ebp - 4], 0
jmp 0x5720db
mov dword [0x7ede00], 0
cmp dword [ebp + 8], 0
jne 0x571e59
mov dword [ebp - 0xc], 0x75b69c
mov edx, dword [ebp + 0x10]
mov dword [ebp - 0x40], edx
cmp dword [ebp - 0x40], 0
je 0x571e06
cmp dword [ebp - 0x40], 1
je 0x571e12
jmp 0x571e1e
mov dword [0x7ede00], 0x7f000001
jmp 0x571e57
mov dword [0x7ede00], 0
jmp 0x571e57
call fcn.005798d0
push str.BIO_lookup_ex
push 0x322
push str.crypto_bio_bio_addr.c
call fcn.00579920
add esp, 0xc
push 0
push 0xc0103
push 0x20
call fcn.00579970
add esp, 0xc
mov dword [ebp - 4], 0
jmp 0x5720db
jmp 0x571eaa
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x571eaa
call fcn.005798d0
push str.BIO_lookup_ex
push 0x33f
push str.crypto_bio_bio_addr.c
call fcn.00579920
add esp, 0xc
push str.calling_gethostbyname__
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 2
call fcn.00579970
add esp, 0xc
mov dword [ebp - 4], 0
jmp 0x5720db
cmp dword [ebp + 0xc], 0
jne 0x571ec8
xor ecx, ecx
mov word [ebp - 0x50], cx
mov dword [ebp - 0x4c], 0
lea edx, [ebp - 0x58]
mov dword [ebp - 0x1c], edx
jmp 0x571fda
mov dword [ebp - 0x14], 0
push 0xa
lea eax, [ebp - 0x14]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.006f2d0a
add esp, 0xc
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x18], 0
mov edx, dword [ebp + 0x18]
mov dword [ebp - 0x44], edx
cmp dword [ebp - 0x44], 1
je 0x571eff
cmp dword [ebp - 0x44], 2
je 0x571f08
jmp 0x571f0f
mov dword [ebp - 0x18], 0x75b6b0
jmp 0x571f0f
mov dword [ebp - 0x18], 0x75b6ac
mov eax, dword [ebp - 0x14]
cmp eax, dword [ebp + 0xc]
je 0x571f50
mov ecx, dword [ebp - 0x14]
movsx edx, byte [ecx]
test edx, edx
jne 0x571f50
cmp dword [ebp - 0x28], 0
jle 0x571f50
cmp dword [ebp - 0x28], 0x10000
jge 0x571f50
movzx eax, word [ebp - 0x28]
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x50], ax
mov ecx, dword [ebp - 0x18]
mov dword [ebp - 0x4c], ecx
lea edx, [ebp - 0x58]
mov dword [ebp - 0x1c], edx
jmp 0x571fda
mov eax, dword [ebp - 0x14]
cmp eax, dword [ebp + 0xc]
jne 0x571fa8
mov ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call dword [sym.imp.WS2_32.dll_getservbyname]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
jne 0x571fa6
call fcn.005798d0
push str.BIO_lookup_ex
push 0x36e
push str.crypto_bio_bio_addr.c
call fcn.00579920
add esp, 0xc
push str.calling_getservbyname__
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 2
call fcn.00579970
add esp, 0xc
jmp 0x5720db
jmp 0x571fda
call fcn.005798d0
push str.BIO_lookup_ex
push 0x373
push str.crypto_bio_bio_addr.c
call fcn.00579920
add esp, 0xc
push 0
push 0x82
push 0x20
call fcn.00579970
add esp, 0xc
jmp 0x5720db
mov eax, dword [ebp + 0x20]
mov dword [eax], 0
mov dword [ebp - 0x30], 0
mov ecx, dword [ebp - 0xc]
mov edx, dword [ecx + 0xc]
mov dword [ebp - 8], edx
jmp 0x571ffe
mov eax, dword [ebp - 8]
add eax, 4
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 8]
cmp dword [ecx], 0
je 0x572008
jmp 0x571ff5
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 8]
sub eax, dword [edx + 0xc]
sar eax, 2
mov dword [ebp - 0x2c], eax
mov ecx, dword [ebp - 8]
sub ecx, 4
mov dword [ebp - 8], ecx
mov edx, dword [ebp - 0x2c]
mov dword [ebp - 0x48], edx
mov eax, dword [ebp - 0x2c]
sub eax, 1
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x48], 0
jbe 0x5720d4
lea ecx, [ebp - 0x30]
push ecx
mov edx, dword [ebp - 0x1c]
movzx eax, word [edx + 8]
push eax
mov ecx, dword [ebp - 0xc]
movsx edx, word [ecx + 0xa]
push edx
mov eax, dword [ebp - 8]
mov ecx, dword [eax]
push ecx
mov edx, dword [ebp + 0x18]
push edx
mov eax, dword [ebp - 0xc]
movsx ecx, word [eax + 8]
push ecx
call fcn.00573660
add esp, 0x18
test eax, eax
jne 0x57206d
jmp 0x572082
mov edx, dword [ebp - 0x30]
mov eax, dword [ebp + 0x20]
mov ecx, dword [eax]
mov dword [edx + 0x1c], ecx
mov edx, dword [ebp + 0x20]
mov eax, dword [ebp - 0x30]
mov dword [edx], eax
jmp 0x572017
mov ecx, dword [ebp + 0x20]
mov edx, dword [ecx]
push edx
call fcn.00571790
add esp, 4
mov eax, dword [ebp + 0x20]
mov dword [eax], 0
call fcn.005798d0
push str.BIO_lookup_ex
push 0x39d
push str.crypto_bio_bio_addr.c
call fcn.00579920
add esp, 0xc
push 0
push 0xc0100
push 0x20
call fcn.00579970
add esp, 0xc
mov dword [ebp - 4], 0
jmp 0x5720db
mov dword [ebp - 4], 1
mov ecx, dword [0x7f09e4]
push ecx
call fcn.00575d20
add esp, 4
mov eax, dword [ebp - 4]
mov esp, ebp
pop ebp
ret