Blame SOURCES/ntp-4.2.6p5-identlen.patch

6e16f6
diff -up ntp-4.2.6p5/html/keygen.html.identlen ntp-4.2.6p5/html/keygen.html
6e16f6
--- ntp-4.2.6p5/html/keygen.html.identlen	2012-12-05 11:43:46.666828864 +0100
6e16f6
+++ ntp-4.2.6p5/html/keygen.html	2012-12-05 12:00:45.331085982 +0100
6e16f6
@@ -43,7 +43,7 @@
6e16f6
 
6e16f6
 

Synopsis

6e16f6
 
6e16f6
-

<tt>ntp-keygen [ -deGHIMPT ] [ -c [RSA-MD2 | RSA-MD5 | RSA-SHA

6e16f6
+

<tt>ntp-keygen [ -deGHIMPT ] [ -b modulus ] [ -c [RSA-MD2 | RSA-MD5 | RSA-SHA

6e16f6
 		| RSA-SHA1 | RSA-MDC2 | RSA-RIPEMD160 | DSA-SHA | DSA-SHA1 ] ] [
6e16f6
 		-i group ]
6e16f6
 		[ -m modulus ]  [ -p passwd2 ] [ -q passwd1 ] [ -S
6e16f6
@@ -140,6 +140,8 @@
6e16f6
 

Command Line Options

6e16f6
 
6e16f6
 
6e16f6
+
<tt>-b modulus</tt>
6e16f6
+
Set the modulus for generating identity keys to modulus bits. The modulus defaults to 256, but can be set from 256 (32 octets) to 2048 (256 octets). Use the larger moduli with caution, as this can consume considerable computing resources and increases the size of authenticated packets.
6e16f6
 
6e16f6
 
<tt>-c [ RSA-MD2 | RSA-MD5 | RSA-SHA | RSA-SHA1 | RSA-MDC2 | RSA-RIPEMD160 | DSA-SHA | DSA-SHA1 ]</tt>
6e16f6
 
Select certificate and message digest/signature encryption scheme. Note that
6e16f6
diff -up ntp-4.2.6p5/util/ntp-keygen-opts.def.identlen ntp-4.2.6p5/util/ntp-keygen-opts.def
6e16f6
--- ntp-4.2.6p5/util/ntp-keygen-opts.def.identlen	2009-12-09 08:36:35.000000000 +0100
6e16f6
+++ ntp-4.2.6p5/util/ntp-keygen-opts.def	2012-12-05 12:03:17.991124514 +0100
6e16f6
@@ -16,6 +16,19 @@ include        = '#include <stdlib.h>';
6e16f6
 #include       version.def
6e16f6
 
6e16f6
 flag = {
6e16f6
+    value     = b;
6e16f6
+    name      = imbits;
6e16f6
+    arg-type  = number;
6e16f6
+    arg-name  = imbits;
6e16f6
+    arg-range = '256->2048';
6e16f6
+    ifdef     = OPENSSL;
6e16f6
+    descrip   = "identity modulus bits";
6e16f6
+    doc = <<-  _EndOfDoc_
6e16f6
+	The number of bits in the identity modulus.  The default is 256.
6e16f6
+	_EndOfDoc_;
6e16f6
+};
6e16f6
+
6e16f6
+flag = {
6e16f6
     value     = c;
6e16f6
     name      = certificate;
6e16f6
     arg-type  = string;
6e16f6
diff -up ntp-4.2.6p5/util/ntp-keygen.c.identlen ntp-4.2.6p5/util/ntp-keygen.c
6e16f6
--- ntp-4.2.6p5/util/ntp-keygen.c.identlen	2011-12-25 00:27:16.000000000 +0100
6e16f6
+++ ntp-4.2.6p5/util/ntp-keygen.c	2012-12-05 12:03:43.318130907 +0100
6e16f6
@@ -318,6 +318,10 @@ main(
6e16f6
 		mvpar++;
6e16f6
 		nkeys = OPT_VALUE_MV_KEYS;
6e16f6
 	}
6e16f6
+
6e16f6
+	if (HAVE_OPT( IMBITS ))
6e16f6
+		modulus2 = OPT_VALUE_IMBITS;
6e16f6
+
6e16f6
 	if (HAVE_OPT( MODULUS ))
6e16f6
 		modulus = OPT_VALUE_MODULUS;
6e16f6