<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Title" content="">
<meta name="Keywords" content="">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Garamond;
panose-1:2 2 4 4 3 3 1 1 8 3;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:#0563C1;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:#954F72;
text-decoration:underline;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Garamond",serif;
color:windowtext;}
span.msoIns
{mso-style-type:export-only;
mso-style-name:"";
text-decoration:underline;
color:teal;}
.MsoChpDefault
{mso-style-type:export-only;
font-family:"Calibri",sans-serif;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style>
</head>
<body bgcolor="white" lang="EN-US" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-family:"Garamond",serif">I’m having a problem with setting up my first Windows SP. The IdP has been in service for several years. I can call a service on the SP (called “secure”) and I see it redirect properly to the IdP.
I can successfully enter my Network ID and password. And I see that the IdP correctly sends assertions to the SP. But when it returns from the IdP back to the SP it wants to start a whole new session again. Ending up in an endless loop. I’ve searched the
archives and didn’t find any solutions that worked for me.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">My environment:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">* A pair of linux IdPs behind a load balancer<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">* A single Windows SP behind a load balancer (in the future I’ll have a pair)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">Calling “Shibboleth.sso\Status” and running “shibd.exe –check” both are good.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">One thing I find odd is that all traffic from the loadbalancer to the SP comes to the SP as one IP address (Eg 192.1.2.3)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">which is the load balancer. Which is to say, a client who is 10.4.5.6 gets changed to 192.1.2.3 when it arrives at the SP.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">Likewise, if the IdP is 134.2.3.4 when redirected back to the SP it also shows up as 192.1.2.3. I know that’s just<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">the way the load balancer is setup. Could this be a problem?<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">Here is my shibboleth2.xml:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"><SPConfig
<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> clockSkew="180"><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <InProcess logger="native.logger"><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <ISAPI normalizeRequest="true" safeHeaderNames="false"><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <Site id="1" name="dev-sp.it.wsu.edu" scheme="https" port="443"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> </ISAPI><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> </InProcess><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <RequestMapper type="Native"><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <RequestMap><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <Host name="dev-sp.it.wsu.edu" redirectToSSL="443"><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <Path name="secure" authType="shibboleth" requireSession="true"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> </Host><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> </RequestMap><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> </RequestMapper><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <ApplicationDefaults entityID="<a href="https://dev-sp.it.wsu.edu/">https://dev-sp.it.wsu.edu/</a>"<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> REMOTE_USER="employeeNumber uid "<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> cipherSuites="ECDHE+AESGCM:ECDHE:!aNULL:!eNULL:!LOW:!EXPORT:!RC4:!SHA:!SSLv2"><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <Sessions lifetime="32400" timeout="32400" checkAddress="false"<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> consistentAddress="true" relayState="ss:mem" handlerSSL="true"<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> postData="ss:mem" postTemplate="postTemplate.html" <o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> cookieProps="; HttpOnly path=/; secure"><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <SSO entityID="<a href="https://dev-idp.it.wsu.edu/idp/shibboleth">https://dev-idp.it.wsu.edu/idp/shibboleth</a>"<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> discoveryProtocol="SAMLDS"<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> discoveryURL="<a href="https://dev-idp.it.wsu.edu/DS/WAYF%22">https://dev-idp.it.wsu.edu/DS/WAYF"</a>><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> SAML2 SAML1<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> </SSO><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <Logout>SAML2 Local</Logout><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <Handler type="MetadataGenerator" Location="/Metadata" signing="false"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <Handler type="Status" Location="/Status" acl="127.0.0.1 ::1 192.1.2.3"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <Handler type="Session" Location="/Session" showAttributeValues="true"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <Handler type="DiscoveryFeed" Location="/DiscoFeed"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> </Sessions><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <MetadataProvider type="XML"<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> uri="<a href="https://dev-idp.it.wsu.edu/idp/profile/Metadata/SAML">https://dev-idp.it.wsu.edu/idp/profile/Metadata/SAML</a>"<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> backingFilePath="dev-dp.it.wsu.edu.metadata.xml" reloadInterval="7200"> <o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> </MetadataProvider><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <AttributeExtractor type="XML" validate="true" reloadChanges="false" path="attribute-map.xml"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <AttributeResolver type="Query" subjectMatch="true"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <AttributeFilter type="XML" validate="true" path="attribute-policy.xml"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <CredentialResolver type="File" key="sp-key.pem" certificate="sp-cert.pem"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> </ApplicationDefaults><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <SecurityPolicyProvider type="XML" validate="true" path="security-policy.xml"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <ProtocolProvider type="XML" validate="true" reloadChanges="false" path="protocols.xml"/><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"></SPConfig><o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">Now I’ll show what I see in the logs (I added DEBUG).<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">From the transaction log there is a new session:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:24 INFO Shibboleth-TRANSACTION [1]: New session (ID: _2e2ff5942eee70e545d547a17f10cb68) with (applicationId: default) for principal from (IdP: <a href="https://dev-idp.it.wsu.edu/idp/shibboleth">https://dev-idp.it.wsu.edu/idp/shibboleth</a>)
at (ClientAddress: 192.1.2.3) with (NameIdentifier: _c903d65316185de5601c9ab64d457efd) using (Protocol: urn:oasis:names:tc:SAML:2.0:protocol) from (AssertionID: _fe90e6343940bf111acce98d9ad7f116)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">Then in the shibd.log you can see this session inserted (I’ve removed a lot of the chatter, hopefully not too much):<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:24 DEBUG Shibboleth.SessionCache [1]: creating new session<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:24 DEBUG Shibboleth.SessionCache [1]: storing new session...<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:24 DEBUG XMLTooling.StorageService [1]: inserted record (session) in context (_2e2ff5942eee70e545d547a17f10cb68) with expiration (1507360104)<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:24 INFO Shibboleth.SessionCache [1]: new session created: ID (_2e2ff5942eee70e545d547a17f10cb68) IdP (<a href="https://dev-idp.it.wsu.edu/idp/shibboleth">https://dev-idp.it.wsu.edu/idp/shibboleth</a>)
Protocol(urn:oasis:names:tc:SAML:2.0:protocol) Address (192.1.2.3)<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:24 DEBUG Shibboleth.SSO.SAML2 [1]: ACS returning via redirect to: <a href="https://dev-sp.it.wsu.edu/secure">https://dev-sp.it.wsu.edu/secure</a><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:24 DEBUG OpenSAML.MessageEncoder.SAML2Redirect [1]: marshalled message:<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"><samlp:AuthnRequest xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol" AssertionConsumerServiceURL="<a href="https://dev-sp.it.wsu.edu/Shibboleth.sso/SAML2/POST">https://dev-sp.it.wsu.edu/Shibboleth.sso/SAML2/POST</a>"
Destination="<a href="https://dev-idp.it.wsu.edu/idp/profile/SAML2/Redirect/SSO">https://dev-idp.it.wsu.edu/idp/profile/SAML2/Redirect/SSO</a>" ID="_b73b7072cd5f9b9fc36c7dfb20be730a" IssueInstant="2017-10-06T22:08:24Z" ProtocolBinding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST"
Version="2.0"><saml:Issuer xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion"><a href="https://dev-sp.it.wsu.edu/%3c/saml:Issuer%3e%3csamlp:NameIDPolicy">https://dev-sp.it.wsu.edu/</saml:Issuer><samlp:NameIDPolicy</a> AllowCreate="1"/></samlp:AuthnRequest><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">.<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">.<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">. <o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 DEBUG Shibboleth.SSO.SAML2 [1]: SSO profile processing completed successfully<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 DEBUG Shibboleth.SSO.SAML2 [1]: extracting pushed attributes...<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 DEBUG Shibboleth.AttributeFilter [1]: filtering 4 attribute(s) from (<a href="https://dev-idp.it.wsu.edu/idp/shibboleth">https://dev-idp.it.wsu.edu/idp/shibboleth</a>)<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 DEBUG Shibboleth.SSO.SAML2 [1]: resolving attributes...<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">So I can see that the IdP successfully passed assertions back to the SP like expected.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">And for some reason, it starts a new session all over and does not continue with the above session:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 DEBUG Shibboleth.SessionCache [1]: creating new session<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 DEBUG Shibboleth.SessionCache [1]: storing new session...<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 DEBUG XMLTooling.StorageService [1]: inserted record (session) in context (_b3dbbf5e504b36cef0054c707e8bc8d1) with expiration (1507360105)<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 DEBUG XMLTooling.StorageService [1]: updated record (_c903d65316185de5601c9ab64d457efd) in context (NameID) with expiration (1507360105)<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 DEBUG XMLTooling.StorageService [1]: inserted record (_8844a118fbbdbe128b0e39ade4695f66) in context (_b3dbbf5e504b36cef0054c707e8bc8d1) with expiration
(1507360105)<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 INFO Shibboleth.SessionCache [1]: new session created: ID (_b3dbbf5e504b36cef0054c707e8bc8d1) IdP (<a href="https://dev-idp.it.wsu.edu/idp/shibboleth">https://dev-idp.it.wsu.edu/idp/shibboleth</a>)
Protocol(urn:oasis:names:tc:SAML:2.0:protocol) Address (192.1.2.3)<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-family:"Garamond",serif">2017-10-06 15:08:25 DEBUG XMLTooling.StorageService [1]: deleted record (43c735b0c32fdead9da3eb39252dafec58b691d04cfda9bcb84b0fc8e651e433) in context (RelayState)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">And sure enough, the transaction log also shows a new session:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">And the process loops over and over and over ….<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">I’ve tried various suggestions in the archives related to looping, but I haven’t found the right answer yet.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif">thanks – Dean<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Garamond",serif"><o:p> </o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.5pt;color:black"><o:p> </o:p></span></p>
</div>
<p class="MsoNormal"><span style="font-size:10.5pt;color:black"><o:p> </o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;color:black">Dean Guenther </span><span style="font-size:10.5pt;color:black"><a href="mailto:dean.guenther@wsu.edu"><span style="font-size:10.0pt;color:blue">dean.guenther@wsu.edu</span></a></span><span style="font-size:10.0pt;color:black"><br>
Washington State University Phone: 509 335-0433<br>
Pullman, WA. 99164-1222 fax: 509 335-0540<br>
Identity and Access Management Manager</span><span style="font-size:10.5pt;color:black"><o:p></o:p></span></p>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</body>
</html>