Search code examples
javasecurityauthenticationsamlws-federation

WS-Federation Active Requestor Profile SOAP Request


I'm working on a project that will be using the WS-Federation protocol to request a SAML token from an identify provider (ADFS in our case). Since one of the requirements is that the application collect the username and password itself, we'll be taking advantage of the WS-Federation Active Requestor Profile to accomplish this. However, examples and documentation are fairly hard to find on this profile. It seems the majority of examples and docs deal with the Passive Profile approach.

I was wondering if anyone would be able to provide an actual full SOAP request sample which would contain the username and password and take advantage of the Active Requestor profile. Ideally this request should request a SAML token.

Also if anyone is aware of any working Java library or code that works with the Active Requestor profile that would be very helpful too.


Solution

  • I don't have an example in Java, but my answer here contains code to retrieve a SAML token from ADFS in exchange for a username and password using .NET 4.5.

    You can install Fiddler and extract the RST message as it goes over the wire.