Lti_1p3.Nonces (Lti 1p3 v0.6.0)

Link to this section Summary

Functions

Removes all nonces older than the configured @max_nonce_ttl_sec value

Creates a nonce. Returns a error if the nonce already exists

Gets a single nonce. Returns nil if the Nonce does not exist.

Link to this section Functions

Link to this function

cleanup_nonce_store()

Removes all nonces older than the configured @max_nonce_ttl_sec value

Link to this function

create_nonce(value, domain \\ nil)

Creates a nonce. Returns a error if the nonce already exists

examples

Examples

iex> create_nonce("value", "domain")
{:ok, %Nonce{}}
iex> create_nonce("value", "domain")
{:error, %Lti_1p3.DataProviderError{}}

Gets a single nonce. Returns nil if the Nonce does not exist.

examples

Examples

iex> get_nonce(123)
%Nonce{}
iex> get_nonce(456)
nil