Forum Discussion

AlgebraicMirror's avatar
AlgebraicMirror
Icon for Altostratus rankAltostratus
Aug 02, 2015

Is there a way in iRules to modify which IDP profile the APM selects?

Is there any way to modify how the APM matches an SP to an IDP configuration? I know normally it looks at the Issuer ID that the SP sends and uses that to match an SP configuration, which is in turn bound to an IDP configuration. But I've run into a situation with Office365 where that won't work for me.

 

It turns out Office365 has this issue: if you have multiple domains inside a single tenant account, they all come in with the Issuer ID and the same Assertion Consumer Service URL (actually, I think all domains regardless of account use the same issuer ID and ACS URL). The way to distinguish the assertion requests (and the way ADFS handles this, according to Microsoft support) is to look at the user that the SP sent the assertion request for. The user comes in a name@domain.com format, and the domains will be different there, which is how ADFS tells the SPs apart and knows which domain to send an assertion to.

 

I'd like to do the same thing on the F5. I'm sure there's probably a way to do decodes and look at the SAML request, but is there any way to override what IDP configuration gets selected based on what I find the user's domain to be? Unfortunately, Microsoft requires that if you have two domains, the IDP must send back assertions to each domain with a different issuer ID so that Microsoft can tell them apart. I could create two IDP configurations with two different issuer IDs easily enough, but I can't create separate SP configurations to go with them since they have the same issuer ID. So there's no way I can find out of the box to get the bindings to work for me.

 

PS - I know I could probably make a separate Virtual Server with its own access policy and use Microsoft's federation settings to point each domain at a different virtual server, but the end goal of this is to have single sign on for everyone, which necessitates the use of the same policy. There are a number of other non-Microsoft SPs I want to federate with, and users in both the Microsoft domains need to get SSO access to the other SPs, necessitating the use of the same policy and virtual server.

 

15 Replies