+ All Categories
Home > Documents > DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP...

DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP...

Date post: 24-Sep-2018
Category:
Upload: buithuy
View: 218 times
Download: 0 times
Share this document with a friend
27
DNS and BIND David White
Transcript
Page 1: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

DNS and BIND

David White

Page 2: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

DNS: Backbone of the Internet

• Translates Domains into unique IP Addresses– i.e. “developcents.com” =

“66.228.59.103”

• Distributed Database of Host Information

• Works seamlessly “behind the scenes”

Page 3: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

So what is a “Domain”?

• RFC 920: Domains are Administrative entities

• A unique name

• Can contain subdomain names

Page 4: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

• Hierarchical, Tree-like structure

• Made up of individual Nodes

Basic Structure

Page 5: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

DNS:Series of Delegated Information

A Silly Example…

checkers.boardgames.games.fun.com

Page 6: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

checkers.boardgames.games.fun.com

. (root)

.com .fun

.games .boardgames

Page 7: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

Domain Namespace: Another Picture

root (.)

com

google developcents

server1 server2

edu

taylor

This “tree” is also called a “domain namespace.”

Page 8: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

Components of DNS

• Domain Name Space• Name Servers (Authoritative Name

Servers)• Resolvers (Caching Name Servers)

Page 9: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

DNS Zones

• A portion of a Domain Namespace defined by Zone Files (which contain Zone Records)

• Portion of a Domain Namespace that has been administratively delegated

• … Therefore, this information comes from an authoritative source (Master Name Server)

• Can be loaded by Slave Name Servers (for backup and redundancy purposes)

Page 10: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

Components of Zone Files

• TTL (Time to Live)– Tells caching nameservers how long

they should cache information from an authoritative source

• The domain administrator’s contact information

• DNS Records

Page 11: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

Common DNS Records(Resource Records)

• SOA Record (Start of Authority)– Indicates that the nameserver is the best source of

info for data within a domain’s zone

• A Record (Address)– Directly maps a name to an IP address

• MX Record (Mail Exchanger)– Specifies which servers receive email for a domain

(and in what order they should be tried)

Page 12: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

Common DNS Records(Resource Records)

• 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

Page 13: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

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.

• A record that’s served by a DNS server that’s not authoritative for the zone.

Page 14: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

Glue Records: How?

• Add IP addresses to your nameservers in your Domain Registrar

• THEN… add NS records AND A records for your authoritative nameservers:

INNS ns1.example.com.INNS ns2.example.com.

ns1 INA 1.2.3.4ns2 INA 2.3.4.5

Page 15: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

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.

Page 16: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

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/

Page 17: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

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

Page 18: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

Configuring BIND (for CentOS)

First, install BIND with: “Yum install bind”

Main config file: /etc/named.conf

Zone file(s) for Master: /var/named/

Zone file(s) for Slave (Caching): /var/named/slaves

Page 19: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

BIND’s named.conf forMaster Name Server

Options {listen-on port53 { any; };allow-transfer { 2.3.4.5; };recursion no;

};

Page 20: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

BIND’s named.conf forMaster Name Server

zone “example.com” IN {type master;file “path-to-zone-file-location”;

};

Page 21: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

BIND’s named.conf forSlave (Caching) Name Server

Options {recursion: no;

};

Page 22: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

BIND’s named.conf forSlave (Caching) Name Server

zone “example.com” IN {type slave;file “path-to-zone-file-location”;masters { 1.2.3.4; };

};

Page 23: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

A Couple Security Considerations

An Open Resolver is a BAD IDEA

DNS Security Extensions (DNSSEC)• Digitally signs DNS data so that you are

assured its valid. It’s a digital signature, • No encryption or decryption takes place• Must be deployed at each step of the

lookup process

Page 24: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

Recommended Resources

• BIND Homepagehttps://www.isc.org/software/bind

• O’Reilly’s DNS and BIND

• RFCs 920, 1034, 1035, 2308 & their updates - http://tools.ietf.org/html/

• Wikipedia’s List of DNS Record Types: http://en.wikipedia.org/wiki/List_of_DNS_record_types

Page 25: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

Recommended Resources (con’t)

• Website (Intro to DNS): “How does DNS work?”http://cr.yp.to/djbdns/intro-dns.html

• Pingdom’s DNS Check Tool: http://dnscheck.pingdom.com/

• MX Toolbox (for testing MX and DNS configuration):http://www.mxtoolbox.com/

Page 26: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

Recommended Resources (con’t)

• DNSSEC – What Is It and Why Is It Important?http://www.icann.org/en/about/learning/factsheets/dnssec-qaa-09oct08-en.htm

Page 27: DNS and BIND - Develop CENTS · DNS: Backbone of the Internet • Translates Domains into unique IP Addresses – i.e. “developcents.com” = “66.228.59.103” • Distributed

The End

This presentation was prepared and presented by David White, Founder & CEO of Develop CENTS, LLC.

IT Consulting, Technical Support, Hosting & More for Nonprofits.

Visit http://developcents.com to learn more.


Recommended