Creates a new header for this object. The string for header
is copied internally, so do not require that the pointer or string
remain valid for the lifetime of this object. It is an error if you
try to add a header that already exists.
@param jwt Pointer to a JWT object.
@param header String containing the name of the header to add.
@param val boolean containing the value to be saved for header.
@return Returns 0 on success, valid errno otherwise.
Note, this only allows for boolean based headers. If you wish to add
string headers, then use jwt_add_header(). If you wish to add more
complex headers (e.g. an array), then use jwt_add_headers_json().
Add a new boolean header to this JWT object.
Creates a new header for this object. The string for header is copied internally, so do not require that the pointer or string remain valid for the lifetime of this object. It is an error if you try to add a header that already exists.
@param jwt Pointer to a JWT object. @param header String containing the name of the header to add. @param val boolean containing the value to be saved for header. @return Returns 0 on success, valid errno otherwise.
Note, this only allows for boolean based headers. If you wish to add string headers, then use jwt_add_header(). If you wish to add more complex headers (e.g. an array), then use jwt_add_headers_json().