@clarketm/jwt-utils

Command line utilities for working with JSON Web Tokens (JWT)

This package has been renamed to "@clarketm/jwt-cli"
Last updated 2 years ago by clarketm .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @clarketm/jwt-utils 
SYNC missed versions from official npm registry.

jwt-utils

NPM release Build Status License

Command line utilities for working with JSON Web Tokens (JWT).



Installation

Yarn

yarn global add "@clarketm/jwt-utils"

Npm

npm install --global "@clarketm/jwt-utils"

Demo

usage demo

Usage

sign [options] payload secret

$ jwt sign '{"user": "Travis Clarke"}' "super secret"
copied to clipboard:

eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhIjoxLCJpYXQiOjE1MjczMTI3NTIsImV4cCI6MTUyNzMxNjM1Mn0.2l4wyaoxNBBY7nvm6sAqAcmXSuuKjBubNo_h42hcigU

Note: the sign subcommand accepts all the same options as auth0/node-jsonwebtoken with the exception of mutatePayload which is not applicable.

verify [options] token secret

$ jwt verify "eyJhbGciOiJIUzI1..." "super secret"
valid!

Note: the verify subcommand accepts all the same options as auth0/node-jsonwebtoken

decode [options] token

$ jwt decode "eyJhbGciOiJIUzI1..."
copied to clipboard:

a:   1
iat: 1527312832
exp: 1527316432

Note: the decode subcommand accepts all the same options as auth0/node-jsonwebtoken with the exception of json which is not applicable.

Related

License

MIT © Travis Clarke

Current Tags

  • 1.0.0                                ...           latest (2 years ago)

4 Versions

  • 1.0.0 [deprecated]           ...           2 years ago
  • 0.0.3 [deprecated]           ...           2 years ago
  • 0.0.2 [deprecated]           ...           2 years ago
  • 0.0.1 [deprecated]           ...           2 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 4
Last Day 0
Last Week 4
Last Month 2
Dependencies (4)
Dev Dependencies (8)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |