// return it)
for (final PGPPublicKeyRing candidate : trusted) {
final PGPPublicKey firstKey = candidate.getPublicKey();
final PgpKeyId candidateKeyId = new PgpKeyId(firstKey);
// Try to refresh
PGPPublicKeyRing newKeyRing;
try {
newKeyRing = getPublicKey(candidateKeyId);
}
catch (final Exception e) {
// Can't retrieve, so keep the old one for now
stillTrusted.add(candidate);
result.put(candidateKeyId,
"WARNING: Retained original (download issue)");
continue;
}
// Do not store if the first key is revoked
if (newKeyRing.getPublicKey().isRevoked()) {
result.put(candidateKeyId,
"WARNING: Key revoked, so removed from trust list");
}
else {
stillTrusted.add(newKeyRing);