log "unspecified" flags differently

This commit is contained in:
Vincent Breitmoser
2014-09-22 17:02:53 +02:00
parent f6ac887ce0
commit 862c9a8b3c
3 changed files with 14 additions and 2 deletions

View File

@@ -389,9 +389,17 @@ public class ProviderHelper {
// see above
if (masterKeyId == keyId) {
log(LOG_TYPES_FLAG_MASTER[(c?1:0) + (e?2:0) + (s?4:0) + (a?8:0)]);
if (key.getKeyUsage() == null) {
log(LogType.MSG_IP_MASTER_FLAGS_UNSPECIFIED);
} else {
log(LOG_TYPES_FLAG_MASTER[(c?1:0) + (e?2:0) + (s?4:0) + (a?8:0)]);
}
} else {
log(LOG_TYPES_FLAG_SUBKEY[(c?1:0) + (e?2:0) + (s?4:0) + (a?8:0)]);
if (key.getKeyUsage() == null) {
log(LogType.MSG_IP_SUBKEY_FLAGS_UNSPECIFIED);
} else {
log(LOG_TYPES_FLAG_SUBKEY[(c ? 1 : 0) + (e ? 2 : 0) + (s ? 4 : 0) + (a ? 8 : 0)]);
}
}
Date creation = key.getCreationTime();