This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
FYI: getP() for DSA keys and parameter-spec returned q
- From: Mark Wielaard <mark at klomp dot org>
- To: java-patches at gcc dot gnu dot org
- Date: 03 Dec 2002 19:46:01 +0100
- Subject: FYI: getP() for DSA keys and parameter-spec returned q
Hi,
Raif Naffah found an embarressing bug in all DSA*.getP() methods.
They returned q, not p.
2002-12-03 Raif Naffah <raif@fl.net.au>
* java/security/spec/DSAParameterSpec.java (getP): Return p, not q.
* java/security/spec/DSAPrivateKeySpec.java (getP): Likewise.
* java/security/spec/DSAPublicKeySpec.java (getP): Likewise.
Committed as obvious.
Cheers,
Mark
Index: java/security/spec/DSAParameterSpec.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/security/spec/DSAParameterSpec.java,v
retrieving revision 1.2
diff -u -r1.2 DSAParameterSpec.java
--- java/security/spec/DSAParameterSpec.java 22 Jan 2002 22:40:35 -0000 1.2
+++ java/security/spec/DSAParameterSpec.java 3 Dec 2002 18:45:46 -0000
@@ -74,7 +74,7 @@
*/
public BigInteger getP()
{
- return this.q;
+ return this.p;
}
/**
Index: java/security/spec/DSAPrivateKeySpec.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/security/spec/DSAPrivateKeySpec.java,v
retrieving revision 1.2
diff -u -r1.2 DSAPrivateKeySpec.java
--- java/security/spec/DSAPrivateKeySpec.java 22 Jan 2002 22:40:35 -0000 1.2
+++ java/security/spec/DSAPrivateKeySpec.java 3 Dec 2002 18:45:46 -0000
@@ -87,7 +87,7 @@
*/
public BigInteger getP()
{
- return this.q;
+ return this.p;
}
/**
Index: java/security/spec/DSAPublicKeySpec.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/security/spec/DSAPublicKeySpec.java,v
retrieving revision 1.2
diff -u -r1.2 DSAPublicKeySpec.java
--- java/security/spec/DSAPublicKeySpec.java 22 Jan 2002 22:40:35 -0000 1.2
+++ java/security/spec/DSAPublicKeySpec.java 3 Dec 2002 18:45:46 -0000
@@ -87,7 +87,7 @@
*/
public BigInteger getP()
{
- return this.q;
+ return this.p;
}
/**