Questions tagged [identitymodel]

77 questions
1
vote
0 answers

Why IsNullOrEmpty check of an enumerable part of Microsoft.IdentityModel.Tokens?

I found a code today where an enumerable is being checked for null or empty using static IsNullOrEmpty method exposed through Microsoft.IdentityModel.Tokens. Now in Microsoft documentation it is listed under confidential client. My question is…
1
vote
1 answer

How to set AuthenticationFlow and ResponseMode in .Net 6

I migrated my application from .Net Core 3.1 to .Net 6 and also upgraded the IdentityModel.OidcClient nuget package(currently using 5.2.1 version). But now I don't see the Flow(AuthenticationFlow) and ResponseMode properties in OidcClientOptions…
1
vote
1 answer

JWT with no expires date

I'm using Microsoft.IdentityModel.Tokens to create a JWT but I need a token with no expiration date, can I create that token with the CreateJwtSecurityToken function? I tried ignoring the expires parameter but that not work.
M. Gar
  • 889
  • 4
  • 16
  • 33
1
vote
1 answer

Task.Delay in Dispose method of LoopbackListener in IdentityModel.OidcClient

I'm using IdentityModel.OidcClient's SystemBrowser to request a token in a console app via browser. What I don't understand is, why there is an await Task.Delay(500) in the Dispose method of the LoopbackHttpListener. I see why you would do the…
1
vote
1 answer

.NET Core 3.1 OAUTH 2 Token Introspection with Custom JSON Response - "Status Code cannot be set because the response has already started"

I have already tried all the solutions here, and nothing is working. I am using package IdentityModel.AspNetCore.OAuth2Introspection v6.0.0. The business use case I have is that I have to return a 401 Unauthorized status code plus a custom JSON…
codeMonkey
  • 4,134
  • 2
  • 31
  • 50
1
vote
1 answer

Parameter Count Mismatch CreateEndSessionUrl - IdentityModel

I'm new to C#. I'm using .NET IdentityModel with AWS Cognito User Pools and attempting to get logout to work. CreateEndSessionUrl sets post_logout_redirect_uri but Cognito requires logout_uri. I'm attempting to use the extra parameter but getting a…
Bubba
  • 71
  • 6
1
vote
0 answers

Will a certificate work after expiration date if there are no checks for its validity?

I got an application from a 3rd party which uses a certificate in the process of authenticating. I wonder if the certificate will still work after its expiration date if the source code uses it in the following ways: X509Store store = new…
Michael
  • 11
  • 2
1
vote
1 answer

IdentityModel.OidcClient migration from 3.1.2 to 4.0 in UWP App

I have recently updated the nuget package of IdentityModel.OidcClient from version 3.1.2 to 4.0. Now I get errors on my existing implementation due to missing properties and couldn't figure how to migrate from XXX to 4.0. return new…
1
vote
1 answer

IdentityModel implementation: How to verify (and refresh) access_token on or after expiry date?

Backstory: I'm trying to link up a new client application using .NET 5 (MVC) with an existing IdentityServer4. IdentityServer4 (IS4 in short) is used both to authenticate the client, as well as providing claims & roles and the access_token that the…
1
vote
1 answer

Configure ClientCredential of IdentityModel using values retrieved from Cloud Foundry CredHub

Short Problem Statement: How to get value from Cloud Foundry CredHub to be used inside ConfigureServices(IServiceCollection services)? Existing Condition: Let's say that I have a class called SystemConfig for holding configuration values. I use a…
Keith
  • 361
  • 1
  • 3
  • 17
1
vote
2 answers

Windows Authentication with IdentityServer4 on IIS

I am trying to use Windows Authentication credentials to connect with my native (Winforms, console app) client to Identity Server hosted on IIS. The point is for user to be authenticated by AD and with those credentials get the right claims and…
VidyaPuri
  • 93
  • 1
  • 1
  • 6
1
vote
1 answer

IdentityServer4 sample code gives unauthorized_client error

I am trying to learn the Identitymodel.OidcClient package and started by testing one of the provided samples: the ConsoleSystemBrowser sample. It's a pretty straightforward sample, and I was expecting it to give me a fully configured and working…
user9366235
1
vote
0 answers

.net 4.8 IdentityModel The located assembly's manifest definition does not match the assembly reference

I have a solution with two project (.net 4.8) WebAPI Class library In my web api I am using IdentityServer3.AccessTokenValidation and there is a dependency with IdentityModel 1.9.2. In Class library I added IdentityModel 4.4.0 to get the…
1
vote
0 answers

Understanding & Using Microsoft Identity

Background: I'm developing my first enterprise software solution as a part of starting my software company. I'm developing on .NET Core. I've been reading through all of the Microsoft documentation regarding Authentication vs. Authorization,…
1
vote
1 answer

IdentityModel vs Microsoft.IdentityModel vs System.IdentityModel

I am implementing OIDC/OAuth authentication & authorization in a classic ASP.net MVC application using OWIN. For API calls that are not supported by Microsoft's OIDC middleware, it appears that I have some choices. I can craft and make rest…
Mark Good
  • 4,271
  • 2
  • 31
  • 43