0% found this document useful (0 votes)
27 views11 pages

SSH - Bypass Instructions Final

This document provides instructions for setting up a server instance that allows SSH access through blocked ports by using a proxy server. It involves launching an Amazon EC2 server instance, changing the SSH port from 22 to 443, and then SSHing into the instance to circumvent network port blocks and access other servers. The summary steps are: 1) Sign up for an AWS account, 2) Launch an EC2 Ubuntu server instance, 3) Change the SSH port from 22 to 443 and restart the service. This allows the user to SSH into the instance and then to other servers, bypassing port restrictions.

Uploaded by

Michael Wong
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
27 views11 pages

SSH - Bypass Instructions Final

This document provides instructions for setting up a server instance that allows SSH access through blocked ports by using a proxy server. It involves launching an Amazon EC2 server instance, changing the SSH port from 22 to 443, and then SSHing into the instance to circumvent network port blocks and access other servers. The summary steps are: 1) Sign up for an AWS account, 2) Launch an EC2 Ubuntu server instance, 3) Change the SSH port from 22 to 443 and restart the service. This allows the user to SSH into the instance and then to other servers, bypassing port restrictions.

Uploaded by

Michael Wong
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 11

How To: Setting up a Server Instance Allowing for

SSH Access Through Blocked Ports


Written by: Michael Wong
Last Updated: Sept 23, 2014
________________________________________________________________________
Purpose
To enable a user to SSH into a server from within the school's network by means of a proxy server instance. The
school network blocks the default SSH port (port 22), and using this method, a user is capable of circumventing that SSH
port restriction.
Applicability and Scope
Applicable for use within networks that block a port required for SSH access. This includes the
school network as well as any other network that does NOT block port 443.
Requirements
-Operating system that has SSH capabilities (Ubuntu, Linux, MacOS)
-Knowledge of basic Command Line commands
-Access to unrestricted network (outside of blocked network) to prepare server
Procedure
1. Go to http://aws.amazon.com/ and sign up for a free account (may need to put in credit card
information)

2. Sign in via https://console.aws.amazon.com/?nc1=h_m_mc

3. Access the EC2 Web Services

4. Launch a new EC2 server instance

5. Select the Amazon Machine Image (AMI) to create: Ubuntu Server 14.04 LTS (HVM)

6. Click Review and Launch

7. Press Launch

8. Select Create a new key pair with a key pair name (ex. ssh_bypass). Press the "Download Key Pair"
button. Make sure that "ssh_bypass.pem" is downloaded. Select Launch Instance

9. Click View Instances

10. Click on the newly created instance and wait until the the Status Checks display "2/2 checks...". Find
the field that states Public DNS and copy it down.

11. Click on Security Groups tab, select the security group (should be most recently created one), select
Inbound tab, press Edit

12. Press Add Rule, and then fill in a new rule, Save

13. Open a SSH terminal and input the following commands


-To change privacy of downloaded key_pair
chmod 400 Downloads/ssh_bypass.pem
-SSH into server instance
ssh -i Downloads/ssh_bypass.pem ubuntu@serverpublicaddress

14. Open up the SSH port to allow for access from port 443
sudo sed -i 's_Port 22_Port 443_' /etc/ssh/sshd_config
15. Restart SSH session
sudo service sshd restart

16. Disconnect from the server, and reconnect

Conclusion
If you are able to successfully SSH into the server, then congratulations! From SSH'ing into this
new server, you are now able to SSH from there into any server. This is due to Port 443 not blocked on
many networks, and allowing this method an alternative way out.

You might also like