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

@krtn/dns-authoritative-server

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@krtn/dns-authoritative-server - npm Package Compare versions

Comparing version 0.1.1 to 0.1.2

.idea/misc.xml

2

package.json
{
"name": "@krtn/dns-authoritative-server",
"description": "Pure JavaScript implementation of an authoritative name server",
"version": "0.1.1",
"version": "0.1.2",
"main": "./index.js",

@@ -6,0 +6,0 @@ "types": "./index.d.ts",

@@ -5,2 +5,3 @@ 'use strict'

const dnsPacket = require('dns-packet')
const rcodes = require('dns-packet/rcodes')

@@ -29,7 +30,3 @@ class BaseServer {

flags: dnsPacket.AUTHORITATIVE_ANSWER,
opcode: 'QUERY',
questions: dnsRequest.questions,
answers: [],
authorities: [],
additionals: []
questions: dnsRequest.questions
}

@@ -42,7 +39,6 @@

response.rcode = 'NOERROR'
response.answers = await this.#answerQuestions(dnsRequest.questions)
} catch (e) {
console.error('Error occurred when resolving answers', e)
response.rcode = e instanceof ZoneNotAllowedError ? 'REFUSED' : 'SERVFAIL'
response.flags |= rcodes.toRcode(e instanceof ZoneNotAllowedError ? 'REFUSED' : 'SERVFAIL')
}

@@ -75,6 +71,4 @@

type: 'A',
class: 'IN',
name: question.name,
ttl: 30,
flush: true,
data

@@ -81,0 +75,0 @@ })

Sorry, the diff of this file is not supported yet

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