net/dns.lua
changeset 12608 bd9e006a7a74
parent 12391 05c250fa335a
child 12978 ba409c67353b
equal deleted inserted replaced
12607:05ca75309fa0 12608:bd9e006a7a74
     6 -- todo: quick (default) header generation
     6 -- todo: quick (default) header generation
     7 -- todo: nxdomain, error handling
     7 -- todo: nxdomain, error handling
     8 -- todo: cache results of encodeName
     8 -- todo: cache results of encodeName
     9 
     9 
    10 
    10 
    11 -- reference: http://tools.ietf.org/html/rfc1035
    11 -- reference: https://www.rfc-editor.org/rfc/rfc1035.html
    12 -- reference: http://tools.ietf.org/html/rfc1876 (LOC)
    12 -- reference: https://www.rfc-editor.org/rfc/rfc1876.html (LOC)
    13 
    13 
    14 
    14 
    15 local socket = require "socket";
    15 local socket = require "socket";
    16 local have_timer, timer = pcall(require, "util.timer");
    16 local have_timer, timer = pcall(require, "util.timer");
    17 local new_ip = require "util.ip".new_ip;
    17 local new_ip = require "util.ip".new_ip;