Socket
Socket
Sign inDemoInstall

hapi-auth-cookie

Package Overview
Dependencies
Maintainers
2
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

hapi-auth-cookie - npm Package Compare versions

Comparing version 2.0.0-rc1 to 2.0.0-rc2

5

example/index.js
var Hapi = require('hapi');
var uuid = 1; // Use seq instead of proper unique identifiers for demo only

@@ -79,7 +78,7 @@

var server = new Hapi.Server();
server.connect({ port: 8000 });
server.connection({ port: 8000 });
server.register(require('../'), function (err) {
var cache = server.cache('sessions', { expiresIn: 3 * 24 * 60 * 60 * 1000 });
var cache = server.cache({ segment: 'sessions', expiresIn: 3 * 24 * 60 * 60 * 1000 });
server.app.cache = cache;

@@ -86,0 +85,0 @@

6

lib/index.js

@@ -154,6 +154,6 @@ // Load modules

var redirectTo = settings.redirectTo;
if (request.route.plugins['hapi-auth-cookie'] &&
request.route.plugins['hapi-auth-cookie'].redirectTo !== undefined) {
if (request.route.settings.plugins['hapi-auth-cookie'] &&
request.route.settings.plugins['hapi-auth-cookie'].redirectTo !== undefined) {
redirectTo = request.route.plugins['hapi-auth-cookie'].redirectTo;
redirectTo = request.route.settings.plugins['hapi-auth-cookie'].redirectTo;
}

@@ -160,0 +160,0 @@

{
"name": "hapi-auth-cookie",
"description": "Cookie authentication plugin",
"version": "2.0.0-rc1",
"version": "2.0.0-rc2",
"repository": "git://github.com/hapijs/hapi-auth-cookie",

@@ -6,0 +6,0 @@ "main": "index",

@@ -7,3 +7,3 @@ ### hapi-auth-cookie

Lead Maintainer: [Eran Hammer](https://github.com/hueniverse)
Lead Maintainer: [James Weston](https://github.com/jaw187)

@@ -10,0 +10,0 @@ Cookie authentication provides a simple cookie-based session management. The user has to be

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc