Koozali.org: home of the SME Server

Hamachi VPN - pings OK but no services

Offline Marco Hess

  • *
  • 149
  • +0/-0
    • http://www.through-ip.com
Hamachi VPN - pings OK but no services
« on: September 12, 2007, 07:54:27 AM »
Hi All,

I needed a way to get to a SME server in server only mode that sits behind a firewall that I don't have access to for opening any ports. As I have played around with Hamachi VPN under Windows, I have setup the Hamachi Linux version on the SME box as I was hoping this would be able to get through the firewall from the inside out.

It installed quite easy and I now have a setup and connects to the Hamachi network that I created. I can ping from the other machines to the SME box using the Hamachi IP address and visa-versa but when trying to access any services on the SME (e.g. browsing the web service) the connections all time out.

Now looking around the forums, I suspect that the firewall in SME drop the IP packets from the Hamachi connection because it does not look like the local network address range and it created its own virtual network adaptor 'ham0':

 Kernel IP routing table
 Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
 10.0.0.0        *               255.255.255.0   U     0      0        0 eth1
 10.1.0.0        *               255.255.255.0   U     0      0        0 eth0
 5.0.0.0         *               255.0.0.0       U     0      0        0 ham0
 default         10.0.0.1        0.0.0.0         UG    0      0        0 eth1


So is this something with the iptables? Does anybody have any pointers as to how to enable services (like web access or sshd) to be accessed through the hamachi link?

I looked through the masq templates and its output and it is a bit daunting to say the least  :(

Regards,

Marco



Adelaide - Australia

Offline axelmasok

  • 3
  • +0/-0
Re: Hamachi VPN - pings OK but no services
« Reply #1 on: February 01, 2008, 05:38:26 AM »
Just done a search re Hamachi on this forum.
Same questions with no answers.
I have an answer and a question so hopefully we can get this sorted.

Answer:
Hamachi installs fine via command line.
Runs fine and connects OK.
You cannot access the SME server services because primarily iptables won't allow it.
I fixed this by logging onto the https admin console and adding 5.0.0.0/8 as a "Local Network".
As you will find out the interface won't let us add this new network without a gateway. I had to add a gateway corresponding to the existing LAN gateway (eg. 192.168.0.1) then add this to /etc/rc.local to remove the route:
route del -net 5.0.0.0 gw 192.168.0.1 netmask 255.255.255.0

Question:
Why can't we add a network through the interface without a gateway or at least 0.0.0.0 as the gateway?
Is there a better way to do this?


Offline nakor_au

  • 18
  • +0/-0
Re: Hamachi VPN - pings OK but no services
« Reply #2 on: February 01, 2008, 06:19:46 AM »
hopefully if enough people ask about this some one will be nice enough to make a sme contrib for hamachi :)
ive had hamachi installed on sme for a while now waiting for some one to make a easy way for it to work.
im not good enough with sme to just start edits of files.
so im just waiting for a contrib :)

Offline chris burnat

  • ****
  • 1,135
  • +2/-0
    • http://www.burnat.com
Re: Hamachi VPN - pings OK but no services
« Reply #3 on: February 03, 2008, 09:07:40 AM »
This post is off topic and has been removed.
- chris
If it does not work out of the box, please fill in a Bug Report @ Bugzilla (http://bugs.contribs.org)  - check: http://wiki.contribs.org/Bugzilla_Help .  Thanks.

Offline byte

  • *
  • 2,183
  • +2/-0
Re: Hamachi VPN - pings OK but no services
« Reply #4 on: February 03, 2008, 01:39:42 PM »
Moving this topic to the SME 7.x contribs forum, it is more appropriate there. Thanks!
--[byte]--

Have you filled in a Bug Report over @ http://bugs.contribs.org ? Please don't wait to be told this way you help us to help you/others - Thanks!

Offline chris burnat

  • ****
  • 1,135
  • +2/-0
    • http://www.burnat.com
Re: Hamachi VPN - pings OK but no services
« Reply #5 on: February 08, 2008, 12:01:47 PM »
ooops... Very sorry about this.
Thanks Byte.
- chris
If it does not work out of the box, please fill in a Bug Report @ Bugzilla (http://bugs.contribs.org)  - check: http://wiki.contribs.org/Bugzilla_Help .  Thanks.