Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

hapi

Package Overview
Dependencies
Maintainers
1
Versions
295
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

hapi - npm Package Compare versions

Comparing version 16.4.2 to 16.4.3

29

lib/request.js

@@ -79,3 +79,17 @@ 'use strict';

this.mime = null; // Set if payload is parsed
this.headers = req.headers;
// Request info
this.info = {
received: now,
responded: 0,
remoteAddress: req.connection.remoteAddress,
remotePort: req.connection.remotePort || '',
referrer: req.headers.referrer || req.headers.referer || '',
host: req.headers.host ? req.headers.host.replace(/\s/g, '') : ''
};
this.info.hostname = this.info.host.split(':')[0];
this.setUrl = this._setUrl; // Decoration removed after 'onRequest'

@@ -86,3 +100,2 @@ this.setMethod = this._setMethod;

this._setMethod(req.method); // Sets: this.method
this.headers = req.headers;

@@ -147,16 +160,6 @@ this.id = now + ':' + connection.info.id + ':' + connection._requestCounter.value++;

// Request info
// Encoding
this.info = {
received: now,
responded: 0,
remoteAddress: req.connection.remoteAddress,
remotePort: req.connection.remotePort || '',
referrer: req.headers.referrer || req.headers.referer || '',
host: req.headers.host ? req.headers.host.replace(/\s/g, '') : '',
acceptEncoding: this.connection._compression.accept(this)
};
this.info.acceptEncoding = this.connection._compression.accept(this); // Delay until request object fully initialized
this.info.hostname = this.info.host.split(':')[0];
// Listen to request state

@@ -163,0 +166,0 @@

@@ -5,3 +5,3 @@ {

"homepage": "http://hapijs.com",
"version": "16.4.2",
"version": "16.4.3",
"repository": {

@@ -8,0 +8,0 @@ "type": "git",

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