Table of Contents

Class EntraWorkloadOptions

Namespace
NuvTools.Security.AspNetCore.Entra
Assembly
NuvTools.Security.AspNetCore.Entra.dll

Who may call as a workload: the Entra tenant that issues the tokens, the audience they must be issued for, and the applications allowed to present them.

public class EntraWorkloadOptions
Inheritance
EntraWorkloadOptions
Inherited Members

Remarks

Left incomplete, the scheme is still registered and refuses every caller. It is never silently skipped: an endpoint that admitted anybody because a setting was missing is the failure this scheme exists to prevent.

Properties

AllowedApplicationIds

The application (client) IDs allowed to call — typically managed identities' — matched against the token's appid (v1) or azp (v2).

public IList<string> AllowedApplicationIds { get; set; }

Property Value

IList<string>

Remarks

An allowlist rather than "any identity in the tenant": every app in the tenant can ask Entra for a token for any audience, so without it the check would be "is the caller anyone".

Audience

The audience the callers ask for — the receiving API's App ID URI, such as api://{tenantId}/my-api-uat — exactly as it appears in the token's aud.

public string Audience { get; set; }

Property Value

string

Remarks

Checked, and not merely the issuer: every workload in the tenant can obtain a token from the same issuer, so the issuer alone says nothing about who the token was meant for. A managed identity is issued a v1 token, whose aud is the URI it asked for, so the registration must stay on v1 tokens (the default).

IsConfigured

Whether enough is configured for the scheme to admit anybody at all.

public bool IsConfigured { get; }

Property Value

bool

TenantId

The Entra tenant the callers' tokens are issued by.

public string TenantId { get; set; }

Property Value

string