[shibboleth-sp2] 25/82: SSPCPP-694 Native IIS: Todo and Role Based AuthN

Etienne Dysli Metref edm-guest at moszumanska.debian.org
Thu Nov 16 08:16:21 UTC 2017


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

edm-guest pushed a commit to branch master
in repository shibboleth-sp2.

commit a7c6e7ae3cdf62a8acd0b2626f2b0edff058286e
Author: Rod Widdowson <rdw at steadingsoftware.com>
Date:   Fri Apr 28 14:50:59 2017 +0100

    SSPCPP-694 Native IIS: Todo and Role Based AuthN
    
    https://issues.shibboleth.net/jira/browse/SSPCPP-694
    
    Add a review note to ShibHttpModule.cpp.
    Add a fixed role to our Principal: This allows us to test Role based AuthN.
---
 iis7_shib/ShibHttpModule.cpp | 1 +
 iis7_shib/ShibUser.cpp       | 8 +++++---
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/iis7_shib/ShibHttpModule.cpp b/iis7_shib/ShibHttpModule.cpp
index 0734e07..a74cb38 100644
--- a/iis7_shib/ShibHttpModule.cpp
+++ b/iis7_shib/ShibHttpModule.cpp
@@ -38,6 +38,7 @@ ShibHttpModule::DoHandler(
     threadid += lexical_cast<string>(_getpid()) + "] native_shib";
     xmltooling::NDC ndc(threadid.c_str());
 
+    // TODO the handler and the Filter both use the same class.  Should it?
     NativeRequest handler(pHttpContext, pProvider, false);
 
     pair<bool, long> res = handler.getServiceProvider().doHandler(handler);
diff --git a/iis7_shib/ShibUser.cpp b/iis7_shib/ShibUser.cpp
index 53025d4..4728e23 100644
--- a/iis7_shib/ShibUser.cpp
+++ b/iis7_shib/ShibUser.cpp
@@ -80,17 +80,19 @@ ShibUser::DereferenceUser(VOID)
 BOOL
 ShibUser::SupportsIsInRole(VOID)
 {
-    return FALSE;
+    return TRUE;
 }
 
 HRESULT
 ShibUser::IsInRole(_In_  PCWSTR  pszRoleName, _Out_ BOOL *  pfInRole)
 {
-    return E_NOTIMPL;
+    wstring role(pszRoleName);
+    *pfInRole = (role == L"shibAuthn");
+    return S_OK;
 }
 PVOID
 ShibUser::GetUserVariable(_In_ PCSTR    pszVariableName)
 {
-    return  nullptr;
+    return  "flibby";
 }
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-shibboleth/shibboleth-sp2.git



More information about the Pkg-shibboleth-devel mailing list