question

RomanGelfand-6864 avatar image
0 Votes"
RomanGelfand-6864 asked RomanGelfand-6864 answered

Read ADFS Claims in .net framework web forms application

I have successfully setup ad fs to redirect to .net framework web forms site upon successful login. I have defined claims for this relying part trust. How do I retrieve those claims in redirect page code behind?

Thanks in advance

dotnet-csharpwindows-active-directoryadfs
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

piaudonn avatar image
0 Votes"
piaudonn answered

It depends what you use on your application. There are examples in the public documentation: https://docs.microsoft.com/en-us/windows-server/identity/ad-fs/development/ad-fs-openid-connect-oauth-concepts

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

RomanGelfand-6864 avatar image
0 Votes"
RomanGelfand-6864 answered

Thanks for your help.

Actually, I am looking for a more detailed exampled.

To elaborate what I am looking for...

I am attempting to conver an exisiting web forms application to use ad fs.

I have successfully setup ad fs to redirect to .net framework web forms site upon successful login. I have defined claims for this relying part trust. How do I retrieve those claims in redirect page code behind?

I was able to retrieve the claims only when changing the authentication mode from anonymous to windows. However, this, also, produces authentication windows authentication popups. I don't want the popups. I suppose what I am looking for, let me know if it wrong, 1) upon successful ad fs login, I am redirected to web forms application signin page which doesn't prompt user with login since it receives user identity and other claims from ad fs. 2) Retrieve claims and lookup permissions on backend db based on user identity and claims. 3) Create and maintain session. Step 2 and 3 are done by the web forms application currently. So, I am looking to retrieve claims in 2).

Thanks again

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.