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

multicast-dns

Package Overview
Dependencies
Maintainers
2
Versions
41
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

multicast-dns - npm Package Compare versions

Comparing version 5.5.0 to 6.0.0

10

index.js

@@ -1,2 +0,2 @@

var packets = require('./packets')
var packet = require('dns-packet')
var dgram = require('dgram')

@@ -36,3 +36,3 @@ var thunky = require('thunky')

try {
message = packets.decode(message)
message = packet.decode(message)
} catch (err) {

@@ -72,4 +72,4 @@ that.emit('warning', err)

that.send = function (packet, rinfo, cb) {
if (typeof rinfo === 'function') return that.send(packet, null, rinfo)
that.send = function (value, rinfo, cb) {
if (typeof rinfo === 'function') return that.send(value, null, rinfo)
if (!cb) cb = noop

@@ -79,3 +79,3 @@ if (!rinfo) rinfo = me

if (err) return cb(err)
var message = packets.encode(packet)
var message = packet.encode(value)
socket.send(message, 0, message.length, rinfo.port, rinfo.address || rinfo.host, cb)

@@ -82,0 +82,0 @@ })

{
"name": "multicast-dns",
"version": "5.5.0",
"version": "6.0.0",
"description": "Low level multicast-dns implementation in pure javascript",

@@ -11,4 +11,4 @@ "main": "index.js",

"dependencies": {
"thunky": "^0.1.0",
"ip": "^1.1.0"
"dns-packet": "^1.0.1",
"thunky": "^0.1.0"
},

@@ -15,0 +15,0 @@ "devDependencies": {

@@ -149,17 +149,2 @@ var mdns = require('./')

test('TXT record - empty', function (dns, t) {
dns.once('query', function (packet) {
dns.respond([{type: 'TXT', name: 'hello-world', ttl: 120}])
})
dns.once('response', function (packet) {
t.same(packet.answers[0], {type: 'TXT', name: 'hello-world', ttl: 120, data: new Buffer('00', 'hex'), class: 1, flush: false})
dns.destroy(function () {
t.end()
})
})
dns.query('hello-world', 'TXT')
})
test('QU question bit', function (dns, t) {

@@ -166,0 +151,0 @@ dns.once('query', function (packet) {

Sorry, the diff of this file is not supported yet

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