New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

dns

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dns - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

6

lib/dns.js

@@ -85,2 +85,3 @@ module.exports = function () {

var object;
if (!err && value) {

@@ -103,4 +104,5 @@ try {

if (object[question.type]) {
object[question.type].forEach(function(data) {
answer.data = data;
var vector = typeof(object[question.type]) === 'Array' ? object[question.type] : [object[question.type]];
vector.forEach(function(data) {
answer.data = ''+data;
res.answer.push(answer);

@@ -107,0 +109,0 @@ $this.logger.log('info', '%s:%s/%s - local - %s question:"%s" - %j', req.connection.remoteAddress, req.connection.remotePort, req.connection.type, hostname, question, answer, $this.meta);

@@ -56,6 +56,6 @@ module.exports = function () {

if (req.body.ipv4) {
record.A = req.body.ipv4;
record.A = typeof(req.body.ipv4) === 'Array' ? req.body.ipv4 : [req.body.ipv4];
}
if (req.body.ipv6) {
record.AAAA = req.body.ipv6;
record.AAAA = typeof(req.body.ipv6) === 'Array' ? req.body.ipv6 : [req.body.ipv6];
}

@@ -80,3 +80,3 @@ }

}
var hostname = hostnames.shift();
var hostname = ''+hostnames.shift(); // Make sure it is a string
var arpa = hostname.split('.').reverse().join('.') + '.in-addr.arpa';

@@ -83,0 +83,0 @@ store.set(prefix + arpa, JSON.stringify(record), function (err, result) {

@@ -5,3 +5,3 @@ {

"description": "A DNS Server with a REST API",
"version": "0.2.0",
"version": "0.2.1",
"keywords": [

@@ -8,0 +8,0 @@ "dns",

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