Show / Hide Table of Contents

Class OpenIddictServerDataProtectionBuilder

Exposes the necessary methods required to configure the OpenIddict ASP.NET Core Data Protection integration.

Inheritance
System.Object
OpenIddictServerDataProtectionBuilder
Inherited Members
System.Object.Equals(System.Object, System.Object)
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: Microsoft.Extensions.DependencyInjection
Assembly: cs.temp.dll.dll
Syntax
public class OpenIddictServerDataProtectionBuilder

Constructors

OpenIddictServerDataProtectionBuilder(IServiceCollection)

Initializes a new instance of OpenIddictServerDataProtectionBuilder.

Declaration
public OpenIddictServerDataProtectionBuilder(IServiceCollection services)
Parameters
Type Name Description
IServiceCollection services

The services collection.

Properties

Services

Gets the services collection.

Declaration
public IServiceCollection Services { get; }
Property Value
Type Description
IServiceCollection

Methods

Configure(Action<OpenIddictServerDataProtectionOptions>)

Amends the default OpenIddict server ASP.NET Core Data Protection configuration.

Declaration
public OpenIddictServerDataProtectionBuilder Configure(Action<OpenIddictServerDataProtectionOptions> configuration)
Parameters
Type Name Description
System.Action<OpenIddictServerDataProtectionOptions> configuration

The delegate used to configure the OpenIddict options.

Returns
Type Description
OpenIddictServerDataProtectionBuilder

The OpenIddictServerDataProtectionBuilder.

Remarks

This extension can be safely called multiple times.

Equals(Object)

Declaration
public override bool Equals(object obj)
Parameters
Type Name Description
System.Object obj
Returns
Type Description
System.Boolean
Overrides
System.Object.Equals(System.Object)

GetHashCode()

Declaration
public override int GetHashCode()
Returns
Type Description
System.Int32
Overrides
System.Object.GetHashCode()

PreferDefaultAccessTokenFormat()

Configures OpenIddict to use the default token format (JWT) when issuing new access tokens.

Declaration
public OpenIddictServerDataProtectionBuilder PreferDefaultAccessTokenFormat()
Returns
Type Description
OpenIddictServerDataProtectionBuilder

The OpenIddictServerDataProtectionBuilder.

PreferDefaultAuthorizationCodeFormat()

Configures OpenIddict to use the default token format (JWT) when issuing new authorization codes.

Declaration
public OpenIddictServerDataProtectionBuilder PreferDefaultAuthorizationCodeFormat()
Returns
Type Description
OpenIddictServerDataProtectionBuilder

The OpenIddictServerDataProtectionBuilder.

PreferDefaultDeviceCodeFormat()

Configures OpenIddict to use the default token format (JWT) when issuing new device codes.

Declaration
public OpenIddictServerDataProtectionBuilder PreferDefaultDeviceCodeFormat()
Returns
Type Description
OpenIddictServerDataProtectionBuilder

The OpenIddictServerDataProtectionBuilder.

PreferDefaultRefreshTokenFormat()

Configures OpenIddict to use the default token format (JWT) when issuing new refresh tokens.

Declaration
public OpenIddictServerDataProtectionBuilder PreferDefaultRefreshTokenFormat()
Returns
Type Description
OpenIddictServerDataProtectionBuilder

The OpenIddictServerDataProtectionBuilder.

PreferDefaultUserCodeFormat()

Configures OpenIddict to use the default token format (JWT) when issuing new user codes.

Declaration
public OpenIddictServerDataProtectionBuilder PreferDefaultUserCodeFormat()
Returns
Type Description
OpenIddictServerDataProtectionBuilder

The OpenIddictServerDataProtectionBuilder.

ToString()

Declaration
public override string ToString()
Returns
Type Description
System.String
Overrides
System.Object.ToString()

UseDataProtectionProvider(IDataProtectionProvider)

Configures OpenIddict to use a specific data protection provider instead of relying on the default instance provided by the DI container.

Declaration
public OpenIddictServerDataProtectionBuilder UseDataProtectionProvider(IDataProtectionProvider provider)
Parameters
Type Name Description
IDataProtectionProvider provider

The data protection provider used to create token protectors.

Returns
Type Description
OpenIddictServerDataProtectionBuilder

The OpenIddictServerDataProtectionBuilder.

UseFormatter(IOpenIddictServerDataProtectionFormatter)

Configures OpenIddict to use a specific formatter instead of relying on the default instance.

Declaration
public OpenIddictServerDataProtectionBuilder UseFormatter(IOpenIddictServerDataProtectionFormatter formatter)
Parameters
Type Name Description
IOpenIddictServerDataProtectionFormatter formatter

The formatter used to read and write tokens.

Returns
Type Description
OpenIddictServerDataProtectionBuilder

The OpenIddictServerDataProtectionBuilder.

In This Article
Back to top Generated by DocFX