diff options
author | Alex Auvolat <alex@adnab.me> | 2022-01-04 18:59:17 +0100 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2022-01-04 18:59:17 +0100 |
commit | 677ab60cc117677bf53dc4887a6ff1c094e17cd0 (patch) | |
tree | deed8c5e3a0e22fa0d1d987d4ca1313fd5c54fb7 /src/api/signature.rs | |
parent | df35feba18787cac06b2a87e3426752fb78da2d5 (diff) | |
download | garage-677ab60cc117677bf53dc4887a6ff1c094e17cd0.tar.gz garage-677ab60cc117677bf53dc4887a6ff1c094e17cd0.zip |
Small changes in key model and refactoringnew-buckets
Diffstat (limited to 'src/api/signature.rs')
-rw-r--r-- | src/api/signature.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/api/signature.rs b/src/api/signature.rs index b5da7b62..c580cb3a 100644 --- a/src/api/signature.rs +++ b/src/api/signature.rs @@ -66,6 +66,7 @@ pub async fn check_signature( .await? .filter(|k| !k.state.is_deleted()) .ok_or_else(|| Error::Forbidden(format!("No such key: {}", authorization.key_id)))?; + let key_p = key.params().unwrap(); let canonical_request = canonical_request( request.method(), @@ -79,7 +80,7 @@ pub async fn check_signature( let mut hmac = signing_hmac( &date, - &key.secret_key, + &key_p.secret_key, &garage.config.s3_api.s3_region, "s3", ) |