UNPKG

email-domain-check

Version:

Comprehensive email domain validation library with DNS, MX, SMTP, DKIM, DMARC and MTA-STS support.

34 lines (33 loc) 2.49 kB
"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); exports.DNS_ERRORS = void 0; const node_dns_1 = __importDefault(require("node:dns")); exports.DNS_ERRORS = { NODATA: node_dns_1.default.NODATA, // No data: query completed but no records of requested type FORMERR: node_dns_1.default.FORMERR, // Format error: name server could not parse the query SERVFAIL: node_dns_1.default.SERVFAIL, // Server failure: general server-side failure NOTFOUND: node_dns_1.default.NOTFOUND, // Name error / NXDOMAIN: domain does not exist NOTIMP: node_dns_1.default.NOTIMP, // Not implemented: server does not support requested operation REFUSED: node_dns_1.default.REFUSED, // Refused: server refused to perform the operation BADQUERY: node_dns_1.default.BADQUERY, // Bad query: malformed query from client BADNAME: node_dns_1.default.BADNAME, // Bad name: invalid domain name in query BADFAMILY: node_dns_1.default.BADFAMILY, // Bad family: address family not supported (e.g., IPv6/IPv4 mismatch) BADRESP: node_dns_1.default.BADRESP, // Bad response: malformed response from server CONNREFUSED: node_dns_1.default.CONNREFUSED, // Connection refused: transport-level connection refused TIMEOUT: node_dns_1.default.TIMEOUT, // Timed out: operation exceeded allowed time EOF: node_dns_1.default.EOF, // Unexpected EOF from underlying stream/socket FILE: node_dns_1.default.FILE, // File error: problem reading/writing a file NOMEM: node_dns_1.default.NOMEM, // Out of memory DESTRUCTION: node_dns_1.default.DESTRUCTION, // Resolver destroyed while operation in progress BADSTR: node_dns_1.default.BADSTR, // Bad string: invalid string in input BADFLAGS: node_dns_1.default.BADFLAGS, // Bad flags provided to resolver API NONAME: node_dns_1.default.NONAME, // No name/host information available BADHINTS: node_dns_1.default.BADHINTS, // Bad hints passed to resolver (invalid auxiliary data) NOTINITIALIZED: node_dns_1.default.NOTINITIALIZED, // Resolver not initialized before use LOADIPHLPAPI: node_dns_1.default.LOADIPHLPAPI, // Windows: failed to load IP helper API ADDRGETNETWORKPARAMS: node_dns_1.default.ADDRGETNETWORKPARAMS, // Windows: failed to obtain network params CANCELLED: node_dns_1.default.CANCELLED, // Operation was canceled };