Suppose you are running on your laptop (box A) some Java code in your
browser that talks to a remote server (box B). All is fine until you find
yourself in a hotel that blocks the relevant ports (say, 8100-8120). OK,
at least SSH is not blocked and you do have an account on a more open
remote box (C) - so a trivial, but not very elegant, solution is to run
the browser on C and "fetch" the display with VNC through an SSH tunnel.
From a bandwidth / responsiveness point of view, however, this is a total
overkill. All you have is a trickle of data (mouse clicks and keystrokes),
why bloat it with graphics.
Is there some networking solution that can help? I tried tunneling through
SSH (SSH port forwarding) but it did not help - as I could not redirect the
A->B connection request. On top of that, even if I managed to make the incoming
connection to the server seem to come from C, upon connection the server will
directly ask the Java client for its IP number and use that to open a
separate direct B->A channel. To me it looks like the only solution would
be to make the code on A think that the local IP is that of C, and map
all A->B requests (now C->B requests) to go through C.
If anyone knows a fix, or has some ideas, please let me know - either here
or at
mc2718@gmail.com.
------------------
P.S: the only strategy I see at the moment is to run an "outpost" (proxy,
if you wish) on C and modify the local Java VM on A to direct networking
through that one. By modifying an open source VM code this is doable, but
looks like a LOT of work. A dirty alternative is to hack the Linux kernel
to map ethernet connections to/from certain IPs to go through some fixed
local ports. Does not look very appealing either...