Tuesday, December 22, 2020

Reverse SSH usage example 1

(Just for my reference) 
Scenario: 
  1. Server 10.0.0.18, 10.0.0.19, 10.0.0.20 are behind firewall. 10.0.0.18 has full access to the other servers. 
  2. Server 10.0.0.18 has a public IP x.x.x.x 
  3. Laptop 192.168.1.16 can only ssh connect to x.x.x.x on port 22 with certificate myCert
Requests: 
  1. The Laptop need to access Server 10.0.0.18 on https port 8834 (https://x.x.x.x:8834 won't work because only port 22 is opened to the Internet). 
  2. The Laptop need to access other servers on https port 443 
Steps: 
  1. On Laptop run "sudo ssh -D 1081 -i myCert root@x.x.x.x. 
  2. Setup Firefox proxy: use socket 4, localhost, port 1081 
  3. Open Firefox, browse https://localhost:8834
  4. Browse https://10.0.0.18
  5. Browse https://10.0.0.19

No comments:

Post a Comment