Skip to content

Latest commit

 

History

History
30 lines (21 loc) · 665 Bytes

File metadata and controls

30 lines (21 loc) · 665 Bytes

License

crypto-session

Usage

const session = require('crypto-session')
const app = require('koa')()

session(app, {
  crypto_key: 'exiKdyF+IwRIXJDmtGIl4vWUz4i3eVSISpfZoeYc0s4='
})

Generate a new crypto_key (note, the length depends on your algorithm):

$ node
> crypto.randomBytes(32).toString('base64')

License

MIT