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

nat-upnp

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nat-upnp - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

17

lib/nat-upnp/client.js

@@ -149,2 +149,3 @@ var nat = require('../nat-upnp'),

this.findGateway(function(err, gateway, address) {
if (err) return callback(err);
gateway.run('GetExternalIPAddress', [], function(err, data) {

@@ -168,8 +169,18 @@ if (err) return callback(err);

Client.prototype.findGateway = function findGateway(callback) {
var p = this.ssdp.search(
'urn:schemas-upnp-org:device:InternetGatewayDevice:1'
);
var timeout,
timeouted = false,
p = this.ssdp.search(
'urn:schemas-upnp-org:device:InternetGatewayDevice:1'
);
timeout = setTimeout(function() {
timeouted = true;
p.emit('end');
callbacK(new Error('timeout'));
}, 5000);
p.on('device', function(info, address) {
if (timeouted) return;
p.emit('end');
clearTimeout(timeout);

@@ -176,0 +187,0 @@ // Create gateway

2

package.json
{
"name": "nat-upnp",
"version": "0.2.0",
"version": "0.2.1",
"main": "lib/nat-upnp",

@@ -5,0 +5,0 @@ "author": "Fedor Indutny <fedor@indutny.com>",

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