public AuthConfiguration(KeyAuthenticationMode mode)
        {
            KeyAuthenticationMode = mode;

            if (mode == KeyAuthenticationMode.TemporaryKey)
            {
                TemporaryJwtKey = GeneratedJwtKey.Create();
            }
        }
Exemple #2
0
 public AuthOptions(KeyAuthenticationMode mode)
 {
     KeyAuthenticationMode = mode;
 }
Exemple #3
0
        public static AuthConfiguration CreateAuthConfiguration(bool noAuth, bool tempApiKey)
        {
            KeyAuthenticationMode authMode = noAuth ? KeyAuthenticationMode.NoAuth : tempApiKey ? KeyAuthenticationMode.TemporaryKey : KeyAuthenticationMode.StoredKey;

            return(new AuthConfiguration(authMode));
        }