Disable ssh and ping

Business solution to host your own OpenVPN server with web management interface and bundled clients.
Post Reply
webstyler
OpenVpn Newbie
Posts: 3
Joined: Tue Aug 20, 2013 7:12 pm

Disable ssh and ping

Post by webstyler » Wed Jul 05, 2023 3:26 pm

Hello guys

We have install new OpenVPN Access Server, last release.

How to:
- disable ping so main IP not respond?
- disable ssh access?

For both we can work from hypervisor

Thanks

User avatar
openvpn_inc
OpenVPN Inc.
Posts: 1333
Joined: Tue Feb 16, 2021 10:41 am

Re: Disable ssh and ping

Post by openvpn_inc » Tue Jul 11, 2023 9:18 am

Hello webstyler,

SSH can be turned off by using system management in the operating system. Disabling ping response is something that can be done with iptables rules. Both things are something that are pretty easy to find instructions about online. Here's some examples;

To turn off SSH service entirely:
systemctl stop --now ssh
systemctl disable --now ssh

And stop responding to ICMP:
nano /etc/sysctl.conf
Add this line:
net.ipv4.icmp_echo_ignore_al = 1
Save and exit from nano, then run:
sysctl -p

Note that you must be root for these commands to work, or else prepend it with sudo, as per normal procedure on Linux.

Kind regards,
Johan
Image OpenVPN Inc.
Answers provided by OpenVPN Inc. staff members here are provided on a voluntary best-effort basis, and no rights can be claimed on the basis of answers posted in this public forum. If you wish to get official support from OpenVPN Inc. please use the official support ticket system: https://openvpn.net/support

Post Reply