{
  "manifest": {
    "name": "multicast-dns",
    "version": "7.2.5",
    "description": "Low level multicast-dns implementation in pure javascript",
    "main": "index.js",
    "scripts": {
      "test": "standard && tape test.js"
    },
    "bin": {
      "multicast-dns": "cli.js"
    },
    "dependencies": {
      "dns-packet": "^5.2.2",
      "thunky": "^1.0.2"
    },
    "devDependencies": {
      "standard": "^11.0.1",
      "tape": "^4.8.0"
    },
    "repository": {
      "type": "git",
      "url": "https://github.com/mafintosh/multicast-dns.git"
    },
    "author": {
      "name": "Mathias Buus",
      "url": "@mafintosh"
    },
    "license": "MIT",
    "bugs": {
      "url": "https://github.com/mafintosh/multicast-dns/issues"
    },
    "homepage": "https://github.com/mafintosh/multicast-dns",
    "keywords": [
      "multicast",
      "dns",
      "mdns",
      "multicastdns",
      "dns-sd",
      "service",
      "discovery",
      "bonjour",
      "avahi"
    ],
    "coordinates": [
      55.6465878,
      12.5492251
    ],
    "_registry": "npm",
    "_loc": "/homez.1033/heliovt/.cache/yarn/v6/npm-multicast-dns-7.2.5-77eb46057f4d7adbd16d9290fa7299f6fa64cced-integrity/node_modules/multicast-dns/package.json",
    "readmeFilename": "README.md",
    "readme": "# multicast-dns\n\nLow level multicast-dns implementation in pure javascript\n\n```\nnpm install multicast-dns\n```\n\n[![build status](http://img.shields.io/travis/mafintosh/multicast-dns.svg?style=flat)](http://travis-ci.org/mafintosh/multicast-dns)\n\n## Usage\n\n``` js\nvar mdns = require('multicast-dns')()\n\nmdns.on('response', function(response) {\n  console.log('got a response packet:', response)\n})\n\nmdns.on('query', function(query) {\n  console.log('got a query packet:', query)\n})\n\n// lets query for an A record for 'brunhilde.local'\nmdns.query({\n  questions:[{\n    name: 'brunhilde.local',\n    type: 'A'\n  }]\n})\n```\n\nRunning the above (change `brunhilde.local` to `your-own-hostname.local`) will print an echo of the query packet first\n\n``` js\ngot a query packet: { type: 'query',\n  questions: [ { name: 'brunhilde.local', type: 'A', class: 1 } ],\n  answers: [],\n  authorities: [],\n  additionals: [] }\n```\n\nAnd then a response packet\n\n``` js\ngot a response packet: { type: 'response',\n  questions: [],\n  answers:\n   [ { name: 'brunhilde.local',\n       type: 'A',\n       class: 'IN',\n       ttl: 120,\n       flush: true,\n       data: '192.168.1.5' } ],\n  authorities: [],\n  additionals:\n   [ { name: 'brunhilde.local',\n       type: 'A',\n       class: 'IN',\n       ttl: 120,\n       flush: true,\n       data: '192.168.1.5' },\n     { name: 'brunhilde.local',\n       type: 'AAAA',\n       class: 'IN',\n       ttl: 120,\n       flush: true,\n       data: 'fe80::5ef9:38ff:fe8c:ceaa' } ] }\n```\n\n\n# CLI\n\n```\nnpm install -g multicast-dns\n```\n\n```\nmulticast-dns brunhilde.local\n> 192.168.1.1\n```\n\n# API\n\nA packet has the following format\n\n``` js\n{\n  questions: [{\n    name: 'brunhilde.local',\n    type: 'A'\n  }],\n  answers: [{\n    name: 'brunhilde.local',\n    type: 'A',\n    ttl: seconds,\n    data: (record type specific data)\n  }],\n  additionals: [\n    (same format as answers)\n  ],\n  authorities: [\n    (same format as answers)\n  ]\n}\n```\n\nCurrently data from `SRV`, `A`, `PTR`, `TXT`, `AAAA` and `HINFO` records is passed\n\n#### `mdns = multicastdns([options])`\n\nCreates a new `mdns` instance. Options can contain the following\n\n``` js\n{\n  multicast: true // use udp multicasting\n  interface: '192.168.0.2' // explicitly specify a network interface. defaults to all\n  port: 5353, // set the udp port\n  ip: '224.0.0.251', // set the udp ip\n  ttl: 255, // set the multicast ttl\n  loopback: true, // receive your own packets\n  reuseAddr: true // set the reuseAddr option when creating the socket (requires node >=0.11.13)\n}\n```\n\n#### `mdns.on('query', (packet, rinfo))`\n\nEmitted when a query packet is received.\n\n``` js\nmdns.on('query', function(query) {\n  if (query.questions[0] && query.questions[0].name === 'brunhilde.local') {\n    mdns.respond(someResponse) // see below\n  }\n})\n```\n\n#### `mdns.on('response', (packet, rinfo))`\n\nEmitted when a response packet is received.\n\nThe response might not be a response to a query you send as this\nis the result of someone multicasting a response.\n\n#### `mdns.query(packet, [cb])`\n\nSend a dns query. The callback will be called when the packet was sent.\n\nThe following shorthands are equivalent\n\n``` js\nmdns.query('brunhilde.local', 'A')\nmdns.query([{name:'brunhilde.local', type:'A'}])\nmdns.query({\n  questions: [{name:'brunhilde.local', type:'A'}]\n})\n```\n\n#### `mdns.respond(packet, [cb])`\n\nSend a dns response. The callback will be called when the packet was sent.\n\n``` js\n// reply with a SRV and a A record as an answer\nmdns.respond({\n  answers: [{\n    name: 'my-service',\n    type: 'SRV',\n    data: {\n      port: 9999,\n      weight: 0,\n      priority: 10,\n      target: 'my-service.example.com'\n    }\n  }, {\n    name: 'brunhilde.local',\n    type: 'A',\n    ttl: 300,\n    data: '192.168.1.5'\n  }]\n})\n```\n\nThe following shorthands are equivalent\n\n``` js\nmdns.respond([{name:'brunhilde.local', type:'A', data:'192.158.1.5'}])\nmdns.respond({\n  answers: [{name:'brunhilde.local', type:'A', data:'192.158.1.5'}]\n})\n```\n\n#### `mdns.destroy()`\n\nDestroy the mdns instance. Closes the udp socket.\n\n# Development\n\nTo start hacking on this module you can use this example to get started\n\n```\ngit clone git://github.com/mafintosh/multicast-dns.git\nnpm install\nnode example.js\nnode cli.js $(hostname).local\n```\n\n## License\n\nMIT\n",
    "licenseText": "The MIT License (MIT)\n\nCopyright (c) 2015 Mathias Buus\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\nTHE SOFTWARE.\n"
  },
  "artifacts": [],
  "remote": {
    "resolved": "https://registry.yarnpkg.com/multicast-dns/-/multicast-dns-7.2.5.tgz#77eb46057f4d7adbd16d9290fa7299f6fa64cced",
    "type": "tarball",
    "reference": "https://registry.yarnpkg.com/multicast-dns/-/multicast-dns-7.2.5.tgz",
    "hash": "77eb46057f4d7adbd16d9290fa7299f6fa64cced",
    "integrity": "sha512-2eznPJP8z2BFLX50tf0LuODrpINqP1RVIm/CObbTcBRITQgmC/TjcREF1NeTBzIcR5XO/ukWo+YHOjBbFwIupg==",
    "registry": "npm",
    "packageName": "multicast-dns",
    "cacheIntegrity": "sha512-2eznPJP8z2BFLX50tf0LuODrpINqP1RVIm/CObbTcBRITQgmC/TjcREF1NeTBzIcR5XO/ukWo+YHOjBbFwIupg== sha1-d+tGBX9NetvRbZKQ+nKZ9vpkzO0="
  },
  "registry": "npm",
  "hash": "77eb46057f4d7adbd16d9290fa7299f6fa64cced"
}