]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
Check openssl_bin path is executable before using.
authorDarren Tucker <dtucker@dtucker.net>
Fri, 6 Jan 2023 23:34:18 +0000 (10:34 +1100)
committerDarren Tucker <dtucker@dtucker.net>
Fri, 6 Jan 2023 23:34:18 +0000 (10:34 +1100)
configure.ac

index be8d9ad821e15b935ecee3f5bc3f428686578ca4..f6802500fcedd37540df561960febdb9e68f789c 100644 (file)
@@ -2696,14 +2696,11 @@ AC_ARG_WITH([ssl-dir],
                        esac
                        if test -d "$withval/lib"; then
                                libcrypto_path="${withval}/lib"
-                               openssl_bin="${withval}/bin/openssl"
                        elif test -d "$withval/lib64"; then
                                libcrypto_path="$withval/lib64"
-                               openssl_bin="${withval}/bin/openssl"
                        else
                                # Built but not installed
                                libcrypto_path="${withval}"
-                               openssl_bin="${withval}/apps/openssl"
                        fi
                        if test -n "${rpath_opt}"; then
                                LDFLAGS="-L${libcrypto_path} ${rpath_opt}${libcrypto_path} ${LDFLAGS}"
@@ -2715,6 +2712,11 @@ AC_ARG_WITH([ssl-dir],
                        else
                                CPPFLAGS="-I${withval} ${CPPFLAGS}"
                        fi
+                       if test -x "${withval}/bin/openssl"; then
+                               openssl_bin="${withval}/bin/openssl"
+                       elif test -x "${withval}/apps/openssl"; then
+                               openssl_bin="${withval}/apps/openssl"
+                       fi
                fi
        ]
 )