Questions tagged [identityserver4]

OpenID Connect Provider and OAuth 2.0 Authorization Server Framework based on ASP.NET Core

IdentityServer4 is an OpenID Connect Provider and OAuth 2.0 Authorization Server Framework built on ASP.NET Core.

Allows for the implementation of single sign-on and access control for modern web applications and APIs using protocols such as OpenID Connect and OAuth2. It supports a wide range of clients like mobile, web, SPAs and desktop applications and is extensible to allow integration in new and existing architectures.

IdentityServer4 is officially certified by the OpenID Foundation and thus spec-compliant and interoperable. It is part of the .NET Foundation, and operates under their code of conduct. It is licensed under Apache 2 (an OSI approved license).

For the .NET 4.x, katana based version see Identity Server 3

5377 questions
2
votes
0 answers

Integrating IdentityServer 4 into an existing Asp.Net Core 2 Web API Project

I'm integrating IdentityServer4 into an existing ASP.NET Core 2 Web API project. The goal is to provide security for the api that will be accessed by front end code plus calls from a known third party application. To this end, i'm setting up two…
Treika
  • 21
  • 2
2
votes
2 answers

HttpContext.SignOutAsync() not deleting local cookie

I am following along the IdentityServer4 Quickstart project to get up to speed on how it is implemented. My Startup.cs is close to identical, my implementation of the AccountController.cs class is more or less the same, and so on. However, there…
w0f
  • 908
  • 9
  • 23
2
votes
1 answer

Programmatically requesting access token on behalf of user

I want to programmatically get access token for the current user after logging in. I've figured out how to get a token using client credentials but I couldn't figure out how to get one on behalf of the user. Here's what I tried to get using client…
dstr
  • 8,362
  • 12
  • 66
  • 106
2
votes
0 answers

Implementing IdentityServer4 security on SSRS reports

We have a SPA built on Angular and WebApi Dotnet Core. This application is using IdentityServer4 for authentication and authorization. We want to integrate Sql Reporting Services reports inside it. How can we secure these reports with the…
The Eagle
  • 427
  • 1
  • 4
  • 13
2
votes
1 answer

IdentityServer4 in Docker images running on Linux & Azure repositories & authentication issue

My solution consists of three projects, which are: An ASP.NET MVC Core project that hosts the IdentityServer. An ASP.NET Core API project which is protected and manages the IdentityServer. Another ASP.NET MVC Core that calls the API. So, the MVC…
Bug
  • 832
  • 2
  • 9
  • 37
2
votes
3 answers

IdentityServer4 Sample with ASP Identity with real SQL Server

I have been struggling to get the final SAMPLE (ASP.Net, EF Core, SQL) to work against a real SQL Server. Every sample I can find does not use real SQL they always opt for in-memory data store I changed the connection string "Data Source=.;Initial…
2
votes
0 answers

What is Logsource for Aspnetcore.Authentication.JwtBearer

I have aspnetcore2 api that is using IdentityServer4.AccessTokenValidation and Microsoft.AspNetCore.Authentication.JwtBearer packes to handle access token authentication. I've setup Serilog logging in my application with the following config:…
Eugene S.
  • 3,256
  • 1
  • 25
  • 36
2
votes
2 answers

Redirecting url from Identity server 4 is not behaving as expected and "Cannot cast Newtonsoft.Json.Linq.JArray to Newtonsoft.Json.Linq.JToken" error

Note : After resolving the redirection issue i had an another issue that is getting an error "Cannot cast Newtonsoft.Json.Linq.JArray to Newtonsoft.Json.Linq.JToken". So in my answer I have provided the correct solution for both. I have identity…
2
votes
1 answer

identityserver4 - ArgumentNullException: Value cannot be null

I am using IdentityServer4 and I keep having an issue when the access token has expired. If the user tries to do something like logout after this happens then it gives the error below. But this also happens when you try to login again as well. The…
BinaryNexus
  • 875
  • 3
  • 15
  • 30
2
votes
1 answer

How to customise Identity Models to rename columns and resize datatypes in IdentityServer4

I've been playing around with this quickstart example & have been trying to see how far I can customise the database (I have an existing database I've been half-trying to replicate). I'm trying my hand at renaming fields and redefining the datatypes…
derpasaurus
  • 397
  • 3
  • 13
2
votes
1 answer

Entity type 'Microsoft.AspNetCore.Identity.IdentityRole' is in shadow-state

I've been playing around with this quickstart example & have been trying to see how far I can customise the database (I have an existing database I've been half-trying to replicate). I've managed to trigger the exception below and am having trouble…
2
votes
1 answer

How to return different scopes for different roles in IdentityServer 4?

I am using IdentityServer4 for protecting my .net core app. I would like to use Policy-Based Authorization Here is example of one policy I did options.AddPolicy("api.order.write", builder => builder.RequireScope( …
Oleh
  • 447
  • 1
  • 11
  • 30
2
votes
2 answers

Identity Server 4 Claims empty on API

I have been trying to Integrate Identity Server 4 with SPA application. I am able to Authorize the Application in API but after the authorization the User.Claims are always empty though i have added the Claims in Scopes. I am using Asp.net Identity…
2
votes
1 answer

Identity Server 4 Use a new Signing Key after Startup

I have IdentityServer4 setup in an aspnetcore API Service (running in Service Fabric as a Stateless Service) which uses a signing certificate generated and held in Azure Key Vault. In the Startup class I'm using the AddSigningCredential method to…
2
votes
1 answer

update client database for IdentityServer4

I have identityServer4 as my oAuth server in my net core appilication. I was able to initialize my client database using the following code: public void Configure(IApplicationBuilder app, IHostingEnvironment env) { if…
user3097695
  • 1,152
  • 2
  • 16
  • 42