mirror of
https://github.com/moparisthebest/open-keychain
synced 2024-11-27 11:12:15 -05:00
commit
dce5b92d25
Binary file not shown.
@ -132,7 +132,8 @@ public class PgpMain {
|
||||
}
|
||||
|
||||
// Not BC due to the use of Spongy Castle for Android
|
||||
public static final String BOUNCY_CASTLE_PROVIDER_NAME = "SC";
|
||||
public static final String SC = BouncyCastleProvider.PROVIDER_NAME;
|
||||
public static final String BOUNCY_CASTLE_PROVIDER_NAME = SC;
|
||||
|
||||
private static final int[] PREFERRED_SYMMETRIC_ALGORITHMS = new int[] {
|
||||
SymmetricKeyAlgorithmTags.AES_256, SymmetricKeyAlgorithmTags.AES_192,
|
||||
@ -323,8 +324,9 @@ public class PgpMain {
|
||||
}
|
||||
|
||||
PGPSecretKeyRing newKeyRing = PGPSecretKeyRing.copyWithNewPassword(keyRing,
|
||||
oldPassPhrase.toCharArray(), newPassPhrase.toCharArray(), keyRing.getSecretKey().getKeyEncryptionAlgorithm(),
|
||||
new SecureRandom(), BOUNCY_CASTLE_PROVIDER_NAME);
|
||||
new JcePBESecretKeyDecryptorBuilder(
|
||||
new JcaPGPDigestCalculatorProviderBuilder().setProvider(BOUNCY_CASTLE_PROVIDER_NAME).build()).setProvider(BOUNCY_CASTLE_PROVIDER_NAME).build(oldPassPhrase.toCharArray()),
|
||||
new JcePBESecretKeyEncryptorBuilder(keyRing.getSecretKey().getKeyEncryptionAlgorithm()).build(newPassPhrase.toCharArray()));
|
||||
|
||||
updateProgress(progress, R.string.progress_savingKeyRing, 50, 100);
|
||||
|
||||
|
@ -49,7 +49,7 @@ On error see: http://code.google.com/p/zxing/issues/detail?id=1207
|
||||
|
||||
## Build Spongy Castle
|
||||
|
||||
Spongy Castle is the stock Bouncy Castle libraries with a couple of small changes to make it work on Android. OpenPGP-Keychain uses a forked version with some small changes to improve key import speed. These changes will be sent to Bouncy Castle, and Spongy Castle will be used again when they have filtered down.
|
||||
Spongy Castle is the stock Bouncy Castle libraries with a couple of small changes to make it work on Android. OpenPGP-Keychain uses a forked version with some small changes to improve key import speed. These changes have been sent to Bouncy Castle, and Spongy Castle will be used again when they have filtered down.
|
||||
|
||||
see
|
||||
* http://rtyley.github.com/spongycastle/
|
||||
|
Loading…
Reference in New Issue
Block a user