Please let me know if you encounter any issues with the shared custom ruleset or if you need any assistance improving the decoders or rules.
If you are still unable to get the expected results, could you please share the sample logs for each detection requirement separately? Also, please provide a clear description of the issue you are facing, including what you expected to happen and what result you are currently getting.
For example, you can refer to below documents to have more details regarding decoders and rules:
Let me know the update on this, with sample logs so we can check further.--
You received this message because you are subscribed to a topic in the Google Groups "Wazuh | Mailing List" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/wazuh/CfhCsaUSHOw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to wazuh+un...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/wazuh/e0d8459c-bf02-4572-98df-ec77c31bafebn%40googlegroups.com.
Hi George,
Thanks for the update.
To replicate this scenario on my end and review it properly, could you please share a few sample logs in text format? Please make sure to mask or remove any sensitive information before sharing them.
Without the sample logs, I won’t be able to accurately validate the decoders and rules or confirm what needs to be adjusted.
You can also test the sample logs using the wazuh-logtest tool to check how Wazuh is currently decoding and matching them.
Please let me know once you have an update, and I’ll be happy to check further.
Hi George,
If you still need help with this, please feel free to share some sample logs. I’ll review them and try to replicate the issue on my end.
Thanks!
It looks like the decoders and rules were generated by an LLM. Initially, the decoder you shared wasn't matching at all, but after some testing I was able to get it working.
You can replace your existing custom decoders with the ones below. The custom decoder files are located in:
/var/ossec/etc/decoders
I modified the parent rule to use the parent decoder; otherwise, they won't be linked correctly. You can replace the custom rule you've added in the /var/ossec/etc/rules/ folder with this one.
I tested it, and it looks like the last rule isn't working. I haven't found the root cause yet, but once I figure out a workaround, I'll share it with you.
Ref:
Decoders Syntax - Ruleset XML syntax
Custom Decoders
Wazuh Regex
Custom rules
Rule syntax
To view this discussion visit https://groups.google.com/d/msgid/wazuh/fe354a0f-35b1-418b-882c-fe9695eb4fddn%40googlegroups.com.
Apologies for the delay. If you change the decoder name, it may affect the child decoders if they are not updated accordingly. Similarly, changing the parent decoder name may also affect the parent rules.
Before adding these custom rules, we first need to identify what is causing the syntax error and find the root cause. Please share the manager's ossec.log after restarting the Wazuh manager.
Please run the following commands and share the output:
systemctl restart wazuh-manager
systemctl status wazuh-manager -l
cat /var/ossec/logs/ossec.log | grep -i -E "error|warn"
If the syntax issue has already been resolved, please proceed with updating the rules I shared below.
You can update the custom rules in the following path for Postfix:
/var/ossec/etc/rules
Then test with wazuh-logtest to verify updated rules are working.
/var/ossec/bin/wazuh-logtest
Please let me know the update once this has been completed.
Ref: