Material de DNS e Bind
Material de DNS e Bind
Material de DNS e Bind
David White
DNS:
Backbone of the Internet
• A unique name
A Silly Example…
checkers.boardgames.games.fun.com
checkers.boardgames.games.fun.com
.com .fun
Domain Namespace: Another
Picture
This “tree” is also called a “domain
namespace.”
root
(.)
com edu
server1 server2
Components of DNS
• Domain Name Space
• Name Servers (Authoritative Name
Servers)
• Resolvers (Caching Name Servers)
DNS Zones
• A portion of a Domain Namespace defined by
Zone Files (which contain Zone Records)
• DNS Records
Common DNS Records
(Resource Records)
• A Record (Address)
– Directly maps a name to an IP address
• NS Records (nameserver)
– Required
– Identify which servers are a particular
zone’s nameservers
– Does NOT have to be the same as the
zone’s domain
Glue Records: What and Why?
• Solve a circular dependency problem:
– The TLD delegates DNS requests for
“example.com” to the particular
authoritative name servers for
example.com.
– But this DNS information is contained
within example.com’s nameservers.
INNS ns1.example.com.
INNS ns2.example.com.
ns1 INA 1.2.3.4
ns2 INA 2.3.4.5
Anti-Spam Mechanisms
• SPF Records
– Identifies which IP addresses are allowed to send
an email from a certain domain.
• DKIM Records
– Uses encryption keys to determine if a sending
mail server is who it says it is.
• DMARC
– Specifies what should happen to email if a SPF and
DKIM check fails.
Introduction to BIND
Berkeley Internet Name Domain
• Originally developed at University of
California Berkeley
• Maintained and supported by ISC
(Internet Systems Consortium)
– https://www.isc.org/software/bind/
Intro to BIND (con’t)
• Most widely used Domain Name
Server Software
• Ported to most flavors of UNIX
(including Ubuntu, RHEL, and
CentOS)
• Can also be run on Microsoft
Windows
Configuring BIND (for
CentOS)
First, install BIND with: “Yum install bind”
Options {
listen-on port53 { any; };
allow-transfer { 2.3.4.5; };
recursion no;
};
BIND’s named.conf for
Master Name Server
zone “example.com” IN {
type master;
file “path-to-zone-file-location”;
};
BIND’s named.conf for
Slave (Caching) Name Server
Options {
recursion: no;
};
BIND’s named.conf for
Slave (Caching) Name Server
zone “example.com” IN {
type slave;
file “path-to-zone-file-location”;
masters { 1.2.3.4; };
};
A Couple Security
Considerations
An Open Resolver is a BAD IDEA