Add files using upload-large-folder tool
Browse filesThis view is limited to 50 files because it contains too many changes. See raw diff
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_keys.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_name.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_opt.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_opt_byid.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_opt_cnt.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_str.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_ttl.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_type.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_u16.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_u32.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_u8.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_key_datatype.3 +4 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_key_t.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_key_to_rec_type.3 +4 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_key_tostr.3 +4 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_addr.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_addr6.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_bin.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_opt.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_str.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_u16.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_u32.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_u8.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_section_t.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_section_tostr.3 +4 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_write.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dup.3 +25 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_expand_name.3 +51 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_expand_string.3 +48 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_fds.3 +57 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_free_data.3 +62 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_free_hostent.3 +30 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_free_string.3 +19 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_freeaddrinfo.3 +22 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_get_servers.3 +69 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_get_servers_csv.3 +4 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_get_servers_ports.3 +4 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_getaddrinfo.3 +194 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_gethostbyaddr.3 +100 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_gethostbyname.3 +108 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_gethostbyname_file.3 +68 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_getnameinfo.3 +147 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_getsock.3 +53 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_inet_ntop.3 +34 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_inet_pton.3 +35 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_init.3 +3 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_init_options.3 +415 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_library_cleanup.3 +66 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_library_init.3 +98 -0
- miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_library_init_android.3 +127 -0
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_keys.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_mapping.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_name.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_opt.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_opt_byid.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_opt_cnt.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_str.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_ttl.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_type.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_u16.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_u32.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_get_u8.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_key_datatype.3
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright (C) Daniel Stenberg
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.so man3/ares_dns_mapping.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_key_t.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_key_to_rec_type.3
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright (C) Daniel Stenberg
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.so man3/ares_dns_mapping.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_key_tostr.3
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright (C) Daniel Stenberg
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.so man3/ares_dns_mapping.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_addr.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_addr6.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_bin.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_opt.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_str.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_u16.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_u32.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_rr_set_u8.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_section_t.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_rr.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_section_tostr.3
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright (C) Daniel Stenberg
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.so man3/ares_dns_mapping.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dns_write.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_dns_record.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_dup.3
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright (C) 2004-2009 by Daniel Stenberg
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_DUP 3 "26 May 2009"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_dup \- Duplicate a resolver channel
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
int ares_dup(ares_channel_t **\fIdest\fP, const ares_channel_t *\fIsource\fP)
|
| 13 |
+
.fi
|
| 14 |
+
.SH DESCRIPTION
|
| 15 |
+
The \fBares_dup(3)\fP function duplicates an existing communications channel
|
| 16 |
+
for name service lookups. If it returns successfully, \fBares_dup(3)\fP will
|
| 17 |
+
set the variable pointed to by \fIdest\fP to a handle used to identify the
|
| 18 |
+
name service channel. The caller should invoke \fIares_destroy(3)\fP on the
|
| 19 |
+
handle when the channel is no longer needed.
|
| 20 |
+
.SH SEE ALSO
|
| 21 |
+
.BR ares_destroy (3),
|
| 22 |
+
.BR ares_init (3),
|
| 23 |
+
.BR ares_library_init (3)
|
| 24 |
+
.SH AVAILABILITY
|
| 25 |
+
\fIares_dup(3)\fP was added in c-ares 1.6.0
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_expand_name.3
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_EXPAND_NAME 3 "20 Nov 2009"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_expand_name \- Expand a DNS-encoded domain name
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
int ares_expand_name(const unsigned char *\fIencoded\fP,
|
| 13 |
+
const unsigned char *\fIabuf\fP, int \fIalen\fP,
|
| 14 |
+
char **\fIs\fP, long *\fIenclen\fP)
|
| 15 |
+
.fi
|
| 16 |
+
.SH DESCRIPTION
|
| 17 |
+
The
|
| 18 |
+
.B ares_expand_name
|
| 19 |
+
function converts a DNS-encoded domain name to a dot-separated C
|
| 20 |
+
string. The argument
|
| 21 |
+
.I encoded
|
| 22 |
+
gives the beginning of the encoded domain name, and the arguments
|
| 23 |
+
.I abuf
|
| 24 |
+
and
|
| 25 |
+
.I alen
|
| 26 |
+
give the containing message buffer (necessary for the processing of
|
| 27 |
+
indirection pointers within the encoded domain name). The result is
|
| 28 |
+
placed in a NUL-terminated allocated buffer, a pointer to which is
|
| 29 |
+
stored in the variable pointed to by
|
| 30 |
+
.IR s .
|
| 31 |
+
The length of the encoded name is stored in the variable pointed to by
|
| 32 |
+
.I enclen
|
| 33 |
+
so that the caller can advance past the encoded domain name to read
|
| 34 |
+
further data in the message.
|
| 35 |
+
|
| 36 |
+
Use \fIares_free_string(3)\fP to free the allocated hostname.
|
| 37 |
+
.SH RETURN VALUES
|
| 38 |
+
.B ares_expand_name
|
| 39 |
+
can return any of the following values:
|
| 40 |
+
.TP 15
|
| 41 |
+
.B ARES_SUCCESS
|
| 42 |
+
Expansion of the encoded name succeeded.
|
| 43 |
+
.TP 15
|
| 44 |
+
.B ARES_EBADNAME
|
| 45 |
+
The encoded domain name was malformed and could not be expanded.
|
| 46 |
+
.TP 15
|
| 47 |
+
.B ARES_ENOMEM
|
| 48 |
+
Memory was exhausted.
|
| 49 |
+
.SH SEE ALSO
|
| 50 |
+
.BR ares_mkquery (3),
|
| 51 |
+
.BR ares_free_string (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_expand_string.3
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_EXPAND_NAME 3 "20 Nov 2009"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_expand_string \- Expand a length encoded string
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
int ares_expand_string(const unsigned char *\fIencoded\fP,
|
| 13 |
+
const unsigned char *\fIabuf\fP, int \fIalen\fP,
|
| 14 |
+
unsigned char **\fIs\fP, long *\fIenclen\fP)
|
| 15 |
+
.fi
|
| 16 |
+
.SH DESCRIPTION
|
| 17 |
+
The
|
| 18 |
+
.B ares_expand_string
|
| 19 |
+
function converts a length encoded string to a NUL-terminated C
|
| 20 |
+
string. The argument
|
| 21 |
+
.I encoded
|
| 22 |
+
gives the beginning of the encoded string, and the arguments
|
| 23 |
+
.I abuf
|
| 24 |
+
and
|
| 25 |
+
.I alen
|
| 26 |
+
give the containing message buffer (necessary for the processing of
|
| 27 |
+
indirection pointers within the encoded domain name). The result is
|
| 28 |
+
placed in a NUL-terminated allocated buffer, a pointer to which is
|
| 29 |
+
stored in the variable pointed to by
|
| 30 |
+
.IR s .
|
| 31 |
+
The length of the encoded string is stored in the variable pointed to by
|
| 32 |
+
.I enclen
|
| 33 |
+
so that the caller can advance past the encoded string to read
|
| 34 |
+
further data in the message.
|
| 35 |
+
.SH RETURN VALUES
|
| 36 |
+
.B ares_expand_string
|
| 37 |
+
can return any of the following values:
|
| 38 |
+
.TP 15
|
| 39 |
+
.B ARES_SUCCESS
|
| 40 |
+
Expansion of the encoded string succeeded.
|
| 41 |
+
.TP 15
|
| 42 |
+
.B ARES_EBADSTR
|
| 43 |
+
The encoded string was malformed and could not be expanded.
|
| 44 |
+
.TP 15
|
| 45 |
+
.B ARES_ENOMEM
|
| 46 |
+
Memory was exhausted.
|
| 47 |
+
.SH SEE ALSO
|
| 48 |
+
.BR ares_free_string (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_fds.3
ADDED
|
@@ -0,0 +1,57 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_FDS 3 "23 July 1998"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_fds \- return file descriptors to select on (deprecated)
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
int ares_fds(const ares_channel_t *\fIchannel\fP,
|
| 13 |
+
fd_set *\fIread_fds\fP,
|
| 14 |
+
fd_set *\fIwrite_fds\fP)
|
| 15 |
+
.fi
|
| 16 |
+
.SH DESCRIPTION
|
| 17 |
+
See the \fBNOTES\fP section on issues with this function and alternatives.
|
| 18 |
+
|
| 19 |
+
The \fBares_fds(3)\fP function retrieves the set of file descriptors which the
|
| 20 |
+
calling application should \fBselect(2)\fP on for reading and writing for the
|
| 21 |
+
processing of name service queries pending on the name service channel
|
| 22 |
+
identified by \fIchannel\fP. Should not be used with \fBARES_OPT_EVENT_THREAD\fP
|
| 23 |
+
is passed to \fIares_init_options(3)\fP.
|
| 24 |
+
|
| 25 |
+
File descriptors will be set in the file descriptor sets pointed to by
|
| 26 |
+
\fIread_fds\fP and \fIwrite_fds\fP as appropriate. File descriptors already
|
| 27 |
+
set in \fIread_fds\fP and \fIwrite_fds\fP will remain set; initialization of
|
| 28 |
+
the file descriptor sets (using \fBFD_ZERO\fP) is the responsibility of the
|
| 29 |
+
caller.
|
| 30 |
+
.SH RETURN VALUES
|
| 31 |
+
\fBares_fds(3)\fP returns a value that is one greater than the number of the
|
| 32 |
+
highest socket set in either \fIread_fds\fP or \fIwrite_fds\fP. If no queries
|
| 33 |
+
are active, \fBares_fds(3)\fP returns 0.
|
| 34 |
+
|
| 35 |
+
.SH NOTES
|
| 36 |
+
The \fBselect(2)\fP call which takes the \fIfd_set\fP parameter has significant
|
| 37 |
+
limitations which can impact modern systems. The limitations can vary from
|
| 38 |
+
system to system, but in general if the file descriptor value itself is greater
|
| 39 |
+
than 1024 (not the count but the actual value), this can lead to
|
| 40 |
+
\fBares_fds(3)\fP writing out of bounds which will cause a system crash. In
|
| 41 |
+
modern networking clients, it is not unusual to have file descriptor values
|
| 42 |
+
above 1024, especially when a library is pulled in as a dependency into a larger
|
| 43 |
+
project.
|
| 44 |
+
|
| 45 |
+
c-ares does not attempt to detect this condition to prevent crashes due to both
|
| 46 |
+
implementation-defined behavior in the OS as well as integrator-controllable
|
| 47 |
+
tunables which may impact the limits.
|
| 48 |
+
|
| 49 |
+
It is recommended to use \fBARES_OPT_EVENT_THREAD\fP passed to
|
| 50 |
+
\fIares_init_options(3)\fP, or socket state callbacks
|
| 51 |
+
(\fBARES_OPT_SOCK_STATE_CB\fP) registered via \fIares_init_options(3)\fP and use
|
| 52 |
+
more modern methods to check for socket readable/writable state such as
|
| 53 |
+
\fIpoll(2)\fP, \fIepoll(2)\fP, or \fIkqueue(2)\fP.
|
| 54 |
+
.SH SEE ALSO
|
| 55 |
+
.BR ares_init_options (3),
|
| 56 |
+
.BR ares_timeout (3),
|
| 57 |
+
.BR ares_process (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_free_data.3
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" Copyright (C) 2004-2010 by Daniel Stenberg
|
| 4 |
+
.\" SPDX-License-Identifier: MIT
|
| 5 |
+
.\"
|
| 6 |
+
.TH ARES_FREE_DATA 3 "5 March 2010"
|
| 7 |
+
.SH NAME
|
| 8 |
+
ares_free_data \- Free data allocated by several c-ares functions
|
| 9 |
+
.SH SYNOPSIS
|
| 10 |
+
.nf
|
| 11 |
+
#include <ares.h>
|
| 12 |
+
|
| 13 |
+
void ares_free_data(void *\fIdataptr\fP)
|
| 14 |
+
.fi
|
| 15 |
+
.SH DESCRIPTION
|
| 16 |
+
.PP
|
| 17 |
+
The \fBares_free_data(3)\fP function frees one or more data structures
|
| 18 |
+
allocated and returned by several c-ares functions. Specifically the data
|
| 19 |
+
returned by the following list of functions must be deallocated using this
|
| 20 |
+
function.
|
| 21 |
+
.TP 5
|
| 22 |
+
.B ares_get_servers(3)
|
| 23 |
+
When used to free the data returned by \fIares_get_servers(3)\fP this will
|
| 24 |
+
free the whole linked list of ares_addr_node structures returned by
|
| 25 |
+
\fIares_get_servers(3)\fP.
|
| 26 |
+
.TP
|
| 27 |
+
.B ares_parse_srv_reply(3)
|
| 28 |
+
When used to free the data returned by \fIares_parse_srv_reply(3)\fP this will
|
| 29 |
+
free the whole linked list of ares_srv_reply structures returned by
|
| 30 |
+
\fIares_parse_srv_reply(3)\fP, along with any additional storage associated
|
| 31 |
+
with those structures.
|
| 32 |
+
.TP
|
| 33 |
+
.B ares_parse_mx_reply(3)
|
| 34 |
+
When used to free the data returned by \fIares_parse_mx_reply(3)\fP this will
|
| 35 |
+
free the whole linked list of ares_mx_reply structures returned by
|
| 36 |
+
\fIares_parse_mx_reply(3)\fP, along with any additional storage associated
|
| 37 |
+
with those structures.
|
| 38 |
+
.TP
|
| 39 |
+
.B ares_parse_txt_reply(3)
|
| 40 |
+
When used to free the data returned by \fIares_parse_txt_reply(3)\fP this will
|
| 41 |
+
free the whole linked list of ares_txt_reply structures returned by
|
| 42 |
+
\fIares_parse_txt_reply(3)\fP, along with any additional storage associated
|
| 43 |
+
with those structures.
|
| 44 |
+
.TP
|
| 45 |
+
.B ares_parse_soa_reply(3)
|
| 46 |
+
When used to free the data returned by \fIares_parse_soa_reply(3)\fP this will
|
| 47 |
+
free the ares_soa_reply structure, along with any additional storage
|
| 48 |
+
associated with those structure.
|
| 49 |
+
.B ares_parse_uri_reply(3)
|
| 50 |
+
When used to free the data returned by \fIares_parse_uri_reply(3)\fP this will
|
| 51 |
+
free list of ares_uri_reply structures, along with any additional storage
|
| 52 |
+
associated with those structure.
|
| 53 |
+
.SH RETURN VALUE
|
| 54 |
+
The \fIares_free_data(3)\fP function does not return a value.
|
| 55 |
+
.SH AVAILABILITY
|
| 56 |
+
This function was first introduced in c-ares version 1.7.0.
|
| 57 |
+
.SH SEE ALSO
|
| 58 |
+
.BR ares_get_servers (3),
|
| 59 |
+
.BR ares_parse_srv_reply (3),
|
| 60 |
+
.BR ares_parse_mx_reply (3),
|
| 61 |
+
.BR ares_parse_txt_reply (3),
|
| 62 |
+
.BR ares_parse_soa_reply (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_free_hostent.3
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_FREE_HOSTENT 3 "23 July 1998"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_free_hostent \- Free host structure allocated by ares functions
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
void ares_free_hostent(struct hostent *\fIhost\fP)
|
| 13 |
+
.fi
|
| 14 |
+
.SH DESCRIPTION
|
| 15 |
+
The
|
| 16 |
+
.I ares_free_hostent
|
| 17 |
+
function frees a
|
| 18 |
+
.B struct hostent
|
| 19 |
+
allocated by one of the functions \fIares_parse_a_reply(3)\fP,
|
| 20 |
+
\fIares_parse_aaaa_reply(3)\fP, or \fIares_parse_ptr_reply(3)\fP.
|
| 21 |
+
.SH NOTES
|
| 22 |
+
It is not necessary (and is not correct) to free the host structure passed to
|
| 23 |
+
the callback functions for \fIares_gethostbyname(3)\fP or
|
| 24 |
+
\fIares_gethostbyaddr(3)\fP. c-ares will automatically free such host
|
| 25 |
+
structures when the callback returns.
|
| 26 |
+
.SH SEE ALSO
|
| 27 |
+
.BR ares_parse_a_reply (3),
|
| 28 |
+
.BR ares_parse_aaaa_reply (3),
|
| 29 |
+
.BR ares_parse_ptr_reply (3),
|
| 30 |
+
.BR ares_parse_ns_reply (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_free_string.3
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 2000 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_FREE_STRING 3 "4 February 2004"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_free_string \- Free strings allocated by ares functions
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
void ares_free_string(void *\fIstr\fP)
|
| 13 |
+
.fi
|
| 14 |
+
.SH DESCRIPTION
|
| 15 |
+
The \fIares_free_string(3)\fP function frees a string allocated by an ares
|
| 16 |
+
function.
|
| 17 |
+
.SH SEE ALSO
|
| 18 |
+
.BR ares_mkquery (3)
|
| 19 |
+
.BR ares_expand_string (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_freeaddrinfo.3
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_FREEADDRINFO 3 "31 October 2018"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_freeaddrinfo \- Free addrinfo structure allocated by ares functions
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
void ares_freeaddrinfo(struct ares_addrinfo *\fIai\fP)
|
| 13 |
+
.fi
|
| 14 |
+
.SH DESCRIPTION
|
| 15 |
+
The
|
| 16 |
+
.B ares_freeaddrinfo
|
| 17 |
+
function frees a
|
| 18 |
+
.B struct ares_addrinfo
|
| 19 |
+
returned in \fIresult\fP of
|
| 20 |
+
.B ares_addrinfo_callback
|
| 21 |
+
.SH SEE ALSO
|
| 22 |
+
.BR ares_getaddrinfo (3),
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_get_servers.3
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" Copyright (C) 2008-2010 by Daniel Stenberg
|
| 4 |
+
.\" SPDX-License-Identifier: MIT
|
| 5 |
+
.\"
|
| 6 |
+
.TH ARES_GET_SERVERS 3 "5 March 2010"
|
| 7 |
+
.SH NAME
|
| 8 |
+
ares_get_servers, ares_get_servers_ports \- Retrieve name servers from an initialized ares_channel (deprecated)
|
| 9 |
+
.SH SYNOPSIS
|
| 10 |
+
.nf
|
| 11 |
+
#include <ares.h>
|
| 12 |
+
|
| 13 |
+
int ares_get_servers(const ares_channel_t *\fIchannel\fP,
|
| 14 |
+
struct ares_addr_node **\fIservers\fP)
|
| 15 |
+
|
| 16 |
+
int ares_get_servers_ports(const ares_channel_t *\fIchannel\fP,
|
| 17 |
+
struct ares_addr_port_node **\fIservers\fP)
|
| 18 |
+
.fi
|
| 19 |
+
.SH DESCRIPTION
|
| 20 |
+
The \fBares_get_servers(3)\fP function retrieves name servers configuration
|
| 21 |
+
from the
|
| 22 |
+
channel data identified by
|
| 23 |
+
.IR channel ,
|
| 24 |
+
as a linked list of ares_addr_node structs storing a pointer to the first
|
| 25 |
+
node at the address specified by
|
| 26 |
+
.IR servers .
|
| 27 |
+
|
| 28 |
+
The \fBares_get_servers_ports(3)\fP function also retrieves any per-server
|
| 29 |
+
port information that may have been previously configured, returning a linked
|
| 30 |
+
list of ares_addr_port structures.
|
| 31 |
+
|
| 32 |
+
Function caller may traverse the returned name server linked list, or may use
|
| 33 |
+
it directly as suitable input for the \fBares_set_servers(3)\fP /
|
| 34 |
+
\fBares_set_servers_ports(3)\fP functions, but
|
| 35 |
+
shall not shrink or extend the list on its own.
|
| 36 |
+
|
| 37 |
+
Each node of the name server linked list is stored in memory dynamically
|
| 38 |
+
allocated and managed by c-ares. It is the caller's responsibility to free
|
| 39 |
+
the resulting linked list, using \fBares_free_data(3)\fP , once the caller
|
| 40 |
+
does not need it any longer.
|
| 41 |
+
|
| 42 |
+
This function is capable of handling IPv4 and IPv6 name server
|
| 43 |
+
addresses simultaneously, rendering \fBares_save_options(3)\fP with
|
| 44 |
+
optmask \fBARES_OPT_SERVERS\fP functionally obsolete except for
|
| 45 |
+
IPv4-only name server usage.
|
| 46 |
+
|
| 47 |
+
.SH RETURN VALUES
|
| 48 |
+
This function may return any of the following values:
|
| 49 |
+
.TP 15
|
| 50 |
+
.B ARES_SUCCESS
|
| 51 |
+
The name servers configuration was successfully retrieved
|
| 52 |
+
.TP 15
|
| 53 |
+
.B ARES_ENOMEM
|
| 54 |
+
The memory was exhausted
|
| 55 |
+
.TP 15
|
| 56 |
+
.B ARES_ENODATA
|
| 57 |
+
The channel data identified by
|
| 58 |
+
.IR channel
|
| 59 |
+
was invalid.
|
| 60 |
+
.SH SEE ALSO
|
| 61 |
+
.BR ares_set_servers (3),
|
| 62 |
+
.BR ares_init_options (3),
|
| 63 |
+
.BR ares_save_options(3)
|
| 64 |
+
.SH AVAILABILITY
|
| 65 |
+
\fBares_get_servers(3)\fP was added in c-ares 1.7.1;
|
| 66 |
+
\fBares_get_servers_ports(3)\fP was added in c-ares 1.11.0.
|
| 67 |
+
.SH NOTES
|
| 68 |
+
As of c-ares 1.24, these functions are deprecated due to their lack of ability
|
| 69 |
+
to store the entire server configuration. Use \fBares_get_servers_csv(3)\fP.
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_get_servers_csv.3
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright (C) Daniel Stenberg
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.so man3/ares_set_servers_csv.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_get_servers_ports.3
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright (C) Daniel Stenberg
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.so man3/ares_get_servers.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_getaddrinfo.3
ADDED
|
@@ -0,0 +1,194 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_GETADDRINFO 3 "4 November 2018"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_getaddrinfo \- Initiate a host query by name and service
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
typedef void (*ares_addrinfo_callback)(void *\fIarg\fP, int \fIstatus\fP,
|
| 13 |
+
int \fItimeouts\fP,
|
| 14 |
+
struct ares_addrinfo *\fIresult\fP)
|
| 15 |
+
|
| 16 |
+
void ares_getaddrinfo(ares_channel_t *\fIchannel\fP, const char *\fIname\fP,
|
| 17 |
+
const char* \fIservice\fP,
|
| 18 |
+
const struct ares_addrinfo_hints *\fIhints\fP,
|
| 19 |
+
ares_addrinfo_callback \fIcallback\fP, void *\fIarg\fP)
|
| 20 |
+
.fi
|
| 21 |
+
.SH DESCRIPTION
|
| 22 |
+
The \fBares_getaddrinfo(3)\fP function initiates a host query by name on the
|
| 23 |
+
name service channel identified by
|
| 24 |
+
.IR channel .
|
| 25 |
+
The
|
| 26 |
+
.I name
|
| 27 |
+
and
|
| 28 |
+
.I service
|
| 29 |
+
parameters give the hostname and service as NULL-terminated C strings.
|
| 30 |
+
The
|
| 31 |
+
.I hints
|
| 32 |
+
parameter is an
|
| 33 |
+
.BR ares_addrinfo_hints
|
| 34 |
+
structure:
|
| 35 |
+
.PP
|
| 36 |
+
.RS
|
| 37 |
+
.EX
|
| 38 |
+
struct ares_addrinfo_hints {
|
| 39 |
+
int ai_flags;
|
| 40 |
+
int ai_family;
|
| 41 |
+
int ai_socktype;
|
| 42 |
+
int ai_protocol;
|
| 43 |
+
};
|
| 44 |
+
.EE
|
| 45 |
+
.RE
|
| 46 |
+
.TP
|
| 47 |
+
.I ai_family
|
| 48 |
+
Specifies desired address family. AF_UNSPEC means return both AF_INET and AF_INET6.
|
| 49 |
+
.TP
|
| 50 |
+
.I ai_socktype
|
| 51 |
+
Specifies desired socket type, for example SOCK_STREAM or SOCK_DGRAM.
|
| 52 |
+
Setting this to 0 means any type.
|
| 53 |
+
.TP
|
| 54 |
+
.I ai_protocol
|
| 55 |
+
Setting this to 0 means any protocol.
|
| 56 |
+
.TP
|
| 57 |
+
.I ai_flags
|
| 58 |
+
Specifies additional options, see below.
|
| 59 |
+
.PP
|
| 60 |
+
.TP 19
|
| 61 |
+
.B ARES_AI_NUMERICSERV
|
| 62 |
+
If this option is set
|
| 63 |
+
.I service
|
| 64 |
+
field will be treated as a numeric value.
|
| 65 |
+
.TP 19
|
| 66 |
+
.B ARES_AI_CANONNAME
|
| 67 |
+
The ares_addrinfo structure will return a canonical names list.
|
| 68 |
+
.TP 19
|
| 69 |
+
.B ARES_AI_NOSORT
|
| 70 |
+
Result addresses will not be sorted and no connections to resolved addresses will be attempted.
|
| 71 |
+
.TP 19
|
| 72 |
+
.B ARES_AI_ENVHOSTS
|
| 73 |
+
Read hosts file path from the environment variable
|
| 74 |
+
.I CARES_HOSTS .
|
| 75 |
+
.PP
|
| 76 |
+
When the query is complete or has failed, the ares library will invoke \fIcallback\fP.
|
| 77 |
+
Completion or failure of the query may happen immediately, or may happen
|
| 78 |
+
during a later call to \fIares_process(3)\fP, \fIares_destroy(3)\fP or
|
| 79 |
+
\fIares_cancel(3)\fP.
|
| 80 |
+
.PP
|
| 81 |
+
When the associated callback is called, it is called with a channel lock so care
|
| 82 |
+
must be taken to ensure any processing is minimal to prevent DNS channel stalls.
|
| 83 |
+
|
| 84 |
+
The callback may be triggered from a different thread than the one which
|
| 85 |
+
called \fIares_getaddrinfo(3)\fP.
|
| 86 |
+
|
| 87 |
+
For integrators running their own event loops and not using \fBARES_OPT_EVENT_THREAD\fP,
|
| 88 |
+
care needs to be taken to ensure any file descriptor lists are updated immediately
|
| 89 |
+
within the eventloop when notified.
|
| 90 |
+
.PP
|
| 91 |
+
The callback argument
|
| 92 |
+
.I arg
|
| 93 |
+
is copied from the \fBares_getaddrinfo(3)\fP argument
|
| 94 |
+
.IR arg .
|
| 95 |
+
The callback argument
|
| 96 |
+
.I status
|
| 97 |
+
indicates whether the query succeeded and, if not, how it failed. It
|
| 98 |
+
may have any of the following values:
|
| 99 |
+
.TP 19
|
| 100 |
+
.B ARES_SUCCESS
|
| 101 |
+
The host lookup completed successfully.
|
| 102 |
+
.TP 19
|
| 103 |
+
.B ARES_ENOTIMP
|
| 104 |
+
The ares library does not know how to find addresses of type
|
| 105 |
+
.IR family .
|
| 106 |
+
.TP 19
|
| 107 |
+
.B ARES_ENOTFOUND
|
| 108 |
+
The
|
| 109 |
+
.I name
|
| 110 |
+
was not found.
|
| 111 |
+
.TP 19
|
| 112 |
+
.B ARES_ENOMEM
|
| 113 |
+
Memory was exhausted.
|
| 114 |
+
.TP 19
|
| 115 |
+
.B ARES_ESERVICE
|
| 116 |
+
The textual service name provided could not be dereferenced into a port.
|
| 117 |
+
.TP 19
|
| 118 |
+
.B ARES_ECANCELLED
|
| 119 |
+
The query was cancelled.
|
| 120 |
+
.TP 19
|
| 121 |
+
.B ARES_EDESTRUCTION
|
| 122 |
+
The name service channel
|
| 123 |
+
.I channel
|
| 124 |
+
is being destroyed; the query will not be completed.
|
| 125 |
+
.PP
|
| 126 |
+
On successful completion of the query, the callback argument
|
| 127 |
+
.I result
|
| 128 |
+
points to a
|
| 129 |
+
.B struct ares_addrinfo
|
| 130 |
+
which contains two linked lists, one with resolved addresses and another with canonical names.
|
| 131 |
+
Also included is the official name of the host (analogous to gethostbyname() h_name).
|
| 132 |
+
.PP
|
| 133 |
+
.RS
|
| 134 |
+
.EX
|
| 135 |
+
struct ares_addrinfo {
|
| 136 |
+
struct ares_addrinfo_cname *cnames;
|
| 137 |
+
struct ares_addrinfo_node *nodes;
|
| 138 |
+
char *name;
|
| 139 |
+
};
|
| 140 |
+
.EE
|
| 141 |
+
.RE
|
| 142 |
+
.PP
|
| 143 |
+
.I ares_addrinfo_node
|
| 144 |
+
structure is similar to RFC3493 addrinfo, but without canonname and with extra ttl field.
|
| 145 |
+
.RS
|
| 146 |
+
.PP
|
| 147 |
+
.EX
|
| 148 |
+
struct ares_addrinfo_node {
|
| 149 |
+
int ai_ttl;
|
| 150 |
+
int ai_flags;
|
| 151 |
+
int ai_family;
|
| 152 |
+
int ai_socktype;
|
| 153 |
+
int ai_protocol;
|
| 154 |
+
ares_socklen_t ai_addrlen;
|
| 155 |
+
struct sockaddr *ai_addr;
|
| 156 |
+
struct ares_addrinfo_node *ai_next;
|
| 157 |
+
};
|
| 158 |
+
.EE
|
| 159 |
+
.RE
|
| 160 |
+
.PP
|
| 161 |
+
.I ares_addrinfo_cname
|
| 162 |
+
structure is a linked list of CNAME records where
|
| 163 |
+
.I ttl
|
| 164 |
+
is a time to live
|
| 165 |
+
.I alias
|
| 166 |
+
is a label of the resource record and
|
| 167 |
+
.I name
|
| 168 |
+
is a value (canonical name) of the resource record.
|
| 169 |
+
See RFC2181 10.1.1. CNAME terminology.
|
| 170 |
+
.RS
|
| 171 |
+
.PP
|
| 172 |
+
.EX
|
| 173 |
+
struct ares_addrinfo_cname {
|
| 174 |
+
int ttl;
|
| 175 |
+
char *alias;
|
| 176 |
+
char *name;
|
| 177 |
+
struct ares_addrinfo_cname *next;
|
| 178 |
+
};
|
| 179 |
+
.EE
|
| 180 |
+
.RE
|
| 181 |
+
.PP
|
| 182 |
+
The reserved memory has to be deleted by \fBares_freeaddrinfo(3)\fP.
|
| 183 |
+
|
| 184 |
+
The result is sorted according to RFC6724 except:
|
| 185 |
+
- Rule 3 (Avoid deprecated addresses)
|
| 186 |
+
- Rule 4 (Prefer home addresses)
|
| 187 |
+
- Rule 7 (Prefer native transport)
|
| 188 |
+
|
| 189 |
+
Please note that the function will attempt a connection
|
| 190 |
+
on each of the resolved addresses as per RFC6724.
|
| 191 |
+
.SH AVAILABILITY
|
| 192 |
+
This function was added in c-ares 1.16.0, released in March 2020.
|
| 193 |
+
.SH SEE ALSO
|
| 194 |
+
.BR ares_freeaddrinfo (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_gethostbyaddr.3
ADDED
|
@@ -0,0 +1,100 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_GETHOSTBYADDR 3 "24 July 1998"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_gethostbyaddr \- Initiate a host query by address
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
typedef void (*ares_host_callback)(void *\fIarg\fP, int \fIstatus\fP,
|
| 13 |
+
int \fItimeouts\fP,
|
| 14 |
+
struct hostent *\fIhostent\fP)
|
| 15 |
+
|
| 16 |
+
void ares_gethostbyaddr(ares_channel_t *\fIchannel\fP, const void *\fIaddr\fP,
|
| 17 |
+
int \fIaddrlen\fP, int \fIfamily\fP,
|
| 18 |
+
ares_host_callback \fIcallback\fP, void *\fIarg\fP)
|
| 19 |
+
.fi
|
| 20 |
+
.SH DESCRIPTION
|
| 21 |
+
The
|
| 22 |
+
.B ares_gethostbyaddr
|
| 23 |
+
function initiates a host query by address on the name service channel
|
| 24 |
+
identified by
|
| 25 |
+
.IR channel .
|
| 26 |
+
The parameters
|
| 27 |
+
.I addr
|
| 28 |
+
and
|
| 29 |
+
.I addrlen
|
| 30 |
+
give the address as a series of bytes, and
|
| 31 |
+
.I family
|
| 32 |
+
gives the type of address. When the query is complete or has failed, the ares
|
| 33 |
+
library will invoke \fIcallback\fP. Completion or failure of the query may
|
| 34 |
+
happen immediately, or may happen during a later call to
|
| 35 |
+
\fIares_process(3)\fP, \fIares_destroy(3)\fP or \fIares_cancel(3)\fP.
|
| 36 |
+
.PP
|
| 37 |
+
The callback argument
|
| 38 |
+
.I arg
|
| 39 |
+
is copied from the
|
| 40 |
+
.B ares_gethostbyaddr
|
| 41 |
+
argument
|
| 42 |
+
.IR arg .
|
| 43 |
+
The callback argument
|
| 44 |
+
.I status
|
| 45 |
+
indicates whether the query succeeded and, if not, how it failed. It
|
| 46 |
+
may have any of the following values:
|
| 47 |
+
.TP 19
|
| 48 |
+
.B ARES_SUCCESS
|
| 49 |
+
The host lookup completed successfully.
|
| 50 |
+
.TP 19
|
| 51 |
+
.B ARES_ENOTIMP
|
| 52 |
+
The ares library does not know how to look up addresses of type
|
| 53 |
+
.IR family .
|
| 54 |
+
.TP 19
|
| 55 |
+
.B ARES_ENOTFOUND
|
| 56 |
+
The address
|
| 57 |
+
.I addr
|
| 58 |
+
was not found.
|
| 59 |
+
.TP 19
|
| 60 |
+
.B ARES_ENOMEM
|
| 61 |
+
Memory was exhausted.
|
| 62 |
+
.TP 19
|
| 63 |
+
.B ARES_ECANCELLED
|
| 64 |
+
The query was cancelled.
|
| 65 |
+
.TP 19
|
| 66 |
+
.B ARES_EDESTRUCTION
|
| 67 |
+
The name service channel
|
| 68 |
+
.I channel
|
| 69 |
+
is being destroyed; the query will not be completed.
|
| 70 |
+
.PP
|
| 71 |
+
The callback argument
|
| 72 |
+
.I timeouts
|
| 73 |
+
reports how many times a query timed out during the execution of the
|
| 74 |
+
given request.
|
| 75 |
+
.PP
|
| 76 |
+
On successful completion of the query, the callback argument
|
| 77 |
+
.I hostent
|
| 78 |
+
points to a
|
| 79 |
+
.B struct hostent
|
| 80 |
+
containing the name of the host returned by the query. The callback
|
| 81 |
+
need not and should not attempt to free the memory pointed to by
|
| 82 |
+
.IR hostent ;
|
| 83 |
+
the ares library will free it when the callback returns. If the query
|
| 84 |
+
did not complete successfully,
|
| 85 |
+
.I hostent
|
| 86 |
+
will be
|
| 87 |
+
.BR NULL .
|
| 88 |
+
.PP
|
| 89 |
+
When the associated callback is called, it is called with a channel lock so care
|
| 90 |
+
must be taken to ensure any processing is minimal to prevent DNS channel stalls.
|
| 91 |
+
|
| 92 |
+
The callback may be triggered from a different thread than the one which
|
| 93 |
+
called \fIares_gethostbyaddr(3)\fP.
|
| 94 |
+
|
| 95 |
+
For integrators running their own event loops and not using \fBARES_OPT_EVENT_THREAD\fP,
|
| 96 |
+
care needs to be taken to ensure any file descriptor lists are updated immediately
|
| 97 |
+
within the eventloop when notified.
|
| 98 |
+
.SH SEE ALSO
|
| 99 |
+
.BR ares_process (3),
|
| 100 |
+
.BR ares_gethostbyname (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_gethostbyname.3
ADDED
|
@@ -0,0 +1,108 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_GETHOSTBYNAME 3 "25 July 1998"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_gethostbyname \- Initiate a host query by name
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
typedef void (*ares_host_callback)(void *\fIarg\fP, int \fIstatus\fP,
|
| 13 |
+
int \fItimeouts\fP,
|
| 14 |
+
struct hostent *\fIhostent\fP)
|
| 15 |
+
|
| 16 |
+
void ares_gethostbyname(ares_channel_t *\fIchannel\fP, const char *\fIname\fP,
|
| 17 |
+
int \fIfamily\fP, ares_host_callback \fIcallback\fP,
|
| 18 |
+
void *\fIarg\fP)
|
| 19 |
+
.fi
|
| 20 |
+
.SH DESCRIPTION
|
| 21 |
+
The
|
| 22 |
+
.B ares_gethostbyname
|
| 23 |
+
function initiates a host query by name on the name service channel
|
| 24 |
+
identified by
|
| 25 |
+
.IR channel .
|
| 26 |
+
The parameter
|
| 27 |
+
.I name
|
| 28 |
+
gives the hostname as a NUL-terminated C string, and
|
| 29 |
+
.I family
|
| 30 |
+
gives the desired type of address for the resulting host entry. When the
|
| 31 |
+
query is complete or has failed, the ares library will invoke \fIcallback\fP.
|
| 32 |
+
Completion or failure of the query may happen immediately, or may happen
|
| 33 |
+
during a later call to \fIares_process(3)\fP, \fIares_destroy(3)\fP or
|
| 34 |
+
\fIares_cancel(3)\fP.
|
| 35 |
+
.PP
|
| 36 |
+
The callback argument
|
| 37 |
+
.I arg
|
| 38 |
+
is copied from the
|
| 39 |
+
.B ares_gethostbyname
|
| 40 |
+
argument
|
| 41 |
+
.IR arg .
|
| 42 |
+
The callback argument
|
| 43 |
+
.I status
|
| 44 |
+
indicates whether the query succeeded and, if not, how it failed. It
|
| 45 |
+
may have any of the following values:
|
| 46 |
+
.TP 19
|
| 47 |
+
.B ARES_SUCCESS
|
| 48 |
+
The host lookup completed successfully.
|
| 49 |
+
.TP 19
|
| 50 |
+
.B ARES_ENOTIMP
|
| 51 |
+
The ares library does not know how to find addresses of type
|
| 52 |
+
.IR family .
|
| 53 |
+
.TP 19
|
| 54 |
+
.B ARES_EBADNAME
|
| 55 |
+
The hostname
|
| 56 |
+
.B name
|
| 57 |
+
is composed entirely of numbers and periods, but is not a valid
|
| 58 |
+
representation of an Internet address.
|
| 59 |
+
.TP 19
|
| 60 |
+
.B ARES_ENODATA
|
| 61 |
+
There was no data returned to extract a result from.
|
| 62 |
+
.TP 19
|
| 63 |
+
.B ARES_ENOTFOUND
|
| 64 |
+
The name
|
| 65 |
+
.I name
|
| 66 |
+
was not found.
|
| 67 |
+
.TP 19
|
| 68 |
+
.B ARES_ENOMEM
|
| 69 |
+
Memory was exhausted.
|
| 70 |
+
.TP 19
|
| 71 |
+
.B ARES_ECANCELLED
|
| 72 |
+
The query was cancelled.
|
| 73 |
+
.TP 19
|
| 74 |
+
.B ARES_EDESTRUCTION
|
| 75 |
+
The name service channel
|
| 76 |
+
.I channel
|
| 77 |
+
is being destroyed; the query will not be completed.
|
| 78 |
+
.PP
|
| 79 |
+
The callback argument
|
| 80 |
+
.I timeouts
|
| 81 |
+
reports how many times a query timed out during the execution of the
|
| 82 |
+
given request.
|
| 83 |
+
.PP
|
| 84 |
+
On successful completion of the query, the callback argument
|
| 85 |
+
.I hostent
|
| 86 |
+
points to a
|
| 87 |
+
.B struct hostent
|
| 88 |
+
containing the name of the host returned by the query. The callback
|
| 89 |
+
need not and should not attempt to free the memory pointed to by
|
| 90 |
+
.IR hostent ;
|
| 91 |
+
the ares library will free it when the callback returns. If the query
|
| 92 |
+
did not complete successfully,
|
| 93 |
+
.I hostent
|
| 94 |
+
will be
|
| 95 |
+
.BR NULL .
|
| 96 |
+
.PP
|
| 97 |
+
When the associated callback is called, it is called with a channel lock so care
|
| 98 |
+
must be taken to ensure any processing is minimal to prevent DNS channel stalls.
|
| 99 |
+
|
| 100 |
+
The callback may be triggered from a different thread than the one which
|
| 101 |
+
called \fIares_gethostbyname(3)\fP.
|
| 102 |
+
|
| 103 |
+
For integrators running their own event loops and not using \fBARES_OPT_EVENT_THREAD\fP,
|
| 104 |
+
care needs to be taken to ensure any file descriptor lists are updated immediately
|
| 105 |
+
within the eventloop when notified.
|
| 106 |
+
.SH SEE ALSO
|
| 107 |
+
.BR ares_process (3),
|
| 108 |
+
.BR ares_gethostbyaddr (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_gethostbyname_file.3
ADDED
|
@@ -0,0 +1,68 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_GETHOSTBYNAME 3 "25 July 1998"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_gethostbyname_file \- Lookup a name in the system's hosts file
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
int ares_gethostbyname_file(ares_channel_t *\fIchannel\fP, const char *\fIname\fP,
|
| 13 |
+
int \fIfamily\fP, struct hostent **host)
|
| 14 |
+
.fi
|
| 15 |
+
.SH DESCRIPTION
|
| 16 |
+
The
|
| 17 |
+
.B ares_gethostbyname_file
|
| 18 |
+
function performs a host lookup by name against the system's hosts file (or equivalent local hostname database).
|
| 19 |
+
The
|
| 20 |
+
.IR channel
|
| 21 |
+
parameter is required, but no asynchronous queries are performed. Instead, the
|
| 22 |
+
lookup is done via the same mechanism used to perform 'f' lookups
|
| 23 |
+
(see the
|
| 24 |
+
.I lookups
|
| 25 |
+
options field in \fIares_init_options(3)\fP).
|
| 26 |
+
The parameter
|
| 27 |
+
.I name
|
| 28 |
+
gives the hostname as a NUL-terminated C string, and
|
| 29 |
+
.I family
|
| 30 |
+
gives the desired type of address for the resulting host entry.
|
| 31 |
+
.PP
|
| 32 |
+
The return value indicates whether the query succeeded and, if not, how it
|
| 33 |
+
failed. It may have any of the following values:
|
| 34 |
+
.TP 19
|
| 35 |
+
.B ARES_SUCCESS
|
| 36 |
+
The host lookup completed successfully and
|
| 37 |
+
.I host
|
| 38 |
+
now points to the result (and must be freed with \fIares_free_hostent(3)\fP).
|
| 39 |
+
.TP 19
|
| 40 |
+
.B ARES_ENOTFOUND
|
| 41 |
+
The hostname
|
| 42 |
+
.I name
|
| 43 |
+
was not found.
|
| 44 |
+
.TP 19
|
| 45 |
+
.B ARES_EFILE
|
| 46 |
+
There was a file I/O error while performing the lookup.
|
| 47 |
+
.TP 19
|
| 48 |
+
.B ARES_ENOMEM
|
| 49 |
+
Memory was exhausted.
|
| 50 |
+
.PP
|
| 51 |
+
On successful completion of the query, the pointer pointed to by
|
| 52 |
+
.I host
|
| 53 |
+
points to a
|
| 54 |
+
.B struct hostent
|
| 55 |
+
containing the address of the host returned by the lookup. The user must
|
| 56 |
+
free the memory pointed to by
|
| 57 |
+
.IR host
|
| 58 |
+
when finished with it by calling \fIares_free_hostent(3)\fP. If the lookup did
|
| 59 |
+
not complete successfully,
|
| 60 |
+
.I host
|
| 61 |
+
will be
|
| 62 |
+
.BR NULL .
|
| 63 |
+
.SH AVAILABILITY
|
| 64 |
+
Added in c-ares 1.5.4
|
| 65 |
+
.SH SEE ALSO
|
| 66 |
+
.BR ares_gethostbyname (3),
|
| 67 |
+
.BR ares_free_hostent (3),
|
| 68 |
+
.BR ares_init_options (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_getnameinfo.3
ADDED
|
@@ -0,0 +1,147 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 2005 by Dominick Meglio.
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_GETNAMEINFO 3 "1 May 2009"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_getnameinfo \- Address-to-nodename translation in protocol-independent manner
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
typedef void (*ares_nameinfo_callback)(void *\fIarg\fP, int \fIstatus\fP,
|
| 13 |
+
int \fItimeouts\fP, char *\fInode\fP,
|
| 14 |
+
char *\fIservice\fP)
|
| 15 |
+
|
| 16 |
+
void ares_getnameinfo(ares_channel_t *\fIchannel\fP, const struct sockaddr *\fIsa\fP,
|
| 17 |
+
ares_socklen_t \fIsalen\fP, int \fIflags\fP,
|
| 18 |
+
ares_nameinfo_callback \fIcallback\fP, void *\fIarg\fP)
|
| 19 |
+
.fi
|
| 20 |
+
.SH DESCRIPTION
|
| 21 |
+
The
|
| 22 |
+
.B ares_getnameinfo
|
| 23 |
+
function is defined for protocol-independent address translation. The function
|
| 24 |
+
is a combination of \fIares_gethostbyaddr(3)\fP and \fIgetservbyport(3)\fP. The function will
|
| 25 |
+
translate the address either by executing a host query on the name service channel
|
| 26 |
+
identified by
|
| 27 |
+
.IR channel
|
| 28 |
+
or it will attempt to resolve it locally if possible.
|
| 29 |
+
The parameters
|
| 30 |
+
.I sa
|
| 31 |
+
and
|
| 32 |
+
.I len
|
| 33 |
+
give the address as a sockaddr structure, and
|
| 34 |
+
.I flags
|
| 35 |
+
gives the options that the function will use. Valid flags are listed below:
|
| 36 |
+
.TP 19
|
| 37 |
+
.B ARES_NI_NOFQDN
|
| 38 |
+
Only the nodename portion of the FQDN is returned for local hosts.
|
| 39 |
+
.TP 19
|
| 40 |
+
.B ARES_NI_NUMERICHOST
|
| 41 |
+
The numeric form of the hostname is returned rather than the name.
|
| 42 |
+
.TP 19
|
| 43 |
+
.B ARES_NI_NAMEREQD
|
| 44 |
+
An error is returned if the hostname cannot be found in the DNS.
|
| 45 |
+
.TP 19
|
| 46 |
+
.B ARES_NI_NUMERICSERV
|
| 47 |
+
The numeric form of the service is returned rather than the name.
|
| 48 |
+
.TP 19
|
| 49 |
+
.B ARES_NI_TCP
|
| 50 |
+
The service name is to be looked up for the TCP protocol.
|
| 51 |
+
.TP 19
|
| 52 |
+
.B ARES_NI_UDP
|
| 53 |
+
The service name is to be looked up for the UDP protocol.
|
| 54 |
+
.TP 19
|
| 55 |
+
.B ARES_NI_SCTP
|
| 56 |
+
The service name is to be looked up for the SCTP protocol.
|
| 57 |
+
.TP 19
|
| 58 |
+
.B ARES_NI_DCCP
|
| 59 |
+
The service name is to be looked up for the DCCP protocol.
|
| 60 |
+
.TP 19
|
| 61 |
+
.B ARES_NI_NUMERICSCOPE
|
| 62 |
+
The numeric form of the scope ID is returned rather than the name.
|
| 63 |
+
.TP 19
|
| 64 |
+
.B ARES_NI_LOOKUPHOST
|
| 65 |
+
A hostname lookup is being requested.
|
| 66 |
+
.TP 19
|
| 67 |
+
.B ARES_NI_LOOKUPSERVICE
|
| 68 |
+
A service name lookup is being requested.
|
| 69 |
+
.PP
|
| 70 |
+
When the query
|
| 71 |
+
is complete or has
|
| 72 |
+
failed, the ares library will invoke \fIcallback\fP. Completion or failure of
|
| 73 |
+
the query may happen immediately, or may happen during a later call to
|
| 74 |
+
\fIares_process(3)\fP, \fIares_destroy(3)\fP or \fIares_cancel(3)\fP.
|
| 75 |
+
.PP
|
| 76 |
+
When the associated callback is called, it is called with a channel lock so care
|
| 77 |
+
must be taken to ensure any processing is minimal to prevent DNS channel stalls.
|
| 78 |
+
|
| 79 |
+
The callback may be triggered from a different thread than the one which
|
| 80 |
+
called \fIares_getnameinfo(3)\fP.
|
| 81 |
+
|
| 82 |
+
For integrators running their own event loops and not using \fBARES_OPT_EVENT_THREAD\fP,
|
| 83 |
+
care needs to be taken to ensure any file descriptor lists are updated immediately
|
| 84 |
+
within the eventloop when notified.
|
| 85 |
+
.PP
|
| 86 |
+
The callback argument
|
| 87 |
+
.I arg
|
| 88 |
+
is copied from the
|
| 89 |
+
.B ares_getnameinfo
|
| 90 |
+
argument
|
| 91 |
+
.IR arg .
|
| 92 |
+
The callback argument
|
| 93 |
+
.I status
|
| 94 |
+
indicates whether the query succeeded and, if not, how it failed. It
|
| 95 |
+
may have any of the following values:
|
| 96 |
+
.TP 19
|
| 97 |
+
.B ARES_SUCCESS
|
| 98 |
+
The host lookup completed successfully.
|
| 99 |
+
.TP 19
|
| 100 |
+
.B ARES_ENOTIMP
|
| 101 |
+
The ares library does not know how to look up addresses of type
|
| 102 |
+
.IR family .
|
| 103 |
+
.TP 19
|
| 104 |
+
.B ARES_ENOTFOUND
|
| 105 |
+
The address
|
| 106 |
+
.I addr
|
| 107 |
+
was not found.
|
| 108 |
+
.TP 19
|
| 109 |
+
.B ARES_ENOMEM
|
| 110 |
+
Memory was exhausted.
|
| 111 |
+
.TP 19
|
| 112 |
+
.B ARES_ECANCELLED
|
| 113 |
+
The query was cancelled.
|
| 114 |
+
.TP 19
|
| 115 |
+
.B ARES_EDESTRUCTION
|
| 116 |
+
The name service channel
|
| 117 |
+
.I channel
|
| 118 |
+
is being destroyed; the query will not be completed.
|
| 119 |
+
.TP 19
|
| 120 |
+
.B ARES_EBADFLAGS
|
| 121 |
+
The
|
| 122 |
+
.I flags
|
| 123 |
+
parameter contains an illegal value.
|
| 124 |
+
.PP
|
| 125 |
+
The callback argument
|
| 126 |
+
.I timeouts
|
| 127 |
+
reports how many times a query timed out during the execution of the
|
| 128 |
+
given request.
|
| 129 |
+
.PP
|
| 130 |
+
On successful completion of the query, the callback argument
|
| 131 |
+
.I node
|
| 132 |
+
contains a string representing the hostname (assuming
|
| 133 |
+
.B ARES_NI_LOOKUPHOST
|
| 134 |
+
was specified). Additionally,
|
| 135 |
+
.I service
|
| 136 |
+
contains a string representing the service name (assuming
|
| 137 |
+
.B ARES_NI_LOOKUPSERVICE
|
| 138 |
+
was specified).
|
| 139 |
+
If the query did not complete successfully, or one of the values
|
| 140 |
+
was not requested,
|
| 141 |
+
.I node
|
| 142 |
+
or
|
| 143 |
+
.I service
|
| 144 |
+
will be
|
| 145 |
+
.BR NULL .
|
| 146 |
+
.SH SEE ALSO
|
| 147 |
+
.BR ares_process (3),
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_getsock.3
ADDED
|
@@ -0,0 +1,53 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by Daniel Stenberg
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_GETSOCK 3 "11 March 2010"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_getsock \- get socket descriptors to wait on (deprecated)
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
int ares_getsock(const ares_channel_t *\fIchannel\fP, ares_socket_t *\fIsocks\fP,
|
| 13 |
+
int \fInumsocks\fP);
|
| 14 |
+
.fi
|
| 15 |
+
.SH DESCRIPTION
|
| 16 |
+
The
|
| 17 |
+
.B ares_getsock
|
| 18 |
+
function retrieves the set of socket descriptors which the calling
|
| 19 |
+
application should wait on for reading and/or writing for the
|
| 20 |
+
processing of name service queries pending on the name service channel
|
| 21 |
+
identified by
|
| 22 |
+
.IR channel .
|
| 23 |
+
Socket descriptors will be set in the socket descriptor array pointed to by
|
| 24 |
+
\fIsocks\fP.
|
| 25 |
+
\fInumsocks\fP is the size of the given array in number of ints.
|
| 26 |
+
|
| 27 |
+
This function can only return information up to 16 sockets. If more are
|
| 28 |
+
in use, they are simply not reported back.
|
| 29 |
+
.SH RETURN VALUES
|
| 30 |
+
\fBares_getsock\fP returns a bitmask for what actions to wait for on the
|
| 31 |
+
different sockets. The ares.h header file provides these convenience macros to
|
| 32 |
+
extract the information appropriately:
|
| 33 |
+
|
| 34 |
+
.nf
|
| 35 |
+
#define ARES_GETSOCK_MAXNUM 16 /* ares_getsock() can return info about
|
| 36 |
+
this many sockets */
|
| 37 |
+
#define ARES_GETSOCK_READABLE(bits,num) (bits & (1<< (num)))
|
| 38 |
+
#define ARES_GETSOCK_WRITABLE(bits,num) (bits & (1 << ((num) + \
|
| 39 |
+
ARES_GETSOCK_MAXNUM)))
|
| 40 |
+
.fi
|
| 41 |
+
.SH NOTES
|
| 42 |
+
This function was added in c-ares 1.3.1 and deprecated in c-ares 1.20.0 due to
|
| 43 |
+
the implementation of \fBARES_OPT_MAX_UDP_QUERIES\fP which makes it likely to
|
| 44 |
+
exceed 16 open file descriptors.
|
| 45 |
+
|
| 46 |
+
It is recommended to use \fBARES_OPT_EVENT_THREAD\fP passed to
|
| 47 |
+
\fIares_init_options(3)\fP or to use socket state callbacks
|
| 48 |
+
(\fBARES_OPT_SOCK_STATE_CB\fP) registered via \fBares_init_options(3)\fP.
|
| 49 |
+
.SH SEE ALSO
|
| 50 |
+
.BR ares_init_options (3),
|
| 51 |
+
.BR ares_timeout (3),
|
| 52 |
+
.BR ares_fds (3),
|
| 53 |
+
.BR ares_process (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_inet_ntop.3
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright (C) 2013 by Daniel Stenberg
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_INET_NTOP 3 "17 Feb 2013"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_inet_ntop \- convert a network format address to presentation format
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
const char *ares_inet_ntop(int \fIaf\fP, const void *\fIsrc\fP, char *\fIdst\fP,
|
| 13 |
+
ares_socklen_t \fIsize\fP);
|
| 14 |
+
.fi
|
| 15 |
+
.SH DESCRIPTION
|
| 16 |
+
This is a portable version with the identical functionality of the commonly
|
| 17 |
+
available \fIinet_ntop\fP.
|
| 18 |
+
|
| 19 |
+
The ares_inet_ntop() function converts a numeric address into a text string
|
| 20 |
+
suitable for presentation. The \fBaf\fP argument shall specify the family of
|
| 21 |
+
the address. This can be AF_INET or AF_INET6. The \fBsrc\fP argument points
|
| 22 |
+
to a buffer holding an IPv4 address if the af argument is AF_INET, or an IPv6
|
| 23 |
+
address if the af argument is AF_INET6; the address must be in network byte
|
| 24 |
+
order. The \fBdst\fP argument points to a buffer where the function stores the
|
| 25 |
+
resulting text string; it shall not be NULL. The \fBsize\fP argument specifies
|
| 26 |
+
the size of this buffer, which shall be large enough to hold the text string
|
| 27 |
+
(INET_ADDRSTRLEN (16) characters for IPv4, INET6_ADDRSTRLEN (46) characters
|
| 28 |
+
for IPv6).
|
| 29 |
+
.SH SEE ALSO
|
| 30 |
+
.BR ares_init (3),
|
| 31 |
+
.BR ares_inet_pton (3)
|
| 32 |
+
.SH AVAILABILITY
|
| 33 |
+
made properly publicly available in c-ares for real in version 1.10.0
|
| 34 |
+
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_inet_pton.3
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright (C) 2013 by Daniel Stenberg
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_INET_PTON 3 "17 Feb 2013"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_inet_pton \- convert an IPv4 or IPv6 address from text to binary form
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
int ares_inet_pton(int \fIaf\fP, const char *\fIsrc\fP, void *\fIdst\fP);
|
| 13 |
+
.fi
|
| 14 |
+
.SH DESCRIPTION
|
| 15 |
+
This is a portable version with the identical functionality of the commonly
|
| 16 |
+
available \fIinet_pton\fP.
|
| 17 |
+
|
| 18 |
+
The ares_inet_pton() function converts the address in its standard text
|
| 19 |
+
presentation form into its numeric binary form. The \fBaf\fP argument shall
|
| 20 |
+
specify the family of the address. The AF_INET and AF_INET6 address families
|
| 21 |
+
shall be supported. The \fBsrc\fP argument points to the string being passed
|
| 22 |
+
in. The \fBdst\fP argument points to a buffer into which the function stores
|
| 23 |
+
the numeric address; this shall be large enough to hold the numeric address
|
| 24 |
+
(32 bits for AF_INET, 128 bits for AF_INET6).
|
| 25 |
+
|
| 26 |
+
It returns 1 if the address was valid for the specified address family, or 0
|
| 27 |
+
if the address was not parseable in the specified address family, or -1 if
|
| 28 |
+
some system error occurred (in which case errno will have been set).
|
| 29 |
+
|
| 30 |
+
.SH SEE ALSO
|
| 31 |
+
.BR ares_init (3),
|
| 32 |
+
.BR ares_inet_ntop (3)
|
| 33 |
+
.SH AVAILABILITY
|
| 34 |
+
made properly publicly available in c-ares for real in version 1.10.0
|
| 35 |
+
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_init.3
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\" Copyright (C) 2023 The c-ares project and its contributors.
|
| 2 |
+
.\" SPDX-License-Identifier: MIT
|
| 3 |
+
.so man3/ares_init_options.3
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_init_options.3
ADDED
|
@@ -0,0 +1,415 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" Copyright (C) 2004-2010 by Daniel Stenberg
|
| 4 |
+
.\"
|
| 5 |
+
.\" SPDX-License-Identifier: MIT
|
| 6 |
+
.\"
|
| 7 |
+
.TH ARES_INIT_OPTIONS 3 "5 March 2010"
|
| 8 |
+
.SH NAME
|
| 9 |
+
ares_init_options, ares_init \- Initialize a resolver channel
|
| 10 |
+
.SH SYNOPSIS
|
| 11 |
+
.nf
|
| 12 |
+
#include <ares.h>
|
| 13 |
+
|
| 14 |
+
struct ares_server_failover_options {
|
| 15 |
+
unsigned short retry_chance;
|
| 16 |
+
size_t retry_delay;
|
| 17 |
+
};
|
| 18 |
+
|
| 19 |
+
struct ares_options {
|
| 20 |
+
int flags;
|
| 21 |
+
int timeout; /* in seconds or milliseconds, depending on options */
|
| 22 |
+
int tries;
|
| 23 |
+
int ndots;
|
| 24 |
+
unsigned short udp_port;
|
| 25 |
+
unsigned short tcp_port;
|
| 26 |
+
int socket_send_buffer_size;
|
| 27 |
+
int socket_receive_buffer_size;
|
| 28 |
+
struct in_addr *servers;
|
| 29 |
+
int nservers;
|
| 30 |
+
char **domains;
|
| 31 |
+
int ndomains;
|
| 32 |
+
char *lookups;
|
| 33 |
+
ares_sock_state_cb sock_state_cb;
|
| 34 |
+
void *sock_state_cb_data;
|
| 35 |
+
struct apattern *sortlist;
|
| 36 |
+
int nsort;
|
| 37 |
+
int ednspsz;
|
| 38 |
+
char *resolvconf_path;
|
| 39 |
+
char *hosts_path;
|
| 40 |
+
int udp_max_queries;
|
| 41 |
+
int maxtimeout; /* in milliseconds */
|
| 42 |
+
unsigned int qcache_max_ttl; /* in seconds */
|
| 43 |
+
ares_evsys_t evsys;
|
| 44 |
+
struct ares_server_failover_options server_failover_opts;
|
| 45 |
+
};
|
| 46 |
+
|
| 47 |
+
int ares_init_options(ares_channel_t **\fIchannelptr\fP,
|
| 48 |
+
const struct ares_options *\fIoptions\fP,
|
| 49 |
+
int \fIoptmask\fP);
|
| 50 |
+
|
| 51 |
+
int ares_init(ares_channel_t **\fIchannelptr\fP);
|
| 52 |
+
|
| 53 |
+
.fi
|
| 54 |
+
.SH DESCRIPTION
|
| 55 |
+
The \fBares_init(3)\fP function is equivalent to calling
|
| 56 |
+
\fBares_init_options(channelptr, NULL, 0)\fP. It is recommended to use
|
| 57 |
+
\fBares_init_options(3)\fP instead and to set or make configurable the
|
| 58 |
+
appropriate options for your application.
|
| 59 |
+
|
| 60 |
+
The \fBares_init_options(3)\fP function initializes a communications channel
|
| 61 |
+
for name service lookups. If it returns successfully,
|
| 62 |
+
\fBares_init_options(3)\fP will set the variable pointed to by
|
| 63 |
+
\fIchannelptr\fP to a handle used to identify the name service channel. The
|
| 64 |
+
caller should invoke \fIares_destroy(3)\fP on the handle when the channel is
|
| 65 |
+
no longer needed.
|
| 66 |
+
|
| 67 |
+
It is recommended for an application to have at most one ares channel and use
|
| 68 |
+
this for all DNS queries for the life of the application. When system
|
| 69 |
+
configuration changes, \fIares_reinit(3)\fP can be called to reload the
|
| 70 |
+
configuration if necessary. The recommended concurrent query limit is about
|
| 71 |
+
32k queries, but remembering that when specifying AF_UNSPEC for
|
| 72 |
+
\fBares_getaddrinfo(3)\fP or \fBares_gethostbyname(3)\fP, they may spawn
|
| 73 |
+
2 queries internally. The reason for the limit is c-ares does not allow
|
| 74 |
+
duplicate DNS query ids (which have a maximum of 64k) to be oustanding at a
|
| 75 |
+
given time, and it must randomly search for an available id thus 32k will limit
|
| 76 |
+
the number of searches. This limitation should not be a concern for most
|
| 77 |
+
implementations and c-ares may implement queuing in future releases to lift this
|
| 78 |
+
limitation.
|
| 79 |
+
|
| 80 |
+
The \fIoptmask\fP parameter generally specifies which fields in the structure pointed to
|
| 81 |
+
by \fIoptions\fP are set, as follows:
|
| 82 |
+
.TP 18
|
| 83 |
+
.B ARES_OPT_FLAGS
|
| 84 |
+
.B int \fIflags\fP;
|
| 85 |
+
.br
|
| 86 |
+
Flags controlling the behavior of the resolver:
|
| 87 |
+
.RS 4
|
| 88 |
+
.TP 23
|
| 89 |
+
.B ARES_FLAG_USEVC
|
| 90 |
+
Always use TCP queries (the "virtual circuit") instead of UDP
|
| 91 |
+
queries. Normally, TCP is only used if a UDP query yields a truncated
|
| 92 |
+
result.
|
| 93 |
+
.TP 23
|
| 94 |
+
.B ARES_FLAG_PRIMARY
|
| 95 |
+
Only query the first server in the list of servers to query.
|
| 96 |
+
.TP 23
|
| 97 |
+
.B ARES_FLAG_IGNTC
|
| 98 |
+
If a truncated response to a UDP query is received, do not fall back
|
| 99 |
+
to TCP; simply continue on with the truncated response.
|
| 100 |
+
.TP 23
|
| 101 |
+
.B ARES_FLAG_NORECURSE
|
| 102 |
+
Do not set the "recursion desired" bit on outgoing queries, so that the name
|
| 103 |
+
server being contacted will not try to fetch the answer from other servers if
|
| 104 |
+
it doesn't know the answer locally. Be aware that ares will not do the
|
| 105 |
+
recursion for you. Recursion must be handled by the application calling ares
|
| 106 |
+
if \fIARES_FLAG_NORECURSE\fP is set.
|
| 107 |
+
.TP 23
|
| 108 |
+
.B ARES_FLAG_STAYOPEN
|
| 109 |
+
Do not close communications sockets when the number of active queries
|
| 110 |
+
drops to zero.
|
| 111 |
+
.TP 23
|
| 112 |
+
.B ARES_FLAG_NOSEARCH
|
| 113 |
+
Do not use the default search domains; only query hostnames as-is or
|
| 114 |
+
as aliases.
|
| 115 |
+
.TP 23
|
| 116 |
+
.B ARES_FLAG_NOALIASES
|
| 117 |
+
Do not honor the HOSTALIASES environment variable, which normally
|
| 118 |
+
specifies a file of hostname translations.
|
| 119 |
+
.TP 23
|
| 120 |
+
.B ARES_FLAG_NOCHECKRESP
|
| 121 |
+
Do not discard responses with the SERVFAIL, NOTIMP, or REFUSED
|
| 122 |
+
response code or responses whose questions don't match the questions
|
| 123 |
+
in the request. Primarily useful for writing clients which might be
|
| 124 |
+
used to test or debug name servers.
|
| 125 |
+
.TP 23
|
| 126 |
+
.B ARES_FLAG_EDNS
|
| 127 |
+
Include an EDNS pseudo-resource record (RFC 2671) in generated requests. As of
|
| 128 |
+
v1.22, this is on by default if flags are otherwise not set.
|
| 129 |
+
.TP 23
|
| 130 |
+
.B ARES_FLAG_NO_DFLT_SVR
|
| 131 |
+
Do not attempt to add a default local named server if there are no other
|
| 132 |
+
servers available. Instead, fail initialization with \fIARES_ENOSERVER\fP.
|
| 133 |
+
.TP 23
|
| 134 |
+
.B ARES_FLAG_DNS0x20
|
| 135 |
+
Enable support for DNS 0x20 as per https://datatracker.ietf.org/doc/html/draft-vixie-dnsext-dns0x20-00
|
| 136 |
+
which adds additional entropy to the request by randomizing the case of the
|
| 137 |
+
query name. Integrators need to ensure they treat DNS name responses as
|
| 138 |
+
case-insensitive. In rare circumstances this may cause the inability to lookup
|
| 139 |
+
certain domains if the upstream server or the authoritative server for the
|
| 140 |
+
domain is non-compliant.
|
| 141 |
+
.RE
|
| 142 |
+
.TP 18
|
| 143 |
+
.B ARES_OPT_TIMEOUT
|
| 144 |
+
.B int \fItimeout\fP;
|
| 145 |
+
.br
|
| 146 |
+
The number of seconds each name server is given to respond to a query on the
|
| 147 |
+
first try. See \fIARES_OPT_TIMEOUTMS\fP which this value is converted into.
|
| 148 |
+
.TP 18
|
| 149 |
+
.B ARES_OPT_TIMEOUTMS
|
| 150 |
+
.B int \fItimeout\fP;
|
| 151 |
+
.br
|
| 152 |
+
The number of milliseconds each name server is given to respond to a query on
|
| 153 |
+
the first try of any given server. The default is two seconds, however any
|
| 154 |
+
value below 250ms will automatically be set to 250ms (roughly the RTT half-way
|
| 155 |
+
around the world). Note that this option is specified with the same struct field
|
| 156 |
+
as the former \fIARES_OPT_TIMEOUT\fP, it is but the option bits that tell c-ares
|
| 157 |
+
how to interpret the number. This option was added in c-ares 1.5.2.
|
| 158 |
+
|
| 159 |
+
As of c-ares 1.32.0, this option is only honored on the first successful query
|
| 160 |
+
to any given server, after that the timeout is automatically calculated based
|
| 161 |
+
on prior query history.
|
| 162 |
+
.TP 18
|
| 163 |
+
.B ARES_OPT_TRIES
|
| 164 |
+
.B int \fItries\fP;
|
| 165 |
+
.br
|
| 166 |
+
The number of tries the resolver will try contacting each name server
|
| 167 |
+
before giving up. The default is three tries.
|
| 168 |
+
.TP 18
|
| 169 |
+
.B ARES_OPT_NDOTS
|
| 170 |
+
.B int \fIndots\fP;
|
| 171 |
+
.br
|
| 172 |
+
The number of dots which must be present in a domain name for it to be
|
| 173 |
+
queried for "as is" prior to querying for it with the default domain
|
| 174 |
+
extensions appended. The default value is 1 unless set otherwise by
|
| 175 |
+
resolv.conf or the RES_OPTIONS environment variable. Valid range is 0-15.
|
| 176 |
+
.TP 18
|
| 177 |
+
.B ARES_OPT_MAXTIMEOUTMS
|
| 178 |
+
.B int \fImaxtimeout\fP;
|
| 179 |
+
.br
|
| 180 |
+
The upper bound for timeout between sequential retry attempts. When retrying
|
| 181 |
+
queries, the timeout is increased from the requested timeout parameter, this
|
| 182 |
+
caps the value.
|
| 183 |
+
.TP 18
|
| 184 |
+
.B ARES_OPT_UDP_PORT
|
| 185 |
+
.B unsigned short \fIudp_port\fP;
|
| 186 |
+
.br
|
| 187 |
+
The port to use for queries over UDP, in host byte order.
|
| 188 |
+
The default value is 53, the standard name service port.
|
| 189 |
+
.TP 18
|
| 190 |
+
.B ARES_OPT_TCP_PORT
|
| 191 |
+
.B unsigned short \fItcp_port\fP;
|
| 192 |
+
.br
|
| 193 |
+
The port to use for queries over TCP, in host byte order.
|
| 194 |
+
The default value is 53, the standard name service port.
|
| 195 |
+
.TP 18
|
| 196 |
+
.B ARES_OPT_SERVERS
|
| 197 |
+
.B struct in_addr *\fIservers\fP;
|
| 198 |
+
.br
|
| 199 |
+
.B int \fInservers\fP;
|
| 200 |
+
.br
|
| 201 |
+
The list of IPv4 servers to contact, instead of the servers specified in
|
| 202 |
+
resolv.conf or the local named. In order to allow specification of either IPv4
|
| 203 |
+
or IPv6 name servers, the \Bares_set_servers(3)\fP function must be used
|
| 204 |
+
instead.
|
| 205 |
+
.TP 18
|
| 206 |
+
.B ARES_OPT_DOMAINS
|
| 207 |
+
.B char **\fIdomains\fP;
|
| 208 |
+
.br
|
| 209 |
+
.B int \fIndomains\fP;
|
| 210 |
+
.br
|
| 211 |
+
The domains to search, instead of the domains specified in resolv.conf
|
| 212 |
+
or the domain derived from the kernel hostname variable.
|
| 213 |
+
.TP 18
|
| 214 |
+
.B ARES_OPT_LOOKUPS
|
| 215 |
+
.B char *\fIlookups\fP;
|
| 216 |
+
.br
|
| 217 |
+
The lookups to perform for host queries.
|
| 218 |
+
.I lookups
|
| 219 |
+
should be set to a string of the characters "b" or "f", where "b"
|
| 220 |
+
indicates a DNS lookup and "f" indicates a lookup in the hosts file.
|
| 221 |
+
.TP 18
|
| 222 |
+
.B ARES_OPT_SOCK_STATE_CB
|
| 223 |
+
.B void (*\fIsock_state_cb\fP)(void *data, ares_socket_t socket_fd, int readable, int writable);
|
| 224 |
+
.br
|
| 225 |
+
.B void *\fIsock_state_cb_data\fP;
|
| 226 |
+
.br
|
| 227 |
+
A callback function to be invoked when a socket changes state.
|
| 228 |
+
.I socket_fd
|
| 229 |
+
will be passed the socket whose state has changed;
|
| 230 |
+
.I readable
|
| 231 |
+
will be set to true if the socket should listen for read events, and
|
| 232 |
+
.I writable
|
| 233 |
+
will be set to true if the socket should listen for write events.
|
| 234 |
+
The value of
|
| 235 |
+
.I sock_state_cb_data
|
| 236 |
+
will be passed as the
|
| 237 |
+
.I data
|
| 238 |
+
argument. The channel lock is held during this callback, if in a multithreaded
|
| 239 |
+
application, care must be taken to ensure lock order is correct to be able to
|
| 240 |
+
handle this and avoid deadlocks.
|
| 241 |
+
|
| 242 |
+
Cannot be used with \fBARES_OPT_EVENT_THREAD\fP.
|
| 243 |
+
.TP 18
|
| 244 |
+
.B ARES_OPT_SORTLIST
|
| 245 |
+
.B struct apattern *\fIsortlist\fP;
|
| 246 |
+
.br
|
| 247 |
+
.B int \fInsort\fP;
|
| 248 |
+
.br
|
| 249 |
+
A list of IP address ranges that specifies the order of preference that
|
| 250 |
+
results from \fIares_gethostbyname\fP should be returned in. Note that
|
| 251 |
+
this can only be used with a sortlist retrieved via
|
| 252 |
+
\fBares_save_options(3)\fP (because
|
| 253 |
+
.B struct apattern
|
| 254 |
+
is opaque); to set a fresh sort list, use \fBares_set_sortlist(3)\fP.
|
| 255 |
+
.TP 18
|
| 256 |
+
.B ARES_OPT_SOCK_SNDBUF
|
| 257 |
+
.B int \fIsocket_send_buffer_size\fP;
|
| 258 |
+
.br
|
| 259 |
+
The send buffer size to set for the socket.
|
| 260 |
+
.TP 18
|
| 261 |
+
.B ARES_OPT_SOCK_RCVBUF
|
| 262 |
+
.B int \fIsocket_receive_buffer_size\fP;
|
| 263 |
+
.br
|
| 264 |
+
The receive buffer size to set for the socket.
|
| 265 |
+
.TP 18
|
| 266 |
+
.B ARES_OPT_EDNSPSZ
|
| 267 |
+
.B int \fIednspsz\fP;
|
| 268 |
+
.br
|
| 269 |
+
The message size to be advertised in EDNS; only takes effect if the
|
| 270 |
+
.B ARES_FLAG_EDNS
|
| 271 |
+
flag is set. Defaults to 1232, the recommended size.
|
| 272 |
+
.TP 18
|
| 273 |
+
.B ARES_OPT_RESOLVCONF
|
| 274 |
+
.B char *\fIresolvconf_path\fP;
|
| 275 |
+
.br
|
| 276 |
+
The path to use for reading the resolv.conf file. The
|
| 277 |
+
.I resolvconf_path
|
| 278 |
+
should be set to a path string, and will be honoured on *nix like systems. The
|
| 279 |
+
default is
|
| 280 |
+
.B /etc/resolv.conf
|
| 281 |
+
.br
|
| 282 |
+
.TP 18
|
| 283 |
+
.B ARES_OPT_HOSTS_FILE
|
| 284 |
+
.B char *\fIhosts_path\fP;
|
| 285 |
+
.br
|
| 286 |
+
The path to use for reading the hosts file. The
|
| 287 |
+
.I hosts_path
|
| 288 |
+
should be set to a path string, and will be honoured on *nix like systems. The
|
| 289 |
+
default is
|
| 290 |
+
.B /etc/hosts
|
| 291 |
+
.br
|
| 292 |
+
.TP 18
|
| 293 |
+
.B ARES_OPT_UDP_MAX_QUERIES
|
| 294 |
+
.B int \fIudp_max_queries\fP;
|
| 295 |
+
.br
|
| 296 |
+
The maximum number of udp queries that can be sent on a single ephemeral port
|
| 297 |
+
to a given DNS server before a new ephemeral port is assigned. Any value of 0
|
| 298 |
+
or less will be considered unlimited, and is the default.
|
| 299 |
+
.br
|
| 300 |
+
.TP 18
|
| 301 |
+
.B ARES_OPT_QUERY_CACHE
|
| 302 |
+
.B unsigned int \fIqcache_max_ttl\fP;
|
| 303 |
+
.br
|
| 304 |
+
As of c-ares 1.31.0, the query cache is enabled by default with a TTL of 1hr.
|
| 305 |
+
To disable the query cache, specify this option with a TTL of 0. The query
|
| 306 |
+
cache is based on the returned TTL in the DNS message. Only fully successful
|
| 307 |
+
and NXDOMAIN query results will be cached. Fill in the \fIqcache_max_ttl\fP
|
| 308 |
+
with the maximum number of seconds a query result may be cached which will
|
| 309 |
+
override a larger TTL in the response message. This must be a non-zero value
|
| 310 |
+
otherwise the cache will be disabled. Choose a reasonable value for your
|
| 311 |
+
application such as 300 (5 minutes) or 3600 (1 hour). The query cache is
|
| 312 |
+
automatically flushed if a server configuration change is made.
|
| 313 |
+
.br
|
| 314 |
+
.TP 18
|
| 315 |
+
.B ARES_OPT_EVENT_THREAD
|
| 316 |
+
.B ares_evsys_t \fIevsys\fP;
|
| 317 |
+
.br
|
| 318 |
+
Enable the built-in event thread (Recommended). Introduced in c-ares 1.26.0.
|
| 319 |
+
Set the \fIevsys\fP parameter to \fBARES_EVSYS_DEFAULT\fP (0). Other values are
|
| 320 |
+
reserved for testing and should not be used by integrators.
|
| 321 |
+
|
| 322 |
+
This option cannot be used with the \fBARES_OPT_SOCK_STATE_CB\fP option, nor the
|
| 323 |
+
\fIares_set_socket_functions(3)\fP or
|
| 324 |
+
\fIares_set_socket_configure_callback(3)\fP functions.
|
| 325 |
+
|
| 326 |
+
When enabled, the integrator is no longer responsible for notifying c-ares of
|
| 327 |
+
any events on the file descriptors, so \fIares_process(3)\fP nor
|
| 328 |
+
\fIares_process_fd(3)\fP should ever be called when this option is enabled.
|
| 329 |
+
|
| 330 |
+
As of c-ares 1.29.0, when enabled, it will also automatically re-load the
|
| 331 |
+
system configuration when changes are detected.
|
| 332 |
+
|
| 333 |
+
Use \fIares_threadsafety(3)\fP to determine if this option is available to be
|
| 334 |
+
used.
|
| 335 |
+
|
| 336 |
+
Returns \fBARES_ENOTIMP\fP if this option is passed but not available, and
|
| 337 |
+
\fBARES_ESERVFAIL\fP if there is a critical failure during initialization of
|
| 338 |
+
the event thread.
|
| 339 |
+
.br
|
| 340 |
+
.TP 18
|
| 341 |
+
.B ARES_OPT_SERVER_FAILOVER
|
| 342 |
+
.B struct ares_server_failover_options \fIserver_failover_opts\fP;
|
| 343 |
+
.br
|
| 344 |
+
Configure server failover retry behavior. When a DNS server fails to
|
| 345 |
+
respond to a query, c-ares will deprioritize the server. On subsequent
|
| 346 |
+
queries, servers with fewer consecutive failures will be selected in
|
| 347 |
+
preference. However, in order to detect when such a server has recovered,
|
| 348 |
+
c-ares will occasionally retry failed servers by probing with a copy of
|
| 349 |
+
the query, without affecting the latency of the actual requested query. The
|
| 350 |
+
\fIares_server_failover_options\fP structure contains options to control this
|
| 351 |
+
behavior.
|
| 352 |
+
The \fIretry_chance\fP field gives the probability (1/N) of retrying a
|
| 353 |
+
failed server on any given query. Setting to a value of 0 disables retries.
|
| 354 |
+
The \fIretry_delay\fP field gives the minimum delay in milliseconds that c-ares
|
| 355 |
+
will wait before retrying a specific failed server.
|
| 356 |
+
If this option is not specificed then c-ares will use a probability of 10%
|
| 357 |
+
and a minimum delay of 5 seconds.
|
| 358 |
+
.br
|
| 359 |
+
.PP
|
| 360 |
+
The \fIoptmask\fP parameter also includes options without a corresponding
|
| 361 |
+
field in the
|
| 362 |
+
.B ares_options
|
| 363 |
+
structure, as follows:
|
| 364 |
+
.TP 23
|
| 365 |
+
.B ARES_OPT_ROTATE
|
| 366 |
+
Perform round-robin selection of the nameservers configured for the channel
|
| 367 |
+
for each resolution.
|
| 368 |
+
.TP 23
|
| 369 |
+
.B ARES_OPT_NOROTATE
|
| 370 |
+
Do not perform round-robin nameserver selection; always use the list of
|
| 371 |
+
nameservers in the same order. The default is not to rotate servers, however
|
| 372 |
+
the system configuration can specify the desire to rotate and this
|
| 373 |
+
configuration value can negate such a system configuration.
|
| 374 |
+
.PP
|
| 375 |
+
|
| 376 |
+
.SH RETURN VALUES
|
| 377 |
+
\fBares_init_options(3)\fP and \fBares_init(3)\fP can return any of the
|
| 378 |
+
following values:
|
| 379 |
+
.TP 14
|
| 380 |
+
.B ARES_SUCCESS
|
| 381 |
+
Initialization succeeded.
|
| 382 |
+
.TP 14
|
| 383 |
+
.B ARES_EFILE
|
| 384 |
+
A configuration file could not be read.
|
| 385 |
+
.TP 14
|
| 386 |
+
.B ARES_ENOMEM
|
| 387 |
+
The process's available memory was exhausted.
|
| 388 |
+
.TP 14
|
| 389 |
+
.B ARES_ENOTINITIALIZED
|
| 390 |
+
c-ares library initialization not yet performed.
|
| 391 |
+
.TP 14
|
| 392 |
+
.B ARES_ENOSERVER
|
| 393 |
+
No DNS servers were available to use.
|
| 394 |
+
.SH NOTES
|
| 395 |
+
When initializing from
|
| 396 |
+
.B /etc/resolv.conf,
|
| 397 |
+
(or, alternatively when specified by the
|
| 398 |
+
.I resolvconf_path
|
| 399 |
+
path location)
|
| 400 |
+
\fBares_init_options(3)\fP and \fBares_init(3)\fP reads the \fIdomain\fP and
|
| 401 |
+
\fIsearch\fP directives to allow lookups of short names relative to the domains
|
| 402 |
+
specified. The \fIdomain\fP and \fIsearch\fP directives override one another.
|
| 403 |
+
If more than one instance of either \fIdomain\fP or \fIsearch\fP directives is
|
| 404 |
+
specified, the last occurrence wins. For more information, please see the
|
| 405 |
+
.BR resolv.conf (5)
|
| 406 |
+
manual page.
|
| 407 |
+
.SH SEE ALSO
|
| 408 |
+
.BR ares_reinit (3),
|
| 409 |
+
.BR ares_destroy (3),
|
| 410 |
+
.BR ares_dup (3),
|
| 411 |
+
.BR ares_library_init (3),
|
| 412 |
+
.BR ares_save_options (3),
|
| 413 |
+
.BR ares_set_servers (3),
|
| 414 |
+
.BR ares_set_sortlist (3),
|
| 415 |
+
.BR ares_threadsafety (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_library_cleanup.3
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" Copyright (C) 2004-2009 by Daniel Stenberg
|
| 4 |
+
.\" SPDX-License-Identifier: MIT
|
| 5 |
+
.\"
|
| 6 |
+
.TH ARES_LIBRARY_CLEANUP 3 "19 May 2009"
|
| 7 |
+
.SH NAME
|
| 8 |
+
ares_library_cleanup \- c-ares library deinitialization
|
| 9 |
+
.SH SYNOPSIS
|
| 10 |
+
.nf
|
| 11 |
+
#include <ares.h>
|
| 12 |
+
|
| 13 |
+
void ares_library_cleanup(void)
|
| 14 |
+
.fi
|
| 15 |
+
.SH DESCRIPTION
|
| 16 |
+
.PP
|
| 17 |
+
The
|
| 18 |
+
.B ares_library_cleanup
|
| 19 |
+
function uninitializes the c-ares library, freeing all resources
|
| 20 |
+
previously acquired by \fIares_library_init(3)\fP when the library
|
| 21 |
+
was initialized, provided there was only one single previous call to
|
| 22 |
+
\fIares_library_init(3)\fP. If there was more than one previous call to
|
| 23 |
+
\fIares_library_init(3)\fP, this function uninitializes the c-ares
|
| 24 |
+
library only if it is the call matching the call to
|
| 25 |
+
\fIares_library_init(3)\fP which initialized the library
|
| 26 |
+
(usually the very first call to \fIares_library_init(3)\fP).
|
| 27 |
+
Other calls to \fIares_library_cleanup(3)\fP have no effect other than
|
| 28 |
+
decrementing an internal counter.
|
| 29 |
+
.PP
|
| 30 |
+
This function must be called when the program using c-ares will
|
| 31 |
+
no longer need any c-ares function. Once the program has called
|
| 32 |
+
\fIares_library_cleanup(3)\fP sufficiently often such that the
|
| 33 |
+
library is uninitialised, it shall not make any further call to any
|
| 34 |
+
c-ares function.
|
| 35 |
+
.PP
|
| 36 |
+
This function does not cancel any pending c-ares lookups or requests
|
| 37 |
+
previously done. Program must use \fIares_cancel(3)\fP for this purpose.
|
| 38 |
+
.PP
|
| 39 |
+
.B This function is not thread safe.
|
| 40 |
+
You have to call it once the program is about to terminate, but this call must
|
| 41 |
+
be done once the program has terminated every single thread that it could have
|
| 42 |
+
initiated. This is required to avoid potential race conditions in library
|
| 43 |
+
deinitialization, and also due to the fact that \fIares_library_cleanup(3)\fP
|
| 44 |
+
might call functions from other libraries that are thread unsafe, and could
|
| 45 |
+
conflict with any other thread that is already using these other libraries.
|
| 46 |
+
.PP
|
| 47 |
+
Win32/64 application DLLs shall not call \fIares_library_cleanup(3)\fP from
|
| 48 |
+
the DllMain function. Doing so will produce deadlocks and other problems.
|
| 49 |
+
.SH AVAILABILITY
|
| 50 |
+
This function was first introduced in c-ares version 1.7.0 along with the
|
| 51 |
+
definition of preprocessor symbol \fICARES_HAVE_ARES_LIBRARY_CLEANUP\fP as an
|
| 52 |
+
indication of the availability of this function. Reference counting in
|
| 53 |
+
\fIares_library_init(3)\fP and \fIares_library_cleanup(3)\fP, which requires
|
| 54 |
+
calls to the former function to match calls to the latter, is present since
|
| 55 |
+
c-ares version 1.10.0. Earlier versions would deinitialize the library on the
|
| 56 |
+
first call to \fIares_library_cleanup(3)\fP.
|
| 57 |
+
.PP
|
| 58 |
+
Since the introduction of this function, it is absolutely mandatory to call it
|
| 59 |
+
for any Win32/64 program using c-ares.
|
| 60 |
+
.PP
|
| 61 |
+
Non-Win32/64 systems can still use c-ares version 1.7.0 without calling
|
| 62 |
+
\fIares_library_cleanup(3)\fP due to the fact that \fIcurrently\fP it is nearly
|
| 63 |
+
a do-nothing function on non-Win32/64 platforms.
|
| 64 |
+
.SH SEE ALSO
|
| 65 |
+
.BR ares_library_init (3),
|
| 66 |
+
.BR ares_cancel (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_library_init.3
ADDED
|
@@ -0,0 +1,98 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright 1998 by the Massachusetts Institute of Technology.
|
| 3 |
+
.\" Copyright (C) 2004-2009 by Daniel Stenberg
|
| 4 |
+
.\" SPDX-License-Identifier: MIT
|
| 5 |
+
.\"
|
| 6 |
+
.TH ARES_LIBRARY_INIT 3 "19 May 2009"
|
| 7 |
+
.SH NAME
|
| 8 |
+
ares_library_init \- c-ares library initialization
|
| 9 |
+
.SH SYNOPSIS
|
| 10 |
+
.nf
|
| 11 |
+
#include <ares.h>
|
| 12 |
+
|
| 13 |
+
int ares_library_init(int \fIflags\fP)
|
| 14 |
+
|
| 15 |
+
int ares_library_init_mem(int \fIflags\fP,
|
| 16 |
+
void *(*\fIamalloc\fP)(size_t),
|
| 17 |
+
void (*\fIafree\fP)(void *ptr),
|
| 18 |
+
void (*\fIarealloc\fP)(void *ptr, size_t size))
|
| 19 |
+
.fi
|
| 20 |
+
.SH DESCRIPTION
|
| 21 |
+
.PP
|
| 22 |
+
The
|
| 23 |
+
.B ares_library_init
|
| 24 |
+
function performs initializations internally required by the c-ares
|
| 25 |
+
library that must take place before any other function provided by
|
| 26 |
+
c-ares can be used in a program.
|
| 27 |
+
.PP
|
| 28 |
+
This function must be called at least once within the life of a program,
|
| 29 |
+
before the program actually executes any other c-ares library function.
|
| 30 |
+
Initializations done by this function remain effective until a number of
|
| 31 |
+
calls to \fIares_library_cleanup(3)\fP equal to the number of calls to
|
| 32 |
+
this function are performed.
|
| 33 |
+
.PP
|
| 34 |
+
Successive calls to this function do nothing further, only the first
|
| 35 |
+
call done when c-ares is in an uninitialized state is actually
|
| 36 |
+
effective.
|
| 37 |
+
.PP
|
| 38 |
+
The
|
| 39 |
+
.I flags
|
| 40 |
+
parameter is a bit pattern that tells c-ares exactly which features
|
| 41 |
+
should be initialized, as described below. Set the desired bits by
|
| 42 |
+
ORing the values together. In normal operation you should specify
|
| 43 |
+
\fIARES_LIB_INIT_ALL\fP. Don't use any other value unless you are
|
| 44 |
+
familiar with it and trying to control some internal c-ares feature.
|
| 45 |
+
.PP
|
| 46 |
+
The
|
| 47 |
+
.B ares_library_init_mem
|
| 48 |
+
function allows the caller to provide memory management functions that the
|
| 49 |
+
c-ares library will be use instead of \fImalloc(3)\fP, \fIfree(3)\fP and
|
| 50 |
+
\fIrealloc(3)\fP.
|
| 51 |
+
.PP
|
| 52 |
+
.B This function is not thread safe.
|
| 53 |
+
You have to call it once the program has started, but this call must be done
|
| 54 |
+
before the program starts any other thread. This is required to avoid
|
| 55 |
+
potential race conditions in library initialization, and also due to the fact
|
| 56 |
+
that \fIares_library_init(3)\fP might call functions from other libraries that
|
| 57 |
+
are thread unsafe, and could conflict with any other thread that is already
|
| 58 |
+
using these other libraries.
|
| 59 |
+
.PP
|
| 60 |
+
On Windows platforms, the library user should ensure that \fIWSAStartup()\fP
|
| 61 |
+
is called before the c-ares library is initialized and used.
|
| 62 |
+
.PP
|
| 63 |
+
Win32/64 application DLLs shall not call \fIares_library_init(3)\fP from the
|
| 64 |
+
DllMain function. Doing so will produce deadlocks and other problems.
|
| 65 |
+
.SH FLAGS
|
| 66 |
+
.TP 5
|
| 67 |
+
.B ARES_LIB_INIT_ALL
|
| 68 |
+
Initialize everything possible. This sets all known bits.
|
| 69 |
+
.TP
|
| 70 |
+
.B ARES_LIB_INIT_WIN32
|
| 71 |
+
Initialize Win32/64 specific libraries. As of c-ares 1.19.0, this is ignored
|
| 72 |
+
as there are no currently dynamically loaded libraries.
|
| 73 |
+
.TP
|
| 74 |
+
.B ARES_LIB_INIT_NONE
|
| 75 |
+
Initialize nothing extra. This sets no bit.
|
| 76 |
+
.SH RETURN VALUE
|
| 77 |
+
Upon successful completion, \fIares_library_init(3)\fP returns 0. Otherwise,
|
| 78 |
+
a non-zero error number is returned to indicate the error. Except for
|
| 79 |
+
\fIares_strerror(3)\fP, you shall not call any other c-ares function upon
|
| 80 |
+
\fIares_library_init(3)\fP failure.
|
| 81 |
+
.SH AVAILABILITY
|
| 82 |
+
This function was first introduced in c-ares version 1.7.0 along with the
|
| 83 |
+
definition of preprocessor symbol \fICARES_HAVE_ARES_LIBRARY_INIT\fP as an
|
| 84 |
+
indication of the availability of this function. Its recursive behavior, which
|
| 85 |
+
requires a matching number of calls to \fIares_library_cleanup(3)\fP in order
|
| 86 |
+
to deinitialize the library, is present since c-ares version 1.10.0. Earlier
|
| 87 |
+
versions would deinitialize the library on the first call to
|
| 88 |
+
\fIares_library_cleanup(3)\fP.
|
| 89 |
+
.PP
|
| 90 |
+
Since the introduction of this function it is absolutely mandatory to
|
| 91 |
+
call it for any Win32/64 program using c-ares.
|
| 92 |
+
.PP
|
| 93 |
+
Non-Win32/64 systems can still use c-ares version 1.7.0 without calling
|
| 94 |
+
\fIares_library_init(3)\fP due to the fact that \fIcurrently\fP it is nearly
|
| 95 |
+
a do-nothing function on non-Win32/64 platforms at this point.
|
| 96 |
+
.SH SEE ALSO
|
| 97 |
+
.BR ares_library_cleanup (3),
|
| 98 |
+
.BR ares_strerror (3)
|
miniconda3/pkgs/c-ares-1.34.6-hd44998d_0/share/man/man3/ares_library_init_android.3
ADDED
|
@@ -0,0 +1,127 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
.\"
|
| 2 |
+
.\" Copyright (C) 2017 by John Schember
|
| 3 |
+
.\" SPDX-License-Identifier: MIT
|
| 4 |
+
.\"
|
| 5 |
+
.TH ARES_LIBRARY_INIT_ANDROID 3 "13 Sept 2017"
|
| 6 |
+
.SH NAME
|
| 7 |
+
ares_library_init_android \- c-ares library Android initialization
|
| 8 |
+
.SH SYNOPSIS
|
| 9 |
+
.nf
|
| 10 |
+
#include <ares.h>
|
| 11 |
+
|
| 12 |
+
int ares_library_init_android(jobject \fIconnectivity_manager\fP)
|
| 13 |
+
|
| 14 |
+
int ares_library_android_initialized();
|
| 15 |
+
|
| 16 |
+
void ares_library_init_jvm(JavaVM *\fIjvm\fP)
|
| 17 |
+
|
| 18 |
+
.fi
|
| 19 |
+
.SH DESCRIPTION
|
| 20 |
+
The \fIares_library_init_android(3)\fP function performs initializations
|
| 21 |
+
internally required by the c-ares library when used on Android. This can take
|
| 22 |
+
place anytime after \fIares_library_init(3)\fP. It must take place after
|
| 23 |
+
\fIares_library_init_jvm\fP. ares_library_init_android must be called before
|
| 24 |
+
DNS resolution will work on Android 8 (Oreo) or newer when targetSdkVersion is
|
| 25 |
+
set to 26+.
|
| 26 |
+
|
| 27 |
+
As of Android 8 (API level 26) getting DNS server information has
|
| 28 |
+
becomei more restrictive and can only be accessed using the
|
| 29 |
+
Connectivity Manager. It is necessary to pass the connectivity
|
| 30 |
+
manager to c-ares via JNI. Also, the ACCESS_NETWORK_STATE permission
|
| 31 |
+
must be present in the Android application.
|
| 32 |
+
|
| 33 |
+
Android older than 8 do not need to to be initialized as they
|
| 34 |
+
are less restrictive. However, this is a run time not compile time
|
| 35 |
+
limitation. Proper Android initialization should take place regardless
|
| 36 |
+
of the targeted Android version.
|
| 37 |
+
|
| 38 |
+
Deinitialization will take place though \fIares_library_cleanup(3)\fP.
|
| 39 |
+
|
| 40 |
+
The \fBares_library_init_jvm\fP function allows the caller to register the JVM
|
| 41 |
+
with c-ares. It's meant to be called during JNI_OnLoad because you're
|
| 42 |
+
guaranteed to have the JVM in that function. The JVM is required in order to
|
| 43 |
+
use the Connectivity Manager registered using
|
| 44 |
+
\fIares_library_init_android(3)\fP. This must be call before
|
| 45 |
+
\fIares_library_init_android(3)\fP.
|
| 46 |
+
|
| 47 |
+
The \fBares_library_android_initialized\fP function can be used to check
|
| 48 |
+
whether c-ares has been initialized for use with Android.
|
| 49 |
+
.SH RETURN VALUES
|
| 50 |
+
ARES_SUCCESS will be returned on success otherwise an error code will be
|
| 51 |
+
returned.
|
| 52 |
+
.SH THREAD SAFETY
|
| 53 |
+
.B These init functions are not thread safe.
|
| 54 |
+
You have to call it once the program has started, but this call must be done
|
| 55 |
+
before the program starts any other thread. This is required to avoid
|
| 56 |
+
potential race conditions in library initialization, and also due to the fact
|
| 57 |
+
these might call functions from other libraries that
|
| 58 |
+
are thread unsafe, and could conflict with any other thread that is already
|
| 59 |
+
using these other libraries.
|
| 60 |
+
.SH JNI
|
| 61 |
+
Accessing the Connectivity Manager though Java:
|
| 62 |
+
|
| 63 |
+
Register the \fIares_library_android_init\fP.
|
| 64 |
+
.nf
|
| 65 |
+
static JNINativeMethod funcs[] = {
|
| 66 |
+
{ "initialize_native", "(Landroid/net/ConnectivityManager;)I",
|
| 67 |
+
(void *)&ares_library_init_android}
|
| 68 |
+
};
|
| 69 |
+
|
| 70 |
+
JNIEXPORT jint JNICALL JNI_OnLoad(JavaVM *vm, void *reserved)
|
| 71 |
+
{
|
| 72 |
+
JNIEnv *env = NULL;
|
| 73 |
+
jclass cls = NULL;
|
| 74 |
+
jint res;
|
| 75 |
+
|
| 76 |
+
if ((*vm)->GetEnv(vm, (void **)&env, JNI_VERSION_1_6) != JNI_OK)
|
| 77 |
+
return -1;
|
| 78 |
+
|
| 79 |
+
cls = (*env)->FindClass(env, JNIT_CLASS);
|
| 80 |
+
if (cls == NULL)
|
| 81 |
+
return -1;
|
| 82 |
+
|
| 83 |
+
res = (*env)->RegisterNatives(env, cls, funcs, sizeof(funcs)/sizeof(funcs[0]));
|
| 84 |
+
if (res != 0)
|
| 85 |
+
return -1;
|
| 86 |
+
|
| 87 |
+
ares_library_init_jvm(vm);
|
| 88 |
+
return JNI_VERSION_1_6;
|
| 89 |
+
}
|
| 90 |
+
.fi
|
| 91 |
+
Calling the registered function from Java:
|
| 92 |
+
.nf
|
| 93 |
+
public class MyObject {
|
| 94 |
+
static {
|
| 95 |
+
System.loadLibrary("cares");
|
| 96 |
+
}
|
| 97 |
+
|
| 98 |
+
private static native boolean initialize_native(ConnectivityManager
|
| 99 |
+
connectivity_manager);
|
| 100 |
+
|
| 101 |
+
public static boolean initialize(Context context) {
|
| 102 |
+
initialize_native((ConnectivityManager)context.getSystemService(Context.CONNECTIVITY_SERVICE));
|
| 103 |
+
}
|
| 104 |
+
}
|
| 105 |
+
.fi
|
| 106 |
+
Initializing the Connectivity Manager in JNI directly using an Android
|
| 107 |
+
Context. It is assumed the JVM has already been registered through
|
| 108 |
+
\fIJNI_OnLoad\fP.
|
| 109 |
+
.nf
|
| 110 |
+
void initialize(jobject android_context)
|
| 111 |
+
{
|
| 112 |
+
jclass obj_cls = jni_get_class(env, "android/content/Context");
|
| 113 |
+
jmethodID obj_mid = jni_get_method_id(env, obj_cls, "getSystemService", "(Ljava/lang/String;)Ljava/lang/Object;");
|
| 114 |
+
jfieldID fid = (*env)->GetStaticFieldID(env, obj_cls, "CONNECTIVITY_SERVICE", "Ljava/lang/String;");
|
| 115 |
+
jstring str = (*env)->GetStaticObjectField(env, obj_cls, fid);
|
| 116 |
+
connectivity_manager = (*env)->CallObjectMethod(env, android_context, obj_mid, str);
|
| 117 |
+
if (connectivity_manager == NULL)
|
| 118 |
+
return;
|
| 119 |
+
ares_library_init_android(connectivity_manager);
|
| 120 |
+
}
|
| 121 |
+
.fi
|
| 122 |
+
.SH AVAILABILITY
|
| 123 |
+
This function was first introduced in c-ares version 1.15.0.
|
| 124 |
+
.SH SEE ALSO
|
| 125 |
+
.BR ares_library_init (3),
|
| 126 |
+
.BR ares_library_cleanup (3),
|
| 127 |
+
|