From 93b460a289ae1dde7baa2512010e3db6433fe505 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dominik=20Sch=C3=BCrmann?= Date: Sun, 15 Sep 2013 16:45:07 +0200 Subject: rename encryptAndSign to signAndEncrypt --- .../keychain/pgp/PgpOperation.java | 25 +--------------------- .../keychain/service/KeychainIntentService.java | 2 +- .../keychain/service/remote/OpenPgpService.java | 4 ++-- 3 files changed, 4 insertions(+), 27 deletions(-) diff --git a/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/pgp/PgpOperation.java b/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/pgp/PgpOperation.java index 823fb1f2e..d79ccdf3b 100644 --- a/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/pgp/PgpOperation.java +++ b/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/pgp/PgpOperation.java @@ -111,30 +111,7 @@ public class PgpOperation { } } - /** - * Encrypt and Sign data - * - * @param mContext - * @param mProgress - * @param mData - * @param mOutStream - * @param useAsciiArmor - * @param compression - * @param encryptionKeyIds - * @param symmetricEncryptionAlgorithm - * @param encryptionPassphrase - * @param signatureKeyId - * @param signatureHashAlgorithm - * @param signatureForceV3 - * @param signaturePassphrase - * @throws IOException - * @throws PgpGeneralException - * @throws PGPException - * @throws NoSuchProviderException - * @throws NoSuchAlgorithmException - * @throws SignatureException - */ - public void encryptAndSign(boolean useAsciiArmor, int compression, long[] encryptionKeyIds, + public void signAndEncrypt(boolean useAsciiArmor, int compression, long[] encryptionKeyIds, String encryptionPassphrase, int symmetricEncryptionAlgorithm, long signatureKeyId, int signatureHashAlgorithm, boolean signatureForceV3, String signaturePassphrase) throws IOException, PgpGeneralException, PGPException, NoSuchProviderException, diff --git a/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/service/KeychainIntentService.java b/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/service/KeychainIntentService.java index 6b459b969..749b46405 100644 --- a/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/service/KeychainIntentService.java +++ b/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/service/KeychainIntentService.java @@ -331,7 +331,7 @@ public class KeychainIntentService extends IntentService implements ProgressDial .getForceV3Signatures()); } else { Log.d(Constants.TAG, "encrypt..."); - operation.encryptAndSign(useAsciiArmor, compressionId, encryptionKeyIds, + operation.signAndEncrypt(useAsciiArmor, compressionId, encryptionKeyIds, encryptionPassphrase, Preferences.getPreferences(this) .getDefaultEncryptionAlgorithm(), secretKeyId, Preferences .getPreferences(this).getDefaultHashAlgorithm(), Preferences diff --git a/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/service/remote/OpenPgpService.java b/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/service/remote/OpenPgpService.java index 480b88ca5..4b451ecfb 100644 --- a/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/service/remote/OpenPgpService.java +++ b/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/service/remote/OpenPgpService.java @@ -242,11 +242,11 @@ public class OpenPgpService extends RemoteService { return; } - operation.encryptAndSign(asciiArmor, appSettings.getCompression(), keyIds, null, + operation.signAndEncrypt(asciiArmor, appSettings.getCompression(), keyIds, null, appSettings.getEncryptionAlgorithm(), appSettings.getKeyId(), appSettings.getHashAlgorithm(), true, passphrase); } else { - operation.encryptAndSign(asciiArmor, appSettings.getCompression(), keyIds, null, + operation.signAndEncrypt(asciiArmor, appSettings.getCompression(), keyIds, null, appSettings.getEncryptionAlgorithm(), Id.key.none, appSettings.getHashAlgorithm(), true, null); } -- cgit v1.2.3