From babce676a8e87084dc605b6fe52863dc0f59b935 Mon Sep 17 00:00:00 2001 From: jakob Date: Mon, 13 Aug 2001 07:28:32 +0000 Subject: [PATCH] 1. change /dev/urandom -> /dev/arandom 2. fix potentially bug and/or hole in implementation of PEM_DIR variable. from mpech@ --- security/stunnel/patches/patch-configure | 61 ++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 security/stunnel/patches/patch-configure diff --git a/security/stunnel/patches/patch-configure b/security/stunnel/patches/patch-configure new file mode 100644 index 00000000000..6934e12686a --- /dev/null +++ b/security/stunnel/patches/patch-configure @@ -0,0 +1,61 @@ +$OpenBSD: patch-configure,v 1.1 2001/08/13 07:28:32 jakob Exp $ +--- configure.orig Fri Aug 10 12:30:48 2001 ++++ configure Mon Aug 13 09:58:52 2001 +@@ -959,20 +959,20 @@ EOF + # Check whether --with-pem-dir or --without-pem-dir was given. + if test "${with_pem_dir+set}" = set; then + withval="$with_pem_dir" +- PEM_DIR="$withval" +- ++else ++ withval="/etc/ssl" + fi ++PEM_DIR="$withval" + + if test -n "$PEM_DIR" ; then + cat >> confdefs.h <> confdefs.h <> confdefs.h <&6 +-echo "configure:1030: checking for "/dev/urandom"" >&5 ++ac_safe=`echo ""/dev/arandom"" | sed 'y%./+-%__p_%'` ++echo $ac_n "checking for "/dev/arandom"""... $ac_c" 1>&6 ++echo "configure:1030: checking for "/dev/arandom"" >&5 + if eval "test \"`echo '$''{'ac_cv_file_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + if test "$cross_compiling" = yes; then + { echo "configure: error: Cannot check for file existence when cross compiling" 1>&2; exit 1; } + else +- if test -r "/dev/urandom"; then ++ if test -r "/dev/arandom"; then + eval "ac_cv_file_$ac_safe=yes" + else + eval "ac_cv_file_$ac_safe=no" +@@ -1043,7 +1043,7 @@ fi + if eval "test \"`echo '$ac_cv_file_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + +- RANDOM_FILE="/dev/urandom"; ++ RANDOM_FILE="/dev/arandom"; + + + else