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
Fix logbuilder for target 'agent' on <localfile> #4942
Conversation
Analysis_dynamic_valgrind logcollector analysis:Commit: c21fc1a Lines executed:31.41% of 1859
Coverage report detail: coverage-report-summary |
Analysis_dynamic_valgrind syscheckd analysis:Commit: c21fc1a Lines executed:26.49% of 2997
Coverage report detail: coverage-report-summary |
Analysis_dynamic_valgrind logcollector analysis:Commit: c21fc1a Lines executed:31.41% of 1859
Coverage report detail: coverage-report-summary |
Analysis_dynamic_valgrind syscheckd analysis:Commit: c21fc1a Lines executed:26.49% of 2997
Coverage report detail: coverage-report-summary |
c21fc1a
to
1df4c2b
Compare
Analysis_dynamic_valgrind logcollector analysis:Commit: 1df4c2b Lines executed:31.41% of 1859
Coverage report detail: coverage-report-summary |
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.
LGTM!
Analysis_dynamic_valgrind syscheckd analysis:Commit: 1df4c2b Lines executed:26.49% of 2997
Coverage report detail: coverage-report-summary |
Analysis_dynamic_valgrind logcollector analysis:Commit: 1df4c2b Lines executed:31.41% of 1859
Coverage report detail: coverage-report-summary |
Analysis_dynamic_valgrind syscheckd analysis:Commit: 1df4c2b Lines executed:26.49% of 2997
Coverage report detail: coverage-report-summary |
Description
The problem was that the
<out_format>
tag didn't work when the<localfile>
target was "agent". This was caused by a modification that was made in the PR #4696, and it made that the messages that had target agent were sent without being built as a log.To fix this I have added that the
SendMSGtoSCK()
function considers the target agent and sends it in a normal way after building the log. I have also changed the call to the function to send the log when the target is an agent.Tests
Tests specified here: wazuh/wazuh-qa#656