Skip to content

Conversation

@guardrex
Copy link
Collaborator

@guardrex guardrex commented May 20, 2025

@guardrex guardrex self-assigned this May 20, 2025
@guardrex guardrex changed the title Recommend distributed caches In-memory/production distributed caches May 20, 2025
@guardrex guardrex requested a review from halter73 May 20, 2025 14:38
Copy link
Member

@halter73 halter73 left a comment

Choose a reason for hiding this comment

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

Should we also show setting MsalDistributedTokenCacheAdapterOptions.Encrypt = true so the access tokens are data protected at rest? Of course, then we have to link to content about managing data protection keys. But if we're already asking you to manage a distributed cache, that feels like a similar level of complexity.

@blowdart @GrabYourPitchforks

@guardrex
Copy link
Collaborator Author

The PR is updated with ...

  • The MSAL token cache options (encrypt, sliding period, etc.).
  • Shared DP key ring with Azure Blob Storage and Key Vault as the example.
  • Remarks on how to just use an in-memory provider and unencrypted tokens during early development and testing.

The companion PR that updates the sample apps is also ready at dotnet/blazor-samples#544.

@guardrex guardrex merged commit 48911cf into main May 27, 2025
3 checks passed
@guardrex guardrex deleted the guardrex/ms-id-web-token-caches branch May 27, 2025 23:18
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.

Use in-memory distributed caching and recommend a production provider

2 participants