http over SSH port forward = weird characters

Linux howto's, compile information, information on whatever we learned on working with linux, MACOs and - of course - Products of the big evil....
Post Reply
User avatar
peter_b
Chatterbox
Posts: 381
Joined: Tue Nov 12, 2013 2:05 am

http over SSH port forward = weird characters

Post by peter_b »

[PROBLEM]
I try to open a website over SSH port-forwarded SSL, and get a reply but it's just some weird unicode blocks.

The setup is as follows:
  • Localhost: My local PC
  • "Server1": My proxy server
  • "Server2": 3rd party server, running https website - but restricted access to IP of "Server1"
So I'm connecting from Localhost to Server1, port-tunneling local port "localhost:10001" to "server2:443".

When I open my browser and connect to "http://localhost:10001" I get an answer, but it's just a bunch of "4-hex-character-in-a-block" symbols (unicode?), like this:

Code: Select all

(Remark: There are 6 characters in the code block, but only the question-mark one is displayed here. Sorry.)

Hex editor says it's:

Code: Select all

15 03 01 EF BF BD 02 02

[SOLUTION]
Well yeah: I accidentially accessed "http://" - not "https://".
But once I got that broken http-reply, I couldn't just fix the URL to https - I had to either open/close the browser - or open another Firefox container tab. Seems like something got "stuck" otherwise.

Posting it here, because maybe someone runs into the same byte sequence reply issue? 8) :lol:
Post Reply