Skip to content

Commit

Permalink
improved error messages for evtxanalyze sessions and session
Browse files Browse the repository at this point in the history
  • Loading branch information
janstarke committed Jul 29, 2024
1 parent de301d4 commit cb837c4
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/bin/evtxanalyze/sessions/session_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,14 @@ impl SessionStore {

for filename in KNOWN_FILES {
let path = evtx_files_dir.join(filename);
if !(path.exists() && path.is_file()) {
log::warn!("unable to read file {}", path.display());

if ! path.exists() {
log::error!("expected file '{}', but it does not exist. Omitting it...", path.display());
continue;
}

if ! path.is_file() {
log::error!("tried to read '{}', but it is not a file. Omiting it...", path.display());
continue;
}

Expand Down

0 comments on commit cb837c4

Please sign in to comment.