The Domain Name System (DNS) is a hierarchical and distributed name service that provides a naming system for computers, services, and other resources on the Internet or other Internet Protocol (IP) networks. This module registers those services.
Initialization takes place in init(). In access point mode it creates a DNS server and responds to all queries with the address of the softAP. This "funnelling" of DNS and traffic triggers the captive portal (sign in) to appear.