Skip to content

OfflineAccess Enum

Whether a client may receive offline access, the refresh tokens the offline_access scope asks for, and whether its authorization request has to ask for consent with prompt=consent to receive it.

C#
public enum OfflineAccess

Fields

Disabled 0

The client receives no offline access: it is refused where the request would otherwise receive it, and is issued no refresh token, nor renews the ones it holds.

ConsentRequired 1

The client receives offline access from an authorization request that asks for consent with prompt=consent; a request that does not has its offline_access scope ignored.

Allowed 2

The client receives offline access without asking for consent with prompt=consent. It is host-side configuration only: a client registering itself receives it only where the host grants it to new clients (OfflineAccess), or keeps it on an RFC 7592 update once the host has given it.

Remarks

OpenID Connect Core 1.0, section 11, requires prompt=consent for offline access "unless other conditions for processing the request permitting offline access to the requested resources are in place", and Allowed is where the host states such conditions for a client. Either way, consent to offline access is the end user's, as the host's consent provider reports it.

On the wire it is the offline_access client registration parameter, a server extension to RFC 7591 metadata, which names each value as its member's System.Text.Json.Serialization.JsonStringEnumMemberNameAttribute says.