diff options
author | Jay Doane <jaydoane@apache.org> | 2022-01-12 08:46:16 -0800 |
---|---|---|
committer | Jay Doane <jay.s.doane@gmail.com> | 2022-01-12 12:27:07 -0800 |
commit | 7954acafa0ab8bc1b8738e66471ea999bcb89ccd (patch) | |
tree | 527a697003c4e55eeab0d5b80f68d260071f3dd7 /build-aux | |
parent | 6e8713d3be142ac8a55727aa097a1ba52d087702 (diff) | |
download | couchdb-7954acafa0ab8bc1b8738e66471ea999bcb89ccd.tar.gz |
Expose `decode/4` to skip decoding steps
Currently, `decode/3` performs various checks on a JWT, and then
base64 decodes and finally JSON decodes the token. However, in some
cases, it's desirable to skip the decoding steps, and just return the
token payload in binary form.
This exposes `decode/4` where the 4th argument is a decoder fun that
defaults to `decode_b64url_json/1` for `decode/3` to retain existing
behavior, but also exposes `decode_passthrough/1` in case a client
wants to avoid any decoding steps.
Diffstat (limited to 'build-aux')
0 files changed, 0 insertions, 0 deletions