mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-01 23:28:08 -07:00
net-mail/courier-imap: openssl gendh is no more valid
Closes: https://bugs.gentoo.org/956634 Signed-off-by: Alfredo Tupone <tupone@gentoo.org>
This commit is contained in:
@@ -1,7 +1,5 @@
|
||||
#! /bin/sh
|
||||
#
|
||||
# mkimapdcert,v 1.1 2001/01/02 03:54:25 drobbins Exp
|
||||
#
|
||||
# Copyright 2000 Double Precision, Inc. See COPYING for
|
||||
# distribution information.
|
||||
#
|
||||
@@ -13,7 +11,6 @@ test -x /usr/bin/openssl || exit 0
|
||||
|
||||
prefix="/usr"
|
||||
pemfile="/etc/courier-imap/imapd.pem"
|
||||
randfile="/etc/courier-imap/imapd.rand"
|
||||
|
||||
if test -f $pemfile
|
||||
then
|
||||
@@ -27,13 +24,9 @@ chown root $pemfile
|
||||
|
||||
cleanup() {
|
||||
rm -f $pemfile
|
||||
rm -f $randfile
|
||||
exit 1
|
||||
}
|
||||
|
||||
dd if=/dev/urandom of=$randfile count=1 2>/dev/null
|
||||
/usr/bin/openssl req -new -x509 -days 365 -nodes \
|
||||
-config /etc/courier-imap/imapd.cnf -out $pemfile -keyout $pemfile || cleanup
|
||||
/usr/bin/openssl gendh -rand $randfile 512 >> $pemfile || cleanup
|
||||
/usr/bin/openssl x509 -subject -dates -fingerprint -noout -in $pemfile || cleanup
|
||||
rm -f $randfile
|
||||
|
||||
@@ -13,7 +13,6 @@ test -x /usr/bin/openssl || exit 0
|
||||
|
||||
prefix="/usr"
|
||||
pemfile="/etc/courier-imap/pop3d.pem"
|
||||
randfile="/etc/courier-imap/pop3d.rand"
|
||||
|
||||
if test -f $pemfile
|
||||
then
|
||||
@@ -27,13 +26,9 @@ chown root $pemfile
|
||||
|
||||
cleanup() {
|
||||
rm -f $pemfile
|
||||
rm -f $randfile
|
||||
exit 1
|
||||
}
|
||||
|
||||
dd if=/dev/urandom of=$randfile count=1 2>/dev/null
|
||||
/usr/bin/openssl req -new -x509 -days 365 -nodes \
|
||||
-config /etc/courier-imap/pop3d.cnf -out $pemfile -keyout $pemfile || cleanup
|
||||
/usr/bin/openssl gendh -rand $randfile 512 >> $pemfile || cleanup
|
||||
/usr/bin/openssl x509 -subject -dates -fingerprint -noout -in $pemfile || cleanup
|
||||
rm -f $randfile
|
||||
|
||||
Reference in New Issue
Block a user