Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 04-22-2004, 07:27 AM   #1
Registered: Jan 2003
Location: nearby switzerland
Distribution: Suse 8.0 / Suse 9.0 / Slackware 9.1 / Debian Sarge testing / Gentoo 1.4.10
Posts: 165

Rep: Reputation: 30
ssh wrapping


i would like to perform the following:

My workstation sits behind a router and the sshd is reachable from outside through a portforwarding at the router. My router does not have the abillity to forward for example port 3000 to 22 within the lan. It only allows 22 -> 22. So i dont like this! My idea was, creating a portforwarding at the router lets say port 4000 and forward it to my worksation, then create an iptable rule which forwards the connection to itself

iptables -t nat -A PREROUTING -i eth0 -p tcp -d my.ip.add.ress --dport 4000 --to my.ip.add.ress:22

what do you think about this idea? I have red that its not possible to start the sshd at an unprivileged port. Any hints on this?
Old 04-22-2004, 08:17 AM   #2
Registered: Dec 2003
Location: Australia
Distribution: Mandrake 9.2
Posts: 151

Rep: Reputation: 30
well unprivileged ports start at 1024, so a quick fix is to use port 222 or basically <1024.

but yeah try the iptables rule, umm you might have to use INPUT insted of PREROUTEING
as it is locally delivered but i'm not 100% sure.


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
Mouse/Screen Wrapping xaenn Linux - Software 0 04-18-2005 07:40 PM
Desktop Text wrapping Commando464 SUSE / openSUSE 1 10-23-2004 04:44 AM
line wrapping in terminal emetib Linux - General 4 10-29-2003 09:18 PM
ncurses word wrapping? gtanghookup Programming 1 09-12-2003 05:47 PM
Wrapping text in tables Graanco Programming 1 09-27-2001 04:04 PM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 03:56 PM.

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