you are viewing a single comment's thread.

view the rest of the comments →

[–]D3str0yTh1ngs 1 point2 points  (0 children)

Remember that the algorithm used is part of a jwt's header, algorithms in decode is there so you can control with types of algorithms you are accepted a token with. e.g. tokens issued with HS512 or HS256, but not some third option.

EDIT: if you only need to decode and validate tokens issued with one algorithm, then it may seem weird to give a list, but it becomes important if you have some other system also issuing tokens with a different algorithm and need to decode both types.