proxy_pass directive don't catch sequence

Kzone nginx-forum at
Sun Feb 7 10:04:54 UTC 2021


The goal is to send correct response when a malformed URL leads to 404 file
not found. What happens is that, from times to times, I get a faulty URl
like this one :


But the required file is located in

Therefore I've set a proxy_pass directive following the location, but it
seems that the involved sequence is not correctly catched up and the
malformed url are still returned. What am I doing wrong ?

The double slashes in proxy_pass between 'login' and 'jsapi' is needed and
I'm under Windows Server 2016


Code chunk :

 ## Redirect to tomcat when mismatch with /jsapi/dojo/ (20210130)

    location /jsapi/dojo/ {

        proxy_http_version 1.1;
        include C:/NginX/1.19.1/proxyparams/proxy_params.conf;
        sub_filter 'Server-IP-Adress:1543' 'FQDN-Server-Adress';
        proxy_buffering on;
        proxy_buffer_size 16k;
        proxy_busy_buffers_size 24k;
        proxy_buffers 64 4k;
        client_max_body_size 12m;

Posted at Nginx Forum:,290676,290676#msg-290676

More information about the nginx mailing list