JSON Web Signatures
{% capture private_key_pem = options.private_key_pem__required_code_multiline %}
{% assign claims = options.payload_json__code_multiline | parse_json | json | base64_url_safe_encode %}
{% assign header = '{"alg":"RS256","typ":"JWT"}' | base64_encode %}
{% assign input = header | append: "." | append: claims %}
{% assign signature = input | rsa_sha256: private_key_pem | base64_url_safe_encode %}
{% log header: header, claims: claims, input: input, signature: signature %}Last updated
Was this helpful?