Project 15 for CNIT 122 - SSH Tunnel (15 pts.)

What You Need

Purpose

We will create an SSH Tunnel, so the Windows machine can surf the Web safely.

Starting the Windows Machine

Start your Windows machine and make sure it is connected to the Internet.

Starting the Linux Machine

Start your Linux machine and make sure it is connected to the Internet.

PING from the Linux machine to the Windows machine and make sure you are getting replies. If you are using Virtual machines, make sure they are both on the same subnet--either both Bridged or both NAT. If you are using a Linux VM and the Windows host, use Bridged networking for the Linux VM.

Starting SSH

On the Linux machine, in a Terminal window, enter these commands, pressing Enter after each one:
sshd-generate

/etc/init.d/ssh start

update-rc.d ssh defaults

ifconfig

Note the IP address of your Linux machine.

Downloading Putty on the Windows Machine

On the Windows machine, open a browser and go to

http://www.chiark.greenend.org.uk/~sgtatham/putty/

Click Download

In the "Binaries" section, in the "For Windows..." section, click putty.exe as shown below:

Configuring PuTTY on the Windows Machine

Double-click the downloaded putty.exe file.

Putty opens.

In the "Host Name (or IP address)" box, enter your Linux server's IP address, as shown below:

In the left pane of the PuTTY Configuration window, expand the SSH container.

In the left pane of the PuTTY Configuration window, click X11.

In the right pane of the PuTTY Configuration window, check the "Enable X11 forwarding" box.

In the "X display location" box, type localhost:0 as shown below:

Click the Open button.

A "PuTTY Security Alert" box opens, as shown below:

Click Yes.

Log in as root with the password toor

Installing Xming on the Windows Machine

You need an X Server on the Windows machine, so it can display the X Windows graphical information coming from the SSH tunnel.

On the Windows machine, open a Web browser and go to

http://sourceforge.net/projects/xming/

Click the Files link.

Click the Download button, as shown below:

Begin installing the software as usual, but when you reach the "Select Components" box, click the "Don't install an SSH client" button, as shown below:

Continue with the installation, accepting the default options.

Launching Firefox on the Windows Machine

On the Windows machine, in the PuTTY window, type firefox to launch a Firefox process on the Linux server.

A Linux-based Firefox window opens on your Windows desktop, as shown below:

Saving the Screen Image

Make sure both the Linux Firefox command in the PuTTY window and the Firefox window open on the Windows desktop are visible, as shown above.

Save a screen capture with a filename of "Proj 15 from YOUR NAME".

Turning In Your Project

Email the image to cnit.122sam@gmail.com with a subject of "Project 15 from YOUR NAME".


Sources

http://j2neon.blogspot.com/2011/05/ssh-with-x11-and-ftp-in-bt5.html

http://a62.video2.blip.tv/8810008645655/2neon-sshtunnel938.mp4?brs=549&bri=1.9


Last modified 11-8-11 10:30 pm