chore(jwt authn): improve tests, add pool_size to schema
This commit is contained in:
parent
4adfe75530
commit
7301009b8e
|
@ -72,6 +72,7 @@ fields('jwks') ->
|
||||||
[
|
[
|
||||||
{use_jwks, sc(hoconsc:enum([true]), #{required => true, desc => ?DESC(use_jwks)})},
|
{use_jwks, sc(hoconsc:enum([true]), #{required => true, desc => ?DESC(use_jwks)})},
|
||||||
{endpoint, fun endpoint/1},
|
{endpoint, fun endpoint/1},
|
||||||
|
{pool_size, fun emqx_connector_schema_lib:pool_size/1},
|
||||||
{refresh_interval, fun refresh_interval/1},
|
{refresh_interval, fun refresh_interval/1},
|
||||||
{ssl, #{
|
{ssl, #{
|
||||||
type => hoconsc:union([
|
type => hoconsc:union([
|
||||||
|
|
|
@ -61,7 +61,7 @@ t_jwt_authenticator_hmac_based(_) ->
|
||||||
algorithm => 'hmac-based',
|
algorithm => 'hmac-based',
|
||||||
secret => Secret,
|
secret => Secret,
|
||||||
secret_base64_encoded => false,
|
secret_base64_encoded => false,
|
||||||
verify_claims => []
|
verify_claims => [{<<"username">>, <<"${username}">>}]
|
||||||
},
|
},
|
||||||
{ok, State} = emqx_authn_jwt:create(?AUTHN_ID, Config),
|
{ok, State} = emqx_authn_jwt:create(?AUTHN_ID, Config),
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue