[cpp-sp] branch master updated: SSPCPP-692 - Provide HandlerURL as a environment/header value

Scott Cantor cantor.2 at osu.edu
Tue May 31 16:12:05 EDT 2016


This is an automated email from the git hooks/post-receive script.

scantor pushed a commit to branch master
in repository cpp-sp.

The following commit(s) were added to refs/heads/master by this push:
       new  fa6d1e9   SSPCPP-692 - Provide HandlerURL as a environment/header value
fa6d1e9 is described below

commit fa6d1e994825447f67e2f1ec406425dbb2d6930c
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Tue May 31 16:11:27 2016 -0400

    SSPCPP-692 - Provide HandlerURL as a environment/header value
    
    https://issues.shibboleth.net/jira/browse/SSPCPP-692
---
 shibsp/ServiceProvider.cpp | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/shibsp/ServiceProvider.cpp b/shibsp/ServiceProvider.cpp
index 3ac5236..3d38c4f 100644
--- a/shibsp/ServiceProvider.cpp
+++ b/shibsp/ServiceProvider.cpp
@@ -158,6 +158,7 @@ namespace shibsp {
         app.clearHeader(request, "Shib-AuthnContext-Class", "HTTP_SHIB_AUTHNCONTEXT_CLASS");
         app.clearHeader(request, "Shib-AuthnContext-Decl", "HTTP_SHIB_AUTHNCONTEXT_DECL");
         app.clearHeader(request, "Shib-Assertion-Count", "HTTP_SHIB_ASSERTION_COUNT");
+        app.clearHeader(request, "Shib-Handler", "HTTP_SHIB_HANDLER");
         app.clearAttributeHeaders(request);
         request.clearHeader("REMOTE_USER", "HTTP_REMOTE_USER");
     }
@@ -320,11 +321,14 @@ pair<bool,long> ServiceProvider::doAuthentication(SPRequest& request, bool handl
                     return make_pair(true, request.sendRedirect(loc.c_str()));
                 }
             }
+            app->setHeader(request, "Shib-Handler", handlerURL);
         }
         else {
             // No session.  Maybe that's acceptable?
-            if ((!requireSession.first || !requireSession.second) && !requireSessionWith.first)
+            if ((!requireSession.first || !requireSession.second) && !requireSessionWith.first) {
+                app->setHeader(request, "Shib-Handler", handlerURL);
                 return make_pair(true, request.returnOK());
+            }
 
             // No session, but we require one. Initiate a new session using the indicated method.
             const SessionInitiator* initiator=nullptr;

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list