Posting a SAML token to ASP.NET MVC website
Asked Answered
C

1

6

I have a claims aware MVC website setup using the Thinktecture Identity Server. I now have a requirement to allow a 3rd party to access certain parts of the website.

Is it possible to programmatically authenticate with the Identity Server and post this to the website so that the user at the 3rd party is not required to manually go through the normal login process?

I have previously used the identity server to obtain a SAML token for the purpose of making WCF calls, I was wondering if it would be possible to re-use some of this approach?

The complications arise from the fact that the 3rd party are using a desktop based Java app with some browser component built in for accessing the MVC website. Users are already authenticated with the desktop app so we don't want them entering credentials again to view these web pages.

Crybaby answered 13/1, 2014 at 11:38 Comment(0)
I
1

Hmm, tough one to solve in a secure fashion. Basically I don't trust desktop apps ;-)

You might be looking for some sort of federation. Basically it is about letting your Identity Server trust the 3rd party (by means of signature). Your Identity Server would then use a SAML token from 3rd party as login information and generate a new SAML token (signed by you) to forward to the the MVC web application. I think Dominick has a video or two about it, but not sure it meets your requirements. Take a look at https://github.com/thinktecture/Thinktecture.IdentityServer.v2/wiki

The Java desktop app probably cannot create a signed SAML token, so you could consider using "something else". Preferably something signed from where they logged in the first time.

You should avoid having your web app trust anyone but your own Identity Server / Identity Provider.

Hope this helps? Happy to help where I can :-)

Ishmul answered 27/3, 2014 at 20:13 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.