Table of Contents

Class Secret

Namespace
Fdyay.IdentityServer.Models
Assembly
Fdyay.IdentityServer.Core.dll

A shared secret, X.509 thumbprint, or JWK used to authenticate a client or API.

public class Secret
Inheritance
Secret
Inherited Members

Constructors

Secret()

An empty secret, for an initializer or a configuration binder to fill. A shared secret unless Type says otherwise.

public Secret()

Secret(string, DateTime?)

A shared secret with no description.

public Secret(string value, DateTime? expiration = null)

Parameters

value string

The secret value — for a shared secret, its hash.

expiration DateTime?

When the secret stops being accepted, or null for never.

Secret(string, string?, DateTime?)

A shared secret with a description.

public Secret(string value, string? description, DateTime? expiration = null)

Parameters

value string

The secret value — for a shared secret, its hash.

description string

A human-readable description, or null.

expiration DateTime?

When the secret stops being accepted, or null for never.

Properties

Description

Optional human-readable description.

public string? Description { get; set; }

Property Value

string

Expiration

Optional expiration.

public DateTime? Expiration { get; set; }

Property Value

DateTime?

Type

The secret type. Defaults to a shared secret.

public string Type { get; set; }

Property Value

string

Value

The secret value. For shared secrets this is expected to be hashed at rest.

public string Value { get; set; }

Property Value

string