MCPcopy Create free account
hub / github.com/clockworklabs/SpacetimeDB / default_auth_environment

Function default_auth_environment

crates/client-api/src/auth.rs:245–248  ·  view source on GitHub ↗

Create a new AuthEnvironment using the default caching validator.

(keys: JwtKeys, local_issuer: Box<str>)

Source from the content-addressed store, hash-verified

243
244// Create a new AuthEnvironment using the default caching validator.
245pub fn default_auth_environment(keys: JwtKeys, local_issuer: Box<str>) -> JwtKeyAuthProvider<DefaultValidator> {
246 let validator = new_validator(keys.public.clone(), local_issuer.clone());
247 JwtKeyAuthProvider::new(keys, local_issuer, validator)
248}
249
250impl<TV: TokenValidator + Send + Sync> JwtKeyAuthProvider<TV> {
251 fn new(keys: JwtKeys, local_issuer: Box<str>, validator: TV) -> Self {

Callers 1

initMethod · 0.85

Calls 3

new_validatorFunction · 0.85
newFunction · 0.50
cloneMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…