Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RandomBytes ¶ added in v0.4.0
RandomBytes returns n random bytes by reading from crypto/rand.Reader
Types ¶
type HMACStrategy ¶
type HMACStrategy struct { sync.Mutex Config HMACStrategyConfigurator }
HMACStrategy is responsible for generating and validating challenges.
func (*HMACStrategy) Generate ¶
Generate generates a token and a matching signature or returns an error. This method implements rfc6819 Section 5.1.4.2.2: Use High Entropy for Secrets.
func (*HMACStrategy) Signature ¶
func (*HMACStrategy) Signature(token string) string
type HMACStrategyConfigurator ¶ added in v0.43.0
type HMACStrategyConfigurator interface { fosite.TokenEntropyProvider fosite.GlobalSecretProvider fosite.RotatedGlobalSecretsProvider fosite.HMACHashingProvider }
Click to show internal directories.
Click to hide internal directories.