Repository: Unidata/netcdf-c
Pull request #2969 (2024-08-08 11:01:13)

[S3] Parse AWS configuration with support for profile section
Hello :wave:!

I've faced a **minor problem** on my setup when I have a profile section on the configuration file [1] (valid with aws tools). In such case the netcdf library fails to load the AWS config, not critical but not obvious.

This is a quick fix I did for my myself, but looking at the parser and aws config [specification](https://docs.aws.amazon.com/cli/v1/userguide/cli-configure-files.html) I see parsing problems with:
 - Token delimiter characters in the values
 - Support for comments 
 - Multiline service configuration
 
I'm not sure to which extend you want to support loading the AWS config when the building with the internal S3 implementation.

Thanks!

[1]
`~/.aws/credentials`
```
[default]
aws_access_key_id=123
aws_secret_access_key=456

[user1]
aws_access_key_id=123
aws_secret_access_key=789
```

`~/.aws/config`
```
[default]
region=us-west-2
output=json

[profile user1]
region=us-east-1
output=text
```


Patch:
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3a644ef58..891088789 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -16,27 +16,6 @@ project(netCDF
   VERSION 4.9.3
 )
 
-#####
-# Version Info:
-#
-# Release Version
-# Library Version
-# SO Version
-#
-# SO Version is computed from library version. See:
-# http://www.gnu.org/software/libtool/manual/libtool.html#Libtool-versioning
-#####
-
-set(NC_VERSION_NOTE "-rc1")
-set(netCDF_VERSION ${PROJECT_VERSION}${NC_VERSION_NOTE})
-set(VERSION ${netCDF_VERSION})
-set(NC_VERSION ${netCDF_VERSION})
-set(PACKAGE_VERSION ${VERSION})
-
-# These values should match those in configure.ac
-set(netCDF_LIB_VERSION 22)
-set(netCDF_SO_VERSION 22)
-
 #Add custom CMake Module
 list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules" "${PROJECT_SOURCE_DIR}/cmake")
 
@@ -72,7 +51,26 @@ endif()
 add_library(netcdf)
 add_library(netCDF::netcdf ALIAS netcdf)
 
+#####
+# Version Info:
+#
+# Release Version
+# Library Version
+# SO Version
+#
+# SO Version is computed from library version. See:
+# http://www.gnu.org/software/libtool/manual/libtool.html#Libtool-versioning
+#####
+
+set(NC_VERSION_NOTE "-development")
+set(netCDF_VERSION ${PROJECT_VERSION}${NC_VERSION_NOTE})
+set(VERSION ${netCDF_VERSION})
+set(NC_VERSION ${netCDF_VERSION})
+set(PACKAGE_VERSION ${VERSION})
 
+# These values should match those in configure.ac
+set(netCDF_LIB_VERSION 19)
+set(netCDF_SO_VERSION 19)
 
 # Version of the dispatch table. This must match the value in
 # configure.ac.
@@ -738,18 +736,13 @@ if(NOT WIN32)
 endif()
 
 # Options for S3 Support
-#option(NETCDF_ENABLE_S3 "Enable S3 support." OFF)
-option(NETCDF_ENABLE_S3_AWS "Enable S3 support via AWS-CPP-SDK" OFF)
+option(NETCDF_ENABLE_S3 "Enable S3 support." OFF)
 option(NETCDF_ENABLE_S3_INTERNAL "Enable S3 Internal support." OFF)
-
-cmake_dependent_option(NETCDF_ENABLE_S3 "Enable S3 Support" ON "NETCDF_ENABLE_S3_AWS OR NETCDF_ENABLE_S3_INTERNAL" OFF)
-
-option(NETCDF_ENABLE_NCZARR_S3 "Enable NCZarr S3 support; Deprecated in favor of NETCDF_ENABLE_S3" ${NETCDF_ENABLE_S3})
+option(NETCDF_ENABLE_NCZARR_S3 "Enable NCZarr S3 support; Deprecated in favor of NETCDF_ENABLE_S3" OFF)
 
 if(NOT NETCDF_ENABLE_REMOTE_FUNCTIONALITY)
   set(NETCDF_ENABLE_S3 OFF CACHE BOOL "" FORCE)
   set(NETCDF_ENABLE_S3_INTERNAL OFF CACHE BOOL "" FORCE)
-  set(NETCDF_ENABLE_S3_AWS OFF CACHE BOOL "" FORCE)
   set(NETCDF_ENABLE_NCZARR_S3 OFF CACHE BOOL "" FORCE)
 endif()
 
@@ -1315,7 +1308,6 @@ CHECK_FUNCTION_EXISTS(_filelengthi64 HAVE_FILE_LENGTH_I64)
 CHECK_FUNCTION_EXISTS(mmap HAVE_MMAP)
 CHECK_FUNCTION_EXISTS(mremap HAVE_MREMAP)
 CHECK_FUNCTION_EXISTS(fileno HAVE_FILENO)
-CHECK_FUNCTION_EXISTS(H5Literate2 HAVE_H5LITERATE2)
 
 CHECK_FUNCTION_EXISTS(clock_gettime  HAVE_CLOCK_GETTIME)
 CHECK_SYMBOL_EXISTS("struct timespec" "time.h" HAVE_STRUCT_TIMESPEC)
@@ -1539,7 +1531,10 @@ endif()
 # STATIC_DEFINE netcdf_BUILT_AS_STATIC
 #)
 
-
+#####
+# Build doxygen documentation, if need be.
+#####
+add_subdirectory(docs)
 
 ##
 # Brute force, grab all of the dlls from the dependency directory,
@@ -1810,12 +1805,6 @@ set(abs_top_builddir "${CMAKE_CURRENT_BINARY_DIR}")
 set(abs_top_srcdir "${CMAKE_CURRENT_SOURCE_DIR}")
 configure_file(${CMAKE_CURRENT_SOURCE_DIR}/test_common.in ${CMAKE_CURRENT_BINARY_DIR}/test_common.sh @ONLY NEWLINE_STYLE LF)
 
-#####
-# Build doxygen documentation, if need be.
-# This must come after setting top_builddir, etc.
-#####
-add_subdirectory(docs)
-
 ####
 # Build s3cleanup.sh and s3gc.sh
 #####
diff --git a/README.md b/README.md
index 3253f6eb6..9f99ded0e 100644
--- a/README.md
+++ b/README.md
@@ -57,9 +57,7 @@ Copyright and licensing information can be found [here](https://www.unidata.ucar
 To install the netCDF-C software, please see the file INSTALL in the
 netCDF-C distribution, or the (usually more up-to-date) document:
 
-* [Building NetCDF with CMake](https://docs.unidata.ucar.edu/netcdf-c/current/netCDF-CMake.html)
-* [Building NetCDF with Autoconf/Automake/Libtool](https://docs.unidata.ucar.edu/netcdf-c/current/netCDF-autotools.html)
-* [Building or Getting Binaries for NetCDF on Windows](https://docs.unidata.ucar.edu/netcdf-c/current/winbin.html)
+* [Building NetCDF](https://docs.unidata.ucar.edu/netcdf-c/current/winbin.html)
 
 ### Documentation
 A language-independent User's Guide for netCDF, and some other
diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md
index 61de9da52..12bfa7bda 100644
--- a/RELEASE_NOTES.md
+++ b/RELEASE_NOTES.md
@@ -7,17 +7,11 @@ This file contains a high-level description of this package's evolution. Release
 
 ## 4.9.3 - TBD
 
-* Provide better documentation for the .rc file mechanism and API. See [Github #????](https://github.com/Unidata/netcdf-c/pull/????) for more information.
-* Convert NCZarr V2 to store all netcdf-4 specific info as attributes. This improves interoperability with other Zarr implementations by no longer using non-standard keys. The price to be paid is that lazy attribute reading cannot be supported. See [Github #2836](https://github.com/Unidata/netcdf-c/pull/2936) for more information.
-* Cleanup the option code for NETCDF_ENABLE_SET_LOG_LEVEL\[_FUNC\] See [Github #2931](https://github.com/Unidata/netcdf-c/pull/2931) for more information.
-* 
-### Release Candidate 1 - July 26, 2024
-
 * Convert NCZarr V2 to store all netcdf-4 specific info as attributes. This improves interoperability with other Zarr implementations by no longer using non-standard keys. The price to be paid is that lazy attribute reading cannot be supported. See [Github #2836](https://github.com/Unidata/netcdf-c/issues/2936) for more information.
 * Cleanup the option code for NETCDF_ENABLE_SET_LOG_LEVEL\[_FUNC\] See [Github #2931](https://github.com/Unidata/netcdf-c/issues/2931) for more information.
 * Fix duplicate definition when using aws-sdk-cpp. See [Github #2928](https://github.com/Unidata/netcdf-c/issues/2928) for more information.
-* Cleanup various obsolete options and do some code refactoring. See [Github #2926](https://github.com/Unidata/netcdf-c/pull/2926) for more information.
-* Convert the Zarr-related ENABLE_XXX options to NETCDF_ENABLE_XXX options (part of the cmake overhaul). See [Github #2923](https://github.com/Unidata/netcdf-c/pull/2923) for more information.
+* Cleanup various obsolete options and do some code refactoring. See [Github #2926](https://github.com/Unidata/netcdf-c/issues/2926) for more information.
+* Convert the Zarr-related ENABLE_XXX options to NETCDF_ENABLE_XXX options (part of the cmake overhaul). See [Github #2923](https://github.com/Unidata/netcdf-c/issues/2923) for more information.
 * Refactor macro `_FillValue` to `NC_FillValue` to avoid conflict with libc++ headers. See [Github #2858](https://github.com/Unidata/netcdf-c/issues/2858) for more information.
 * Changed `cmake` build options to be prefaced with `NETCDF`, to bring things in to line with best practices.  This will permit a number of overall quality of life improvements to netCDF, in terms of allowing it to be more easily integrated with upstream projects via `FetchContent()`, `subdirectory()`, etc. Currently, the naming convention in use thus far will still work, but will result in warning messages about deprecation, and instructions on how to update your workflow. See [Github #2895](https://github.com/Unidata/netcdf-c/pull/2895) for more information.
 * Incorporate a more modern look and feel to user documentation generated by Doxygen.  See [Doxygen Awesome CSS](https://github.com/jothepro/doxygen-awesome-css) and [Github #2864](https://github.com/Unidata/netcdf-c/pull/2864) for more information.
diff --git a/cmake/dependencies.cmake b/cmake/dependencies.cmake
index 6aaf3d862..3a35106de 100644
--- a/cmake/dependencies.cmake
+++ b/cmake/dependencies.cmake
@@ -429,7 +429,7 @@ endif ()
 # because for some reason this screws up if we unconditionally test for sdk
 # and it is not available. Fix someday
 if(NETCDF_ENABLE_S3)
-  if(NETCDF_ENABLE_S3_AWS)
+  if(NOT NETCDF_ENABLE_S3_INTERNAL)
     # See if aws-s3-sdk is available
     find_package(AWSSDK REQUIRED COMPONENTS s3;transfer)
     if(AWSSDK_FOUND)
@@ -441,7 +441,7 @@ if(NETCDF_ENABLE_S3)
     else(AWSSDK_FOUND)
       set(NETCDF_ENABLE_S3_AWS OFF CACHE BOOL "S3 AWS" FORCE)
     endif(AWSSDK_FOUND)
-  else(NETCDF_ENABLE_S3_INTERNAL)
+  else(NOT NETCDF_ENABLE_S3_INTERNAL)
     # Find crypto libraries required with testing with the internal s3 api.
     #find_library(SSL_LIB NAMES ssl openssl)
     find_package(OpenSSL REQUIRED)
@@ -454,7 +454,7 @@ if(NETCDF_ENABLE_S3)
     #  message(FATAL_ERROR "Can't find a crypto library, required by S3_INTERNAL")
     #endif(NOT CRYPTO_LIB)
 
-  endif(NETCDF_ENABLE_S3_AWS)
+  endif(NOT NETCDF_ENABLE_S3_INTERNAL)
 else()
   set(NETCDF_ENABLE_S3_AWS OFF CACHE BOOL "S3 AWS" FORCE)
 endif()
diff --git a/config.h.cmake.in b/config.h.cmake.in
index 3e0bff607..fe7dabcdf 100644
--- a/config.h.cmake.in
+++ b/config.h.cmake.in
@@ -262,9 +262,6 @@ are set when opening a binary file on Windows. */
 /* Define to 1 if you have the `fileno' function. */
 #cmakedefine HAVE_FILENO 1
 
-/* Define to 1 if you have the `H5Literate2' function. */
-#cmakedefine HAVE_H5LITERATE2
-
 /* Define to 1 if you have the `fsync' function. */
 #cmakedefine HAVE_FSYNC 1
 
diff --git a/configure.ac b/configure.ac
index 041b70a4b..d223c19f8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -10,7 +10,7 @@
 AC_PREREQ([2.59])
 
 # Initialize with name, version, and support email address.
-AC_INIT([netCDF],[4.9.4-development],[support-netcdf@unidata.ucar.edu],[netcdf-c])
+AC_INIT([netCDF],[4.9.3-development],[support-netcdf@unidata.ucar.edu],[netcdf-c])
 
 ##
 # Prefer an empty CFLAGS variable instead of the default -g -O2.
@@ -21,7 +21,7 @@ AC_INIT([netCDF],[4.9.4-development],[support-netcdf@unidata.ucar.edu],[netcdf-c
 
 AC_SUBST([netCDF_VERSION_MAJOR]) netCDF_VERSION_MAJOR=4
 AC_SUBST([netCDF_VERSION_MINOR]) netCDF_VERSION_MINOR=9
-AC_SUBST([netCDF_VERSION_PATCH]) netCDF_VERSION_PATCH=4
+AC_SUBST([netCDF_VERSION_PATCH]) netCDF_VERSION_PATCH=3
 AC_SUBST([NC_VERSION_NOTE]) NC_VERSION_NOTE="-development"
 
 ##
@@ -29,7 +29,7 @@ AC_SUBST([NC_VERSION_NOTE]) NC_VERSION_NOTE="-development"
 # See http://www.gnu.org/software/libtool/manual/libtool.html#Libtool-versioning
 # for information regarding incrementing `-version-info`.
 # These values should match those in CMakeLists.txt
-AC_SUBST([netCDF_SO_VERSION]) netCDF_SO_VERSION=22:0:0
+AC_SUBST([netCDF_SO_VERSION]) netCDF_SO_VERSION=21:2:2
 
 #####
 # Set some variables used to generate a libnetcdf.settings file,
@@ -1618,13 +1618,13 @@ if test "x$enable_hdf5" = xyes; then
    # H5Pset_fapl_mpiposix and H5Pget_fapl_mpiposix have been removed since HDF5 1.8.12.
    # Use H5Pset_fapl_mpio and H5Pget_fapl_mpio, instead.
 
-   AC_CHECK_FUNCS([H5Pget_fapl_mpio H5Pset_deflate H5Z_SZIP H5Pset_all_coll_metadata_ops H5Literate H5Literate2])
+   AC_CHECK_FUNCS([H5Pget_fapl_mpio H5Pset_deflate H5Z_SZIP H5Pset_all_coll_metadata_ops H5Literate])
 
    # Check to see if HDF5 library has collective metadata APIs, (HDF5 >= 1.10.0)
    if test "x$ac_cv_func_H5Pset_all_coll_metadata_ops" = xyes; then
       AC_DEFINE([HDF5_HAS_COLL_METADATA_OPS], [1], [if true, use collective metadata ops in parallel netCDF-4])
    fi
- 
+
    # If parallel is available in hdf5, enable it in the C code. Also add some stuff to netcdf.h.
    if test "x$ac_cv_func_H5Pget_fapl_mpio" = xyes -o "x$ac_cv_func_H5Pget_fapl_mpiposix" = xyes; then
       hdf5_parallel=yes
@@ -2092,20 +2092,11 @@ fi
 
 AC_SUBST(STD_FILTERS,[$std_filters])
 
-# The --with-plugin-dir gives the user control of the plugin
-# directory. If set to 'yes' (the default), then first directory in
-# the HDF5_PLUGIN_PATH, or /usr/local/hdf5/lib/plugin (the default
-# HDF5 plugin dir) will be used. If another directory is provided, it
-# will be used. If 'no', then plugins will not be installed.
+# If user wants, then install selected standard filters
 AC_MSG_CHECKING([whether and where we should install plugins])
-AC_ARG_WITH([plugin-dir], [AS_HELP_STRING([--with-plugin-dir=<absolute directory>|yes|no|--without-plugin-dir],
+AC_ARG_WITH([plugin-dir], [AS_HELP_STRING([--with-plugin-dir=<absolute directory>|no|--without-plugin-dir],
               [Install selected standard filters in specified or default directory])],
 	      [],[with_plugin_dir=no])
-if test "x$have_zstd" = xyes; then
-   if test "x$with_plugin_dir" = xno; then
-      with_plugin_dir=yes
-   fi
-fi
 AC_MSG_RESULT([$with_plugin_dir])
 if test "x$with_plugin_dir" = xno ; then # option missing|disabled
     with_plugin_dir=no
diff --git a/docs/.gitignore b/docs/.gitignore
index afe7bb1c1..e69de29bb 100644
--- a/docs/.gitignore
+++ b/docs/.gitignore
@@ -1,6 +0,0 @@
-Doxyfile
-custom_style.css
-latex_main
-man
-Doxyfile.bak
-
diff --git a/docs/CMakeLists.txt b/docs/CMakeLists.txt
index 36f6456e9..50f9285c1 100644
--- a/docs/CMakeLists.txt
+++ b/docs/CMakeLists.txt
@@ -34,9 +34,7 @@ IF(NETCDF_ENABLE_DOXYGEN)
 
   # Generate User Documentation
   ADD_CUSTOM_TARGET(doc_all ALL
-    COMMAND ${DOXYGEN_EXECUTABLE} -u ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
-    COMMAND ${DOXYGEN_EXECUTABLE} -w html ${CMAKE_CURRENT_BINARY_DIR}/header.html ${CMAKE_CURRENT_BINARY_DIR}/footer.html ${CMAKE_CURRENT_BINARY_DIR}/custom_stylesheet.html ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile  
-    COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
+    ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
     COMMAND cp ${CMAKE_CURRENT_SOURCE_DIR}/auth.html ${CMAKE_CURRENT_BINARY_DIR}/html
     COMMAND cp ${CMAKE_CURRENT_SOURCE_DIR}/obsolete/fan_utils.html ${CMAKE_CURRENT_BINARY_DIR}/html
     WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
@@ -98,6 +96,6 @@ inmemory.md DAP2.dox FAQ.md
 known_problems.md
 COPYRIGHT.dox user_defined_formats.md DAP4.md DAP4.dox
 testserver.dox byterange.md filters.md nczarr.md auth.md quantize.md
-quickstart_paths.md quickstart_filters.md quickstart_env.md cloud.md)
+quickstart_paths.md cloud.md)
 
 ADD_EXTRA_DIST("${CUR_EXTRA_DIST}")
diff --git a/docs/Doxyfile.developer b/docs/Doxyfile.developer
index 4d8761780..e384408a1 100644
--- a/docs/Doxyfile.developer
+++ b/docs/Doxyfile.developer
@@ -38,7 +38,7 @@ PROJECT_NAME           = netCDF-C
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-PROJECT_NUMBER         = 4.9.4-development
+PROJECT_NUMBER         = 4.9.3-development
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
 # for a project that appears at the top of each page and should give viewer a
diff --git a/docs/Doxyfile.in b/docs/Doxyfile.in
index e6e6c0e5f..c93fe1a9c 100644
--- a/docs/Doxyfile.in
+++ b/docs/Doxyfile.in
@@ -945,7 +945,6 @@ INPUT                  = @abs_top_srcdir@/docs/mainpage.dox \
                          @abs_top_srcdir@/docs/windows-binaries.md \
                          @abs_top_srcdir@/docs/inmemory.md \
                          @abs_top_srcdir@/docs/byterange.md \
-                         @abs_top_srcdir@/docs/auth.md \
                          @abs_top_srcdir@/docs/nczarr.md \
                          @abs_top_srcdir@/docs/cloud.md \
                          @abs_top_srcdir@/docs/notes.md \
@@ -966,7 +965,6 @@ INPUT                  = @abs_top_srcdir@/docs/mainpage.dox \
                          @abs_top_srcdir@/docs/filters.md \
                          @abs_top_srcdir@/docs/quickstart_filters.md \
                          @abs_top_srcdir@/docs/quickstart_paths.md \
-                         @abs_top_srcdir@/docs/quickstart_env.md \
                          @abs_top_srcdir@/include/netcdf.h \
                          @abs_top_srcdir@/include/netcdf_mem.h \
                          @abs_top_srcdir@/include/netcdf_par.h \
@@ -1354,7 +1352,7 @@ HTML_FILE_EXTENSION    = .html
 # of the possible markers and block names see the documentation.
 # This tag requires that the tag GENERATE_HTML is set to YES.
 
-HTML_HEADER            = @abs_top_builddir@/docs/header.html
+HTML_HEADER            = @abs_top_srcdir@/docs/header.html
 
 # The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each
 # generated HTML page. If the tag is left blank doxygen will generate a standard
@@ -1364,7 +1362,7 @@ HTML_HEADER            = @abs_top_builddir@/docs/header.html
 # that doxygen normally uses.
 # This tag requires that the tag GENERATE_HTML is set to YES.
 
-HTML_FOOTER            = @abs_top_builddir@/docs/footer.html
+HTML_FOOTER            = @abs_top_srcdir@/docs/footer.html
 
 # The HTML_STYLESHEET tag can be used to specify a user-defined cascading style
 # sheet that is used by each HTML page. It can be used to fine-tune the look of
diff --git a/docs/Makefile.am b/docs/Makefile.am
index 3bacd2d08..ba3e41cbb 100644
--- a/docs/Makefile.am
+++ b/docs/Makefile.am
@@ -15,7 +15,7 @@ obsolete/fan_utils.html indexing.dox inmemory.md FAQ.md			\
 known_problems.md COPYRIGHT.md inmeminternal.dox testserver.dox		\
 byterange.md nczarr.md quantize.md all-error-codes.md                   \
 quickstart_paths.md cloud.md header.html attribute_conventions.md \
-file_format_specifications.md quickstart_filters.md quickstart_env.md \
+file_format_specifications.md quickstart_filters.md \
 doxygen-awesome-css netcdf-50x50.png
 
 # Turn off parallel builds in this directory.
@@ -56,11 +56,7 @@ endif
 # includes them in the documentation.
 
 doxyfile.stamp:
-	$(DOXYGEN) -u $(top_builddir)/docs/Doxyfile && \
-	$(DOXYGEN) -w html $(top_builddir)/docs/header.html \
-		$(top_builddir)/docs/footer.html $(top_builddir)/docs/custom_style.css $(top_builddir)/docs/Doxyfile && \
-	$(DOXYGEN) $(top_builddir)/docs/Doxyfile && \
-	cp $(top_srcdir)/docs/auth.md $(top_srcdir)/docs/obsolete/fan_utils.html html
+	$(DOXYGEN) Doxyfile && cp $(top_srcdir)/docs/auth.md $(top_srcdir)/docs/obsolete/fan_utils.html html
 
 CLEANFILES = doxyfile.stamp
 
diff --git a/docs/auth.md b/docs/auth.md
index 392add745..dfb49b326 100644
--- a/docs/auth.md
+++ b/docs/auth.md
@@ -1,18 +1,21 @@
 NetCDF Authorization Support
-====================================
+======================================
 
 <!-- double header is needed to workaround doxygen bug -->
 
+NetCDF Authorization Support {#auth}
+====================================
+
 [TOC]
 
-## Introduction {#auth}
+## Introduction {#auth_intro}
 
 netCDF can support user authorization using the facilities provided by the curl
 library. This includes basic password authentication as well as
 certificate-based authorization.
 At the moment, this document only applies to DAP2 and DAP4 access.
 
-With some exceptions (e.g. see the section on <a href="#auth_redir">redirection</a>)
+With some exceptions (e.g. see the section on <a href="#REDIR">redirection</a>)
 The libcurl authorization mechanisms can be accessed in two ways
 
 1. Inserting the username and password into the url, or
@@ -30,7 +33,7 @@ This username and password will be used if the server asks for
 authentication. Note that only simple password authentication
 is supported in this format.
 
-Specifically note that [redirection-based](#auth_redir)
+Specifically note that [redirection-based](#REDIR)
 authorization may work with this but it is a security risk.
 This is because the username and password
 may be sent to each server in the redirection chain.
@@ -41,12 +44,67 @@ how to properly escape the user and password.
 
 ## RC File Authentication {#auth_dodsrc}
 The netcdf library supports an _rc_ file mechanism to allow the passing
-of a number of run-time parameters to libnetcdf and libcurl.
-This is described in the file "quickstart_env.md". 
+of a number of parameters to libnetcdf and libcurl.
+Locating the _rc_ file is a multi-step process.
+
+### Search Order
+
+The netcdf-c library searches for, and loads from, the following files,
+in this order:
+1. $HOME/.ncrc
+2. $HOME/.dodsrc
+3. $CWD/.ncrc
+4. $CWD/.dodsrc
+
+*$HOME* is the user's home directory and *$CWD* is the current working directory. Entries in later files override any of the earlier files
+
+It is strongly suggested that you pick a uniform location and a uniform name
+and use them always. Otherwise you may observe unexpected results
+when the netcdf-c library loads an rc file you did not expect.
+
+### RC File Format
+
+The rc file format is a series of lines of the general form:
+
+    [<host:port>]<key>=<value>
+
+where the bracket-enclosed host:port is optional.
+
+### URL Constrained RC File Entries
+
+Each line of the rc file can begin with a host+port enclosed in
+square brackets.  The form is "host:port".  If the port is not
+specified then the form is just "host".  The reason that more of
+the url is not used is that libcurl's authorization grain is not
+any finer than host level.
+
+Here are some examples.
+````
+    [remotetest.unidata.ucar.edu]HTTP.VERBOSE=1
+or
+    [fake.ucar.edu:9090]HTTP.VERBOSE=0
+````
+If the url request from, say, the _netcdf_open_ method
+has a host+port matching one of the prefixes in the rc file, then
+the corresponding entry will be used, otherwise ignored.
+This means that an entry with a matching host+port will take
+precedence over an entry without a host+port.
+
+For example, the URL
+````
+    http://remotetest.unidata.ucar.edu/thredds/dodsC/testdata/testData.nc
+````
+will have HTTP.VERBOSE set to 1 because its host matches the example above.
+
+Similarly,
+````
+    http://fake.ucar.edu:9090/dts/test.01
+````
+will have HTTP.VERBOSE set to 0 because its host+port matches the example above.
 
 ## Authorization-Related Keys {#auth_keys}
 
-The currently defined set of authorization-related keys recognized in .netrc are as follows.
+The currently defined set of authorization-related keys are as follows.
 The second column is the affected curl_easy_setopt option(s), if any
 (see reference #1).
 <table>
@@ -79,7 +137,7 @@ This is an alternative to setting it in the url.
 The value must be of the form "username:password".
 See the <a href="#USERPWDESCAPE">password escaping</a> section
 to see how this value must escape certain characters.
-Also see <a href="#auth_redir">redirection authorization</a>
+Also see <a href="#REDIR">redirection authorization</a>
 for important additional information.
 
 The pair of keys
@@ -88,7 +146,7 @@ can be used as an alternative to HTTP.CREDENTIALS.USERPASSWORD
 to set the simple password authentication.
 If present, they take precedence over HTTP.CREDENTIALS.USERPASSWORD.
 The values do not need to be escaped.
-See <a href="#auth_redir">redirection authorization</a>
+See <a href="#REDIR">redirection authorization</a>
 for important additional information.
 
 ### Cookie Jar
@@ -99,7 +157,7 @@ to read cookies (CURLOPT_COOKIEJAR) and also
 the file into which to store cookies (CURLOPT_COOKIEFILE).
 The same value is used for both CURLOPT values.
 It defaults to in-memory storage.
-See [redirection authorization](#auth_redir)
+See [redirection authorization](#REDIR)
 for important additional information.
 
 ### Certificate Authentication
@@ -133,7 +191,7 @@ deprecated; use HTTP.PROXY.SERVER
 HTTP.NETRC
 specifies the absolute path of the .netrc file,
 and causes it to be used instead of username and password.
-See [redirection authorization](#auth_redir)
+See [redirection authorization](#REDIR)
 for information about using *.netrc*.
 
 ## Password Escaping {#auth_userpwdescape}
@@ -231,7 +289,7 @@ machine urs.earthdata.nasa.gov login <user> password <password>
 
 Some systems, notably ESG (Earth System Grid), requires
 the use of client-side certificates, as well as being
-[re-direction based](#auth_redir).
+[re-direction based](#REDIR).
 This requires setting the following entries:
 
 - HTTP.COOKIEJAR &mdash; a file path for storing cookies across re-direction.
@@ -248,7 +306,7 @@ Note that the first two are there to support re-direction based authentication.
 1. https://curl.haxx.se/libcurl/c/curl_easy_setopt.html
 2. https://curl.haxx.se/docs/ssl-compared.html
 
-## Authorization Appendix A. All RC-File Keys {#auth_allkeys}
+## Appendix A. All RC-File Keys {#auth_allkeys}
 
 For completeness, this is the list of all rc-file keys.
 If this documentation is out of date with respect to the actual code,
@@ -275,21 +333,21 @@ the code is definitive.
 <tr><td>HTTP.NETRC</td><td>CURLOPT_NETRC,CURLOPT_NETRC_FILE</td>
 </table>
 
-## Authorization Appendix B. URS Access in Detail {#auth_ursdetail}
+## Appendix B. URS Access in Detail {#auth_ursdetail}
 
 It is possible to use the NASA Earthdata Login System (URS)
 with netcdf by using using the process specified in the
-[redirection based authorization section](#auth_redir).
+[redirection based authorization section](#REDIR).
 In order to access URS controlled datasets, however, it is necessary to
 register as a user with NASA at this website (subject to change):
 
     https://uat.urs.earthdata.nasa.gov/
 
-## Authorization Appendix C. ESG Access in Detail {#auth_esgdetail}
+## Appendix C. ESG Access in Detail {#auth_esgdetail}
 
 It is possible to access Earth Systems Grid (ESG) datasets
 from ESG servers through the netCDF API using the techniques
-described in the section on [Client-Side Certificates](#auth_clientcerts).
+described in the section on [Client-Side Certificates](#CLIENTCERTS).
 
 In order to access ESG datasets, however, it is necessary to
 register as a user with ESG and to setup your environment
@@ -372,7 +430,7 @@ named "truststore"
 
 ### Running the C Client
 
-Refer to the section on [Client-Side Certificates](#auth_clientcerts).
+Refer to the section on [Client-Side Certificates](#CLIENTCERTS).
 The keys specified there  must be set in the rc file to support ESG access.
 
 - HTTP.COOKIEJAR=~/.dods_cookies
diff --git a/docs/building-with-autotools.md b/docs/building-with-autotools.md
deleted file mode 100644
index 962fd20cb..000000000
--- a/docs/building-with-autotools.md
+++ /dev/null
@@ -1,199 +0,0 @@
-Build Instructions for NetCDF-C using autoconf/automake/libtool {#netCDF-autotools}
-===========================================
-
-[TOC]
-
-# Overview {#autotools_overview}
-
-A CMake build of netCDF is also supported. Users should consider using
-the CMake build, which builds netCDF on a wider range of platforms,
-include Microsoft Windows with Visual Studio. The autotools based
-build may eventually be retired; users may considering transitioning
-to the CMake build. See \ref netCDF-CMake.
-
-We also provide pre-built binary downloads for the shared versions of
-netCDF for use with Visual Studio.
-		
-# Requirements {#autotools_requirements}
-The following packages are required to build netCDF-C.
-
-* netCDF-C Source Code
-* Optional Requirements:
-	* HDF5 Libraries for netCDF4/HDF5 support.
-	* libcurl for DAP support.
-
-<center>
-<img src="deptree.jpg" height="250px" />
-</center>
-
-# The Autotools Build Process {#autotools_build}
-
-There are four steps in the Build Process when using autotools:
-
-1. Configuration: Before compiling, the software is configured based on the desired options.
-2. Building: Once configuration is complete, the libraries are compiled.
-3. Testing: Post-build, it is possible to run tests to ensure the functionality of the netCDF-C libraries.
-4. Installation: If all tests pass, the libraries can be installed in the location specified during configuration.
-
-For users who prefer pre-built binaries, installation packages are available at \ref winbin
-
-## Configuration {#autotools_configuration}
-
-The output of the configuration step are the makefiles which build the library, utilities, and tests.
-
-### Common Configure Options {#autotools_common_options}
-
-| **Option** | **Autotools** | **CMake** |
-| :------- | :---- | :----- |
-Specify Install Location | --prefix=PREFIX | -DCMAKE\_INSTALL\_PREFIX=PREFIX
-Enable/Disable netCDF-4 | --enable-netcdf-4<br>--disable-netcdf-4 | -DENABLE\_NETCDF\_4=ON <br> -DENABLE\_NETCDF\_4=OFF
-Enable/Disable DAP | --enable-dap <br> --disable-dap | -DENABLE\_DAP=ON <br> -DENABLE\_DAP=OFF
-Enable/Disable Utilities | --enable-utilities <br> --disable-utilities | -DBUILD\_UTILITIES=ON <br> -DBUILD\_UTILITIES=OFF
-Specify shared/Static Libraries | --enable-shared <br> --enable-static | -DBUILD\_SHARED\_LIBS=ON <br> -DBUILD\_SHARED\_LIBS=OFF
-Enable/Disable Tests | --enable-testsets <br> --disable-testsets | -DENABLE\_TESTS=ON <br> -DENABLE\_TESTS=OFF
-Specify a custom library location | Use *CFLAGS* and *LDFLAGS* | -DCMAKE\_PREFIX\_PATH=/usr/custom_libs/
-Enable parallel I/O tests | --enable-parallel-tests | -DNETCDF\_ENABLE_PARALLEL\_TESTS=ON
-
-A full list of options can be found by invoking `configure --help`. 
-
-### Configuring your build from the command line. {#autotools_command_line}
-
-The easiest configuration case would be one in which all of the
-dependent libraries are installed on the system path (in either
-Unix/Linux or Windows) and all the default options are desired. In the
-source directory:
-
-> $ ./configure
-
-If you have libraries installed in a custom directory, you will need to
-set the CPPFLAGS and LDFLAGS environment variables to tell the compiler where the
-libraries are installed. For example:
-
-> $ CPPFLAGS=-I/usr/local/hdf5-1.14.3/include LDFLAGS=-L/usr/local/hdf5-1.14.3/lib ./configure --prefix=/usr/local/netcdf-c-4.9.3
-
-#### Building with Parallel I/O. {#autotools_parallel_io}
-
-NetCDF will build with parallel I/O if the C compiler is an MPI
-compiler, and HDF5 was built for parallel I/O. To build netcdf-c for
-parallel I/O, first build HDF5 for parallel I/O, then build netcdf-c
-like this:
-
-> $ CC=mpicc CPPFLAGS=-I/usr/local/hdf5-1.14.3_mpich/include LDFLAGS=-L/usr/local/hdf5-1.14.3_mpicj/lib ./configure --prefix=/usr/local/netcdf-c-4.9.3_mpich --enable-parallel-tests
-
-The parallel I/O tests will only run if the additional configure
-option is used: --enable-parallel-tests. Those tests run (by default)
-with mpiexec, on 4, 16, or 32 processors. If mpiexec cannot be used on
-your login-nodes, a different command can be used to launch the
-parallel I/O tests. Used the --with-mpiexec configure option to set a
-different parallel I/O job launcher:
-
-> $ CC=mpicc CPPFLAGS=-I/usr/local/hdf5-1.14.3_mpich/include LDFLAGS=-L/usr/local/hdf5-1.14.3_mpicj/lib ./configure --prefix=/usr/local/netcdf-c-4.9.3_mpich --enable-parallel-tests --with-mpiexec='srun -A acct_name -q queue_name'
-
-## Setting the HDF5 Plugin Path
-
-Use the --with-plugin-dir= option to set the HDF5 plugin path. This
-path must contain the directory where HDF5 filters have been
-installed. --with-plugin-dir accepts three values:
-
-* yes - use the first directory in environment variable
-HDF5_PLUGIN_PATH (if it is set), or /usr/local/hdf5/lib/plugin (Unix)
-or ${ALLUSERSPROFILE}\\hdfd5\\lib\\plugin (Windows).
-
-* a path - path to be used for plugins.
-
-* no - do not install or use plugins.
-
-## Checking the Configure Summary
-
-At the end of the configure, a summary of the build will be
-output. It's important to check this to ensure that the desired build
-features are accurately set. For example:
-
-<pre>
-# NetCDF C Configuration Summary
-==============================
-
-# General
--------
-NetCDF Version:		4.9.4-development
-Dispatch Version:       5
-Configured On:		Wed Aug  7 06:53:22 MDT 2024
-Host System:		x86_64-pc-linux-gnu
-Build Directory: 	/home/ed/netcdf-c
-Install Prefix:         /usr/local/netcdf-c-4.9.3
-Plugin Install Prefix:  N.A.
-
-# Compiling Options
------------------
-C Compiler:		/usr/bin/gcc
-CFLAGS:			 -fno-strict-aliasing
-CPPFLAGS:		-I/usr/local/hdf5-1.14.3/include
-LDFLAGS:		-L/usr/local/hdf5-1.14.3/lib
-AM_CFLAGS:		
-AM_CPPFLAGS:		
-AM_LDFLAGS:		
-Shared Library:		yes
-Static Library:		yes
-Extra libraries:	-lhdf5_hl -lhdf5 -lm -lz -lsz -lzstd -lxml2 -lcurl 
-XML Parser:             libxml2
-
-# Features
---------
-Benchmarks:		no
-NetCDF-2 API:		yes
-HDF4 Support:		no
-HDF5 Support:		yes
-CDF5 Support:		yes
-NC-4 Parallel Support:	no
-PnetCDF Support:	no
-
-DAP2 Support:		yes
-DAP4 Support:		yes
-Byte-Range Support:	yes
-
-S3 Support:	        no
-S3 SDK:  	        none
-
-NCZarr Support:		yes
-NCZarr Zip Support:     no
-
-Diskless Support:	yes
-MMap Support:		no
-ERANGE Fill Support:	no
-Relaxed Boundary Check:	yes
-
-Quantization:		yes
-Logging:     		no
-SZIP Write Support:     yes
-Standard Filters:       bz2 deflate szip zstd
-ZSTD Support:           yes
-Parallel Filters:       yes
-</pre>
-
-Important settings include:
-* Install Prefix - this is where netCDF will be installed.
-* HDF5 Support - must be 'yes' to use netcdf-4/HDF5 files.
-* NC-4 Parallel Support - Must be 'yes' to use HDF5 parallel I/O.
-* PnetCDF Support - Must be 'yes' to use pnetcdf library for parallel I/O with classic netCDF files.
-* Standard Filters - Must include 'zstd' if zstandard compression is to be used.
-* DAP2/DAP4 Support - Must be 'yes' if OPeNDAP is to be used.
-
-## Building {#autotools_building}
-
-The compiler can be executed directly with 'make'.
-
-> $ make
-
-## Testing {#autotools_testing}
-
-Testing can be executed with:
-
-> $ make check
-
-## Installation {#autotools_installation}
-
-Once netCDF has been built and tested, it may be installed using the following command:
-
-> $ make install
-
-
diff --git a/docs/building-with-cmake.md b/docs/building-with-cmake.md
index a47caa301..3448976b4 100644
--- a/docs/building-with-cmake.md
+++ b/docs/building-with-cmake.md
@@ -5,16 +5,9 @@ Build Instructions for NetCDF-C using CMake {#netCDF-CMake}
 
 # Overview {#cmake_overview}
 
-Starting with netCDF-C 4.3.0, we are happy to announce the inclusion
-of CMake support.  CMake will allow for building netCDF on a wider
-range of platforms, include Microsoft Windows with Visual Studio.
-CMake support also provides robust unit and regression testing tools.
-We will also maintain the standard autotools-based build system in
-parallel.
+Starting with netCDF-C 4.3.0, we are happy to announce the inclusion of CMake support.  CMake will allow for building netCDF on a wider range of platforms, include Microsoft Windows with Visual Studio.  CMake support also provides robust unit and regression testing tools.  We will also maintain the standard autotools-based build system in parallel.
 
-In addition to providing new build options for netCDF-C, we will also
-provide pre-built binary downloads for the shared versions of netCDF
-for use with Visual Studio.
+In addition to providing new build options for netCDF-C, we will also provide pre-built binary downloads for the shared versions of netCDF for use with Visual Studio.  
 
 		
 # Requirements {#cmake_requirements}
@@ -74,24 +67,6 @@ If you have libraries installed in a custom directory, you may need to specify t
 
 > $ cmake [Source Directory] -DCMAKE\_PREFIX\_PATH=/usr/custom_libraries/
 
-#### Building with Parallel I/O. {#cmake_parallel_io}
-
-NetCDF will build with parallel I/O if the C compiler is an MPI
-compiler, and HDF5 was built for parallel I/O. To build netcdf-c for
-parallel I/O, first build HDF5 for parallel I/O, then build netcdf-c
-like this:
-
-> $ CC=mpicc cmake [Source Directory] -DNETCDF\_ENABLE\_PARALLEL_TESTS=ON
-
-The parallel I/O tests will only run if the additional configure
-option is used: NETCDF_ENABLE_PARALLEL_TESTS. Those tests run (by default)
-with mpiexec, on 4, 16, or 32 processors. If mpiexec cannot be used on
-your login-nodes, a different command can be used to launch the
-parallel I/O tests. Used the NETCDF_MPIEXEC option to set a
-different parallel I/O job launcher:
-
-> $ CC=mpicc cmake [Source Directory] -DNETCDF\_ENABLE\_PARALLEL_TESTS=ON -DNETCDF\_MPIEXEC='srun -A account'
-
 ## Building {#cmake_building}
 
 The compiler can be executed directly with 'make' or the appropriate command for the configurator which was used.  
diff --git a/docs/footer.html b/docs/footer.html
index efa3357e5..5b4894060 100644
--- a/docs/footer.html
+++ b/docs/footer.html
@@ -1,17 +1,21 @@
-<!-- HTML footer for doxygen 1.9.1-->
-<!-- start footer part -->
-<!--BEGIN GENERATE_TREEVIEW-->
-<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
-  <ul>
-    $navpath
-    <li class="footer">$generatedby <a href="https://www.doxygen.org/index.html"><img class="footer" src="$relpath^doxygen.svg" width="104" height="31" alt="doxygen"/></a> $doxygenversion </li>
-  </ul>
-</div>
-<!--END GENERATE_TREEVIEW-->
-<!--BEGIN !GENERATE_TREEVIEW-->
-<hr class="footer"/><address class="footer"><small>
-$generatedby&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="$relpath^doxygen.svg" width="104" height="31" alt="doxygen"/></a> $doxygenversion
-</small></address>
-<!--END !GENERATE_TREEVIEW-->
-</body>
-</html>
+<!-- HTML footer for doxygen 1.8.17-->
+<!-- start footer part -->
+<!--BEGIN GENERATE_TREEVIEW-->
+<div id="nav-path" class="navpath"> <!-- id is needed for treeview function! -->
+<!--END GENERATE_TREEVIEW-->
+<!--BEGIN !GENERATE_TREEVIEW-->
+<div> <!-- id unnecessary if treeview is not used -->
+<!--END !GENERATE_TREEVIEW-->
+  <hr size="2" />
+  <address style="text-align: center;">
+    <a href="https://www.unidata.ucar.edu/software/netcdf/">Return to the Main Unidata NetCDF page.</a><br>
+    <img src="./$relpath^/uniLogo.png">
+  </address>
+
+  <address style="text-align: right;"><small>
+    Generated on $datetime for $projectname. NetCDF is
+    a <a href="https://www.unidata.ucar.edu/">Unidata</a> library.</small>
+  </address>
+</div>
+</body>
+</html>
diff --git a/docs/header.html b/docs/header.html
index 9c4751e63..af3a75a09 100644
--- a/docs/header.html
+++ b/docs/header.html
@@ -1,54 +1,88 @@
-<!-- HTML header for doxygen 1.9.1-->
+<!-- HTML header for doxygen 1.10.0-->
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html xmlns="http://www.w3.org/1999/xhtml" lang="$langISO">
 <head>
 <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
-<meta http-equiv="X-UA-Compatible" content="IE=9"/>
+<meta http-equiv="X-UA-Compatible" content="IE=11"/>
 <meta name="generator" content="Doxygen $doxygenversion"/>
 <meta name="viewport" content="width=device-width, initial-scale=1"/>
 <!--BEGIN PROJECT_NAME--><title>$projectname: $title</title><!--END PROJECT_NAME-->
 <!--BEGIN !PROJECT_NAME--><title>$title</title><!--END !PROJECT_NAME-->
+<!--BEGIN PROJECT_ICON-->
+<link rel="icon" href="$relpath^$projecticon" type="image/x-icon" />
+<!--END PROJECT_ICON-->
 <link href="$relpath^tabs.css" rel="stylesheet" type="text/css"/>
+<!--BEGIN DISABLE_INDEX-->
+  <!--BEGIN FULL_SIDEBAR-->
+<script type="text/javascript">var page_layout=1;</script>
+  <!--END FULL_SIDEBAR-->
+<!--END DISABLE_INDEX-->
 <script type="text/javascript" src="$relpath^jquery.js"></script>
 <script type="text/javascript" src="$relpath^dynsections.js"></script>
+<!--BEGIN COPY_CLIPBOARD-->
+<script type="text/javascript" src="$relpath^clipboard.js"></script>
+<!--END COPY_CLIPBOARD-->
 $treeview
 $search
 $mathjax
+$darkmode
 <link href="$relpath^$stylesheet" rel="stylesheet" type="text/css" />
 $extrastylesheet
+<html> 
+    <head>
+        <!-- ... other metadata & script includes ... -->
+        <script type="text/javascript" src="$relpath^doxygen-awesome-darkmode-toggle.js"></script>
+        <script type="text/javascript">
+            DoxygenAwesomeDarkModeToggle.init()
+        </script>
+    </head>
+    <body>
+
 </head>
 <body>
+<!--BEGIN DISABLE_INDEX-->
+  <!--BEGIN FULL_SIDEBAR-->
+<div id="side-nav" class="ui-resizable side-nav-resizable"><!-- do not remove this div, it is closed by doxygen! -->
+  <!--END FULL_SIDEBAR-->
+<!--END DISABLE_INDEX-->
+
 <div id="top"><!-- do not remove this div, it is closed by doxygen! -->
 
 <!--BEGIN TITLEAREA-->
 <div id="titlearea">
 <table cellspacing="0" cellpadding="0">
  <tbody>
- <tr style="height: 56px;">
+ <tr id="projectrow">
   <!--BEGIN PROJECT_LOGO-->
-  <td id="projectlogo"><img alt="Logo" src="$relpath^$projectlogo"/></td>
+  <td id="projectlogo"><img alt="Logo" src="$relpath^$projectlogo"$logosize/></td>
   <!--END PROJECT_LOGO-->
   <!--BEGIN PROJECT_NAME-->
-  <td id="projectalign" style="padding-left: 0.5em;">
-   <div id="projectname">$projectname
-   <!--BEGIN PROJECT_NUMBER-->&#160;<span id="projectnumber">$projectnumber</span><!--END PROJECT_NUMBER-->
+  <td id="projectalign">
+   <div id="projectname">$projectname<!--BEGIN PROJECT_NUMBER--><span id="projectnumber">&#160;$projectnumber</span><!--END PROJECT_NUMBER-->
    </div>
    <!--BEGIN PROJECT_BRIEF--><div id="projectbrief">$projectbrief</div><!--END PROJECT_BRIEF-->
   </td>
   <!--END PROJECT_NAME-->
   <!--BEGIN !PROJECT_NAME-->
    <!--BEGIN PROJECT_BRIEF-->
-    <td style="padding-left: 0.5em;">
+    <td>
     <div id="projectbrief">$projectbrief</div>
     </td>
    <!--END PROJECT_BRIEF-->
   <!--END !PROJECT_NAME-->
   <!--BEGIN DISABLE_INDEX-->
    <!--BEGIN SEARCHENGINE-->
-   <td>$searchbox</td>
+     <!--BEGIN !FULL_SIDEBAR-->
+    <td>$searchbox</td>
+     <!--END !FULL_SIDEBAR-->
    <!--END SEARCHENGINE-->
   <!--END DISABLE_INDEX-->
  </tr>
+  <!--BEGIN SEARCHENGINE-->
+   <!--BEGIN FULL_SIDEBAR-->
+   <tr><td colspan="2">$searchbox</td></tr>
+   <!--END FULL_SIDEBAR-->
+  <!--END SEARCHENGINE-->
  </tbody>
 </table>
 </div>
diff --git a/docs/nczarr.md b/docs/nczarr.md
index e3db2016e..ee41e4ffe 100644
--- a/docs/nczarr.md
+++ b/docs/nczarr.md
@@ -320,18 +320,17 @@ Note that this is different from zlib.
 
 ## Addressing Style
 
-The notion of "addressing style" may need some expansion. Amazon S3 accepts two forms for specifying the endpoint for accessing the data (see the document "quickstart_path").
+The notion of "addressing style" may need some expansion.
+Amazon S3 accepts two forms for specifying the endpoint for accessing the data
+(see the document "quickstart_path).
 
 1. Virtual -- the virtual addressing style places the bucket in the host part of a URL.
 For example:
-
 ```
 https://<bucketname>.s2.&lt;region&gt.amazonaws.com/
 ```
-
 2. Path -- the path addressing style places the bucket in at the front of the path part of a URL.
 For example:
-
 ```
 https://s3.&lt;region&gt.amazonaws.com/<bucketname>/
 ```
@@ -538,7 +537,6 @@ Then the following options must be specified for cmake.
 -DAWSSDK_ROOT_DIR=${AWSSDK_ROOT_DIR}
 -DAWSSDK_DIR=${AWSSDK_ROOT_DIR}/lib/cmake/AWSSDK
 ````
-
 # Appendix B. Amazon S3 Imposed Limits {#nczarr_s3limits}
 
 The Amazon S3 cloud storage imposes some significant limits that are inherited by NCZarr (and Zarr also, for that matter).
diff --git a/docs/quickstart_env.md b/docs/quickstart_env.md
deleted file mode 100644
index 9d0f4f812..000000000
--- a/docs/quickstart_env.md
+++ /dev/null
@@ -1,155 +0,0 @@
-Appendix D.3. Environment Variables and .RC files {#nc_env_quickstart}
-==============================
-
-The netCDF-c library provides several parameterization mechanisms to
-control its behavior at run-time. The term _run-time_ means that the
-library's behavior can be changed every time the library is initialized
-
-The most commonly used parameterization mechanisms are:
-1. Environment Variables -- accessed by the getenv() function.
-2. .RC files -- accessed from the file system.
-
-## Environment Variables {#nc_env_vars}
-
-The following table describes (most of) the environment variables
-used by the netcdf-c library. There are some not listed that are only
-used for specialized debugging.
-
-<table>
-<tr><th>Name<th>Description
-<tr><td>ALLUSERSPROFILE<td>This is more-or-less the Windows equivalent of "HOME"
-<tr><td>AWS_ACCESS_KEY_ID<td>Used by the aws access libraries; overrides ${HOME}/.aws/config entries.
-<tr><td>AWS_CONFIG_FILE<td>Used by the aws access libraries; specifies absolute path to the config file.
-<tr><td>AWS_DEFAULT_REGION<td>Used by the aws access libraries; specifies default S3 region.
-<tr><td>AWS_PROFILE<td>Used by the aws access libraries; specifies default AWS profile.
-<tr><td>AWS_REGION<td>Used by the aws access libraries; specifies specific region to use.
-<tr><td>AWS_SECRET_ACCESS_KEY<td>Used by the aws access libraries; overrides ${HOME}/.aws/config entries.
-<tr><td>CURLOPT_VERBOSE<td>Causes libcurl to produce verbose output.
-<tr><td>HOME<td>The user's home directory.
-<tr><td>MSYS2_PREFIX<td>If platform is MSYS2, then specify the root prefix.
-<tr><td>NC_DEFAULT_CREATE_PERMS<td>For NCZarr, specify the default creation permissions for a file.
-<tr><td>NC_DEFAULT_DIR_PERMS<td>For NCZarr, specify the default creation permissions for a directory.
-<tr><td>NCLOGGING<td>Specify the log level: one of "OFF","ERR","WARN","NOTE","DEBUG".
-<tr><td>NCPATHDEBUG<td>Causes path manager to output debugging information.
-<tr><td>NCRCENV_HOME<td>Overrides ${HOME} as the location of the .rc file.
-<tr><td>NCRCENV_IGNORE<td>Causes any .rc files to be ignored.
-<tr><td>NCRCENV_RC<td>The absolute path to use for the .rc file.
-<tr><td>NCTRACING<td>Specify the level of tracing detail.
-<tr><td>NCZARRFORMAT<td>Force use of a specific Zarr format version: 2 or 3.
-<tr><td>NETCDF_LOG_LEVEL<td>Specify the log level for HDF5 logging (separate from e.g. NCLOGGING).
-<tr><td>TEMP<td>For Windows platform, specifies the location of a directory to store temporary files.
-<tr><td>USERPROFILE<td>For Windows platform, overrides ${HOME}.
-</table>
-
-## Resource Control (.rc) Files {#nc_env_rc}
-
-In addition to using environment variables,
-the netcdf-c library supports run-time configuration
-of the library using the so-called ".rc" file mechanism.
-This means that as part of its initialization, the netcdf-c
-library will search for and process a set of files where
-these files contain entries specifying (key,value) pairs.
-These pairs are compiled into a single internal database
-that can be queried by other parts of the netcdf-c library.
-
-### Locating The _.rc_ Files
-
-For historical reasons, multiple .rc files are allowed.
-
-### Search Order
-
-The netcdf-c library searches for, and loads from, the following files,
-in this order:
-1. $HOME/.ncrc
-2. $HOME/.dodsrc
-3. $CWD/.ncrc
-4. $CWD/.dodsrc
-
-*$HOME* is the user's home directory and *$CWD* is the current working directory.
-Entries in later files override any of the earlier files
-
-It is strongly suggested that you pick a uniform location and a uniform name
-and use them always. Otherwise you may observe unexpected results
-when the netcdf-c library loads an rc file you did not expect.
-
-### RC File Format
-
-The rc file format is a series of lines of the general form:
-````
-    [<URL>]<key>=<value>
-````
-where the bracket-enclosed URL is optional. Note that the brackets
-are part of the line.
-
-### URL Constrained RC File Entries
-
-Each line of the rc file can begin with a URL enclosed in
-square brackets. The parts of the URL that are used for choosing
-an entry are the host, the port, and the URL path.
-Note that the host+port is the only part used when searching for
-libcurl related entries. This is because libcurl's authorization grain is not
-any finer than host+port level.
-The URL path may be used for non-curl related entries.
-Also note that the protocol is ignored.
-
-Here are some examples.
-````
-    [https://remotetest.unidata.ucar.edu/thredds]HTTP.VERBOSE=1
-or
-    [https://fake.ucar.edu:9090]HTTP.VERBOSE=0
-````
-
-For selection purposes, the host+port+path is used when the path argument
-for _nc_open()_ or _nc_create()_ takes the form of a URL.
-If the url request from, say, the _netcdf_open_ method
-has a host,port, and path matching one of the prefixes in the rc file, then
-the corresponding entry will be used, otherwise ignored.
-This means that an entry with a matching host+port+path will take
-precedence over an entry without a host+port+path.
-
-For example, passing this URL to _nc_open_
-````
-    http://remotetest.unidata.ucar.edu/thredds/dodsC/testdata/testData.nc
-````
-will have HTTP.VERBOSE set to 1 because its host and path match the example above.
-
-Similarly, using this path
-````
-    http://fake.ucar.edu:9090/dts/test.01
-````
-will have HTTP.VERBOSE set to 0 because its host+port matches the example above.
-
-### Programmatic Access to .rc File
-
-It is possible for client programs to query and modify the internal .rc database
-through the following API.
-* ````char* nc_rc_get(const char* key);````
-    Get the value corresponding to key or return NULL if not defined. The caller must free the resulting value.
-* ````int nc_rc_set(const char* key, const char* value);````
-    Set/overwrite the value corresponding to the specified key.
-
-Note that this API does not (currently) support URL prefixed keys, so the client will need to take this into account.
-
-### Defined .rc file keys
-
-There a a number of keys used by the netcdf-c library. Most of them
-are authorization-related. The file "auth.md" describes these keys.
-
-Other keys are as follows:
-* libdap4/d4curlfunctions.c and oc2/ocinternal.c
-    - HTTP.READ.BUFFERSIZE -- set the read buffer size for DAP2/4 connection
-    - HTTP.KEEPALIVE -- turn on keep-alive for DAP2/4 connection
-* libdispatch/ds3util.c
-    - AWS.PROFILE -- alternate way to specify the default AWS profile
-    - AWS.REGION --  alternate way to specify the default AWS region
-* libnczarr/zinternal.c
-    - ZARR.DIMENSION_SEPARATOR -- alternate way to specify the Zarr dimension separator character
-* oc2/occurlfunctions.c
-    - HTTP.NETRC -- alternate way to specify the path of the .netrc file
-
-## Point of Contact {#nc_env_poc}
-
-__Author__: Dennis Heimbigner<br>
-__Email__: dmh at ucar dot edu<br>
-__Initial Version__: 01/09/2023<br>
-__Last Revised__: 07/30/2024
diff --git a/docs/static-pages/software.html b/docs/static-pages/software.html
index 347993002..9e65dcaf4 100644
--- a/docs/static-pages/software.html
+++ b/docs/static-pages/software.html
@@ -197,9 +197,6 @@
       <li>
         <a href="#ncregrid" >ncregrid</a>
       </li>
-      <li>
-        <a href="#ncstat" >NCSTAT (A collection for complex statistical processing and analysis of huge climate model outputs and datasets).</a>
-      </li>
       <li>
         <a href="#nctoolbox" >nctoolbox (a MATLAB common data model interface)</a>
       </li>
@@ -1917,20 +1914,6 @@ or using ECMWF reanalysis on a reduced grid
     </p>
     <p></p>
 
-    <h2><a id="ncstat" name="ncstat">ncstat</a></h2>
-    <p>
-      The NCSTAT software is a collection of many operators for complex statistical processing and analysis of huge climate model outputs and datasets. NCSTAT is an open-source parallel, multithreaded software written in Fortran 2003 based on the OpenMP standard, using the NetCDF Fortran90 interface of the NetCDF library for input/output data transfer and the STATPACK library (also multithreaded and Fortran 2003) for numerical computations.<br><br>
-
-      The NCSTAT software is freely available here:<br><br>
-
-      <a href="https://pagesperso.locean-ipsl.upmc.fr/terray/ncstat2.2/index.html">https://pagesperso.locean-ipsl.upmc.fr/terray/ncstat2.2/index.html</a><br><br>
-
-      The STATPACK library is also freely available here:<br><br>
-
-      <a href="https://pagesperso.locean-ipsl.upmc.fr/terray/statpack2.3/index.html">https://pagesperso.locean-ipsl.upmc.fr/terray/statpack2.3/index.html</a>
-
-    </p>
-    <p></p>
     <h2><a id="nctoolbox" name="nctoolbox">nctoolbox (a MATLAB common data model interface)</a></h2>
 
     <p>
diff --git a/libdispatch/drc.c b/libdispatch/drc.c
index 351a5a477..9bfaa35a7 100644
--- a/libdispatch/drc.c
+++ b/libdispatch/drc.c
@@ -71,7 +71,6 @@ where the .rc entry has the simple form "key=value".
 If that entry is not found, then return NULL.
 
 @param key table entry key field
-@param  table entry key field
 @return value matching the key -- caller frees
 @return NULL if no entry of the form key=value exists
 */
@@ -270,12 +269,8 @@ done:
 }
 
 /**
- * Locate a entry by property key.
+ * Locate a entry by property key and host+port (may be null)
  * If duplicate keys, first takes precedence.
- * @param key to lookup
- * @param hostport to use for lookup
- * @param urlpath to use for lookup
- * @return the value of the key or NULL if not found.
  */
 char*
 NC_rclookup(const char* key, const char* hostport, const char* urlpath)
@@ -473,7 +468,7 @@ rccompile(const char* filepath)
             }
             line = rtag + 1;
             *rtag = '\0';
-            /* compile the url and pull out the host, port, and path */
+            /* compile the url and pull out the host and protocol */
             if(uri) ncurifree(uri);
             if(ncuriparse(url,&uri)) {
                 nclog(NCLOGERR, "Malformed [url] in %s entry: %s",filepath,line);
diff --git a/libdispatch/ds3util.c b/libdispatch/ds3util.c
index 5ccd01f9e..3b81d18c3 100644
--- a/libdispatch/ds3util.c
+++ b/libdispatch/ds3util.c
@@ -603,13 +603,18 @@ NC_getactives3profile(NCURI* uri, const char** profilep)
     int stat = NC_NOERR;
     const char* profile = NULL;
     struct AWSprofile* ap = NULL;
+    struct NCglobalstate* gs = NC_getglobalstate();
 
-    profile = ncurifragmentlookup(uri,"aws.profile");
-    if(profile == NULL)
-        profile = NC_rclookupx(uri,"AWS.PROFILE");
+    if (uri != NULL) {
+	profile = ncurifragmentlookup(uri,"aws.profile");
+	if(profile == NULL)
+		profile = NC_rclookupx(uri,"AWS.PROFILE");
+    }
 
-    if(profile == NULL)
-        profile = NC_getglobalstate()->aws.profile;
+    if(profile == NULL && gs->aws.profile != NULL) {
+        if((stat=NC_authgets3profile(gs->aws.profile,&ap))) goto done;
+	if(ap) profile = nulldup(gs->aws.profile);
+    }
 
     if(profile == NULL) {
         if((stat=NC_authgets3profile("default",&ap))) goto done;
@@ -837,13 +842,19 @@ awsparse(const char* text, NClist* profiles)
 	if(token ==  AWS_EOF) break; /* finished */
 	if(token ==  AWS_EOL) {continue;} /* blank line */
 	if(token != LBR) {stat = NCTHROW(NC_EINVAL); goto done;}
-	/* parse [profile name] */
+	/* parse [profile name] or [name] */
         token = awslex(parser);
 	if(token != AWS_WORD) {stat = NCTHROW(NC_EINVAL); goto done;}
 	assert(profile == NULL);
 	if((profile = (struct AWSprofile*)calloc(1,sizeof(struct AWSprofile)))==NULL)
 	    {stat = NC_ENOMEM; goto done;}
 	profile->name = ncbytesextract(parser->yytext);
+	if(strncmp("profile", profile->name, sizeof("profile")) == 0 ) {
+		token =  awslex(parser);
+		if(token != AWS_WORD) {stat = NCTHROW(NC_EINVAL); goto done;}
+		nullfree(profile->name);
+		profile->name = ncbytesextract(parser->yytext);
+	}
 	profile->entries = nclistnew();
         token = awslex(parser);
 	if(token != RBR) {stat = NCTHROW(NC_EINVAL); goto done;}
@@ -881,10 +892,22 @@ fprintf(stderr,">>> parse: entry=(%s,%s)\n",entry->key,entry->value);
 	        {stat = NCTHROW(NC_EINVAL); goto done;}
 	}
 
-	/* If this profile already exists, then replace old one */
+	/* If this profile already exists, then overwrite old one */
 	for(size_t i=0;i<nclistlength(profiles);i++) {
 	    struct AWSprofile* p = (struct AWSprofile*)nclistget(profiles,i);
 	    if(strcasecmp(p->name,profile->name)==0) {
+		// Keep unique parameters from previous (incomplete!?) profile
+		for (size_t j=0;j<nclistlength(p->entries);j++){
+			struct AWSentry* old = (struct AWSentry*)nclistget(p->entries,j);
+			int add = 1;
+			for (size_t z=0;z<nclistlength(profile->entries);z++){
+				struct AWSentry* new = (struct AWSentry*)nclistget(profile->entries,z);
+				add &= (strcasecmp(old->key,new->key)!=0);
+			}
+			if(add){
+			    nclistpush(profile->entries, nclistremove(p->entries,j--));
+			}
+		}
 		nclistset(profiles,i,profile);
                 profile = NULL;
 		/* reclaim old one */
diff --git a/libdispatch/ncuri.c b/libdispatch/ncuri.c
index f22b52ea6..e5be032e4 100644
--- a/libdispatch/ncuri.c
+++ b/libdispatch/ncuri.c
@@ -173,10 +173,7 @@ ncuriparse(const char* uri0, NCURI** durip)
 	2. convert all '\\' -> '\' (Temp hack to remove escape characters
                                     inserted by Windows or MinGW)
     */
-    p = uri;
-    while(*p == ' ') p++;
-    for(q=uri;*p;p++) {if((*p == '\\' && p[1] == '\\')) {continue;} else {*q++ = *p;}}
-    while((q - 1) >= uri && *(q - 1) == ' ') q--;
+    for(q=uri,p=uri;*p;p++) {if((*p == '\\' && p[1] == '\\') || *p < ' ') {continue;} else {*q++ = *p;}}
     *q = '\0';
 
     p = uri;
diff --git a/libhdf5/hdf5open.c b/libhdf5/hdf5open.c
index 082d528a0..c30d4e799 100644
--- a/libhdf5/hdf5open.c
+++ b/libhdf5/hdf5open.c
@@ -2675,7 +2675,7 @@ oinfo_list_add(user_data_t *udata, const hdf5_obj_info_t *oinfo)
  */
 static int
 read_hdf5_obj(hid_t grpid, const char *name,
-#if (defined(H5Lget_info_vers) && H5Lget_info_vers == 2) || defined(HAVE_H5LITERATE2)
+#if defined(H5Lget_info_vers) && H5Lget_info_vers == 2
 	      const H5L_info2_t *info,
 #else
 	      const H5L_info_t *info,
@@ -2857,15 +2857,9 @@ rec_read_metadata(NC_GRP_INFO_T *grp)
      * passed as a parameter to the callback function
      * read_hdf5_obj(). (I have also tried H5Oiterate(), but it is much
      * slower iterating over the same file - Ed.) */
-#ifdef HAVE_H5LITERATE2
-    if (H5Literate2(hdf5_grp->hdf_grpid, iter_index, H5_ITER_INC, &idx,
-                   read_hdf5_obj, (void *)&udata) < 0)
-        BAIL(NC_EHDFERR);
-#else
     if (H5Literate(hdf5_grp->hdf_grpid, iter_index, H5_ITER_INC, &idx,
                    read_hdf5_obj, (void *)&udata) < 0)
         BAIL(NC_EHDFERR);
-#endif
 
     /* Process the child groups found. (Deferred until now, so that the
      * types in the current group get processed and are available for


Test patch:
diff --git a/nczarr_test/CMakeLists.txt b/nczarr_test/CMakeLists.txt
index ee95c64a8..382b46d91 100644
--- a/nczarr_test/CMakeLists.txt
+++ b/nczarr_test/CMakeLists.txt
@@ -175,7 +175,7 @@ IF(NETCDF_ENABLE_TESTS)
     if(LARGE_FILE_TESTS)
       BUILD_BIN_TEST(test_readcaching)
       BUILD_BIN_TEST(test_writecaching)
-      build_bin_test_with_util_lib(test_chunkcases test_utils)
+      BUILD_BIN_TEST(test_chunkcases ${TSTCOMMONSRC})
       add_sh_test(nczarr_test run_cachetest)
       add_sh_test(nczarr_test run_chunkcases)
     ENDIF()
diff --git a/nczarr_test/Makefile.am b/nczarr_test/Makefile.am
index e868feb57..e6b95d1b5 100644
--- a/nczarr_test/Makefile.am
+++ b/nczarr_test/Makefile.am
@@ -13,10 +13,10 @@ LDADD = ${top_builddir}/liblib/libnetcdf.la
 
 TESTS_ENVIRONMENT =
 TEST_EXTENSIONS = .sh
-#SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver-verbose
-#sh_LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver-verbose
-#LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver-verbose
-#TESTS_ENVIRONMENT += export SETX=1;
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver-verbose
+sh_LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver-verbose
+LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver-verbose
+TESTS_ENVIRONMENT += export SETX=1;
 #TESTS_ENVIRONMENT += export NCTRACING=1;
 
 AM_CPPFLAGS += -I${top_srcdir} -I${top_srcdir}/libnczarr
diff --git a/nczarr_test/test_writecaching.c b/nczarr_test/test_writecaching.c
index d4238185f..a1d6b3e8b 100644
--- a/nczarr_test/test_writecaching.c
+++ b/nczarr_test/test_writecaching.c
@@ -87,11 +87,11 @@ main(void)
   {
     size_t mbused = getPeakRSS() / (1024 * 1024);
     printf("Max mem: %zu MB\n", mbused);
-    if(mbused > 128) {
-      printf("*** Failed: used: %luMB expected: < 128\n",mbused);
+    if(mbused > 100) {
+      printf("*** Failed: used: %luMB expected: < 100MB\n",mbused);
       return (1);
     } else {
-      printf("*** Passed: used: %luMB (< 128)\n",mbused);
+      printf("*** Passed: used: %luMB (< 100MB)\n",mbused);
       return 0;
     }
   }
diff --git a/unit_test/CMakeLists.txt b/unit_test/CMakeLists.txt
index c08055d93..39074424d 100644
--- a/unit_test/CMakeLists.txt
+++ b/unit_test/CMakeLists.txt
@@ -37,6 +37,9 @@ IF(NETCDF_BUILD_UTILITIES)
   # SDK Test
     build_bin_test(test_s3sdk ${XGETOPTSRC})
     add_sh_test(unit_test run_s3sdk)
+  #AWS Configuration test
+    build_bin_test(aws_config)
+    add_sh_test(unit_test run_aws_config)
   ENDIF()
 ENDIF()
 
diff --git a/unit_test/Makefile.am b/unit_test/Makefile.am
index 7f29e12cb..6061edaf4 100644
--- a/unit_test/Makefile.am
+++ b/unit_test/Makefile.am
@@ -43,6 +43,8 @@ if NETCDF_ENABLE_S3_TESTALL
 check_PROGRAMS += test_s3sdk
 TESTS += run_s3sdk.sh
 endif
+check_PROGRAMS += aws_config
+TESTS += run_aws_config.sh
 endif
 
 EXTRA_DIST = CMakeLists.txt run_s3sdk.sh run_reclaim_tests.sh
diff --git a/unit_test/aws_config.c b/unit_test/aws_config.c
new file mode 100644
index 000000000..1eb6c35c6
--- /dev/null
+++ b/unit_test/aws_config.c
@@ -0,0 +1,90 @@
+/*********************************************************************
+ *   Copyright 2018, UCAR/Unidata
+ *   See netcdf/COPYRIGHT file for copying and redistribution conditions.
+ *********************************************************************/
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <string.h>
+#include <assert.h>
+#include "netcdf.h"
+#include "ncrc.h"
+#include "ncpathmgr.h"
+#include "ncs3sdk.h"
+#include "ncuri.h"
+#include "nc4internal.h"
+
+NCS3INFO s3info;
+void* s3client = NULL;
+
+/* Forward */
+static void cleanup(void);
+
+#define STR(p) p?p:"NULL"
+#define CHECK(code) do {stat = check(code,__func__,__LINE__); if(stat) {goto done;}} while(0)
+
+static int
+check(int code, const char* fcn, int line)
+{
+    if(code == NC_NOERR) return code;
+    fprintf(stderr,"***FAIL: (%d) %s @ %s:%d\n",code,nc_strerror(code),fcn,line);
+    abort();
+}
+
+static void
+cleanup(void)
+{
+    if(s3client)
+        NC_s3sdkclose(s3client, &s3info, 0/*deleteit*/, NULL);
+    s3client = NULL;
+    NC_s3clear(&s3info);
+}
+
+int
+main(int argc, char** argv)
+{
+    int c = 0,stat = NC_NOERR;
+
+    /* Load RC and .aws/config */
+    CHECK(nc_initialize());
+    CHECK(NC_s3sdkinitialize());
+    NCglobalstate* gs = NC_getglobalstate();
+    //Not checking, aborts if ~/.aws/config doesn't exist
+    CHECK(NC_aws_load_credentials(gs));
+    
+    // Lets ensure the active profile is loaded
+    // from the configurtion files instead of an URL
+    const char* activeprofile = NULL;
+    CHECK(NC_getactives3profile(NULL, &activeprofile));
+
+    fprintf(stderr, "Active profile:%s\n", STR(activeprofile));
+    
+    // ARGV contains should contain "key[=value]" to verify
+    // if key was parsed when loading the aws config and if it's
+    // value is updated in case it's redefined on the .aws/credentials
+    for(int i = 1; i < argc; i++) {
+        const char *argkey = strtok(argv[i],"=");
+        const char *argvalue = strtok(NULL,"=");
+        const char* value = NULL;
+
+        NC_s3profilelookup(activeprofile,argkey,&value);
+        fprintf(stderr, "%s\t%s -> %s\n",value?"":"*** FAIL:", argv[i],value?value:"NOT DEFINED!");
+        if ( value == NULL 
+            || (argvalue != NULL 
+                && strncmp(value, argvalue, strlen(value)))
+        ){
+                c++;
+                stat |= NC_ERCFILE;
+        }
+    }
+
+done:
+    cleanup();
+    if(stat)
+        printf("*** FAIL: a total of %d keys were not found on the profile %s\n", c, STR(activeprofile));
+    else
+        printf("***PASS\n");
+    (void)NC_s3sdkfinalize();
+    (void)nc_finalize();
+    exit(stat?:0);
+}
diff --git a/unit_test/run_aws_config.sh b/unit_test/run_aws_config.sh
new file mode 100755
index 000000000..44b352664
--- /dev/null
+++ b/unit_test/run_aws_config.sh
@@ -0,0 +1,69 @@
+#!/bin/sh
+
+if test "x$srcdir" = x ; then srcdir=`pwd`; fi 
+. ../test_common.sh
+
+set -e
+
+#CMD="valgrind --leak-check=full"
+
+isolate "testdir_ut_aws_config"
+
+THISDIR=`pwd`
+cd $ISOPATH
+
+mkdir -p $THISDIR/.aws/
+
+test_cleanup() {
+    rm -rfv $THISDIR/.aws/
+}
+trap test_cleanup EXIT
+
+cat << 'EOF' > $THISDIR/.aws/config
+[uni]
+region = somewhere-1
+endpoint_url = https://example.com/bucket/prefix/1
+key = value
+extrakey = willbepropagated
+
+[profile unidata]
+region = us-east-1
+endpoint_url = https://s3.example.domain/
+dummy_key = dummy_value
+
+[profile play]
+region = us-east-1
+endpoint_url = https://endpoint.example.com/
+EOF
+
+cat << 'EOF' > $THISDIR/.aws/credentials
+[play] 
+aws_access_key_id = DummyKeys
+aws_secret_access_key = DummySecret
+
+[uni]
+region = somewhere-2
+endpoint_url = https://example.com/bucket/prefix/2
+key = value-overwritten
+EOF
+
+echo -e "Testing loading AWS configuration in ${THISDIR}/.aws/config"
+NC_TEST_AWS_DIR=${THISDIR} AWS_PROFILE=unidata ${CMD} ${execdir}/aws_config  endpoint_url region dummy_key
+echo "Status: $?"
+
+NC_TEST_AWS_DIR=${THISDIR} AWS_PROFILE=play ${CMD} ${execdir}/aws_config  endpoint_url region 
+echo "Status: $?"
+
+NC_TEST_AWS_DIR=${THISDIR} AWS_PROFILE=uni ${CMD} ${execdir}/aws_config  endpoint_url region key 
+echo "Status: $?"
+
+NC_TEST_AWS_DIR=${THISDIR} AWS_PROFILE=uni ${CMD} ${execdir}/aws_config key=value-overwritten region=somewhere-2 endpoint_url=https://example.com/bucket/prefix/2 extrakey=willbepropagated
+echo "Status: $?"
+
+# Will use profile=no
+NC_TEST_AWS_DIR=${THISDIR} ${CMD} ${execdir}/aws_config 2>&1 | grep -q 'Active profile:no'
+echo "Status: $?"
+echo -e "Finished"
+
+exit
+