X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Fjournal%2Fjournalctl.c;h=bee26fd7692ed4216e6911ace1d8c39c231bca8e;hb=a45b9fca6b91a767dcd9060cfcb30617dad234c7;hp=0bbf4a045d3b289bdb2d84f480ad660b2ade2aeb;hpb=89fef99014662a5a63e7deaedd6292b7fb4ab2f8;p=elogind.git diff --git a/src/journal/journalctl.c b/src/journal/journalctl.c index 0bbf4a045..bee26fd76 100644 --- a/src/journal/journalctl.c +++ b/src/journal/journalctl.c @@ -659,13 +659,15 @@ static int verify(sd_journal *j) { assert(j); + log_show_color(true); + HASHMAP_FOREACH(f, j->files, i) { int k; usec_t from, to, total; #ifdef HAVE_GCRYPT if (!arg_verify_key && JOURNAL_HEADER_SEALED(f->header)) - log_warning("Journal file %s has sealing enabled but verification key has not been passed using --verify-key=.", f->path); + log_notice("Journal file %s has sealing enabled but verification key has not been passed using --verify-key=.", f->path); #endif k = journal_file_verify(f, arg_verify_key, &from, &to, &total, true); @@ -679,11 +681,18 @@ static int verify(sd_journal *j) { char a[FORMAT_TIMESTAMP_MAX], b[FORMAT_TIMESTAMP_MAX], c[FORMAT_TIMESPAN_MAX]; log_info("PASS: %s", f->path); - if (arg_verify_key && JOURNAL_HEADER_SEALED(f->header)) - log_info("=> Validated from %s to %s, %s missing", - format_timestamp(a, sizeof(a), from), - format_timestamp(b, sizeof(b), to), - format_timespan(c, sizeof(c), total > to ? total - to : 0)); + if (arg_verify_key && JOURNAL_HEADER_SEALED(f->header)) { + if (from > 0) { + log_info("=> Validated from %s to %s, final %s entries not sealed.", + format_timestamp(a, sizeof(a), from), + format_timestamp(b, sizeof(b), to), + format_timespan(c, sizeof(c), total > to ? total - to : 0)); + } else if (total > 0) + log_info("=> No sealing yet, %s of entries not sealed.", + format_timespan(c, sizeof(c), total)); + else + log_info("=> No sealing yet, no entries in file."); + } } }