Use ssh to reverse connect to an intranet host

Source: Internet
Author: User

 

Recently, I was very depressed about this issue.

Our community is zhangkuan (Great Wall broadband). At the beginning, apart from the poor speed, there was no harm. We could also get online 24 hours a day. When I arrive at the company

Use ssh to connect your machine. If you need anything, It is very convenient.

 

However, after a while, we found that the standard port 22 could not be connected to our own machine, and the ping from the company could not be connected to our own machine. It is suspected that the router node is playing tricks, so ssh is transferred to Port 80, and the problem is basically solved.

 

This is not a long time. Today, we found that even port 80 is inaccessible.

So I found this online.

 

This means that you can reverse connect to an intranet host (a host with a firewall) through ssh)

 

Well, the following are the steps:

 

0. Install ssh on both sides

1. Run ssh-f-N-R 10000: localhost: 22 username @ master ip address on the control end. Here, port 10000 and port 22 are the port numbers, that is, a channel is established on port 10000 of the master and port 22 of the control.

2. Run the sshusername @ localhost-p 10000 command on the master side. Here, username is the username of the accused, and 10000 is the port number.

 

OK.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.