{
  "name": "ip",
  "version": "0.3.0",
  "author": {
    "name": "Fedor Indutny",
    "email": "fedor@indutny.com"
  },
  "homepage": "https://github.com/indutny/node-ip",
  "repository": {
    "type": "git",
    "url": "http://github.com/indutny/node-ip.git"
  },
  "main": "lib/ip",
  "devDependencies": {
    "mocha": "~1.3.2"
  },
  "scripts": {
    "test": "mocha --reporter spec test/*-test.js"
  },
  "readme": "# IP\nIP address utilities for node.js\n\n## Usage\nGet your ip address, compare ip addresses, validate ip addresses, etc.\n\n```\nvar ip = require('ip');\n\nip.address() // my ip address\nip.isEqual('::1', '::0:1'); // true\nip.toBuffer('127.0.0.1') // Buffer([127, 0, 0, 1])\nip.toString(new Buffer([127, 0, 0, 1])) // 127.0.0.1\nip.fromPrefixLen(24) // 255.255.255.0\nip.mask('192.168.1.134', '255.255.255.0') // 192.168.1.0\nip.cidr('192.168.1.134/26') // 192.168.1.128\nip.not('255.255.255.0') // 0.0.0.255\nip.or('192.168.1.134', '0.0.0.255') // 192.168.1.255\nip.isPrivate('127.0.0.1') // true\n\n// operate on buffers in-place\nvar buf = new Buffer(128);\nvar offset = 64;\nip.toBuffer('127.0.0.1', buf, offset);  // [127, 0, 0, 1] at offset 64\nip.toString(buf, offset, 4);            // '127.0.0.1'\n\n// subnet information\nip.subnet('192.168.1.134', '255.255.255.192')\n// { networkAddress: '192.168.1.128',\n//   firstAddress: '192.168.1.129',\n//   lastAddress: '192.168.1.190',\n//   broadcastAddress: '192.168.1.191',\n//   subnetMask: '255.255.255.192',\n//   subnetMaskLength: 26,\n//   numHosts: 62,\n//   length: 64 }\nip.cidr('192.168.1.134/26')\n// Same as previous.\n\n// ipv4 long conversion\nip.toLong('127.0.0.1'); // 2130706433\nip.fromLong(2130706433); // '127.0.0.1'\n```\n\n### License\n\nThis software is licensed under the MIT License.\n\nCopyright Fedor Indutny, 2012.\n\nPermission is hereby granted, free of charge, to any person obtaining a\ncopy of this software and associated documentation files (the\n\"Software\"), to deal in the Software without restriction, including\nwithout limitation the rights to use, copy, modify, merge, publish,\ndistribute, sublicense, and/or sell copies of the Software, and to permit\npersons to whom the Software is furnished to do so, subject to the\nfollowing conditions:\n\nThe above copyright notice and this permission notice shall be included\nin all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\nOR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\nNO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\nDAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\nOTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\nUSE OR OTHER DEALINGS IN THE SOFTWARE.\n",
  "readmeFilename": "README.md",
  "description": "IP address utilities for node.js",
  "bugs": {
    "url": "https://github.com/indutny/node-ip/issues"
  },
  "_id": "ip@0.3.0",
  "_shasum": "7a469fffa4e26e56d61b91056a40bf9dbdcd8a8b",
  "_from": "ip@^0.3.0",
  "_resolved": "https://registry.npmjs.org/ip/-/ip-0.3.0.tgz"
}
