Rayo::JWT
Constants
ALPHABET = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"
B64 = begin
t = StaticArray(Int8, 256).new(-1_i8)
"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".each_byte.each_with_index do |b, i| t[b] = i.to_i8 end
t
end
HEADER = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9"
Class methods
decode(src : Bytes, output : Bytes) : Int32
Decodes unpadded base64url. Returns the length, or -1.
encode(src : Bytes, output : Bytes) : Int32
Unpadded base64url. Both codecs require distinct input and output buffers.
encoded_size(n : Int32) : Int32
Source