# \#dotnet

**URL:** https://devforum.okta.com/tag/dotnet/1.md

[Latest](https://devforum.okta.com/latest.md) · [Categories](https://devforum.okta.com/categories.md) · [Tags](https://devforum.okta.com/tags.md)

---

## [How to limit access to specific api's with Client Credentials flow](https://devforum.okta.com/t/how-to-limit-access-to-specific-apis-with-client-credentials-flow/35291)

<div class="topic-metadata">

**Author:** [@Akhil.Mohan](https://devforum.okta.com/u/Akhil.Mohan)\
**Replies:** 3\
**Last updated:** [June 9, 2026, 2:15pm UTC](https://devforum.okta.com/t/how-to-limit-access-to-specific-apis-with-client-credentials-flow/35291 "2026-06-09T14:15:17Z")

</div>

I have a requirement where I need to secure a set of APIs hosted in my own domain using Okta OAuth 2.0 with the Client Credentials flow (Client ID and Client Secret). My requirement is to control access to specific APIs…

---

## [OKTA authentication with Asp.net web form](https://devforum.okta.com/t/okta-authentication-with-asp-net-web-form/35246)

<div class="topic-metadata">

**Author:** [@partapOkta](https://devforum.okta.com/u/partapOkta)\
**Replies:** 5\
**Last updated:** [May 5, 2026, 7:46am UTC](https://devforum.okta.com/t/okta-authentication-with-asp-net-web-form/35246 "2026-05-05T07:46:20Z")

</div>

Old system is using asp dotnet web form for windows AD and now I am using OKTA to authentication user and when user visits https://localhost/SampleApp/index.aspx and OKTA system redirects to https://localhost/SampleApp/…

---

## [Blazor 8 interactive server with MFA](https://devforum.okta.com/t/blazor-8-interactive-server-with-mfa/34653)

<div class="topic-metadata">

**Author:** [@mturek](https://devforum.okta.com/u/mturek)\
**Replies:** 1\
**Last updated:** [December 8, 2025, 4:21pm UTC](https://devforum.okta.com/t/blazor-8-interactive-server-with-mfa/34653 "2025-12-08T16:21:28Z")

</div>

Hi there! Does anybody have an example of Blazor interactive server (.net 8 or higher) with OKTA OIDC authentication and MFA? I am using Okta.AspNetCore package. Getting the following error {“errorCode”:“E0000022”,“error…

---

## [Okta.AspNetCore duplicating tab after completing OIDC login fails](https://devforum.okta.com/t/okta-aspnetcore-duplicating-tab-after-completing-oidc-login-fails/34536)

<div class="topic-metadata">

**Author:** [@wrobertson](https://devforum.okta.com/u/wrobertson)\
**Replies:** 0\
**Last updated:** [October 29, 2025, 12:26am UTC](https://devforum.okta.com/t/okta-aspnetcore-duplicating-tab-after-completing-oidc-login-fails/34536 "2025-10-29T00:26:46Z")

</div>

Hi, I’m currently facing an issue with my ASP.NET core application. We are using Okta.AspNetCore (4.6.3) Once a user has successfully authenticated with my application, using Okta SSO, they are unable to “duplicate” the…

---

## [Message contains error: 'login\_required', error\_description: 'The client specified not to prompt, but the user is not logged in.', error\_uri: 'error\_uri is null'](https://devforum.okta.com/t/message-contains-error-login-required-error-description-the-client-specified-not-to-prompt-but-the-user-is-not-logged-in-error-uri-error-uri-is-null/34478)

<div class="topic-metadata">

**Author:** [@mghos](https://devforum.okta.com/u/mghos)\
**Replies:** 7\
**Last updated:** [October 13, 2025, 3:06pm UTC](https://devforum.okta.com/t/message-contains-error-login-required-error-description-the-client-specified-not-to-prompt-but-the-user-is-not-logged-in-error-uri-error-uri-is-null/34478 "2025-10-13T15:06:49Z")

</div>

I have .Net application which is trying to do silent login, without re-routing to okta’s login page. This was working till I upgraded my .Net framework to .Net Core 9.0. Post that I am getting the below error. “Message …

---

## ["Nonce validation fails in ASP.NET Web Forms - SecurityTokenValidated fires but cookie not persisted"](https://devforum.okta.com/t/nonce-validation-fails-in-asp-net-web-forms-securitytokenvalidated-fires-but-cookie-not-persisted/34476)

<div class="topic-metadata">

**Author:** [@kshah](https://devforum.okta.com/u/kshah)\
**Replies:** 0\
**Last updated:** [October 10, 2025, 12:40am UTC](https://devforum.okta.com/t/nonce-validation-fails-in-asp-net-web-forms-securitytokenvalidated-fires-but-cookie-not-persisted/34476 "2025-10-10T00:40:48Z")

</div>

I’m implementing Okta authentication in an ASP.NET Web Forms application (not MVC) using Microsoft.Owin.Security.OpenIdConnect. Issue: SecurityTokenValidated fires successfully ✓ User is authenticated with all claims…

---

## [Okta Login Widget for .Net Framework 4.0](https://devforum.okta.com/t/okta-login-widget-for-net-framework-4-0/34287)

<div class="topic-metadata">

**Author:** [@Rashda](https://devforum.okta.com/u/Rashda)\
**Replies:** 1\
**Last updated:** [September 5, 2025, 2:46pm UTC](https://devforum.okta.com/t/okta-login-widget-for-net-framework-4-0/34287 "2025-09-05T14:46:24Z")

</div>

I want to embedd Okta Signin Widget to a legacy application built on .Net Framework 4.0 MVC 3.0. Is there an example sowing how to do it. All examples are based on .Net Framework \>=4.8. Is it possible to do this on .Ne…

---

## [Password prompt after 60 minutes](https://devforum.okta.com/t/password-prompt-after-60-minutes/34106)

<div class="topic-metadata">

**Author:** [@drownr](https://devforum.okta.com/u/drownr)\
**Replies:** 4\
**Last updated:** [August 28, 2025, 6:39pm UTC](https://devforum.okta.com/t/password-prompt-after-60-minutes/34106 "2025-08-28T18:39:19Z")

</div>

We are in the process of implementing SSO with OIDC in several of our ASP.Net Core and ASP.Net MVC 5 (.Net Framework 4.8) applications, using the Okta-hosted redirect method. We have based our implementations on the samp…

---

## [Integrate SAML in ASP.net Webforms](https://devforum.okta.com/t/integrate-saml-in-asp-net-webforms/26324)

<div class="topic-metadata">

**Author:** [@Ajayshanbhag](https://devforum.okta.com/u/Ajayshanbhag)\
**Replies:** 9\
**Last updated:** [July 31, 2025, 11:17pm UTC](https://devforum.okta.com/t/integrate-saml-in-asp-net-webforms/26324 "2025-07-31T23:17:27Z")

</div>

How to integrate the SAML in ASP.net Webforms. can you please help me how to do it using sustainsys.saml2 or if you have any other method it will also work

---

## [Okta.AspNetCore OIDC Login Works, but Duplicate Tab Fails](https://devforum.okta.com/t/okta-aspnetcore-oidc-login-works-but-duplicate-tab-fails/33749)

<div class="topic-metadata">

**Author:** [@Farhin](https://devforum.okta.com/u/Farhin)\
**Replies:** 0\
**Last updated:** [June 27, 2025, 3:33pm UTC](https://devforum.okta.com/t/okta-aspnetcore-oidc-login-works-but-duplicate-tab-fails/33749 "2025-06-27T15:33:02Z")

</div>

Hi, The following describes an issue with an ASP.NET Core application using the Okta.AspNetCore library for OpenID Connect (OIDC) authentication. The login process works correctly, and users are successfully authenticat…

---

## [UseOktaMvc Okta Domain switching](https://devforum.okta.com/t/useoktamvc-okta-domain-switching/32991)

<div class="topic-metadata">

**Author:** [@HunterLynch](https://devforum.okta.com/u/HunterLynch)\
**Replies:** 0\
**Last updated:** [April 24, 2025, 9:03pm UTC](https://devforum.okta.com/t/useoktamvc-okta-domain-switching/32991 "2025-04-24T21:03:03Z")

</div>

I have recently added a 2nd branded login page within Okta for a specific client and have a custom domain for them. When I attempt to log in with my new login page, I am rerouted to my main custom log in page rather than…

---

## [We are experiencing a persistent looping behavior in the login process](https://devforum.okta.com/t/we-are-experiencing-a-persistent-looping-behavior-in-the-login-process/32845)

<div class="topic-metadata">

**Author:** [@Jrr](https://devforum.okta.com/u/Jrr)\
**Replies:** 2\
**Last updated:** [April 23, 2025, 5:57pm UTC](https://devforum.okta.com/t/we-are-experiencing-a-persistent-looping-behavior-in-the-login-process/32845 "2025-04-23T17:57:30Z")

</div>

We are encountering a login looping issue during the authentication process integrated with Okta. The problem is browser-specific: while Firefox works without issues, Chrome consistently experiences a redirect loop, and …

---

## [Swagger with SPA (Angular + .Net)](https://devforum.okta.com/t/swagger-with-spa-angular-net/32948)

<div class="topic-metadata">

**Author:** [@davide.nani](https://devforum.okta.com/u/davide.nani)\
**Replies:** 3\
**Last updated:** [April 23, 2025, 1:20pm UTC](https://devforum.okta.com/t/swagger-with-spa-angular-net/32948 "2025-04-23T13:20:48Z")

</div>

Hi to all, I have an angular application + .Net 8 WebApi and I’m trying to make Swagger works. I registered the app on Okta as a SPA and authentication works well using Authorization Code grant with PKCE. But I’m not …

---

## [No SCIM protocol JSON message on authorization error response](https://devforum.okta.com/t/no-scim-protocol-json-message-on-authorization-error-response/32866)

<div class="topic-metadata">

**Author:** [@Smootie](https://devforum.okta.com/u/Smootie)\
**Replies:** 0\
**Last updated:** [April 8, 2025, 5:51pm UTC](https://devforum.okta.com/t/no-scim-protocol-json-message-on-authorization-error-response/32866 "2025-04-08T17:51:45Z")

</div>

I’ve implemented a .NET 8 SCIM server per your really great blog. Testing has gone very well except for one headache. If I test with a bad or no auth header the response is just the http status with no SCIM protocol JS…

---

## [Send email invite when creating "SOCIAL" user with the OKTA SDK](https://devforum.okta.com/t/send-email-invite-when-creating-social-user-with-the-okta-sdk/32605)

<div class="topic-metadata">

**Author:** [@Yassiel](https://devforum.okta.com/u/Yassiel)\
**Replies:** 1\
**Last updated:** [April 8, 2025, 9:23am UTC](https://devforum.okta.com/t/send-email-invite-when-creating-social-user-with-the-okta-sdk/32605 "2025-04-08T09:23:51Z")

</div>

We are in the process of migrating our flows to OKTA OIE and we are facing an issue while inviting new IDP users. We have an internal tool to invite users to the system. Currently, as part of the invite we are sending t…

---

## [Okta redirect throws 302 error after idle time](https://devforum.okta.com/t/okta-redirect-throws-302-error-after-idle-time/32722)

<div class="topic-metadata">

**Author:** [@jayanthy.kapistalam](https://devforum.okta.com/u/jayanthy.kapistalam)\
**Replies:** 1\
**Last updated:** [March 28, 2025, 6:04pm UTC](https://devforum.okta.com/t/okta-redirect-throws-302-error-after-idle-time/32722 "2025-03-28T18:04:23Z")

</div>

We have an application built using .NET Framework 4.8, NHibernate, MVC framework, and Okta.AspNet middleware. Users access the application by clicking on a dashboard chiclet. After 60 minutes of inactivity within the app…

---

## [Okta Asp.Net with Duende.IdentityModel](https://devforum.okta.com/t/okta-asp-net-with-duende-identitymodel/32345)

<div class="topic-metadata">

**Author:** [@jayanthy.kapistalam](https://devforum.okta.com/u/jayanthy.kapistalam)\
**Replies:** 1\
**Last updated:** [March 25, 2025, 1:45pm UTC](https://devforum.okta.com/t/okta-asp-net-with-duende-identitymodel/32345 "2025-03-25T13:45:13Z")

</div>

HI, I have an MVC web application using .net framework 4.8 and Okta authentication. I am using Okta.AspNet middleware, so IdentityModel is installed as part of Okta.AspNet Nuget package. Now that IdentityModel is deprec…

---

## [Net8.0 issue - ## InvalidOperationException: Cannot redirect to the authorization endpoint, the configuration may be missing or invalid](https://devforum.okta.com/t/net8-0-issue-invalidoperationexception-cannot-redirect-to-the-authorization-endpoint-the-configuration-may-be-missing-or-invalid/31848)

<div class="topic-metadata">

**Author:** [@Outlaw99](https://devforum.okta.com/u/Outlaw99)\
**Replies:** 1\
**Last updated:** [March 25, 2025, 1:11pm UTC](https://devforum.okta.com/t/net8-0-issue-invalidoperationexception-cannot-redirect-to-the-authorization-endpoint-the-configuration-may-be-missing-or-invalid/31848 "2025-03-25T13:11:46Z")

</div>

I had this all working before I upgraded everything to Net8.0 and now I am stumped. After I upgraded my webapp I also updated everything in Nuget and am on Okta.AspNetCore 4.6.2 and 9.0.4 of the Okta.SDK. Nothing changed…

---

## [How to redirect from Okta SSO Login page to the mobile app if they cancel/stop the Okta SSO Login in Xamarin](https://devforum.okta.com/t/how-to-redirect-from-okta-sso-login-page-to-the-mobile-app-if-they-cancel-stop-the-okta-sso-login-in-xamarin/32650)

<div class="topic-metadata">

**Author:** [@gian](https://devforum.okta.com/u/gian)\
**Replies:** 0\
**Last updated:** [March 19, 2025, 4:55pm UTC](https://devforum.okta.com/t/how-to-redirect-from-okta-sso-login-page-to-the-mobile-app-if-they-cancel-stop-the-okta-sso-login-in-xamarin/32650 "2025-03-19T16:55:32Z")

</div>

We have a Xamarin mobile app project and recently integrated the Okta SSO Login. I’m using WebAuthenticator.AuthenticateAsync(WebAuthenticatorOptions) method for accessing/navigating both Okta Login and Logout pages/pro…

---

## [Need Okta .Net SDK method to get Access Token, Refresh Token and Id Token using Authorization Code without Client Secret needed](https://devforum.okta.com/t/need-okta-net-sdk-method-to-get-access-token-refresh-token-and-id-token-using-authorization-code-without-client-secret-needed/32065)

<div class="topic-metadata">

**Author:** [@gian](https://devforum.okta.com/u/gian)\
**Replies:** 1\
**Last updated:** [March 19, 2025, 4:40pm UTC](https://devforum.okta.com/t/need-okta-net-sdk-method-to-get-access-token-refresh-token-and-id-token-using-authorization-code-without-client-secret-needed/32065 "2025-03-19T16:40:39Z")

</div>

I need Okta .Net SDK method to get Access Token, Refresh Token, and ID Token using Authorization Code without Client Secret. I’m looking for the same approach here: Implement authorization by grant type | Okta Developer.…

---

## [Can't get Okta Token from .NET HttpClient - Response 400](https://devforum.okta.com/t/cant-get-okta-token-from-net-httpclient-response-400/32583)

<div class="topic-metadata">

**Author:** [@miragejb](https://devforum.okta.com/u/miragejb)\
**Replies:** 4\
**Last updated:** [March 12, 2025, 11:33pm UTC](https://devforum.okta.com/t/cant-get-okta-token-from-net-httpclient-response-400/32583 "2025-03-12T23:33:40Z")

</div>

I need to be able to pass an Okta Token from a stand alone .NET Client (non-UI) to a REST API that is available. I have used the examples I have found in the forums to attempt to get a token. When I run it, I get an HT…

---

## [Adding PKCE to ASP.Net Web Forms application](https://devforum.okta.com/t/adding-pkce-to-asp-net-web-forms-application/32553)

<div class="topic-metadata">

**Author:** [@chajo10](https://devforum.okta.com/u/chajo10)\
**Replies:** 0\
**Last updated:** [March 10, 2025, 3:07pm UTC](https://devforum.okta.com/t/adding-pkce-to-asp-net-web-forms-application/32553 "2025-03-10T15:07:51Z")

</div>

Good day, I’m trying to research into integrating PKCE into an ASP.Net Web Forms application. We previously found OIDC examples and had a working version, but we were asked to switch off to PKCE. So far, I have found n…

---

## [Logout issue blazor](https://devforum.okta.com/t/logout-issue-blazor/32018)

<div class="topic-metadata">

**Author:** [@hsvasan](https://devforum.okta.com/u/hsvasan)\
**Replies:** 1\
**Last updated:** [February 21, 2025, 11:31pm UTC](https://devforum.okta.com/t/logout-issue-blazor/32018 "2025-02-21T23:31:52Z")

</div>

I have a blazor application and I have implemented the login and logout using openId connect. I was able to login and get authenticated. After authenticated, we are getting a link back like this http://{domain}/login/t…

---

## [How to authenticate and generate token native apps without login screen](https://devforum.okta.com/t/how-to-authenticate-and-generate-token-native-apps-without-login-screen/32049)

<div class="topic-metadata">

**Author:** [@ravikishore.p](https://devforum.okta.com/u/ravikishore.p)\
**Replies:** 1\
**Last updated:** [February 19, 2025, 5:08pm UTC](https://devforum.okta.com/t/how-to-authenticate-and-generate-token-native-apps-without-login-screen/32049 "2025-02-19T17:08:32Z")

</div>

Hi Team, I have a requirement for our .NET application where we have our DLL(assembly) which we are hosting in our intranet. This DLL will be used by several users within the company. For this requirement we are plannin…

---

## [Support to Microsoft.AspNet.Identity.Core 2.2.4](https://devforum.okta.com/t/support-to-microsoft-aspnet-identity-core-2-2-4/31909)

<div class="topic-metadata">

**Author:** [@mib](https://devforum.okta.com/u/mib)\
**Replies:** 0\
**Last updated:** [February 6, 2025, 8:32pm UTC](https://devforum.okta.com/t/support-to-microsoft-aspnet-identity-core-2-2-4/31909 "2025-02-06T20:32:27Z")

</div>

Does Okta support native integration with Microsoft.AspNet.Identity.Core 2.2.4?

---

## [How to connect OKTA Saml2.0 application with Aspnet Core 6.0 API?](https://devforum.okta.com/t/how-to-connect-okta-saml2-0-application-with-aspnet-core-6-0-api/31823)

<div class="topic-metadata">

**Author:** [@latop](https://devforum.okta.com/u/latop)\
**Replies:** 1\
**Last updated:** [February 3, 2025, 8:38am UTC](https://devforum.okta.com/t/how-to-connect-okta-saml2-0-application-with-aspnet-core-6-0-api/31823 "2025-02-03T08:38:13Z")

</div>

How to connect an OKTA Saml2.0 application to the AspNet Core 6.0 API? Hi, I would like to know the step-by-step instructions for authenticating the OKTA Saml 2.0 application configured by my client and our AspNet Core…

---

## [OIDC Okta Authentication is not working in .Net 4.8](https://devforum.okta.com/t/oidc-okta-authentication-is-not-working-in-net-4-8/31838)

<div class="topic-metadata">

**Author:** [@Subhathra](https://devforum.okta.com/u/Subhathra)\
**Replies:** 0\
**Last updated:** [January 30, 2025, 9:43am UTC](https://devforum.okta.com/t/oidc-okta-authentication-is-not-working-in-net-4-8/31838 "2025-01-30T09:43:12Z")

</div>

Hi @nate.callaghan, @nate.barbettini, I am new to OKTA, using .Net 4.8 to implement oidc okta. problem is that in startup.cs AuthorizationCodeReceived is not getting hit and hence unable to get the claims/userInfo to my…

---

## [Removing Profile Attribute Mapping via API](https://devforum.okta.com/t/removing-profile-attribute-mapping-via-api/31659)

<div class="topic-metadata">

**Author:** [@digitalelysium](https://devforum.okta.com/u/digitalelysium)\
**Replies:** 0\
**Last updated:** [January 14, 2025, 11:06am UTC](https://devforum.okta.com/t/removing-profile-attribute-mapping-via-api/31659 "2025-01-14T11:06:45Z")

</div>

I am using the API (.NET SDK) to automate the creation of Identity Providers. Everything works as expected with the exception of profile attribute mapping. I only want first name, last name, email and login to be mapped…

---

## [Okta Client WebAuthenticator Result Dialog Disappears if iPhone gets locked](https://devforum.okta.com/t/okta-client-webauthenticator-result-dialog-disappears-if-iphone-gets-locked/31555)

<div class="topic-metadata">

**Author:** [@Rajdeep108002](https://devforum.okta.com/u/Rajdeep108002)\
**Replies:** 0\
**Last updated:** [December 26, 2024, 7:43am UTC](https://devforum.okta.com/t/okta-client-webauthenticator-result-dialog-disappears-if-iphone-gets-locked/31555 "2024-12-26T07:43:20Z")

</div>

We have integrated the Okta Client using .NET MAUI with WebAuthenticator. When the Browser authenticates the Client and Shows the Dialog (Cancel / SignIn) or (Cancel / Logout). At this point if the iPhone gets locked the…

---

## [Close the current user session using OKTA SDK .Net API](https://devforum.okta.com/t/close-the-current-user-session-using-okta-sdk-net-api/31455)

<div class="topic-metadata">

**Author:** [@ssahabdeen](https://devforum.okta.com/u/ssahabdeen)\
**Replies:** 2\
**Last updated:** [December 23, 2024, 7:25pm UTC](https://devforum.okta.com/t/close-the-current-user-session-using-okta-sdk-net-api/31455 "2024-12-23T19:25:57Z")

</div>

Hi Team, Am using OKTA SDK .Net API for authenticating the user and verify MFA, I just can’t get the code for closing the user session. Below is the sample code that am using. (samples-aspnet/primary-auth/okta-aspnet-…

[Next page](https://devforum.okta.com/tag/dotnet/1.md?match_all_tags=true&page=1&tags%5B%5D=dotnet)
