Results 1 to 6 of 6

Thread: ssh port forwarding

Hybrid View

  1. #1
    Senior Member
    Join Date
    Apr 2002
    Posts
    417

    ssh port forwarding

    can someone point me to a good. ssh port forwarding tutorial? Paricualarly in using it to encrypt a vnc session.

    thanx,

  2. #2

    Re:ssh port forwarding

    ssh -L1234:host:5900 foo.bar.org

    this will port map your (-L means local) port 1234 to host's port 5900 . 5900 is vnc for the first display. vnc on linux with X running goes to the second display though so 5901.

    so if i need to vnc to the server where administrator is always left on and i'm at home i use:

    ssh -L5900:ghost:5900 rook -p554

    -L5900 let's me just type vncviewer localhost without a port
    ghost is the server i need
    it's a windows box so it's the first display
    rook is the ssh host
    port 554 is used because 22 is blocked.

    now just hope my system admin doesn't read this and say "gar why is he vnc'ing to my server from home!"

    let me know if you have any troubles.

  3. #3
    Senior Member
    Join Date
    Apr 2002
    Posts
    417

    Re:ssh port forwarding

    yup,

    I think that worked. but how exactly do you know that the session is encrypted.

    I use ethereal to view the tcp session between host w/ port forwarding and w/ out port forwarding. Both were just garbage(no ascii text).

    Has anyone tried to do encypted http/telnet sessions w/ this? For machines that don't support encyption ie network switches

    thanx,

  4. #4
    Senior Member
    Join Date
    Apr 2002
    Posts
    417

    Re:ssh port forwarding

    I actually tried to forward a telnet session from an HP 4000m switch.

    I could login to the switch but, after that, no buttons work but the session is still active as I can see the seconds updated on the console of the switch.

    anyone know how to fix this? SSH or switch problem?

    thanx again.

  5. #5

    Re:ssh port forwarding

    okay a little more indepth, when you are using vncviewer after you did the ssh -L thing, you aren't typing vncviewer IPADDRESSOFTARGET

    you are typing vncviewer localhost

    and you know it's encrypted because the only way you could connect to localhost and get to the right place would be if there is something forwarding between the two.

    also if you sniff and filter port 22 out, you won't see any vnc traffic, because everything is being tunneled through SSH (on port 22)

    that help clear things up any?

  6. #6
    Senior Member
    Join Date
    Apr 2002
    Posts
    417

    Re:ssh port forwarding

    Ok,

    with regards to port forwarding telnet. It actually does work a little bit.

    i can use the up/down, enter buttons. but the focus on each option is not updated. so I press down to an option but the option is not highlighted. when I press enter, the screen switches to that option. so it is working. but navigating through the menu is not easy. Wierd thing is everything that work refreshes fine. so why doesn' t the focus?

    thanx gorn.

Similar Threads

  1. Port forwarding without ssh
    By countach44 in forum Linux - Hardware, Networking & Security
    Replies: 3
    Last Post: 01-10-2005, 10:13 PM
  2. Port forwarding woes
    By friskydrifter in forum Linux - Hardware, Networking & Security
    Replies: 7
    Last Post: 01-28-2004, 03:59 AM
  3. SSH port forwarding
    By crazy ivan in forum Linux - Hardware, Networking & Security
    Replies: 4
    Last Post: 10-07-2003, 11:10 PM
  4. Port Forwarding FTP with NATD
    By Coral_Sea in forum BSD
    Replies: 4
    Last Post: 01-29-2003, 10:55 PM
  5. Port forwarding
    By Schotty in forum Linux - Hardware, Networking & Security
    Replies: 5
    Last Post: 11-29-2001, 05:08 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •