Firewall
Firewalling all traffic except the ones coming from your own IP block
can greatly improve the security of your OpenSSH service and prevent unauthorized access.
By using firewall rules to restrict incoming traffic to only your own IP block, you can effectively block
any attempts from outside the network to connect to your SSH service.
This helps to minimize the risk of attacks and data breaches.
In addition to improving security, firewalling can also improve the performance of your OpenSSH service.
By blocking unwanted traffic, you can
reduce the amount of unnecessary network traffic and improve the speed and responsiveness of your service.
Implementing a firewall rule is just one aspect of securing OpenSSH. It is also crucial to keep your OpenSSH software up-to-date, use public/private key authentication, and monitor logs for suspicious activity.
Firewall rules should be updated regularly to prevent getting locked out due to IP changes. If your IP address changes, updating firewall rules promptly is necessary to maintain remote access.
Having a backup access method is crucial in case of accidental lockout, such as using a secondary administrative account or like serial console in Oracle Cloud.