'ubuntu 20.04 brute force

I am using ubuntu 20.04. When I looked at the auth.log records, I saw that there were many attempts. What security measures can be taken here.

I don't have any previous experience in this field. Security issues are very new to me. I am open to anything you suggest.



Solution 1:[1]

Here are a few recommendations assuming that you are talking about SSH:

  1. Disable login access to root: disable-root-login

  2. Enable public key authentication and disable password based auth: public-key-authentication

  3. Add IP whitelisting, using a firewall such as ufw to ensure people can only access from your IP address

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Nick Lauder