PgpDecryptVerify is now context-free

This commit is contained in:
Dominik Schürmann
2014-04-11 19:43:46 +02:00
parent 9b15482c41
commit 45b450e78a
3 changed files with 81 additions and 23 deletions

View File

@@ -444,7 +444,16 @@ public class KeychainIntentService extends IntentService
// verifyText and decrypt returning additional resultData values for the
// verification of signatures
PgpDecryptVerify.Builder builder = new PgpDecryptVerify.Builder(this, inputData, outStream);
PgpDecryptVerify.Builder builder = new PgpDecryptVerify.Builder(
new ProviderHelper(this),
new PgpDecryptVerify.PassphraseCache() {
@Override
public String getCachedPassphrase(long masterKeyId) {
return PassphraseCacheService.getCachedPassphrase(
KeychainIntentService.this, masterKeyId);
}
},
inputData, outStream);
builder.progressDialogUpdater(this);
builder.allowSymmetricDecryption(true)