Good day all
This might be in the incorrect section, apologies if it is, but this might be relevant to others aswel...
I have a remote VPS Server, its purpose mainly as a easy access point for all my/colleagues devices, i.e. my home server, mobile, laptop,desktop,etc.
My openvpn server has `client-to-client` and `ccd` options configured working perfectly.
SSH'ing into another device by its given IP works perfectly, e.g.
../../.openvpn/ccd/
android-phone
ifconfig-push 10.0.0.34 10.0.0.33
windows-laptop
ifconfig-push 10.0.0.30 10.0.0.29
if both devices are connected, then in my android terminal,
ssh user@10.0.0.30
I can access my laptop perfectly, no issues, but whilst is my server terminal, server meaning OpenVPN server
ssh user@10.0.0.29
ssh user@10.0.0.30
ssh 10.0.0.29
ssh 10.0.0.30
all yield this error
ssh: connect to host 10.0.0.29 port 22: Connection timed out
my iptables as follows
iptables -L
Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT tcp -- anywhere anywhere tcp dpt:ftp-data /* FTP-Data IN (iface:ALL) */ state NEW,RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp dpt:ftp /* FTP-Ctrl IN (iface:ALL) */ state NEW,RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp dpt:ssh /* SSH IN (iface:ALL) */ state NEW,RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp dpt:smtp /* SMTP IN (iface:ALL) */ state ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp dpt:whois /* Whois IN (iface:ALL) */ state NEW,RELATED,ESTABLISHED
ACCEPT udp -- anywhere anywhere udp spt:domain /* DNS IN (iface:ALL) */ state NEW,RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp spt:http /* HTTP IN {NER}(iface:ALL) */ state NEW,RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp spt:https /* HTTPS IN (iface:ALL) */ state NEW,RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp dpt:https /* HTTPS IN (iface:ALL) */ state NEW,RELATED,ESTABLISHED
ACCEPT udp -- anywhere anywhere udp dpt:ntp /* NTP/OPENVPN IN (iface:ALL) */ state NEW,RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp dpt:9800 /* TRANSMISSION IN (iface:ALL) */ state NEW,RELATED,ESTABLISHED
ACCEPT icmp -- anywhere anywhere /* Ping Request/Reply IN (iface:ALL) */ state NEW,RELATED,ESTABLISHED
Chain FORWARD (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere
ACCEPT all -- anywhere anywhere
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
ACCEPT icmp -- anywhere anywhere /* Ping Request/Reply OUT (iface:ALL) */
and NAT table
iptables -L -t nat
iptables v1.4.21: can't initialize iptables table `nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
cybex@server:~$ sudo iptables -L -t nat
Chain PREROUTING (policy ACCEPT)
target prot opt source destination
Chain POSTROUTING (policy ACCEPT)
target prot opt source destination
SNAT all -- anywhere 10.0.0.0/24 to:10.0.0.2
SNAT all -- 10.0.0.0/24 81.4.122.16 to:{external_server_ip}
MASQUERADE all -- 10.0.0.0/24 anywhere
MASQUERADE all -- {external_server_ip} anywhere
Chain OUTPUT (policy ACCEPT)
target prot opt source destination[/conetstat -r
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
10.0.0.2 * 255.255.255.255 UH 0 0 0 tun0
10.0.0.0 10.0.0.2 255.255.255.0 UG 0 0 0 tun0
default * 0.0.0.0 U 0 0 0 venet0 0 0 0 tun0
default
so to sum it all up:
root@openvpn-server:~# (I am here, ssh'ed into my opevpn server), laptop is connected to the server on 10.0.0.30, I want to ssh into my laptop but keep getting connection timed out on port 22.
anyone have any suggestions?