certify: preserve user id certificates when saving secret keys

This commit is contained in:
Vincent Breitmoser
2014-03-15 18:15:39 +01:00
parent 95be228b47
commit 87004fd0ca
4 changed files with 73 additions and 7 deletions

View File

@@ -543,8 +543,9 @@ public class KeychainIntentService extends IntentService
ProviderHelper.getPGPSecretKeyRingByKeyId(this, masterKeyId),
oldPassPhrase, newPassPhrase);
} else {
keyOperations.buildSecretKey(userIds, keys, keysUsages, keysExpiryDates, masterKeyId,
oldPassPhrase, newPassPhrase);
PGPPublicKey pubkey = ProviderHelper.getPGPPublicKeyByKeyId(this, masterKeyId);
keyOperations.buildSecretKey(userIds, keys, keysUsages, keysExpiryDates,
pubkey, oldPassPhrase, newPassPhrase);
}
PassphraseCacheService.addCachedPassphrase(this, masterKeyId, newPassPhrase);