Thanks to this, as it can collect system logs and create specific rules that are parsed for the detection of various events, it is possible to detect weird traffic on ports, although for this, it is necessary to activate the host firewall and collect the logs (or collect the router logs), as these will have enough information to be able to detect port scanning. With these logs, you can create custom rules to match the pattern you are looking for, although if you only configure it this way, keep in mind that there are ways around this detection, which is why some security issues are more successfully detected by inspecting a server's actual network traffic, which is generally not accounted for in the logs.
Wazuh does have native integration with both Suricata and Snort, which are NIDS (Network Intrusion Detection System) software and work well to detect threats in networking.
Also, there is a tool called OwlH, which is part of Wazuh project and will help you deploy the right Network Intrusion Detection System in your environment, configure it correctly and keep it updated. Some features of this tool are:
- Detection of new systems in the network.
- Detection of hidden systems that are using spoofing.
- Detection of unauthorized use of services.
- Prevention mode. Running in Intrusion Prevention System (IPS) mode, a Network IDS may also act by stopping, blocking, or discarding a bad connection as soon as it is detected.
You can read more in these links, about two NIDS open source solution:
According to the rules, there are no default rules for tools like
Nmap, although there are decoders to get the NIDS logs, so you can create a custom rule with the specific threat type. However, they could easily be added if required, depending on what you want to do. Note that Wazuh analyses data and generates alerts for important security events. One option, for example, would be the one discussed above, where we activate the host's firewall, and collect all the relevant information, so that once we have that information, we can create a rule to alert us to a specific pattern of actions. This would require writing some custom decoders and rules for the alerts to be generated. Below, I share with you the step-by-step documentation:
https://documentation.wazuh.com/current/user-manual/ruleset/custom.html