-
-
Notifications
You must be signed in to change notification settings - Fork 174
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Logfile open mode and permission plus location configurability. #556
Conversation
71e81e4
to
d4716c2
Compare
Codecov ReportBase: 73.02% // Head: 72.97% // Decreases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## master #556 +/- ##
==========================================
- Coverage 73.02% 72.97% -0.06%
==========================================
Files 50 50
Lines 3029 3049 +20
==========================================
+ Hits 2212 2225 +13
- Misses 817 824 +7
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
24bc7d9
to
c9987d2
Compare
Hi, I saw there were two CVEs assigned to this: CVE-2022-48257 and CVE-2022-48258. Is there a reason why this is not merged yet? Thanks! |
Fixes MisterTea#555 (Tribute to Colin McRae)
c9987d2
to
04e64d4
Compare
In addition to opt-in for telemetry (see MisterTea#553) this uses the log directory override from MisterTea#556 to place the sentry/telemetry logs.
In addition to opt-in for telemetry (see MisterTea#553) this uses the log directory override from MisterTea#556 to place the sentry/telemetry logs.
// O_NOFOLLOW does not exist on windows | ||
FATAL_FAIL(::open(fullFname.c_str(), O_EXCL | O_CREAT, 0600)); | ||
#else | ||
FATAL_FAIL(::open(fullFname.c_str(), O_NOFOLLOW | O_EXCL | O_CREAT, 0600)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This formulation produces on failure
2024-11-18 11:53:08,053 FATAL [default] Stack Trace:
[0] 0x000000010088bcab et::LogHandler::createLogFile(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&)
[1] 0x000000010088b66d et::LogHandler::setupLogFiles(el::Configurations*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, bool, bool, bool, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>)
[2] 0x00000001007d352b main
[3] 0x0000000200a562cd start
Error: (2): No such file or directory
can we at least log the filename? it does not seem appropriate to use FATAL_FAIL in anything other than tests (and even then it would produce hard-to-action failures).
This addresses #555
Testing: