Author: jflesch
Date: 2007-07-27 18:42:32 +0000 (Fri, 27 Jul 2007)
New Revision: 14398
Modified:
trunk/apps/Thaw/src/frost/crypt/FrostCrypt.java
Log:
Remove java 1.5 code in frost/crypt/FrostCrypt.java
Modified: trunk/apps/Thaw/src/frost/crypt/FrostCrypt.java
===================================================================
--- trunk/apps/Thaw/src/frost/crypt/FrostCrypt.java 2007-07-27 18:28:21 UTC
(rev 14397)
+++ trunk/apps/Thaw/src/frost/crypt/FrostCrypt.java 2007-07-27 18:42:32 UTC
(rev 14398)
@@ -85,7 +85,7 @@
//the return value
String[] result = new String[2];
- StringBuilder temp = new StringBuilder();
+ StringBuffer temp = new StringBuffer();
//create the keys
temp.append( new
String(Base64.encode(pubKey.getExponent().toByteArray())));
@@ -94,7 +94,7 @@
result[1] = temp.toString(); // public key
//rince and repeat, this time exactly the way its done in the
constructor
- temp = new StringBuilder();
+ temp = new StringBuffer();
temp.append(new
String(Base64.encode(privKey.getModulus().toByteArray())));
temp.append(":");
temp.append(new
String(Base64.encode(privKey.getPublicExponent().toByteArray())));
@@ -531,7 +531,7 @@
sha256.update(food);
byte[] poop = sha256.digest();
- StringBuilder sb = new StringBuilder();
+ StringBuffer sb = new StringBuffer();
for (int i=0; i < poop.length; i++) {
sb.append(Integer.toString( ( poop[i] & 0xff ) + 0x100 ,
16).substring(1));
}
@@ -580,7 +580,7 @@
byte[] poop = sha256.digest();
- StringBuilder sb = new StringBuilder();
+ StringBuffer sb = new StringBuffer();
for (int i=0; i < poop.length; i++) {
sb.append(Integer.toString( ( poop[i] & 0xff ) + 0x100 ,
16).substring(1));
}