X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=tools%2Fgenssl;h=b658efb117d927ee1f6e5fcca2ad79f1f13262ae;hb=c23d09f65084e6088111dc974f0e290b042de89d;hp=6cd9fa7165366faf066a02eab4db39e7d9bdb974;hpb=448c50fa4d344fb05a6ffdfec9a21d980ea3ab99;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/tools/genssl b/tools/genssl index 6cd9fa716..b658efb11 100755 --- a/tools/genssl +++ b/tools/genssl @@ -1,4 +1,4 @@ -#!/usr/bin/env perl -w +#!/usr/bin/env perl # # InspIRCd -- Internet Relay Chat Daemon # @@ -82,9 +82,10 @@ time_stamping_key __GNUTLS_END__ close($tmp); my $certtool = `uname -s` eq "Darwin\n" ? 'gnutls-certtool' : 'certtool'; - $status ||= system "$certtool --version >/dev/null 2>1"; + $status ||= system "$certtool --version >/dev/null 2>&1"; $status ||= system "$certtool --generate-privkey --outfile key.pem"; $status ||= system "$certtool --generate-self-signed --load-privkey key.pem --outfile cert.pem --template $tmp"; + $status ||= system "$certtool --generate-dh-params --bits 2048 --outfile dhparams.pem"; } elsif (lc $ARGV[0] eq 'openssl') { my $tmp = new File::Temp(); print $tmp <<__OPENSSL_END__; @@ -97,7 +98,7 @@ $common_name $email __OPENSSL_END__ close($tmp); - $status ||= system 'openssl version >/dev/null 2>1'; + $status ||= system 'openssl version >/dev/null 2>&1'; $status ||= system "cat $tmp | openssl req -x509 -nodes -newkey rsa:2048 -keyout key.pem -out cert.pem -days $days 2>/dev/null"; $status ||= system 'openssl dhparam -out dhparams.pem 2048'; }