-
Notifications
You must be signed in to change notification settings - Fork 60
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot use "sha384": No such hash algorithm #3
Comments
I'm not sure why you have 'basic_auth.hmac', it should just be 'hmac' unless you installed pgcypto into the same schema, I presume you did something like that since the function is being called. @esmeetu try this:
You should get: \x0edb7068ecbf4de2c47b8819fd534333379f208f989c51018d03ee1155e4c0740a418ec220d4260eabcb2d090b16de6e If not, then it sounds like your pgcypto is not correctly installed. |
Thanks for your reply! |
Are you reinstall pgcrypto by a os package like apt or rpm or did you build it from source? If you built it you might be missing some libraries. After you reinstalled did you restart postgres? 'hmac' comes from pycrypto, so I'm not really an expert in building it, I installed it from an ubuntu package. |
I use datagrip, enter this |
@michelp I find the reason, It my fault thati forget that i updated my postgresql today. |
when i run:
select basic_auth.sign('{"sub":"1234567890","name":"John Doe","admin":true}', 'secret', 'HS384')
output this:
other hash algorithms are same.
This is my
algorithm_sign
function:The text was updated successfully, but these errors were encountered: