Socket
Book a DemoInstallSign in
Socket

@salsita/koa-jwt-auth

Package Overview
Dependencies
Maintainers
2
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@salsita/koa-jwt-auth

[![NPM version](https://img.shields.io/npm/v/@salsita/koa-jwt-auth.svg)](https://www.npmjs.com/package/@salsita/koa-jwt-auth) ![Downloads](https://img.shields.io/npm/dm/@salsita/koa-jwt-auth.svg?style=flat) ![Licence](https://img.shields.io/npm/l/@salsita

1.0.3
latest
Source
npmnpm
Version published
Maintainers
2
Created
Source

@salsita/koa-jwt-auth

NPM version Downloads Licence Dependency Status devDependency Status

Configures authentication middleware.

Important options:

  • key - secure key for hashing payload (if persistent key not provided, new key is generated with each server start - logging out all users)
  • version - should be increased with every change in createSession function, so users using old structure are logged out
  • createSession - function returning data which identifies user (usually user id)
  • getUserForSession - function which checks if user exists/session is valid (data returned from createSession are supplied) and result is put into ctx.state.user

FAQs

Package last updated on 26 Oct 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.