mirror of
https://github.com/carlospolop/PEASS-ng
synced 2024-11-20 12:39:21 +01:00
Better error handling in FileAnalysis
The previous specific check doesn't handle the following exception, causing it to be catched by the last try/catch block. Error looking for regexes inside files: System.AggregateException: One or more errors occurred. ---> System.UnauthorizedAccessException: Access to the path '<REDACTED>' is denied.
This commit is contained in:
parent
31aed5cd92
commit
340256b3b3
@ -444,7 +444,7 @@ namespace winPEAS.Checks
|
||||
foundRegexes[regex_obj.name][regex.name] = fileResults;
|
||||
}
|
||||
}
|
||||
catch (System.IO.IOException)
|
||||
catch (Exception ex)
|
||||
{
|
||||
// Cannot read the file
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user