Skip to content

Opaque (reference) access token guidance#36588

Open
guardrex wants to merge 14 commits into
mainfrom
guardrex/blazor-oidc-opaque-access-tokens
Open

Opaque (reference) access token guidance#36588
guardrex wants to merge 14 commits into
mainfrom
guardrex/blazor-oidc-opaque-access-tokens

Conversation

@guardrex
Copy link
Copy Markdown
Collaborator

@guardrex guardrex commented Jan 7, 2026

Fixes #36422

cc: @mikekistler

Stephen ... I hacked some nasty 🦖 code 🙈😆 with the help of AI to give you an idea of what I have in mind for the bits that call the auth server to validate the token.

Apparently, Entra doesn't support opaque access token validation, per this MS answer as of 2023 and a local test that I just ran here with Entra.

I originally had this in the BWA-OIDC article, but it's more general than that, so I just moved it to the additional scenarios article and cross-linked to it there from a few spots.


Internal previews

📄 File 🔗 Preview link
aspnetcore/blazor/security/additional-scenarios.md aspnetcore/blazor/security/additional-scenarios
aspnetcore/blazor/security/blazor-web-app-with-entra.md aspnetcore/blazor/security/blazor-web-app-with-entra
aspnetcore/blazor/security/blazor-web-app-with-oidc.md aspnetcore/blazor/security/blazor-web-app-with-oidc
aspnetcore/blazor/security/index.md aspnetcore/blazor/security/index

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds comprehensive guidance for handling opaque (reference) access tokens in ASP.NET Core Blazor Web Apps with OIDC authentication, addressing issue #36422. The documentation explains when opaque tokens are supported by default and provides a starting-point implementation for scenarios requiring custom token validation.

Key Changes

  • Explains that AddOpenIdConnect inherently supports opaque tokens for basic authentication scenarios without additional configuration
  • Documents the limitation when opaque tokens need to be validated by services using AddJwtBearer
  • Provides a custom AuthenticationHandler implementation as a starting point for developers who need to validate opaque tokens via introspection endpoints

Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
@guardrex guardrex requested a review from halter73 January 7, 2026 14:33
@guardrex

This comment was marked as outdated.

@guardrex

This comment was marked as outdated.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 6 comments.

Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
Comment thread aspnetcore/blazor/security/blazor-web-app-with-oidc.md Outdated
guardrex and others added 13 commits May 19, 2026 09:12
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Luke Latham <1622880+guardrex@users.noreply.github.com>
@guardrex guardrex force-pushed the guardrex/blazor-oidc-opaque-access-tokens branch from b071c5a to 8b16fd9 Compare May 19, 2026 13:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

OIDC Solution Doesn't Work With Opaque Access Tokens

2 participants