On Sunday 27 January 2008 13:40, nextgens at freenetproject.org wrote:
> Author: nextgens
> Date: 2008-01-27 13:40:56 +0000 (Sun, 27 Jan 2008)
> New Revision: 17318
>
> Modified:
> trunk/freenet/src/freenet/crypt/DSAPrivateKey.java
> Log:
> doh!
>
> Modified: trunk/freenet/src/freenet/crypt/DSAPrivateKey.java
> ===================================================================
> --- trunk/freenet/src/freenet/crypt/DSAPrivateKey.java 2008-01-27
> 13:32:37
UTC (rev 17317)
> +++ trunk/freenet/src/freenet/crypt/DSAPrivateKey.java 2008-01-27
> 13:40:56
UTC (rev 17318)
> @@ -35,7 +35,7 @@
> BigInteger tempX;
> do {
> tempX = new NativeBigInteger(256, r);
> - } while (tempX.compareTo(g.getQ()) > -1 ||
tempX.equals(BigInteger.ZERO));
> + } while (tempX.compareTo(g.getQ()) > -1 ||
tempX.compareTo(BigInteger.ZERO) < 1);
I'm pretty sure we don't want it to equal zero. And new
NativeBigInteger(numbits, random) will never return a negative number.
So this patch is incorrect.
> this.x = tempX;
> }
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL:
<https://emu.freenetproject.org/pipermail/devl/attachments/20080128/5b0accc7/attachment.pgp>