port-numbers
Get the information on network port numbers, based on IANA's public listing
Installation
$ npm install --save port-numbers
Example
var pn = require("port-numbers");
pn(80, function(err, result) {
console.log(result);
});
pn(53, "udp", function(err, result) {
console.log(result);
});
API
pn(port, [protocol], [callback])
port
number : the port to lookup. Required.protocol
string : the protocol. Default: tcp
.callback
function : the callback receives err
and an object containing name
and description
.
© 2015 silverwind, distributed under BSD licence