Skip to content

SharedSignalsEndpointOptions Class

What the endpoint adapter leaves to the host: how an authenticated request maps to the receiver identity every management operation is scoped by. Authentication itself stays with the host's middleware - SSF 1.0 Section 7.1.1 deliberately leaves the scheme open.

C#
public sealed record SharedSignalsEndpointOptions : System.IEquatable<Abblix.SharedSignals.MinimalApi.SharedSignalsEndpointOptions>

Inheritance System.Object → SharedSignalsEndpointOptions

Implements System.IEquatable<SharedSignalsEndpointOptions>

Properties

SharedSignalsEndpointOptions.AdvertisedPrefix Property

The management prefix the configuration document advertises, as the outside world reaches it; unset advertises ManagementPrefix. Set it when a proxy in front rewrites paths, so the document names the external addresses while the routes stay mapped on the internal ones.

C#
public Microsoft.AspNetCore.Http.PathString AdvertisedPrefix { get; init; }

Property Value

Microsoft.AspNetCore.Http.PathString

SharedSignalsEndpointOptions.ConfigurationDocumentRoute Property

The route the configuration document is served on; unset takes the canonical well-known address derived from the issuer (SSF 1.0 Section 7.2). A set value is deployment plumbing for a rewriting proxy that maps the canonical address onto an internal route - the EXTERNAL address never moves, because receivers derive it from the issuer.

C#
public Microsoft.AspNetCore.Http.PathString ConfigurationDocumentRoute { get; init; }

Property Value

Microsoft.AspNetCore.Http.PathString

SharedSignalsEndpointOptions.GrantedScopesSelector Property

Reads the scopes the caller's access token was granted. Null - the default - checks no scope at all, which is what this surface did before the option existed.

C#
public System.Func<Microsoft.AspNetCore.Http.HttpContext,System.Collections.Generic.IReadOnlyCollection<string>>? GrantedScopesSelector { get; init; }

Property Value

System.Func<Microsoft.AspNetCore.Http.HttpContext,System.Collections.Generic.IReadOnlyCollection<System.String>>

Remarks

The CAEP Interoperability Profile Section 2.7.2 requires a transmitter to "verify that the authorization represented by the access token is sufficient for the requested resource access", and Section 2.7.3 says what sufficient means: ssf.read for reading, ssf.manage for changing. This library can apply that split per route, but it cannot find the scopes on its own - where they live depends on how the host authenticates, and this package never sees a token.

Set it and every route enforces its own requirement. Leave it null and none do, which keeps a deployment that authorizes some other way working exactly as before - and outside the profile, deliberately, rather than by omission.

A common wiring reads the scope claim: ctx => ctx.User.FindFirst("scope")?.Value.Split(' ') ?? [].

SharedSignalsEndpointOptions.ManagementPrefix Property

The route prefix the management surface is mapped under. Behind a rewriting proxy this is the INTERNAL prefix; what the configuration document advertises is AdvertisedPrefix.

C#
public Microsoft.AspNetCore.Http.PathString ManagementPrefix { get; init; }

Property Value

Microsoft.AspNetCore.Http.PathString

SharedSignalsEndpointOptions.MapWellKnownConfiguration Property

Whether MapSharedSignalsTransmitterEndpoints(this IEndpointRouteBuilder) maps the configuration document at the canonical well-known address. True by default; false is for a host whose gateway or CDN answers that address itself. The address is fixed by SSF 1.0 Section 7.2 and receivers derive it from the issuer, so this flag only suppresses the route, never moves it - a host that must serve the document on another internal path pairs it with ConfigurationDocumentRoute and MapSharedSignalsConfigurationDocument(this IEndpointRouteBuilder).

C#
public bool MapWellKnownConfiguration { get; init; }

Property Value

System.Boolean

SharedSignalsEndpointOptions.ReceiverIdSelector Property

Extracts the receiver identity from the authenticated request; null answers the request with 401. The default reads the "sub" claim and falls back to the identity name - the two places the common authentication handlers put a caller's identifier.

C#
public System.Func<Microsoft.AspNetCore.Http.HttpContext,string?> ReceiverIdSelector { get; init; }

Property Value

System.Func<Microsoft.AspNetCore.Http.HttpContext,System.String>