Forum: NGINX Rewrite from proxy backend with java applet

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
07ee1a3784498fe4ec939caa6dea62dd?d=identicon&s=25 Paul (Guest)
on 2009-02-05 01:42
(Received via mailing list)
I am having a proxy issue that seems to be a java problem..

We have a config that listens on port 10000 https and then proxies https
to the backend on port 443. This works fine until I try and bring up a
java applet which promptly tries to connect to port 443 instead of
10000.  Is there a way to rewrite the information the backend is sending
to the java
applet to make it connect to port 10000 instead of 443?

Thanks
5640e332954fc0006aea97a155ce0afd?d=identicon&s=25 Igor Sysoev (Guest)
on 2009-02-05 08:25
(Received via mailing list)
On Wed, Feb 04, 2009 at 07:31:56PM -0500, Paul wrote:

> I am having a proxy issue that seems to be a java problem..
>
> We have a config that listens on port 10000 https and then proxies https
> to the backend on port 443. This works fine until I try and bring up a
> java applet which promptly tries to connect to port 443 instead of
> 10000.  Is there a way to rewrite the information the backend is sending
> to the java
> applet to make it connect to port 10000 instead of 443?

If this is caused by redirect returned by backend, then try

http://wiki.codemongers.com/NginxHttpProxyModule#p...

proxy_redirect   https://backend/    https://frontend:10000/;

or simply

proxy_redirect   https://backend/    /;
07ee1a3784498fe4ec939caa6dea62dd?d=identicon&s=25 Paul (Guest)
on 2009-02-05 15:12
(Received via mailing list)
But the nginx is only listening on port 10000 , not 443, the backend
sends some URL for the java applet that makes it
connect to 443 instead of 10000 .. I'm trying to figure out what that
is.. Will this intercept something from the backend?

Right now I have it set up like this:
       server
        {
                listen 1.1.1.1:10000;
                ssl on;
                        ssl_certificate
/usr/local/nginx/conf/abc.crt;
                        ssl_certificate_key
/usr/local/nginx/conf/abc.key;
                location /
                {
                        proxy_pass https://10.150.42.112;
                        proxy_redirect https://10.150.42.112/
https://$http_host/;
                        proxy_redirect default;
                }
        }
This topic is locked and can not be replied to.