session/hmac
src/session/hmac.tur
HMAC-SHA256 over the session ID for signed cookies.
Since: v0.2.0
defn
hmac-sign
(hmac-sign [key : cstr msg : cstr] :)
base64url(HMAC-SHA256(key, msg)).
Parameters
| key | signing key bytes (as a string) | |
| msg | message to authenticate (the session ID) |
Returns
:cstr -- base64url MAC, caller-owned.
Since: v0.2.0
defn
ct-eq?
(ct-eq? [a : cstr b : cstr] :)
constant-time string equality.
Since: v0.2.0