-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[security] syslog floods during DoS attack on REST server #13576
Comments
@jeff-yin this is relating to RBAC, pls help followup with your team |
@adyeung I don't think this is a role-based access control issue, as it has to do with unauthenticated users. This is more related to the configuration and logging done by the REST server.
The REST server should be configurable to do this, or a separate mgmt VRF can be configured as well.
Need to take a look at how the REST server is passing error messages to the syslog. But even so, some of these logs are worth keeping for troubleshooting purposes.
I think this is more important than point 2. We should configure this on the host right? |
Sorry, unassigned myself thinking I could re-assign. But I can't. Feel free to re-assign to me for now. |
Discussing offline over email, I will move assignee once we reach a conclusion offline |
@sachinholla from BRCM working on a fix |
Thanks @adyeung and @sachinholla |
hi @jusherma, How to install the "srvr" tool? I did not find it in kali tools page. About REST server listening to the mgmt interface only -- most of the deployments I have seen wanted inband management. Will keep the current behavior as is and consider supporting a bind interface/vrf option in future. About fail2ban -- if I understand correctly, this will be a new service monitoring the logs and adjusting he firewall rules (may be ACLs??).. It should be discussed & tracked as a separate security enhancement for sonic. Not specific to REST server. |
I think you should be able to reproduce this even without the
Binding a server to all interfaces by default is poor security posture. It's ok to allow users to bind telemetry or REST server to all interfaces, but using that as a default is a security risk. I already have opened another issue about telemetry's use of binding to
You're correct--fail2ban monitors log files and uses iptable rules to temporarily block abusive clients. fail2ban needs to both be (a) added to SONIC and (b) enabled for each service we wish to protect. Regardless of how this task is tracked, work will need to be done to enable it for the REST server specifically. |
Description
Sending malicious traffic to the REST server causes log flooding. These logs can rapidly fill the syslog. During tests, more than 1.5 MB of these messages were written per minute of DoS attack. This could be used to force log rotation, concealing earlier malicious activity from logs. It could also cause a system outage by filling up the disk.
Steps to reproduce the issue:
Run these commands in parallel from Kali Linux, where
172.31.0.2
is the IP address of an interface on SONiC and172.31.0.6
is an unassigned IP addressDescribe the results you received:
Within about 2 minutes, warnings about TLS handshake timeouts will start rapidly flooding /var/log/syslog:
Describe the results you expected:
The text was updated successfully, but these errors were encountered: