Fix some 1.6isms and add a missing @Override
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@6478 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -84,7 +84,9 @@ public class AESAuthRequest extends AuthRequest
|
|||||||
try {
|
try {
|
||||||
_contents = SecureUtil.getAESCipher(Cipher.DECRYPT_MODE, _key).doFinal(_contents);
|
_contents = SecureUtil.getAESCipher(Cipher.DECRYPT_MODE, _key).doFinal(_contents);
|
||||||
} catch (GeneralSecurityException gse) {
|
} catch (GeneralSecurityException gse) {
|
||||||
throw new IOException("Failed to decrypt credentials", gse);
|
IOException ioe = new IOException("Failed to decrypt credentials");
|
||||||
|
ioe.initCause(gse);
|
||||||
|
throw ioe;
|
||||||
}
|
}
|
||||||
|
|
||||||
ByteArrayInputStream byteIn = new ByteArrayInputStream(_contents);
|
ByteArrayInputStream byteIn = new ByteArrayInputStream(_contents);
|
||||||
@@ -108,13 +110,16 @@ public class AESAuthRequest extends AuthRequest
|
|||||||
out.writeInt(encrypted.length);
|
out.writeInt(encrypted.length);
|
||||||
out.write(encrypted);
|
out.write(encrypted);
|
||||||
} catch (GeneralSecurityException gse) {
|
} catch (GeneralSecurityException gse) {
|
||||||
throw new IOException("Failed to encrypt credentials", gse);
|
IOException ioe = new IOException("Failed to encrypt credentials");
|
||||||
|
ioe.initCause(gse);
|
||||||
|
throw ioe;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Read in our encrypted contents.
|
* Read in our encrypted contents.
|
||||||
*/
|
*/
|
||||||
|
@Override
|
||||||
public void readObject (ObjectInputStream in)
|
public void readObject (ObjectInputStream in)
|
||||||
throws IOException, ClassNotFoundException
|
throws IOException, ClassNotFoundException
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user