Juha Palomäki's comment helped me.
My scenario is as follows:
server-i-want-to-get-to.com is only accessible via a certain list of IP addresses, my home network is not allowed, but the outgoing IP address of my-server.com (a server I control) is allowed.
So, I want to get to https://server-i-want-get-to.com/, using the outgoing IP address from me@my-server.com
On my laptop (or desktop), I add an entry to /etc/hosts
sudo vi /etc/hosts
127.0.0.1 server-i-want-get-to.com
Now, I ssh in to myserver.com, and use dig to find out the IP address of server-i-want-to-get-to.com
dig server-i-want-to-get-to.com
... and now from the ANSWER SECTION I know the IP address XX.XX.XX.XX
From the terminal on my laptop, establish an ssh tunnel
... pick a port not already in use, 8686 is just an example ...
ssh -L 8686:XX.XX.XX.XX:443 me@my-server.com
Now, I can go to https://server-i-want-to-get-to.com:8686/ in my browser.
Thanks to the /etc/hosts entry, there is no SSL Certificate error.
... it might be necessary to clear browser cache, or start with a fresh browser ...