[Webfunds-commits] java/webfunds/sox SimpleIssuer.java
Jeroen C. van Gelderen
gelderen@cypherpunks.ai
Tue, 5 Sep 2000 18:30:18 -0400 (AST)
gelderen 00/09/05 18:30:18
Modified: webfunds/ricardian KeyUtil.java
webfunds/sox SimpleIssuer.java
Log:
Remove erroneous dependency from SOX on Ricardian Contracts. Constants have
been moved from KeyUtil into Cryptix OpenPGP's PGPArmoury class.
Revision Changes Path
1.10 +3 -6 java/webfunds/ricardian/KeyUtil.java
Index: KeyUtil.java
===================================================================
RCS file: /home/webfunds/cvsroot/java/webfunds/ricardian/KeyUtil.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- KeyUtil.java 2000/09/05 19:39:03 1.9
+++ KeyUtil.java 2000/09/05 22:30:17 1.10
@@ -1,5 +1,5 @@
/*
- * $Id: KeyUtil.java,v 1.9 2000/09/05 19:39:03 iang Exp $
+ * $Id: KeyUtil.java,v 1.10 2000/09/05 22:30:17 gelderen Exp $
*
* Copyright (c) 2000 Systemics Inc on behalf of
* the WebFunds Development Team. All Rights Reserved.
@@ -54,20 +54,17 @@
return (PGPSecretKey)key;
}
- static public final String PUBLIC_KEY_BLOCK = "PGP PUBLIC KEY BLOCK";
- static public final String SECRET_KEY_BLOCK = "PGP PRIVATE KEY BLOCK";
-
public static String secretKeyToString(PGPSecretKey sk)
{
PGPArmoury armouredKey = new PGPArmoury(sk.getEncoded(),
- SECRET_KEY_BLOCK);
+ PGPArmoury.TYPE_SECRET_KEY);
return armouredKey.toString();
}
public static String publicKeyToString(PGPPublicKey pk)
{
PGPArmoury armouredKey = new PGPArmoury(pk.getEncoded(),
- PUBLIC_KEY_BLOCK);
+ PGPArmoury.TYPE_PUBLIC_KEY);
return armouredKey.toString();
}
1.17 +3 -4 java/webfunds/sox/SimpleIssuer.java
Index: SimpleIssuer.java
===================================================================
RCS file: /home/webfunds/cvsroot/java/webfunds/sox/SimpleIssuer.java,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- SimpleIssuer.java 2000/09/05 19:35:28 1.16
+++ SimpleIssuer.java 2000/09/05 22:30:18 1.17
@@ -1,5 +1,5 @@
/*
- * $Id: SimpleIssuer.java,v 1.16 2000/09/05 19:35:28 iang Exp $
+ * $Id: SimpleIssuer.java,v 1.17 2000/09/05 22:30:18 gelderen Exp $
*
* Copyright (c) Systemics Ltd 1995-1999 on behalf of
* the WebFunds Development Team. All Rights Reserved.
@@ -15,7 +15,6 @@
import cryptix.openpgp.*;
import cryptix.openpgp.util.PGPArmoury;
-import webfunds.ricardian.KeyUtil;
/**
* This class is a "SOX Agent" that passes basic requests to the Issuer.
@@ -184,9 +183,9 @@
if (!Crypto.verifyCertificate(serverCert, signerKey)) {
byte[] b = signerKey.getEncoded();
-PGPArmoury ok = new PGPArmoury(b, KeyUtil.PUBLIC_KEY_BLOCK);
+PGPArmoury ok = new PGPArmoury(b, PGPArmoury.TYPE_PUBLIC_KEY);
b = Crypto.getPublicKeyFromCert(serverCert).getEncoded();
-PGPArmoury sk = new PGPArmoury(b, KeyUtil.PUBLIC_KEY_BLOCK);
+PGPArmoury sk = new PGPArmoury(b, PGPArmoury.TYPE_PUBLIC_KEY);
logmsg(
"serverCert (first) not signed by operator Cert (2nd)\n\n"+
sk + "\n\n\n" + ok + "\n\n");