# This webpage has a redirect loop (ERR\_TOO\_MANY\_REDIRECTS)

**URL:** <https://www.ruby-forum.com/t/this-webpage-has-a-redirect-loop-err-too-many-redirects/244219>\
**Category:** NGINX\
**Created:** [March 7, 2016, 8:24pm UTC](https://www.ruby-forum.com/t/this-webpage-has-a-redirect-loop-err-too-many-redirects/244219 "2016-03-07T20:24:21Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sadaf\_N](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/858c86/32.png) [@Sadaf\_N](https://www.ruby-forum.com/u/Sadaf_N)\
**Post date:** [March 7, 2016, 8:24pm UTC](https://www.ruby-forum.com/t/this-webpage-has-a-redirect-loop-err-too-many-redirects/244219/1 "2016-03-07T20:24:21Z")

</div>

Hi,

My set up is as below:

NGINX (reverse proxy) IBM WebSeal (redirects to a common login page,  
after  
authentication forwards to internal proxy along with the redirected url)  
  
Internal Proxy (IBM http Server)  WebSphere Portal.

I am trying to access  
https://\<host\_name\>/wps/seedlist/myserver?Source=com.ibm.lotus.search.plugins.seedlist.retriever.portal.PortalRetrieverFactory&Action=GetDocuments&Range=100&locale=en

Host\_name is the server\_name on NGINX and the url is in the Portal  
server.  
When I am accessing it directly, replacing the host\_name with Portal  
server  
IP/port, it works.

With the host\_name, I am getting the message as in the subject line, on  
the  
browser.

My nginx config is below:-

#Security  
server\_tokens off; #Turn off version number  
add\_header X-Frame-Options “SAMEORIGIN”; #Turn off click jacking; so  
no  
frames  
add\_header X-XSS-Protection “1; mode=block”;  
add\_header X-Content-Type-Options nosniff;

# Redirect all insecure requests to the secure port

server {  
listen \<IP\_address\>:80 ;  
server\_name ;  
return 301 https://\<server\_name\>$request\_uri;  
}

# Serve SSL encrypted data

server {  
listen \<IP\_address\>:443 default\_server ssl;  
add\_header Strict-Transport-Security max-age=15768000;  
server\_name \<server\_name\>;

access\_log /web/nginx/servers/name/logs/access.log;  
error\_log /web/nginx/servers/name/logs/ error.log;

# Security

```
ssl on;
ssl_prefer_server_ciphers on;
ssl_session_cache shared:SSL:10m;
ssl_dhparam /etc/ssl/certs/dhparam.pem;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;

```

ssl\_ciphers  
‘EECDH+AESGCM:EDH+AESGCM:ECDHE-RSA-AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-GCM-SHA256:!aNULL:!eNULL:!EXPORT:!DES:!MD5:!PSK:!RC4’;

# Specify the certificate and key

```
ssl_certificate /etc/nginx/ssl/name/server.name.com.crt;
ssl_certificate_key /etc/nginx/ssl/name/server.name.com.key;

```

location /download/ {  
rewrite  
^/download/vadxeval$  
“https:///mybrocade/secure/navigate?nid=n32&prodCode=VIRTUAL\_ADX&pname=VADX\_DOWNLOAD&completePath=downloads/Virtual  
ADX/Virtual ADX\_Eval” break;  
rewrite  
^/download/apitoolkit$ “https:// /mybrocade/secure/navigate?nid=n30&prodCode=BRD\_API\_SUPPORT&prodCatCode=API&pname=VYATTA\_DOWNLOAD&completePath=Brocade  
API Toolkit” break;  
}

location / {  
rewrite ^/$ https:// /wps/myportal/ break;  
rewrite ^/wps/portal$ http:// /wps/myportal/ break;

```
    index index.html;
    root /web/nginx/servers/name/conf;
proxy_set_header Host $server_name;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;

proxy_pass http://<webseal_hostname>/;
proxy_read_timeout 90;

```

}  
}

Please help.

Thanks,  
Krishna

Posted at Nginx Forum:

> **[This webpage has a redirect loop (ERR\_TOO\_MANY\_REDIRECTS)](https://forum.nginx.org/read.php?2,265136,265136#msg-265136)**
>
> Hi, My set up is as below: NGINX (reverse proxy) IBM WebSeal (redirects to a common login page, after authentication forwards to internal proxy along with the redirected url)  Internal Proxy (IBM http Server)  WebSphere Portal. I am trying to acc
