LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 01-19-2007, 05:12 PM   #1
jonfa
Member
 
Registered: Mar 2001
Location: FL
Posts: 257

Rep: Reputation: 30
ssh to firewall then to computer


Hi All,

I have set up a firewall with Centos and I have other Centos boxes behind it. I want to ssh to the machines behind the firewall, but I don't really understand the syntax to do so. I can ssh to the firewall box with no problem. Any ideas?

Thanks.
 
Old 01-19-2007, 05:40 PM   #2
Tux-Slack
Member
 
Registered: Nov 2006
Location: Slovenia
Distribution: Slackware 13.37
Posts: 511

Rep: Reputation: 36
then ssh next to the machine behind it
use the local ip address of it
i.e. ssh 192.168.26.15
 
Old 01-19-2007, 06:22 PM   #3
capn_hector
LQ Newbie
 
Registered: Nov 2006
Posts: 18

Rep: Reputation: 0
Quote:
Originally Posted by Tux-Slack
then ssh next to the machine behind it
use the local ip address of it
i.e. ssh 192.168.26.15

a little clarification, ssh into your router (ssh root@router-public-ip) and then in your ssh session since your connected into your router controlling it, ssh to your other machines (ssh root@local-machine-ip)

this does work, i set up openwrt and did this alot. its just opening up port 22 in your firewall so your router accepts connections from the world.
 
Old 01-19-2007, 07:14 PM   #4
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,674
Blog Entries: 54

Rep: Reputation: 2953Reputation: 2953Reputation: 2953Reputation: 2953Reputation: 2953Reputation: 2953Reputation: 2953Reputation: 2953Reputation: 2953Reputation: 2953Reputation: 2953
For easier accessing machines behind a fw check out the excellent "Breaking Firewalls with OpenSSH and PuTTY".
 
Old 01-20-2007, 01:58 AM   #5
Tux-Slack
Member
 
Registered: Nov 2006
Location: Slovenia
Distribution: Slackware 13.37
Posts: 511

Rep: Reputation: 36
or you could do it like this
firewall ssh port 22 open, rule ACCEPT in iptables
and for your local machine behind the firewall ssh port 23 i.e.
and in the firewall of your router forward the port 23 to the local machine
so when you ssh to your machine behind your router-firewall you would just connect to port 23 and you would get direct access to the machine behind the firewall
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't browse Windows computer because of firewall dborzasi Linux - Security 4 11-19-2005 02:56 AM
Linux Firewall with a computer Dark_Sniper* Linux - Networking 1 10-19-2005 12:49 AM
connecting computer to firewall brandonweinberg Linux - Newbie 2 02-04-2004 09:05 AM
Conneting to a computer thru a firewall clau_bolson Linux - Networking 7 01-01-2004 06:20 PM
Need some advice on my Firewall/Setup/Computer rootlinux Linux - Security 7 03-15-2002 10:20 PM


All times are GMT -5. The time now is 01:57 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration