Subject: pkg/24649: Can we setenv SASL_ENTROPY_SOURCE in cyrus-sasl2?
To: None <gnats-bugs@gnats.netbsd.org>
From: None <diro@nixsys.bz>
List: netbsd-bugs
Date: 03/02/2004 22:40:37
>Number: 24649
>Category: pkg
>Synopsis: Can we setenv SASL_ENTROPY_SOURCE in cyrus-sasl2?
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: pkg-manager
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Tue Mar 02 22:42:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator:
>Release: NetBSD 1.6.1
>Organization:
>Environment:
System: NetBSD nixsys 1.6.1 NetBSD 1.6.1 (NIXSYS) #9: Fri Jan 30 23:41:47 EST 2004 root@nixsys:/usr/src/sys/arch/alpha/compile/NIXSYS alpha
Architecture: alpha
Machine: alpha
>Description:
Since /dev/*random isn't the only option for entropy, I thought the
cyrus-sasl2 pkg could use an env var, maybe something like SASL_ENTROPY_SOURCE or similar.
>How-To-Repeat:
I tested the above and it works fine:
nixsys% cd pkgsrc/security/cyrus-sasl2
nixsys% setenv SASL_ENTROPY_SOURCE /var/run/egd-pool
nixsys% make depend; make
<snip>
checking /dev/random to use... /var/run/egd-pool
</snip>
<snip>
configure: configuring in saslauthd
configure: running /bin/sh './configure' --prefix=/usr/pkg '--with-saslauthd
=/var/run/saslauthd' '--with-dblib=ndbm' '--with-dbpath=/usr/pkg/etc/sasldb'
'--with-plugindir=/usr/pkg/lib/sasl2' '--disable-anon' '--disable-checkapop'
'--disable-cram' '--disable-digest' '--disable-gssapi' '--disable-krb4' '--di
sable-login' '--disable-ntlm' '--disable-otp' '--disable-plain' '--disable-sq
l' '--disable-srp' '--disable-srp-setpass' '--without-pam' '--enable-anon' '-
-enable-checkapop' '--enable-cram' '--enable-otp' '--enable-plain' '--enable-
digest' '--with-rc4' '--with-openssl=/usr/pkg' '--with-devrandom=/var/run/egd
-pool' '--host=alpha--netbsd' '--prefix=/usr/pkg' 'LDFLAGS=-L/usr/pkg/lib -Wl
,-R/usr/pkg/lib' 'CFLAGS=-O2 -mieee -I/usr/pkg/include' 'CPPFLAGS=-I/usr/pkg/
include' 'host_alias=alpha--netbsd' 'CC=gcc' --cache-file=.././config.cache -
-srcdir=.
</snip>
>Fix:
In /sys/pkgsrc/security/cyrus-sasl2/Makefile:
<snip>
#.if exists(/dev/urandom)
#CONFIGURE_ARGS+= --with-devrandom=/dev/urandom
#.endif
.if defined(SASL_ENTROPY_SOURCE) && exists(${SASL_ENTROPY_SOURCE})
CONFIGURE_ARGS+= --with-devrandom=${SASL_ENTROPY_SOURCE}
.else
CONFIGURE_ARGS+= --with-devrandom=/dev/urandom
.endif
</snip>
or whatever better assigns SASL_DEV_RANDOM in work/cyrus-sasl-2.1.17/config.h
>Release-Note:
>Audit-Trail:
>Unformatted: