{"_id":"passport-jwt","_rev":"4081811","name":"passport-jwt","description":"Passport authentication strategy using JSON Web Tokens","dist-tags":{"latest":"4.0.1"},"maintainers":[{"name":"themikenicholson","email":""}],"time":{"modified":"2025-11-24T21:38:18.000Z","created":"2014-11-12T03:16:36.887Z","4.0.1":"2022-12-24T05:25:24.598Z","4.0.0":"2018-03-13T02:57:13.071Z","3.0.1":"2017-10-27T01:41:42.942Z","3.0.0":"2017-08-16T03:30:54.612Z","2.2.1":"2016-11-10T03:27:16.695Z","2.2.0":"2016-10-31T03:19:18.230Z","2.1.1":"2016-10-31T03:15:26.708Z","2.1.0":"2016-06-21T04:49:24.012Z","2.0.0":"2016-02-11T05:17:55.753Z","1.2.1":"2015-09-17T01:28:41.274Z","1.1.1":"2015-08-20T04:34:53.889Z","1.1.0":"2015-04-24T03:17:54.370Z","1.0.1":"2015-04-08T03:26:32.059Z","1.0.0":"2015-03-03T04:31:13.190Z","0.1.1":"2015-03-03T03:44:38.256Z","0.1.0":"2014-11-12T03:16:36.887Z"},"users":{},"author":{"name":"Mike Nicholson"},"repository":{"type":"git","url":"git+https://github.com/mikenicholson/passport-jwt.git"},"versions":{"4.0.1":{"name":"passport-jwt","version":"4.0.1","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js","testcov":"nyc npm run test"},"repository":{"type":"git","url":"git+https://github.com/mikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/mikenicholson/passport-jwt/issues"},"homepage":"https://github.com/mikenicholson/passport-jwt","devDependencies":{"chai":"^3.0.0","chai-passport-strategy":"^1.0.0","mocha":"^9.2.1","nyc":"^15.1.0","sinon":"^1.0.0"},"dependencies":{"jsonwebtoken":"^9.0.0","passport-strategy":"^1.0.0"},"gitHead":"fed94fa005c5b2dcb7e6d5d5372e3b20cae898f1","_id":"passport-jwt@4.0.1","_nodeVersion":"19.2.0","_npmVersion":"8.19.3","dist":{"shasum":"c443795eff322c38d173faa0a3c481479646ec3d","size":11937,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-4.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-4.0.1.tgz"},"_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"directories":{},"maintainers":[{"name":"themikenicholson","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/passport-jwt_4.0.1_1671859524407_0.6977449494354406"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2022-12-24T05:25:28.434Z","publish_time":1671859524598,"_cnpm_publish_time":1671859524598},"4.0.0":{"name":"passport-jwt","version":"4.0.0","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js","testcov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"git+https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^3.0.0","chai-passport-strategy":"^1.0.0","istanbul":"^0.4.5","mocha":"^3.0.0","sinon":"^1.0.0"},"dependencies":{"jsonwebtoken":"^8.2.0","passport-strategy":"^1.0.0"},"gitHead":"8f543a96f70c8356a13003c2c433b30a62f53a2b","_id":"passport-jwt@4.0.0","_npmVersion":"5.6.0","_nodeVersion":"9.3.0","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"dist":{"shasum":"7f0be7ba942e28b9f5d22c2ebbb8ce96ef7cf065","size":11790,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-4.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-4.0.0.tgz"},"maintainers":[{"name":"themikenicholson","email":""}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/passport-jwt_4.0.0_1520909832992_0.47453212367612907"},"_hasShrinkwrap":false,"publish_time":1520909833071,"_cnpm_publish_time":1520909833071,"_cnpmcore_publish_time":"2021-12-16T12:25:00.834Z"},"3.0.1":{"name":"passport-jwt","version":"3.0.1","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js","testcov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"git+https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^3.0.0","chai-passport-strategy":"^1.0.0","istanbul":"^0.4.5","mocha":"^3.0.0","sinon":"^1.0.0"},"dependencies":{"jsonwebtoken":"^7.0.0","passport-strategy":"^1.0.0"},"gitHead":"6d4b3fafffecd24fa1a69dff2bb15063ba5994db","_id":"passport-jwt@3.0.1","_shasum":"e4f7276dad8bd251d43c6fc38883130b963272f6","_from":".","_npmVersion":"4.2.0","_nodeVersion":"7.9.0","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"dist":{"shasum":"e4f7276dad8bd251d43c6fc38883130b963272f6","size":12034,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-3.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-3.0.1.tgz"},"maintainers":[{"name":"themikenicholson","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/passport-jwt-3.0.1.tgz_1509068501941_0.057028161361813545"},"directories":{},"publish_time":1509068502942,"_hasShrinkwrap":false,"_cnpm_publish_time":1509068502942,"_cnpmcore_publish_time":"2021-12-16T12:25:01.096Z"},"3.0.0":{"name":"passport-jwt","version":"3.0.0","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js","testcov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"git+https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^3.0.0","chai-passport-strategy":"^1.0.0","istanbul":"^0.4.5","mocha":"^3.0.0","sinon":"^1.0.0"},"dependencies":{"jsonwebtoken":"^7.0.0","passport-strategy":"^1.0.0"},"gitHead":"28ffbb0f71a780aa8fe6946cab63068f9d503a5b","_id":"passport-jwt@3.0.0","_shasum":"7d9e4ff0fa0522108540ce1fcfa83bbd8faa29c9","_from":".","_npmVersion":"4.2.0","_nodeVersion":"7.9.0","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"dist":{"shasum":"7d9e4ff0fa0522108540ce1fcfa83bbd8faa29c9","size":11681,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-3.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-3.0.0.tgz"},"maintainers":[{"name":"themikenicholson","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/passport-jwt-3.0.0.tgz_1502854253444_0.4798286303412169"},"directories":{},"publish_time":1502854254612,"_hasShrinkwrap":false,"_cnpm_publish_time":1502854254612,"_cnpmcore_publish_time":"2021-12-16T12:25:01.501Z"},"2.2.1":{"name":"passport-jwt","version":"2.2.1","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js","testcov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"git+https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^3.0.0","chai-passport-strategy":"^1.0.0","istanbul":"^0.4.5","mocha":"^3.0.0","sinon":"^1.0.0"},"dependencies":{"jsonwebtoken":"^7.0.0","passport-strategy":"^1.0.0"},"gitHead":"6ff2a4a63ff6e3475fc0fb28207221e9ca4d3d48","_id":"passport-jwt@2.2.1","_shasum":"0e004c94071319d673d9d9bcfd1574a868011527","_from":".","_npmVersion":"3.10.7","_nodeVersion":"6.7.0","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"dist":{"shasum":"0e004c94071319d673d9d9bcfd1574a868011527","size":9855,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-2.2.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-2.2.1.tgz"},"maintainers":[{"name":"themikenicholson","email":""}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/passport-jwt-2.2.1.tgz_1478748434609_0.21114882663823664"},"directories":{},"publish_time":1478748436695,"_hasShrinkwrap":false,"_cnpm_publish_time":1478748436695,"_cnpmcore_publish_time":"2021-12-16T12:25:01.683Z"},"2.2.0":{"name":"passport-jwt","version":"2.2.0","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js","testcov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"git+https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^5.0.0","passport-strategy":"^1.0.0"},"gitHead":"9fd7f9761ec2917c72742ec526846b8d04d0cff3","_id":"passport-jwt@2.2.0","_shasum":"622ff1a5b72a6afceea190d7af7664c6c80128f3","_from":".","_npmVersion":"3.10.7","_nodeVersion":"6.7.0","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"dist":{"shasum":"622ff1a5b72a6afceea190d7af7664c6c80128f3","size":9859,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-2.2.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-2.2.0.tgz"},"maintainers":[{"name":"themikenicholson","email":""}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/passport-jwt-2.2.0.tgz_1477883956338_0.3572320204693824"},"directories":{},"publish_time":1477883958230,"_hasShrinkwrap":false,"_cnpm_publish_time":1477883958230,"_cnpmcore_publish_time":"2021-12-16T12:25:01.916Z"},"2.1.1":{"name":"passport-jwt","version":"2.1.1","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js","testcov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"git+https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^5.0.0","passport-strategy":"^1.0.0"},"gitHead":"7a09b64a5d5fcbde5d72b6ce5c9735c857033de9","_id":"passport-jwt@2.1.1","_shasum":"8fc7d481fdd6d326a7d44c32f0fc3128ee9bd585","_from":".","_npmVersion":"3.10.7","_nodeVersion":"6.7.0","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"dist":{"shasum":"8fc7d481fdd6d326a7d44c32f0fc3128ee9bd585","size":9862,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-2.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-2.1.1.tgz"},"maintainers":[{"name":"themikenicholson","email":""}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/passport-jwt-2.1.1.tgz_1477883724682_0.6705551852937788"},"directories":{},"publish_time":1477883726708,"_hasShrinkwrap":false,"_cnpm_publish_time":1477883726708,"_cnpmcore_publish_time":"2021-12-16T12:25:02.121Z"},"2.1.0":{"name":"passport-jwt","version":"2.1.0","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js","testcov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"git+https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^5.0.0","passport-strategy":"^1.0.0"},"gitHead":"269d5cad90a9938aa6059a4f9d209cf1515c877c","_id":"passport-jwt@2.1.0","_shasum":"d885d095747f5d9c0ab240dd9413e7381b8ce3ab","_from":".","_npmVersion":"3.3.12","_nodeVersion":"5.4.0","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"dist":{"shasum":"d885d095747f5d9c0ab240dd9413e7381b8ce3ab","size":9697,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-2.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-2.1.0.tgz"},"maintainers":[{"name":"themikenicholson","email":""}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/passport-jwt-2.1.0.tgz_1466484561608_0.18378752982243896"},"directories":{},"publish_time":1466484564012,"_hasShrinkwrap":false,"_cnpm_publish_time":1466484564012,"_cnpmcore_publish_time":"2021-12-16T12:25:02.388Z"},"2.0.0":{"name":"passport-jwt","version":"2.0.0","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js","testcov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"git+https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^5.0.0","passport-strategy":"^1.0.0"},"gitHead":"3c18b55d819f1d824cb544b7e46902a35b18e91d","_id":"passport-jwt@2.0.0","_shasum":"a38e92ddb0235c0e7c55bc5c9967c480b8798308","_from":".","_npmVersion":"3.3.12","_nodeVersion":"5.2.0","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"dist":{"shasum":"a38e92ddb0235c0e7c55bc5c9967c480b8798308","size":9387,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-2.0.0.tgz"},"maintainers":[{"name":"themikenicholson","email":""}],"_npmOperationalInternal":{"host":"packages-9-west.internal.npmjs.com","tmp":"tmp/passport-jwt-2.0.0.tgz_1455167872258_0.570173557382077"},"directories":{},"publish_time":1455167875753,"_hasShrinkwrap":false,"_cnpm_publish_time":1455167875753,"_cnpmcore_publish_time":"2021-12-16T12:25:02.654Z"},"1.2.1":{"name":"passport-jwt","version":"1.2.1","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^5.0.0","passport-strategy":"^1.0.0"},"gitHead":"c88c3a9f151110717a252ed54acefc259d539818","_id":"passport-jwt@1.2.1","_shasum":"b0ce01b22f0e165778ce0b066041d6cacd4bb40f","_from":".","_npmVersion":"2.7.5","_nodeVersion":"0.12.2","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"maintainers":[{"name":"themikenicholson","email":""}],"dist":{"shasum":"b0ce01b22f0e165778ce0b066041d6cacd4bb40f","size":7177,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-1.2.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-1.2.1.tgz"},"directories":{},"publish_time":1442453321274,"_hasShrinkwrap":false,"_cnpm_publish_time":1442453321274,"_cnpmcore_publish_time":"2021-12-16T12:25:02.871Z"},"1.1.1":{"name":"passport-jwt","version":"1.1.1","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^5.0.0","passport-strategy":"^1.0.0"},"gitHead":"0f4ffa460a38c4dbc0fc513e44275692e12c9b8f","_id":"passport-jwt@1.1.1","_shasum":"d511780333803e4d881b4e42e01fd8387f48f573","_from":".","_npmVersion":"2.7.5","_nodeVersion":"0.12.2","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"maintainers":[{"name":"themikenicholson","email":""}],"dist":{"shasum":"d511780333803e4d881b4e42e01fd8387f48f573","size":7021,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-1.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-1.1.1.tgz"},"directories":{},"publish_time":1440045293889,"_hasShrinkwrap":false,"_cnpm_publish_time":1440045293889,"_cnpmcore_publish_time":"2021-12-16T12:25:03.053Z"},"1.1.0":{"name":"passport-jwt","version":"1.1.0","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^5.0.0","passport-strategy":"^1.0.0"},"gitHead":"fb1a12fca439dc104afac96d3e8336b317c09795","_id":"passport-jwt@1.1.0","_shasum":"d06a169493dd5b4ea79bcaab4b5523bae1ba9313","_from":".","_npmVersion":"2.7.1","_nodeVersion":"0.12.0","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"maintainers":[{"name":"themikenicholson","email":""}],"dist":{"shasum":"d06a169493dd5b4ea79bcaab4b5523bae1ba9313","size":6926,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-1.1.0.tgz"},"directories":{},"publish_time":1429845474370,"_hasShrinkwrap":false,"_cnpm_publish_time":1429845474370,"_cnpmcore_publish_time":"2021-12-16T12:25:03.252Z"},"1.0.1":{"name":"passport-jwt","version":"1.0.1","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^1.1.2","passport-strategy":"^1.0.0"},"gitHead":"3eae91ba23dd49bca266de95f49a8e13d31c2f95","_id":"passport-jwt@1.0.1","_shasum":"1f62dfe7ebc53bc8d7c9aa7f7944e5b860c3ebb9","_from":".","_npmVersion":"2.7.1","_nodeVersion":"0.12.0","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"maintainers":[{"name":"themikenicholson","email":""}],"dist":{"shasum":"1f62dfe7ebc53bc8d7c9aa7f7944e5b860c3ebb9","size":6685,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-1.0.1.tgz"},"directories":{},"publish_time":1428463592059,"_hasShrinkwrap":false,"_cnpm_publish_time":1428463592059,"_cnpmcore_publish_time":"2021-12-16T12:25:03.466Z"},"1.0.0":{"name":"passport-jwt","version":"1.0.0","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^1.1.2","passport-strategy":"^1.0.0"},"gitHead":"39d7254cb6be825a8f879e71910ad1d4cf16a0bd","_id":"passport-jwt@1.0.0","_shasum":"54f8c94eb6e46a98a3f07c61e2fc3d794bcac4cd","_from":".","_npmVersion":"2.1.11","_nodeVersion":"0.10.33","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"maintainers":[{"name":"themikenicholson","email":""}],"dist":{"shasum":"54f8c94eb6e46a98a3f07c61e2fc3d794bcac4cd","size":6592,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-1.0.0.tgz"},"directories":{},"publish_time":1425357073190,"_hasShrinkwrap":false,"_cnpm_publish_time":1425357073190,"_cnpmcore_publish_time":"2021-12-16T12:25:03.685Z"},"0.1.1":{"name":"passport-jwt","version":"0.1.1","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^1.1.2","passport-strategy":"^1.0.0"},"gitHead":"f2d4fa313e73e316376204e10aa497deed1ee098","_id":"passport-jwt@0.1.1","_shasum":"6b59333e3bbd3503001be999f59d5b63d42dc8f9","_from":".","_npmVersion":"2.1.11","_nodeVersion":"0.10.33","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"maintainers":[{"name":"themikenicholson","email":""}],"dist":{"shasum":"6b59333e3bbd3503001be999f59d5b63d42dc8f9","size":6569,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-0.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-0.1.1.tgz"},"directories":{},"publish_time":1425354278256,"_hasShrinkwrap":false,"_cnpm_publish_time":1425354278256,"_cnpmcore_publish_time":"2021-12-16T12:25:03.899Z"},"0.1.0":{"name":"passport-jwt","version":"0.1.0","description":"Passport authentication strategy using JSON Web Tokens","main":"./lib","scripts":{"test":"mocha --reporter spec --require test/bootstrap test/*test.js"},"repository":{"type":"git","url":"https://github.com/themikenicholson/passport-jwt.git"},"keywords":["Passport","Strategy","JSON","Web","Token","JWT"],"author":{"name":"Mike Nicholson"},"license":"MIT","bugs":{"url":"https://github.com/themikenicholson/passport-jwt/issues"},"homepage":"https://github.com/themikenicholson/passport-jwt","devDependencies":{"chai":"^1.9.2","chai-passport-strategy":"^0.2.0","mocha":"^2.0.1","sinon":"^1.11.1"},"dependencies":{"jsonwebtoken":"^1.1.2","passport-strategy":"^1.0.0"},"gitHead":"a77b85edfa23f2ed3bc128893ff327ad78bb52bb","_id":"passport-jwt@0.1.0","_shasum":"a2ca889502bd70ed953e38017c55f6dcc9414a0b","_from":".","_npmVersion":"2.1.4","_nodeVersion":"0.10.32","_npmUser":{"name":"themikenicholson","email":"themikenicholson@gmail.com"},"maintainers":[{"name":"themikenicholson","email":""}],"dist":{"shasum":"a2ca889502bd70ed953e38017c55f6dcc9414a0b","size":6331,"noattachment":false,"key":"/passport-jwt/-/passport-jwt-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/passport-jwt/download/passport-jwt-0.1.0.tgz"},"directories":{},"publish_time":1415762196887,"_hasShrinkwrap":false,"_cnpm_publish_time":1415762196887,"_cnpmcore_publish_time":"2021-12-16T12:25:04.114Z"}},"readme":"# passport-jwt\n\n[![Build Status](https://travis-ci.org/mikenicholson/passport-jwt.svg?branch=master)](https://travis-ci.org/mikenicholson/passport-jwt)\n[![Code Climate](https://codeclimate.com/github/mikenicholson/passport-jwt/badges/gpa.svg)](https://codeclimate.com/github/mikenicholson/passport-jwt)\n\nA [Passport](http://passportjs.org/) strategy for authenticating with a\n[JSON Web Token](http://jwt.io).\n\nThis module lets you authenticate endpoints using a JSON web token. It is\nintended to be used to secure RESTful endpoints without sessions.\n\n## Supported By\n\nIf you want to quickly add secure token-based authentication to Node.js apps, feel free to check out Auth0's Node.js SDK and free plan at [auth0.com/developers](https://auth0.com/developers?utm_source=GHsponsor&utm_medium=GHsponsor&utm_campaign=passport-jwt&utm_content=auth) <img alt='Auth0 Logo' src='https://s3.amazonaws.com/passport-jwt-img/Auth0+logo.svg'/>\n\n## Install\n\n    npm install passport-jwt\n\n## Usage\n\n### Configure Strategy\n\nThe JWT authentication strategy is constructed as follows:\n\n    new JwtStrategy(options, verify)\n\n`options` is an object literal containing options to control how the token is\nextracted from the request or verified.\n\n* `secretOrKey` is a string or buffer containing the secret\n  (symmetric) or PEM-encoded public key (asymmetric) for verifying the token's\n  signature. REQUIRED unless `secretOrKeyProvider` is provided.\n* `secretOrKeyProvider` is a callback in the format `function secretOrKeyProvider(request, rawJwtToken, done)`,\n  which should call `done` with a secret or PEM-encoded public key (asymmetric) for the given key and request combination.\n  `done` accepts arguments in the format `function done(err, secret)`. Note it is up to the implementer to decode rawJwtToken.\n  REQUIRED unless `secretOrKey` is provided.\n* `jwtFromRequest` (REQUIRED) Function that accepts a request as the only\n  parameter and returns either the JWT as a string or *null*. See\n  [Extracting the JWT from the request](#extracting-the-jwt-from-the-request) for\n  more details.\n* `issuer`: If defined the token issuer (iss) will be verified against this\n  value.\n* `audience`: If defined, the token audience (aud) will be verified against\n  this value.\n* `algorithms`: List of strings with the names of the allowed algorithms. For instance, [\"HS256\", \"HS384\"].\n* `ignoreExpiration`: if true do not validate the expiration of the token.\n* `passReqToCallback`: If true the request will be passed to the verify\n  callback. i.e. verify(request, jwt_payload, done_callback).\n* `jsonWebTokenOptions`: passport-jwt is verifying the token using [jsonwebtoken](https://github.com/auth0/node-jsonwebtoken).\nPass here an options object for any other option you can pass the jsonwebtoken verifier. (i.e maxAge)\n\n`verify` is a function with the parameters `verify(jwt_payload, done)`\n\n* `jwt_payload` is an object literal containing the decoded JWT payload.\n* `done` is a passport error first callback accepting arguments\n  done(error, user, info)\n\nAn example configuration which reads the JWT from the http\nAuthorization header with the scheme 'bearer':\n\n```js\nvar JwtStrategy = require('passport-jwt').Strategy,\n    ExtractJwt = require('passport-jwt').ExtractJwt;\nvar opts = {}\nopts.jwtFromRequest = ExtractJwt.fromAuthHeaderAsBearerToken();\nopts.secretOrKey = 'secret';\nopts.issuer = 'accounts.examplesoft.com';\nopts.audience = 'yoursite.net';\npassport.use(new JwtStrategy(opts, function(jwt_payload, done) {\n    User.findOne({id: jwt_payload.sub}, function(err, user) {\n        if (err) {\n            return done(err, false);\n        }\n        if (user) {\n            return done(null, user);\n        } else {\n            return done(null, false);\n            // or you could create a new account\n        }\n    });\n}));\n```\n\n### Extracting the JWT from the request\n\nThere are a number of ways the JWT may be included in a request.  In order to remain as flexible as\npossible the JWT is parsed from the request by a user-supplied callback passed in as the\n`jwtFromRequest` parameter.  This callback, from now on referred to as an extractor,\naccepts a request object as an argument and returns the encoded JWT string or *null*.\n\n#### Included extractors\n\nA number of extractor factory functions are provided in passport-jwt.ExtractJwt. These factory\nfunctions return a new extractor configured with the given parameters.\n\n* ```fromHeader(header_name)``` creates a new extractor that looks for the JWT in the given http\n  header\n* ```fromBodyField(field_name)``` creates a new extractor that looks for the JWT in the given body\n  field.  You must have a body parser configured in order to use this method.\n* ```fromUrlQueryParameter(param_name)``` creates a new extractor that looks for the JWT in the given\n  URL query parameter.\n* ```fromAuthHeaderWithScheme(auth_scheme)``` creates a new extractor that looks for the JWT in the\n  authorization header, expecting the scheme to match auth_scheme.\n* ```fromAuthHeaderAsBearerToken()``` creates a new extractor that looks for the JWT in the authorization header\n  with the scheme 'bearer'\n* ```fromExtractors([array of extractor functions])``` creates a new extractor using an array of\n  extractors provided. Each extractor is attempted in order until one returns a token.\n\n### Writing a custom extractor function\n\nIf the supplied extractors don't meet your needs you can easily provide your own callback. For\nexample, if you are using the cookie-parser middleware and want to extract the JWT in a cookie\nyou could use the following function as the argument to the jwtFromRequest option:\n\n```js\nvar cookieExtractor = function(req) {\n    var token = null;\n    if (req && req.cookies) {\n        token = req.cookies['jwt'];\n    }\n    return token;\n};\n// ...\nopts.jwtFromRequest = cookieExtractor;\n```\n\n### Authenticate requests\n\nUse `passport.authenticate()` specifying `'JWT'` as the strategy.\n\n```js\napp.post('/profile', passport.authenticate('jwt', { session: false }),\n    function(req, res) {\n        res.send(req.user.profile);\n    }\n);\n```\n\n### Include the JWT in requests\n\nThe method of including a JWT in a request depends entirely on the extractor\nfunction you choose. For example, if you use the `fromAuthHeaderAsBearerToken`\nextractor, you would include an `Authorization` header in your request with the\nscheme set to `bearer`. e.g.\n\n    Authorization: bearer JSON_WEB_TOKEN_STRING.....\n\n## Migrating\n\nRead the [Migration Guide](docs/migrating.md) for help upgrading to the latest\nmajor version of passport-jwt.\n\n## Tests\n\n    npm install\n    npm test\n\nTo generate test-coverage reports:\n\n    npm install -g istanbul\n    npm run-script testcov\n    istanbul report\n\n## License\n\nThe [MIT License](http://opensource.org/licenses/MIT)\n\nCopyright (c) 2015 Mike Nicholson\n","_attachments":{},"homepage":"https://github.com/mikenicholson/passport-jwt","bugs":{"url":"https://github.com/mikenicholson/passport-jwt/issues"},"license":"MIT"}