aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDominik Schürmann <dominik@dominikschuermann.de>2014-08-21 15:20:49 +0200
committerDominik Schürmann <dominik@dominikschuermann.de>2014-08-21 15:20:49 +0200
commitaa35f6cffbd18fcd2c40d0bc602e9803ca015e34 (patch)
treebf9552483f02838253d2175179349afbc56bd279
parent602fd546f772bb245e4145cfa7bc8c5d1463c127 (diff)
downloadopen-keychain-aa35f6cffbd18fcd2c40d0bc602e9803ca015e34.tar.gz
open-keychain-aa35f6cffbd18fcd2c40d0bc602e9803ca015e34.tar.bz2
open-keychain-aa35f6cffbd18fcd2c40d0bc602e9803ca015e34.zip
Fixing build with Spongy Castle 1.51
-rw-r--r--OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java8
-rw-r--r--OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/WrappedSignature.java27
m---------extern/spongycastle0
3 files changed, 5 insertions, 30 deletions
diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java
index 7d113241b..828bee848 100644
--- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java
+++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java
@@ -523,13 +523,7 @@ public class PgpDecryptVerify {
// update signature buffer if signature is also present
if (signature != null) {
- try {
- signature.update(buffer, 0, length);
- } catch (SignatureException e) {
- Log.e(Constants.TAG, "SignatureException -> Not a valid signature!", e);
- signatureResultBuilder.validSignature(false);
- signature = null;
- }
+ signature.update(buffer, 0, length);
}
alreadyWritten += length;
diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/WrappedSignature.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/WrappedSignature.java
index 03dbe4860..f24259ba7 100644
--- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/WrappedSignature.java
+++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/WrappedSignature.java
@@ -96,9 +96,6 @@ public class WrappedSignature {
} catch (PGPException e) {
// no matter
Log.e(Constants.TAG, "exception reading embedded signatures", e);
- } catch (IOException e) {
- // no matter
- Log.e(Constants.TAG, "exception reading embedded signatures", e);
}
return sigs;
}
@@ -150,27 +147,17 @@ public class WrappedSignature {
}
}
- public void update(byte[] data, int offset, int length) throws PgpGeneralException {
- try {
- mSig.update(data, offset, length);
- } catch(SignatureException e) {
- throw new PgpGeneralException(e);
- }
+ public void update(byte[] data, int offset, int length) {
+ mSig.update(data, offset, length);
}
- public void update(byte data) throws PgpGeneralException {
- try {
- mSig.update(data);
- } catch(SignatureException e) {
- throw new PgpGeneralException(e);
- }
+ public void update(byte data) {
+ mSig.update(data);
}
public boolean verify() throws PgpGeneralException {
try {
return mSig.verify();
- } catch(SignatureException e) {
- throw new PgpGeneralException(e);
} catch(PGPException e) {
throw new PgpGeneralException(e);
}
@@ -179,8 +166,6 @@ public class WrappedSignature {
boolean verifySignature(PGPPublicKey key) throws PgpGeneralException {
try {
return mSig.verifyCertification(key);
- } catch (SignatureException e) {
- throw new PgpGeneralException("Sign!", e);
} catch (PGPException e) {
throw new PgpGeneralException("Error!", e);
}
@@ -189,8 +174,6 @@ public class WrappedSignature {
boolean verifySignature(PGPPublicKey masterKey, PGPPublicKey subKey) throws PgpGeneralException {
try {
return mSig.verifyCertification(masterKey, subKey);
- } catch (SignatureException e) {
- throw new PgpGeneralException("Sign!", e);
} catch (PGPException e) {
throw new PgpGeneralException("Error!", e);
}
@@ -199,8 +182,6 @@ public class WrappedSignature {
boolean verifySignature(PGPPublicKey key, String uid) throws PgpGeneralException {
try {
return mSig.verifyCertification(uid, key);
- } catch (SignatureException e) {
- throw new PgpGeneralException("Error!", e);
} catch (PGPException e) {
throw new PgpGeneralException("Error!", e);
}
diff --git a/extern/spongycastle b/extern/spongycastle
-Subproject 512965ac61c2b0054550e8daed71242d51f4da5
+Subproject d65458612838f7de0b222c0b7168db97018cac3