mirror of
https://github.com/TECHNOFAB11/jwt-authorizer.git
synced 2025-12-12 08:00:07 +01:00
feat: refresh configuration
This commit is contained in:
parent
7b6f8fb4c5
commit
1203163b0c
9 changed files with 189 additions and 58 deletions
|
|
@ -29,13 +29,6 @@ pub struct Keys {
|
|||
}
|
||||
|
||||
impl Keys {
|
||||
fn new(secret: &[u8]) -> Self {
|
||||
Self {
|
||||
alg: Algorithm::HS256,
|
||||
encoding: EncodingKey::from_secret(secret),
|
||||
decoding: DecodingKey::from_secret(secret),
|
||||
}
|
||||
}
|
||||
fn load_rsa() -> Self {
|
||||
Self {
|
||||
alg: Algorithm::RS256,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue