   Changelog for the c-ares project. Generated with git2changes.pl

Version 1.29.0 (22 May 2024)

GitHub (22 May 2024)
- [Brad House brought this change]

  1.29.0 release prep (#762)

Brad House (22 May 2024)
- coverity: try to silence warning

- branch main

- clang-format

GitHub (22 May 2024)
- [Brad House brought this change]

  Auto reload config on changes (requires EventThread) (#759)
  
  Automatically detect configuration changes and reload. On systems which
  provide notification mechanisms, use those, otherwise fallback to
  polling. When a system configuration change is detected, it
  asynchronously applies the configuration in order to ensure it is a
  non-blocking operation for any queries which may still be being
  processed.
  
  On Windows, however, changes aren't detected if a user manually
  sets/changes the DNS servers on an interface, it doesn't appear there is
  any mechanism capable of this. We are relying on
  `NotifyIpInterfaceChange()` for notifications.
  
  Fixes Issue: #613
  Fix By: Brad House (@bradh352)

- [David Hotham brought this change]

  const is fine on ares__channel_[un]lock (#758)
  
  at https://github.com/c-ares/c-ares/pull/601#issuecomment-1801935063 you
  chose not to scatter `const` on the public interface because of the plan
  - now realised - to add threading to c-ares, and in the expectation that
  even read operations would need to lock the mutex.
  
  But the threading implementation has a _pointer_ to a mutex inside the
  ares channel and as I understand it, that means that it is just fine to
  mark `ares__channel_lock` (and `ares__channel_unlock`) as taking a
  `const` channel. It is the pointed-to mutex that is not constant, but C
  does not propagate `const`-ness through pointers.
  
  This PR sprinkles const where appropriate on public interfaces.
  
  Fix By: David Hotham (@dimbleby)

Brad House (15 May 2024)
- remove accidentally committed in-development file

- dns name compression write failure
  
  Due to a logic flaw dns name compression writing was not properly implemented
  which would result in the name prefix not being written for a partial match.
  
  Fixes Bug: #757
  Fix By: Brad House (@bradh352)

GitHub (8 May 2024)
- [Brad House brought this change]

  CI: Add Netbsd workflow (#756)
  
  Add NetBSD as a test target for CI.
  
  Fix By: Brad House (@bradh352)

- [Brad House brought this change]

  CI: OpenBSD (#755)
  
  Github actions appears to support building on a few "unsupported"
  platforms these days:
  https://github.com/cross-platform-actions/action
  
  Lets go ahead and add OpenBSD to try to prevent issues like #754
  
  Fix By: Brad House (@bradh352)

- [Volker Schlecht brought this change]

  Revert PR #659 (#754)
  
  As described in https://github.com/c-ares/c-ares/issues/753 the change
  merged with https://github.com/c-ares/c-ares/pull/659 is ill-advised and
  leads to breakage in applications using c-ares on OpenBSD.
  
  See also https://github.com/nodejs/node/issues/52439

Brad House (7 May 2024)
- static analyzer warning from 48e8cd2
  
  Fixes new issue from last commit.

- ares_getnameinfo(): loosen validation on salen
  
  salen validation should be greater than or equal to the required
  storage size.  Its not uncommon to use `struct sockaddr_storage` in
  modern code which is definitely larger than `struct sockaddr_in` and
  on some systems even larger than `struct sockaddr_in6`.
  
  Fixes Issue: #752
  Fix By: Brad House (@bradh352)

- ares_reinit(): reduce locked duration

- add missing copyrights

- manpage: remove AUTHOR section
  
  The current best practices consider the AUTHOR section to be deprecated
  and recommend removing such a section.

- fix endianness from PR #750

GitHub (29 Apr 2024)
- [Brad House brought this change]

  Apple: reimplement DNS configuration reading (#750)
  
  The DNS configuration for apple is stored in the system configuration
  database. Apple does provide an emulated `/etc/resolv.conf` on MacOS
  (but not iOS), it cannot, however, represent the entirety of the DNS
  configuration. Alternatively, libresolv could be used to also retrieve
  some system configuration, but it too is not capable of retrieving the
  entirety of the DNS configuration.
  
  Attempts to use the preferred public API of `SCDynamicStoreCreate()` and
  friends yielded incomplete DNS information. Instead, that leaves some
  apple "internal" symbols from `configd` that we need to access in order
  to get the entire configuration. We can see that we're not the only ones
  to do this as Google Chrome also does:
  https://chromium.googlesource.com/chromium/src/+/HEAD/net/dns/dns_config_watcher_mac.cc
  
  These internal functions are what what`libresolv` and `scutil` use to
  retrieve the dns configuration. Since these symbols are not publicly
  available, we will dynamically load the symbols from `libSystem` and
  import the `dnsinfo.h` private header extracted from:
  https://opensource.apple.com/source/configd/configd-1109.140.1/dnsinfo/dnsinfo.h
  
  Fix By: Brad House (@bradh352)

- [Oliver Welsh brought this change]

  Add observability into DNS server health via a server state callback, invoked whenever a query finishes (#744)
  
  **Summary**
  
  This PR adds a server state callback that is invoked whenever a query to
  a DNS server finishes.
  
  The callback is invoked with the server details (as a string), a boolean
  indicating whether the query succeeded or failed, flags describing the
  query (currently just indicating whether TCP or UDP was used), and
  custom userdata.
  
  This can be used by user applications to gain observability into DNS
  server health and usage. For example, alerts when a DNS server
  fails/recovers or metrics to track how often a DNS server is used and
  responds successfully.
  
  **Testing**
  
  Three new regression tests `MockChannelTest.ServStateCallback*` have
  been added to test the new callback in different success/failure
  scenarios.
  
  Fix By: Oliver Welsh (@oliverwelsh)

Brad House (25 Apr 2024)
- ares_init_options() fix crash on misuse of event thread options
  
  If an invalid event thread system was provided, it would crash during cleanup due to a NULL pointer dereference.
  
  Fixes Issue: #749
  Fix By: Brad House (@bradh352)

GitHub (22 Apr 2024)
- [Oliver Welsh brought this change]

  Improve reliability in the server retry delay regression tests (#747)
  
  Improve reliability in the server retry delay regression tests by
  increasing the retry delay and sleeping for a little more than the retry
  delay when attempting to force retries.
  
  This helps to account for unreliable timing (e.g. NTP slew)
  intermittently breaking pipelines.
  
  Fix By: Oliver Welsh (@oliverwelsh)

- [Jiwoo Park brought this change]

  cmake: Android requires C99 (#748)
  
  I tried to build c-ares using CMake with the latest Android NDK
  (r26/27), but failed as follows.
  
  ```
  Building C object _deps/c-ares-source-build/src/lib/CMakeFiles/c-ares.dir/Debug/ares__buf.c.o
  FAILED: _deps/c-ares-source-build/src/lib/CMakeFiles/c-ares.dir/Debug/ares__buf.c.o
  
  In file included from c-ares/src/lib/ares__buf.c:27:
  In file included from c-ares/include/ares.h:85:
  In file included from Android/sdk/ndk/27.0.11718014/toolchains/llvm/prebuilt/darwin-x86_64/sysroot/usr/include/netinet/in.h:36:
  In file included from Android/sdk/ndk/27.0.11718014/toolchains/llvm/prebuilt/darwin-x86_64/sysroot/usr/include/linux/in.h:231:
  In file included from Android/sdk/ndk/27.0.11718014/toolchains/llvm/prebuilt/darwin-x86_64/sysroot/usr/include/aarch64-linux-android/asm/byteorder.h:12:
  In file included from Android/sdk/ndk/27.0.11718014/toolchains/llvm/prebuilt/darwin-x86_64/sysroot/usr/include/linux/byteorder/little_endian.h:17:
  Android/sdk/ndk/27.0.11718014/toolchains/llvm/prebuilt/darwin-x86_64/sysroot/usr/include/linux/swab.h:28:8: error: unknown type name 'inline'
     28 | static inline __attribute__((__const__)) __u32 __fswahw32(__u32 val) {
        |        ^
  Android/sdk/ndk/27.0.11718014/toolchains/llvm/prebuilt/darwin-x86_64/sysroot/usr/include/linux/swab.h:28:47: error: expected ';' after top level declarator
     28 | static inline __attribute__((__const__)) __u32 __fswahw32(__u32 val) {
        |                                               ^
  ```
  
  It looks like the NDK recently added C99 code containing `inline`
  functions, but c-ares is setting the `C_STANDARD` CMake property to C90.
  
  Fix By: Jiwoo Park (@jimmy-park)

- [Aviv Keller brought this change]

  Use gender-neutral language in SECURITY.md (#746)
  
  This PR updates the SECURITY.md file to use more gender-inclusive
  language.
  
  Fix By: Aviv Keller (@RedYetiDev)

Brad House (15 Apr 2024)
- check for spurious wakeup

- ares_queue_wait_empty() does not honor timeout_ms >= 0
  
  There is a missing break statement in the case that timeout_ms >= 0
  leading to a possible infinite loop.
  
  Fixes Issue: #742
  Fix By: Brad House (@bradh352)

GitHub (14 Apr 2024)
- [Oliver Welsh brought this change]

  Add server failover retry behavior, where failed servers are retried with small probability after a minimum delay (#731)
  
  **Summary**
  
  By default c-ares will select the server with the least number of
  consecutive failures when sending a query. However, this means that if a
  server temporarily goes down and hits failures (e.g. a transient network
  issue), then that server will never be retried until all other servers
  hit the same number of failures.
  
  This is an issue if the failed server is preferred to other servers in
  the list. For example if a primary server and a backup server are
  configured.
  
  This PR adds new server failover retry behavior, where failed servers
  are retried with small probability after a minimum delay has passed. The
  probability and minimum delay are configurable via the
  `ARES_OPT_SERVER_FAILOVER` option. By default c-ares will use a
  probability of 10% and a minimum delay of 5 seconds.
  
  In addition, this PR includes a small change to always close out
  connections to servers which have hit failures, even with
  `ARES_FLAG_STAYOPEN`. It's possible that resetting the connection can
  resolve some server issues (e.g. by resetting the source port).
  
  **Testing**
  
  A new set of regression tests have been added to test the new server
  failover retry behavior.
  
  Fixes Issue: #717
  Fix By: Oliver Welsh (@oliverwelsh)

Brad House (4 Apr 2024)
- MacOS/iOS: Apple does not allow users to configure DNS resolution timeouts or number of retries as Apple themselves uses dynamic/algorithmic values for their own resolver, so we should disable reading these static dummy values.

GitHub (30 Mar 2024)
- [Chenyu Yang brought this change]

  CMake: remove duplicate checks for sys/random.h (#740)
  
  Fix By: Chenyu Yang (@Ch3nYuY)

Version 1.28.1 (30 Mar 2024)

GitHub (30 Mar 2024)
- [Brad House brought this change]

  release prep for 1.28.1 (#739)

Brad House (30 Mar 2024)
- ares_search() and ares_getaddrinfo() resolution fails if no search domains
  
  Due to an error in creating the list of domains to search, if no search
  domains were configured, resolution would fail.
  
  Fixes Issue: #737
  Fix By: Brad House (@bradh352)

- typo

Version 1.28.0 (28 Mar 2024)

GitHub (28 Mar 2024)
- [Brad House brought this change]

  Allow configuration value for NDots to be zero (#735)
  
  As per Issue #734 some people use `ndots:0` in their configuration which
  is allowed by the system resolver but not by c-ares. Add support for
  `ndots:0` and add a test case to validate this behavior.
  
  Fixes Issue: #734
  Fix By: Brad House (@bradh352)

Brad House (27 Mar 2024)
- typo

GitHub (27 Mar 2024)
- [Brad House brought this change]

  1.28.0 release prep (#733)

Brad House (27 Mar 2024)
- CMake: don't overwrite global required libraries/definitions/includes
  
  When chain building c-ares, global settings were being unset which
  could lead to build problems.
  
  Fixes Issue: #729
  Fix By: Brad House (@bradh352)

- remove tests that have been disabled forever

- clang-format

- ares_search_dnsrec() takes a const

- sonarcloud: clean up some minor codesmells

GitHub (26 Mar 2024)
- [Brad House brought this change]

  mark deprecated functions as such (#732)
  
  Multiple functions have been deprecated over the years, annotate them
  with attribute deprecated.
  
  When possible show a message about their replacements.
  
  This is a continuation/completion of PR #706
  
  Fix By: Cristian Rodríguez (@crrodriguez)

Brad House (26 Mar 2024)
- silence clang static analyzer

- silence coverity

- coverity: fix mostly bogus warnings

- fix missing doc

GitHub (25 Mar 2024)
- [Brad House brought this change]

  Rework internals to pass around `ares_dns_record_t` instead of binary data (#730)
  
  c-ares has historically passed around raw dns packets in binary form.
  Now that we have a new parser, and messages are already parsed
  internally, lets pass around that parsed message rather than requiring
  multiple parse attempts on the same message. Also add a new
  `ares_send_dnsrec()` and `ares_query_dnsrec()` similar to
  `ares_search_dnsrec()` added with PR #719 that can return the pointer to
  the `ares_dns_record_t` to the caller enqueuing queries and rework
  `ares_search_dnsrec()` to use `ares_send_dnsrec()` internally.
  
  Fix By: Brad House (@bradh352)

Brad House (23 Mar 2024)
- tests: mockserver is local, shorten timeouts to make test cases run faster to use less CI resources

- appveyor: disable UWP builds until MSVC version is updated in base image

GitHub (21 Mar 2024)
- [Faraz brought this change]

  Include netinet6/in6.h (#728)
  
  On some platforms, "netinet6/in6.h" is not included by "netinet/in.h"
  and needs to be included separately.
  
  Fix By: Faraz (@farazrbx)

- [Oliver Welsh brought this change]

  Add function ares_search_dnrec() to search for records using the new DNS record parser (#719)
  
  This PR adds a new function `ares_search_dnsrec()` to search for records
  using the new DNS record parser.
  
  The function takes an arbitrary DNS record object to search (that must
  represent a query for a single name). The function takes a new callback
  type, `ares_callback_dnsrec`, that is invoked with a parsed DNS record
  object rather than the raw buffer(+length).
  
  The original motivation for this change is to provide support for
  [draft-kaplan-enum-sip-routing-04](https://datatracker.ietf.org/doc/html/draft-kaplan-enum-sip-routing-04);
  when routing phone calls using an ENUM server, it can be useful to
  include identifying source information in an OPT RR options value, to
  help select the appropriate route for the call. The new function allows
  for more customisable searches like this.
  
  **Summary of code changes**
  
  A new function `ares_search_dnsrec()` has been added and exposed.
  Moreover, the entire `ares_search_int()` internal code flow has been
  refactored to use parsed DNS record objects and the new DNS record
  parser. The DNS record object is passed through the `search_query`
  structure by encoding/decoding to/from a buffer (if multiple search
  domains are used). A helper function `ares_dns_write_query_altname()` is
  used to re-write the DNS record object with a new query name (used to
  append search domains).
  
  `ares_search()` is now a wrapper around the new internal code, where the
  DNS record object is created based on the name, class and type
  parameters.
  
  The new function uses a new callback type, `ares_callback_dnsrec`. This
  is invoked with a parsed DNS record object. For now, we convert from
  `ares_callback` to this new type using `ares__dnsrec_convert_cb()`.
  
  Some functions that are common to both `ares_query()` and
  `ares_search()` have been refactored using the new DNS record parser.
  See `ares_dns_record_create_query()` and
  `ares_dns_query_reply_tostatus()`.
  
  **Testing**
  
  A new FV has been added to test the new function, which searches for a
  DNS record containing an OPT RR with custom options value.
  
  As part of this, I needed to enhance the mock DNS server to expect
  request text (and assert that it matches actual request text). This is
  because the FV needs to check that the request contains the correct OPT
  RR.
  
  **Documentation**
  
  The man page docs have been updated to describe the new feature.
  
  **Futures**
  
  In the future, a new variant of `ares_send()` could be introduced in the
  same vein (`ares_send_dnsrec()`). This could be used by
  `ares_search_dnsrec()`. Moreover, we could migrate internal code to use
  `ares_callback_dnsrec` as the default callback.
  
  This will help to make the new DNS record parser the norm in C-Ares.
  
  ---------
  
  Co-authored-by: Oliver Welsh (@oliverwelsh)

- [Brad House brought this change]

  Replace configuration file parsers with memory-safe parser (#725)
  
  Rewrite configuration parsers using new memory safe parsing functions.
  After CVE-2024-25629 its obvious that we need to prioritize again on
  getting all the hand written parsers with direct pointer manipulation
  replaced. They're just not safe and hard to audit. It was yet another
  example of 20+yr old code having a memory safety issue just now coming
  to light.
  
  Though these parsers are definitely less efficient, they're written with
  memory safety in mind, and any performance difference is going to be
  meaningless for something that only happens once a while.
  
  Fix By: Brad House (@bradh352)

Brad House (12 Mar 2024)
- skip ubsan/asan on debian arm64 due to the compiler getting killed

- ares_init potential memory leak
  
  If initializing using default settings fails, there may be a memory leak of
  search domains that were set by system configuration.
  
  Fixes Issue: #724
  Fix By: Brad House (@bradh352)

GitHub (12 Mar 2024)
- [Faraz Fallahi brought this change]

  simple implementation for isascii where stdlib isascii is not available (#721)
  
  Some platforms don't have the isascii() function.  Implement as a macro.
  
  Fix By: Faraz Fallahi (@fffaraz)

Brad House (11 Mar 2024)
- Doxygen: fix typos
  
  Fix reported typos in doxygen-style comments.
  
  Fixes Issue: #722
  Credit: @dzalyalov88

- CI: update freebsd image

- CMake: Fix Chain building if CMAKE runtime paths not set
  
  This fixes issues created by #708
  
  Fix By: Brad House (@bradh352)

- silence benign warnings

- Remove acountry completely from code, including manpage
  
  Since acountry cannot be restored due to nerd.dk being decommissioned,
  we should completely remove the manpage and source.  This also
  will resolve issue #718.
  
  Fixes Issue: #718
  Fix By: Brad House (@bradh352)

Version 1.27.0 (22 Feb 2024)

GitHub (22 Feb 2024)
- [Brad House brought this change]

  Release 1.27.0 (#715)
  
  release prep for 1.27.0 release

- [Brad House brought this change]

  Merge pull request from GHSA-mg26-v6qh-x48q

- [Oliver Welsh brought this change]

  Add flag to not use a default local named server on channel initialization (#713)
  
  Hello, I work on an application for Microsoft which uses c-ares to
  perform DNS lookups. We have made some minor changes to the library over
  time, and would like to contribute these back to the project in case
  they are useful more widely. This PR adds a new channel init flag,
  described below.
  
  Please let me know if I can include any more information to make this PR
  better/easier for you to review. Thanks!
  
  **Summary**
  When initializing a channel with `ares_init_options()`, if there are no
  nameservers available (because `ARES_OPT_SERVERS` is not used and
  `/etc/resolv.conf` is either empty or not available) then a default
  local named server will be added to the channel.
  
  However in some applications a local named server will never be
  available. In this case, all subsequent queries on the channel will
  fail.
  
  If we know this ahead of time, then it may be preferred to fail channel
  initialization directly rather than wait for the queries to fail. This
  gives better visibility, since we know that the failure is due to
  missing servers rather than something going wrong with the queries.
  
  This PR adds a new flag `ARES_FLAG_NO_DFLT_SVR`, to indicate that a
  default local named server should not be added to a channel in this
  scenario. Instead, a new error `ARES_EINITNOSERVER` is returned and
  initialization fails.
  
  **Testing**
  I have added 2 new FV tests:
  - `ContainerNoDfltSvrEmptyInit` to test that initialization fails when
  no nameservers are available and the flag is set.
  - `ContainerNoDfltSvrFullInit` to test that initialization still
  succeeds when the flag is set but other nameservers are available.
  
  Existing FVs are all passing.
  
  **Documentation**
  I have had a go at manually updating the docs to describe the new
  flag/error, but couldn't see any contributing guidance about testing
  this. Please let me know if you'd like anything more here.
  
  ---------
  
  Fix By: Oliver Welsh (@oliverwelsh)

Brad House (18 Feb 2024)
- badge should be only main branch

- put logo in readme

- clang-format

GitHub (17 Feb 2024)
- [Brad House brought this change]

  Add ares_queue_active_queries() (#712)
  
  Add a function to request the number of active queries from an ares
  channel. This will return the number of inflight requests to dns
  servers. Some functions like `ares_getaddrinfo()` when using `AF_UNSPEC`
  may enqueue multiple queries which will be reflected in this count.
  
  In the future, if we implement support for queuing (e.g. for throttling
  purposes), and/or implement support for tracking user-requested queries
  (e.g. for cancelation), we can provide additional functions for
  inspecting those queues.
  
  Fix By: Brad House (@bradh352)

- [Vojtěch Vobr brought this change]

  fix leaking DNS suffix search list on Windows (#711)
  
  ares__strsplit provides a newly allocated buffer, so suffix list in
  line variable isn't referenced anymore. Related ares_free seems to
  have gone missing during refactoring made in #594
  
  Fix By: Vojtěch Vobr (@vojtechvobr)

- [Brad House brought this change]

  Add ares_queue_wait_empty() for use with EventThreads (#710)
  
  It may be useful to wait for the queue to be empty under certain conditions (mainly test cases), expose a function to efficiently do this and rework test cases to use it.
  
  Fix By: Brad House (@bradh352)

- [Cheng Zhao brought this change]

  Fix warning about ignoring result of write (#709)
  
  Fix the compiler warning from clang:
  
  ```
  ares_event_wake_pipe.c:120:3: error: ignoring return value of function declared with 'warn_unused_result' attribute [-Werror,-Wunused-result]
    120 |   write(p->filedes[1], "1", 1);
        |   ^~~~~ ~~~~~~~~~~~~~~~~~~~~~
  1 error generated.
  ```
  
  Fix By: Cheng Zhao (@zcbenz)

Brad House (5 Feb 2024)
- CMake: don't override target output locations if not top-level
  
  CMake was unconditionally setting output locations globally, but
  it should not do that if it is not the top-level project (e.g.
  during chain building).  Detect this fact and only set the output
  location when top level.
  
  Fixes Issue: #708
  Fix By: Anthony Alayo (@anthonyalayo)

- make docs match PR #705

GitHub (31 Jan 2024)
- [Cristian Rodríguez brought this change]

  lower EDNSPACKETSZ to 1232 (#705)
  
  In 2020, it was agreed this is optimal maximum size and all
  major server software was updated to reflect this.
  
  see https://www.dnsflagday.net/2020/#faq
  
  Fix By: Cristian Rodríguez (@crrodriguez)

Brad House (30 Jan 2024)
- fix version

- fix typo

- bad symlink

- attempt to fix pkgconfig on windows for static builds

GitHub (28 Jan 2024)
- [Andriy Utkin brought this change]

  docs/ares_init_options.3: fix args in analogy (#701)
  
  Fix By: Andriy Utkin <hello@autkin.net>

- [Brad House brought this change]

  sonarcloud: fix minor codesmells (#702)
  
  Fix minor codesmells, mostly related to missing 'const' in the new event system.
  
  Fix By: Brad House (@bradh352)

Brad House (26 Jan 2024)
- remove outdated copyright text

- spelling

- sanity check GTest includes GMock component

GitHub (26 Jan 2024)
- [Brad House brought this change]

  build-time disabled threads breaks c-ares (#700)
  
  Regression introduced in 1.26.0, building c-ares with threading disabled results in ares_init{_options}() failing.
  
  Also adds a new CI test case to prevent this regression in the future.
  
  Fixes Bug: #699
  Fix By: Brad House (@bradh352)

Version 1.26.0 (25 Jan 2024)

Brad House (25 Jan 2024)
- clusterfuzz: enforce maximum DNS packet size due to long parser time

GitHub (24 Jan 2024)
- [Brad House brought this change]

  Release prep for c-ares 1.26.0 (#698)
  
  release prep

Brad House (24 Jan 2024)
- adig: Differentiate between internal and server error
  
  Should not output "Got answer" if there was no answer from the
  server, instead should just output the internal error.
  
  Fix By: Gisle Vanem (@gvanem)

GitHub (24 Jan 2024)
- [Brad House brought this change]

  Event Subsystem: No longer require integrators to have their own (#696)
  
  This PR implements an event thread to process all events on file descriptors registered by c-ares. Prior to this feature, integrators were required to understand the internals of c-ares and how to monitor file descriptors and timeouts and process events.
  
  Implements OS-specific efficient polling such as epoll(), kqueue(), or IOCP, and falls back to poll() or select() if otherwise unsupported. At this point, it depends on basic threading primitives such as pthreads or windows threads.
  
  If enabled via the ARES_OPT_EVENT_THREAD option passed to ares_init_options(), then socket callbacks cannot be used.
  
  Fixes Bug: #611
  Fix By: Brad House (@bradh352)

- [Erik Lax brought this change]

  Added flags to are_dns_parse to force RAW packet parsing (#693)
  
  This pull request adds six flags to instruct the parser under various circumstances to skip parsing of the returned RR records so the raw data can be retrieved.
  
  Fixes Bug: #686
  Fix By: Erik Lax (@eriklax)

- [Brad House brought this change]

  Autotools allow make to override CFLAGS/CPPFLAGS/CXXFLAGS (#695)
  
  The previous build system allowed overwriting of CFLAGS/CPPFLAGS/CXXFLAGS on the make command line. Switch to using AM_CFLAGS/AM_CPPFLAGS/AM_CXXFLAGS when we set our own flags for building which ensures they are kept even when a user tries to override.
  
  Fixes Bug: #694
  Fix By: Brad House (@bradh352)

Brad House (16 Jan 2024)
- fix doxygen typo

GitHub (16 Jan 2024)
- [Brad House brought this change]

  man ares_fds(3): mark as deprecated and add explanation (#691)
  
  ares_fds(3) is not safe to use, mark as deprecated.
  
  Fixes Issue: #687
  Fix By: Brad House (@bradh352)

- [Brad House brought this change]

  autotools: fix building for 32bit windows due to stdcall symbol mangling (#689)
  
  Use AC_CHECK_DECL not AC_CHECK_FUNCS, while this doesn't do a linkage test, it just makes sure the headers define it, this is the only thing without a complex workaround on Windows that will do what we need.
  
  See:
  
  https://github.com/msys2/msys2/wiki/Porting/f87a222118b1008ebc166ad237f04edb759c8f4c#calling-conventions-stdcall-and-autotools
  
  and
  
  https://lists.gnu.org/archive/html/autoconf/2013-05/msg00085.html
  
  and for a more complex workaround, we'd need to use AC_LINK_IFELSE like:
  
  https://mailman.videolan.org/pipermail/vlc-devel/2015-March/101802.html
  
  which would require we check each individually and provide function arguments for the test.  I don't think that is worthwhile.
  
  Fixes Issue: #688
  Fix By: Brad House (@bradh352)

- [Brad House brought this change]

  Do not sanity check RR Name vs Question (#685)
  
  It appears as though we should never sanity check the RR name vs the question name as some DNS servers may return results for alias records.
  
  Fixes Bug: #683
  Fix By: Brad House (@bradh352)

- [Brad House brought this change]

  no reason to include sys/random.h all the time (#684)
  
  External integrations don't need sys/random.h in order to compile, remove the dependency.  Try to fix building on legacy MacOS versions.
  
  Fixes Issue: #682
  Fix By: Brad House (@bradh352)

- [Gregor Jasny brought this change]

  cmake: improve some include related code (#680)
  
  * cmake: avoid warning about non-existing include dir
  
  In the Debian build logs I noticed the following warning:
  cc1: warning: /build/c-ares-1.25.0/test/include: No such file or directory [-Wmissing-include-dirs]
  
  This happened because ${CMAKE_INSTALL_INCLUDEDIR} had been added to
  caresinternal. I believe it has been copied from the "real" lib
  where it's used in the INSTALL_INTERFACE context. But because
  caresinternal is never installed we don't need that include here.
  
  * cmake: drop CARES_TOPLEVEL_DIR variable
  
  The CARES_TOPLEVEL_DIR variable is the same as the automatically
  created PROJECT_SOURCE_DIR variable. Let's stick to the official
  one. Also because it is already used at places where CARES_TOPLEVEL_DIR
  is used as well.
  
  Fix By: Gregor Jasny (@gjasny)

Brad House (5 Jan 2024)
- test: fix outdated license headers

- RELEASE-NOTES -> RELEASE-NOTES.md

- update format slightly

- update release notes format

Version 1.25.0 (2 Jan 2024)

GitHub (2 Jan 2024)
- [Brad House brought this change]

  1.25.0 release prep (#676)

Brad House (31 Dec 2023)
- tests: replace google DNS with CloudFlare for reverse lookups as google's servers stopped responding properly

- OSSFuzz: it assumes autotools builds a static library by default, which means the old autotools must have done that even though there were comments saying it wasn't.  Disable static by default on Windows however since it can't build both simultaneously.

- autotools: update logic for building tests to provide more feedback

- set winver consistently across build systems

GitHub (28 Dec 2023)
- [Brad House brought this change]

  Autotools: rework to simplify and fix recent issues (#674)
  
  Completely rework the autotools build system, issues have cropped up due to the complexity and could cause issues on even semi-modern Linux systems (Ubuntu 20.04 for example).
  
  Changes include:
  
  Remove all curl/xc/cares m4 helper files, they go overboard on detections of functions and datatypes. Go back to more plain autoconf macros as they've come a long way over the years.
  Use known systems and heuristics to determine datatypes for functions like send() and recv(), rather than the error prone detection which required thousands of permutations and might still get it wrong.
  Remove unneeded configure arguments like --enable-debug or --enable-optimize, its more common for people to simply pass their own CFLAGS on the command line.
  Only require CARES_STATICLIB definition on Windows static builds, its not necessary ever for other systems, even when hiding non-public symbols.
  Remove some function and definition detections that were never used in c-ares
  The test framework is now embedded into the toplevel configure system, there was no need to chain build the test system as it is never built externally to c-ares.
  As a side-effect of the changes, a configure run completes in about 25% of the original time.
  
  This has been tested on various Linux distributions (of varying age), FreeBSD, MacOS, Windows (via MSYS2 with Mingw), and Solaris10/11 (by @dfandrich), AIX 7.3 (by @dfandrich). It is not unlikely that this may have broken more esoteric or legacy systems, and we'll likely need to be ready to accept bug reports and patches, but it has removed over 10k lines of build system code. It is very likely any issues that crop up will add far fewer lines of code to fix such systems.
  
  Fixes Bug: #670
  Fix By: Brad House (@bradh352)

Brad House (22 Dec 2023)
- docs: host -> ip
  
  fix mismatched documentation stating host instead of ip
  
  Fix By: Brad House (@bradh352)

GitHub (21 Dec 2023)
- [Brad House brought this change]

  Old MacOS SDKs require you include sys/socket.h before net/if.h (#673)
  
  Old MacOS SDKs (like 10.8) require you include `sys/socket.h` before you include `net/if.h` as reported by MacPorts.  Using a new SDK but with setting the macos target version does not have the same issue.
  
  Fixes Issue: #672
  Fix By: Brad House (@bradh352)

- [Brad House brought this change]

  Autotools warning fixes (#671)
  
  * get rid of clashes with curl namespace
  * remove warnings due to deprecated functionality
  * reorder some macro calls to get rid of warnings due to being called in the wrong order
  
  Fix By: Brad House (@bradh352)

Brad House (19 Dec 2023)
- clang-format

- ares_strsplit() rewrite as wrapper around ares__buf_split()
  
  We want to limit as much as possible any hand written parsers.
  ares__buf_split() uses the new memory-safe parsing routines.  This
  adds a couple of additional flags to remove duplicates which the
  existing split code did.
  
  Fix By: Brad House (@bradh352)

- clang-format

- sonarcloud: const

- Connection failure should increment server failure count first
  
  In order to be sure a different server is chosen on the next query,
  a read error should result in the failure count being updated
  first before requeing the request to a different server.
  
  Fix By: Brad House (@bradh352)

GitHub (18 Dec 2023)
- [Brad House brought this change]

  ahost should use ares_getaddrinfo() these days (#669)
  
  ahost wasn't printing both ipv4 and ipv6 addresses. This day and age, it really should.
  
  This PR also adds the ability to specify the servers to use.
  
  Fix By: Brad House (@bradh352)

Brad House (17 Dec 2023)
- Fix bad stub for ares__iface_ips_enumerate()
  
  If the ability to enumerate interface ip addresses does not exist
  on a system, the stub function contained the wrong prototype.
  
  Fixes Bug: #668
  Fix By: Brad House (@bradh352)

GitHub (17 Dec 2023)
- [Gregor Jasny brought this change]

  Fix minor warnings and documentation typos (#666)
  
  Build warnings could be seen [here](https://buildd.debian.org/status/fetch.php?pkg=c-ares&arch=arm64&ver=1.24.0-1&stamp=1702826366&raw=0) [origin](https://buildd.debian.org/status/package.php?p=c-ares)
  
  Fix By: Gregor Jasny (@gjasny)

- [Brad House brought this change]

  CI: Add Alpine Linux and old Ubuntu (#667)
  
  Alpine linux doesn't use glibc but instead musl c, so provides a good alternative test bed. We are also adding the oldest non-EOL ubuntu version so we can test against older linux variants to prevent surprises.
  
  This patch also migrates more tests to use cmake and ninja in order to reduce overall build times as we seem to run out of credits on Cirrus-CI pretty quickly.
  
  Fix By: Brad House (@bradh352)

Brad House (17 Dec 2023)
- fix support with older google test versions

- getrandom() may require sys/random.h on some systems
  
