Function at 0x5a93e0
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x78
call fcn.007081d0
mov dword [ebp - 4], 0
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
je 0x5a940e
cmp dword [ebp - 0x20], 2
je 0x5a940e
cmp dword [ebp - 0x20], 0x17
je 0x5a940e
jmp 0x5a9410
jmp 0x5a9444
call fcn.00516cf0
push str.BIO_lookup_ex
push 0x29e
push str.crypto_bio_bio_addr.c
call fcn.00516d40
add esp, 0xc
push 0
push 0x83
push 0x20
call fcn.00516d90
add esp, 0xc
xor eax, eax
jmp 0x5a994e
call fcn.005ab2f0
cmp eax, 1
je 0x5a9455
xor eax, eax
jmp 0x5a994e
mov ecx, 1
test ecx, ecx
je 0x5a959b
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x24], 0
push 0x20
push 0
lea edx, [ebp - 0x78]
push edx
call sub.VCRUNTIME140.dll_memset
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 0x5a94a9
cmp dword [ebp + 0x14], 0
jne 0x5a94a9
mov eax, dword [ebp - 0x78]
or eax, 0x400
mov dword [ebp - 0x78], eax
cmp dword [ebp + 0x10], 1
jne 0x5a94b8
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.005a9ce0
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x34], eax
cmp dword [ebp - 0x34], 0
je 0x5a9516
cmp dword [ebp - 0x34], 8
je 0x5a94e4
jmp 0x5a951f
call fcn.00516cf0
push str.BIO_lookup_ex
push 0x2d3
push str.crypto_bio_bio_addr.c
call fcn.00516d40
add esp, 0xc
push 0
push 0xc0100
push 0x20
call fcn.00516d90
add esp, 0xc
jmp 0x5a9596
mov dword [ebp - 4], 1
jmp 0x5a9596
mov ecx, dword [ebp - 0x78]
and ecx, 0x400
je 0x5a954a
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 0x5a94b8
cmp dword [ebp - 0x24], 0
je 0x5a9558
mov edx, dword [ebp - 0x24]
mov dword [ebp - 0x38], edx
jmp 0x5a955e
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x38], eax
call fcn.00516cf0
push str.BIO_lookup_ex
push 0x2e2
push str.crypto_bio_bio_addr.c
call fcn.00516d40
add esp, 0xc
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.005ab0b0
add esp, 4
push eax
push 0x80002
push 0x20
call fcn.00516d90
add esp, 0xc
jmp 0x5a994b
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x54], 0
xor edx, edx
mov word [ebp - 0x50], dx
mov dword [ebp - 0x4c], 0
push 0x5ab0a0
push 0x7d26ac
call fcn.005cdb30
add esp, 8
test eax, eax
je 0x5a95d6
mov eax, dword [0x7d26b0]
mov dword [ebp - 0x3c], eax
jmp 0x5a95dd
mov dword [ebp - 0x3c], 0
cmp dword [ebp - 0x3c], 0
jne 0x5a961c
call fcn.00516cf0
push str.BIO_lookup_ex
push 0x30c
push str.crypto_bio_bio_addr.c
call fcn.00516d40
add esp, 0xc
push 0
push 0xc0100
push 0x20
call fcn.00516d90
add esp, 0xc
mov dword [ebp - 4], 0
jmp 0x5a993c
mov ecx, dword [0x7d3c84]
push ecx
call fcn.005cdc30
add esp, 4
test eax, eax
jne 0x5a963b
mov dword [ebp - 4], 0
jmp 0x5a993c
mov dword [0x7d26a8], 0
cmp dword [ebp + 8], 0
jne 0x5a96b9
mov dword [ebp - 0xc], 0x7714a8
mov edx, dword [ebp + 0x10]
mov dword [ebp - 0x40], edx
cmp dword [ebp - 0x40], 0
je 0x5a9666
cmp dword [ebp - 0x40], 1
je 0x5a9672
jmp 0x5a967e
mov dword [0x7d26a8], 0x7f000001
jmp 0x5a96b7
mov dword [0x7d26a8], 0
jmp 0x5a96b7
call fcn.00516cf0
push str.BIO_lookup_ex
push 0x322
push str.crypto_bio_bio_addr.c
call fcn.00516d40
add esp, 0xc
push 0
push 0xc0103
push 0x20
call fcn.00516d90
add esp, 0xc
mov dword [ebp - 4], 0
jmp 0x5a993c
jmp 0x5a970a
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 0x5a970a
call fcn.00516cf0
push str.BIO_lookup_ex
push 0x33f
push str.crypto_bio_bio_addr.c
call fcn.00516d40
add esp, 0xc
push str.calling_gethostbyname__
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 2
call fcn.00516d90
add esp, 0xc
mov dword [ebp - 4], 0
jmp 0x5a993c
cmp dword [ebp + 0xc], 0
jne 0x5a9728
xor ecx, ecx
mov word [ebp - 0x50], cx
mov dword [ebp - 0x4c], 0
lea edx, [ebp - 0x58]
mov dword [ebp - 0x1c], edx
jmp 0x5a983b
mov dword [ebp - 0x14], 0
push 0xa
lea eax, [ebp - 0x14]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll_strtol]
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 0x5a9760
cmp dword [ebp - 0x44], 2
je 0x5a9769
jmp 0x5a9770
mov dword [ebp - 0x18], 0x7714bc
jmp 0x5a9770
mov dword [ebp - 0x18], 0x7714b8
mov eax, dword [ebp - 0x14]
cmp eax, dword [ebp + 0xc]
je 0x5a97b1
mov ecx, dword [ebp - 0x14]
movsx edx, byte [ecx]
test edx, edx
jne 0x5a97b1
cmp dword [ebp - 0x28], 0
jle 0x5a97b1
cmp dword [ebp - 0x28], 0x10000
jge 0x5a97b1
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 0x5a983b
mov eax, dword [ebp - 0x14]
cmp eax, dword [ebp + 0xc]
jne 0x5a9809
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 0x5a9807
call fcn.00516cf0
push str.BIO_lookup_ex
push 0x36e
push str.crypto_bio_bio_addr.c
call fcn.00516d40
add esp, 0xc
push str.calling_getservbyname__
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 2
call fcn.00516d90
add esp, 0xc
jmp 0x5a993c
jmp 0x5a983b
call fcn.00516cf0
push str.BIO_lookup_ex
push 0x373
push str.crypto_bio_bio_addr.c
call fcn.00516d40
add esp, 0xc
push 0
push 0x82
push 0x20
call fcn.00516d90
add esp, 0xc
jmp 0x5a993c
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 0x5a985f
mov eax, dword [ebp - 8]
add eax, 4
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 8]
cmp dword [ecx], 0
je 0x5a9869
jmp 0x5a9856
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 0x5a9935
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.005aaf40
add esp, 0x18
test eax, eax
jne 0x5a98ce
jmp 0x5a98e3
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 0x5a9878
mov ecx, dword [ebp + 0x20]
mov edx, dword [ecx]
push edx
call fcn.005a8f70
add esp, 4
mov eax, dword [ebp + 0x20]
mov dword [eax], 0
call fcn.00516cf0
push str.BIO_lookup_ex
push 0x39d
push str.crypto_bio_bio_addr.c
call fcn.00516d40
add esp, 0xc
push 0
push 0xc0100
push 0x20
call fcn.00516d90
add esp, 0xc
mov dword [ebp - 4], 0
jmp 0x5a993c
mov dword [ebp - 4], 1
mov ecx, dword [0x7d3c84]
push ecx
call fcn.005cdbe0
add esp, 4
mov eax, dword [ebp - 4]
mov esp, ebp
pop ebp
ret