cosmostail/x-jwt

Inspired by JWT protocol, X-JWT is designed to use AWS KMS to securly encrypt and decrypt data.

dev-master 2017-08-14 03:42 UTC

This package is auto-updated.

Last update: 2024-04-12 05:22:56 UTC


README

Models

//Headers will be saved as plain text
{
    alg: string, //the encrpt algorithm, required
    iss: string, //the issuer
    aud: string, //the audience, optional
    iv: string, //the tnitialization vector
    iat: int, //issue time
    exp: int, //# of seconds after the token expired,
    key: string, //data key generated by aws kms
}

//Payload will be save as encrpted data. You CAN save more than 4k of data.
{
    //Your data
}

//Signiture