From internet, I have access via ssh to the Machine_A and it can access the intranet. So, I can access all intranet sites with command line like:
ssh Machine_A -f 'curl -s http://192.168.0.51' > index.html
The problem is that a web site is a complex thing. It need to download images, javascript, css, etc.
Soo, how can I "tunnel" or "translate" my connection to access the website only using command lines?
See this scenario:
- I want to acess the page in http://192.168.0.51
- So, I connect with
ssh
and download the page with the above command. - I open the
index.html
and the browser see it need to downloadimage.jpg
andscript.js
- Somehow, I intercept this request, make the correct line to download the file and than the browser use it
How can I access this site without direct access? What could I do in Machine_A to be my "gateway" to access the intranet site?