I'm currently reading up on JWTs and have written something to create them. When I created my JWT I noticed that my signature was not being encoded properly.
For instance, given the hash
My code produces
What I'm expecting to get is
Why are encoded hashes so different and what am I missing?