diff options
author | Matthew Wild <mwild1@gmail.com> | 2022-07-02 14:59:52 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2022-07-02 14:59:52 +0100 |
commit | 5316b0005e042f1abeb1ac5fed8715ab65e6752c (patch) | |
tree | 94390f94f83e8cb8b05cebd1eda304a8b3a63ca6 /util/jwt.lua | |
parent | 74351799e9428ac7088900aab1afd6827e96eef6 (diff) | |
download | prosody-5316b0005e042f1abeb1ac5fed8715ab65e6752c.tar.gz prosody-5316b0005e042f1abeb1ac5fed8715ab65e6752c.zip |
util.crypto: More digests for sign/verify, use macros for clarity/consistency
Diffstat (limited to 'util/jwt.lua')
-rw-r--r-- | util/jwt.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/util/jwt.lua b/util/jwt.lua index 433a69f6..7a05e45d 100644 --- a/util/jwt.lua +++ b/util/jwt.lua @@ -142,8 +142,8 @@ end local algorithms = { HS256 = new_hmac_algorithm("HS256", hashes.hmac_sha256); ES256 = new_ecdsa_algorithm("ES256", crypto.ecdsa_sha256_sign, crypto.ecdsa_sha256_verify); - RS256 = new_rsa_algorithm("RS256", crypto.rsassa_pkcs1_256_sign, crypto.rsassa_pkcs1_256_verify); - PS256 = new_rsa_algorithm("PS256", crypto.rsassa_pss_256_sign, crypto.rsassa_pss_256_verify); + RS256 = new_rsa_algorithm("RS256", crypto.rsassa_pkcs1_sha256_sign, crypto.rsassa_pkcs1_sha256_verify); + PS256 = new_rsa_algorithm("PS256", crypto.rsassa_pss_sha256_sign, crypto.rsassa_pss_sha256_verify); }; local function new_signer(algorithm, key_input) |