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
valuestringThe secret value — for a shared secret, its hash.
expirationDateTime?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
valuestringThe secret value — for a shared secret, its hash.
descriptionstringA human-readable description, or null.
expirationDateTime?When the secret stops being accepted, or null for never.
Properties
Description
Optional human-readable description.
public string? Description { get; set; }
Property Value
Expiration
Optional expiration.
public DateTime? Expiration { get; set; }
Property Value
Type
The secret type. Defaults to a shared secret.
public string Type { get; set; }
Property Value
Value
The secret value. For shared secrets this is expected to be hashed at rest.
public string Value { get; set; }