From 3fef01fe5a22eef5d5d9e419989e2e5b01234d3b Mon Sep 17 00:00:00 2001 From: Daniel Segel <71151509+dhsegel@users.noreply.github.com> Date: Wed, 4 Mar 2026 15:01:54 -0800 Subject: [PATCH] SERVER-120938 Fix extensions_verify_visibility task on dynamic and sanitizer build variants GitOrigin-RevId: e940b3763988822ffc36b030480c0b7740fe4e19 --- evergreen/verify_all_extensions_visibility.sh | 2 +- evergreen/verify_extension_visibility_test.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/evergreen/verify_all_extensions_visibility.sh b/evergreen/verify_all_extensions_visibility.sh index 4866bdfbe41..07858b5c249 100755 --- a/evergreen/verify_all_extensions_visibility.sh +++ b/evergreen/verify_all_extensions_visibility.sh @@ -81,7 +81,7 @@ info "extension dir: $EXT_DIR" # Collect all extension .so files except libno_symbol_bad_extension.so. mapfile -t so_files < <( - find "$EXT_DIR" -maxdepth 1 -name '*.so' ! -name '*no_symbol_bad_extension*' | sort + find "$EXT_DIR" -maxdepth 1 -name '*_extension*.so' ! -name '*no_symbol_bad_extension*' | sort ) if [[ ${#so_files[@]} -eq 0 ]]; then diff --git a/evergreen/verify_extension_visibility_test.sh b/evergreen/verify_extension_visibility_test.sh index 3184637a321..9e14cfabf15 100755 --- a/evergreen/verify_extension_visibility_test.sh +++ b/evergreen/verify_extension_visibility_test.sh @@ -110,7 +110,7 @@ ext_ldd="$(ldd_libs_basename "$EXT_SO")" # Base regex for allowed dependencies (common to both direct and transitive) # NOTE: This is still a shared object (dlopen), so libc + loader will be dynamic. # Policy exceptions: OpenSSL (libcrypto/libssl) may be dynamic. libgcc_s is allowed because the server dynamically links it. -ALLOWED_DEPS_BASE='ld-linux.*\.so\.[0-9]+|libc\.so\.[0-9]+|libm\.so\.[0-9]+|libresolv\.so\.[0-9]+|libdl\.so\.[0-9]+|libpthread\.so\.[0-9]+|librt\.so\.[0-9]+|libcrypto\.so\.[0-9]+|libssl\.so\.[0-9]+|libgcc_s\.so\.[0-9]+|linux-vdso\.so\.[0-9]+' +ALLOWED_DEPS_BASE='ld-linux.*\.so\.[0-9.]+|libc\.so\.[0-9.]+|libm\.so\.[0-9.]+|libresolv\.so\.[0-9.]+|libdl\.so\.[0-9.]+|libpthread\.so\.[0-9.]+|librt\.so\.[0-9.]+|libcrypto\.so\.[0-9.]+|libssl\.so\.[0-9.]+|libgcc_s\.so\.[0-9.]+|linux-vdso\.so\.[0-9.]+' # 2a) Check direct dependencies (DT_NEEDED) - stricter control # Direct dependencies are what the extension explicitly links against. @@ -128,7 +128,7 @@ fi # Transitive deps come from libraries that the extension links against. # For example, if extension links OpenSSL, OpenSSL might pull in libz. # libz is allowed transitively (via OpenSSL) but not as a direct dependency. -ALLOWED_TRANSITIVE_DEPS_REGEX="^(${ALLOWED_DEPS_BASE}|libz\.so\.[0-9]+)$" +ALLOWED_TRANSITIVE_DEPS_REGEX="^(${ALLOWED_DEPS_BASE}|libz\.so\.[0-9.]+)$" unexpected_transitive_deps="$(echo "$ext_ldd" | grep -Ev "${ALLOWED_TRANSITIVE_DEPS_REGEX}" || true)" if [[ -n "$unexpected_transitive_deps" ]]; then