nginx-shib / nginx-http-shibboleth

Shibboleth auth request module for nginx
https://github.com/nginx-shib/nginx-http-shibboleth/wiki
Other
209 stars 27 forks source link

No variables are copied to the header #17

Closed greut closed 8 years ago

greut commented 8 years ago

Description of Issue/Question

No variables are copied when using shib_request_use_headers on;.

I've added a couple of ngx_log_debug and came to the conclusion that no headers where available to the subrequest (sr).

https://github.com/nginx-shib/nginx-http-shibboleth/blob/69829b98e14eb20e3f1916675ec407c497674eec/ngx_http_shibboleth_module.c#L271-L281

Do you have any leads to follow?

Kindest regards!

Setup

A mix of your setup and https://github.com/jnyryan/vagrant-shibboleth-sp-nginx https://hesso.whut.ch/ (using http2)

Steps to Reproduce Issue

...

Versions and Systems

nginx version: nginx/1.10.1
built by gcc 5.3.1 20160413 (Ubuntu 5.3.1-14ubuntu2.1) 
built with OpenSSL 1.0.2g-fips  1 Mar 2016
TLS SNI support enabled
configure arguments: --sbin-path=/usr/sbin/nginx --conf-path=/etc/nginx/nginx.conf --pid-path=/run/nginx.pid --error-log-path=/var/log/nginx/error.log --http-log-path=/var/log/nginx/access.log --with-http_ssl_module --with-ipv6 --with-http_v2_module --add-module=/opt/nginx-http-shibboleth --add-module=/opt/headers-more-nginx-module --with-debug

shibboleth 2.5.3
greut commented 8 years ago

Could it be a missing exportAssertion?

greut commented 8 years ago

Indeed... https://github.com/nginx-shib/nginx-http-shibboleth/blob/master/CONFIG.rst#configuring-shibboleths-shibboleth2xml-to-recognise-secured-paths

My bad, thanks for this awesome module!!

davidjb commented 8 years ago

No worries, what was the config issue?

It's can be a pretty complicated setup so if the docs could be improved, open a pull request 😃

greut commented 8 years ago

Adding a <RequestMapper> and making the fastcgi buffer insanely huge did it. I'll see if I have something worth a PR.