8. 8
RFCの形式 著者
RFCの番号 この番号の
RFCを廃⽌止
Network
Working
Group
R.
Arends
Request
for
Comments:
4033
Telematica
Instituut
Obsoletes:
2535,
3008,
3090,
3445,
3655,
3658,
R.
Austein
3755,
3757,
3845
ISC
Updates:
1034,
1035,
2136,
2181,
2308,
3225,
M.
Larson
3007,
3597,
3226
VeriSign
この番号の
Category:
Standards
Track
D.
Massey
RFCを更更新
Colorado
State
University
分類
S.
Rose
NIST
March
2005
タイトル
RFCの発⾏行行⽉月
本⽂文
DNS
Security
Introduction
and
Requirements
Status
of
This
Memo
This
document
specifies
an
Internet
standards
track
protocol
for
the
13. 13
要求レベルを⽰示すために⽤用いられるキーワード
• RFCの⽂文書中に次のような説明がある
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL",
"SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED",
"MAY", and "OPTIONAL" in this document are to be
interpreted as described in RFC 2119.
• RFC 2119 / BCP 14 "Key words for use in
RFCs to Indicate Requirement Levels"
▫ RFCにおいて要求レベルを⽰示すために⽤用いられる
キーワード
14. 14
要求レベルを⽰示すために⽤用いられるキーワード
⼤大⽂文字の時にキーワードとして意味を持つ
キーワード 邦訳 意味
MUST しなければならない 要求事項
REQUIRED 要求される
SHALL するもとのする
MUST NOT してはならない 禁⽌止事項
SHALL NOT しないものとする
SHOULD すべきである 推奨事項
(無視する場合は慎重な判断が必要)
RECOMMENDED 推奨される
SHOULD NOT すべきでない ⾮非推奨事項
(容認する場合は慎重な判断が必要)
NOT RECOMMEDED 推奨されない
MAY してもよい 任意事項
OPTIONAL 任意である
20. 20
DNSの構成要素
ネームサーバー ゾーン転送 ネームサーバー ロード
(権威サーバー) (権威サーバー) マスター
ファイル
ゾーン内のリソース
メッセージ レコードを記述
ドメイン名空間
ネームサーバー
(フルサービス
リソースレコード
リゾルバー)
example.jp. IN SOA ns.exampele.jp. ..
example.jp. IN NS ns.example.jp.
メッセージ com jp
ns.example.jp. IN A 192.0.2.1
ドメイン名 タイプ
リゾルバー example example co
ns www
23. 23
RFC 1034と1035のアップデート
(拡張機能のRFCは除く)
• RFC 1123
▫ Requirements for Internet Hosts -‐‑‒-‐‑‒ Application and Support
• RFC 1982
▫ Serial Number Arithmetic
• RFC 2181
▫ Clarifications to the DNS Specification
• RFC 2308
▫ Negative Caching of DNS Queries (DNS NCACHE)
• RFC 3425
▫ Obsoleting IQUERY
• RFC 4343
▫ Domain Name System (DNS) Case Insensitivity Clarification
• RFC 5452
▫ Measures for Making DNS More Resilient against Forged Answers
• RFC 5936
▫ DNS Zone Transfer Protocol (AXFR)
• RFC 5966
▫ DNS Transport over TCP -‐‑‒ Implementation Requirements
24. 24
DNSの基本仕様およびアップデート
RFC 1982 / PS RFC 4343 / PS
Serial Number Arithmetic Domain Name System
(DNS) Case Insensitivity
Clarification
RFC 1034 / STD 13
DOMAIN NAMES -‐‑‒
CONCEPTS AND RFC 2181 / PS
FACILITIES Clarifications to the DNS RFC 5452 / PS
Specification Measures for Making DNS
More Resilient against
RFC 1035 / STD 13
DOMAIN NAMES -‐‑‒ Forged Answers
IMPLEMENTATION AND
SPECIFICATION RFC 2308 / PS
Negative Caching of DNS RFC 5936 / PS
Queries (DNS NCACHE) DNS Zone Transfer
RFC 1123 / STD 3 Protocol (AXFR)
Requirements for Internet
Hosts -‐‑‒-‐‑‒ Application and
Support
RFC 3425 / PS
Obsoleting IQUERY RFC 5966 / PS
アップデート DNS Transport over TCP -‐‑‒
Implementation
参照 Requirements
26. 26
RFC 1034の⽬目次
• 1. STATUS OF THIS MEMO
本⽂文書の位置づけ
• 2. INTRODUCTION
はじめに
• 3. DOMAIN NAME SPACE and RESOURCE RECORDS
ドメイン名空間とリソースレコード
• 4. NAME SERVERS
ネームサーバー
• 5. RESOLVERS
リゾルバー
• 6. A SCENARIO
シナリオ
• 7. REFERENCES and BIBLIOGRAPHY
出典および参考⽂文献
28. 28
1. STATUS OF THIS MEMO
1. 本⽂文書の位置づけ
• 概要
▫ このRFCはDNSについての紹介を⾏行行う。
– タイトルの通り「概念念と機能」について説明
▫ 詳細はRFC 1035にて⾏行行う。
29. 29
2. INTRODUCTION
2. はじめに
• 2.1. The history of domain names
ドメイン名の歴史
• 2.2. DNS design goals
DNSの設計⽬目標
• 2.3. Assumptions about usage
利利⽤用についての想定
• 2.4. Elements of the DNS
DNSの要素
31. 31
3. DOMAIN NAME SPACE and RESOURCE RECORDS
3. ドメイン名空間とリソースレコード
• 3.1. Name space specifications and
terminology
名前空間の仕様と⽤用語
• 3.2. Administrative guidelines on use
利利⽤用上の管理理ガイドライン
• 3.3. Technical guidelines on use
利利⽤用上の技術ガイドライン
• 3.4. Example name space
名前空間の例例
• 3.5. Preferred name syntax
名前の構⽂文
32. 32
3. DOMAIN NAME SPACE and RESOURCE RECORDS
3. ドメイン名空間とリソースレコード
• 3.6. Resource Records
リソースレコード
• 3.7. Queries
問い合わせ
• 3.8. Status queries (Experimental)
状態問い合わせ(実験機能)
• 3.9. Completion queries (Obsolete)
補完問い合わせ(廃⽌止機能)
33. 33
3章の位置づけ
ネームサーバー ゾーン転送 ネームサーバー ロード
(権威サーバー) (権威サーバー) マスター
ファイル
ゾーン内のリソース
メッセージ レコードを記述
ドメイン名空間
ネームサーバー
(フルサービス
リソースレコード
リゾルバー)
example.jp. IN SOA ns.exampele.jp. ..
example.jp. IN NS ns.example.jp.
メッセージ com jp
ns.example.jp. IN A 192.0.2.1
ドメイン名 タイプ
リゾルバー example example co
ns www
34. 34
3.1. Name space specifications and terminology
3.1. 名前空間の仕様と⽤用語
• ツリー構造とノード ルート
▫ ドメイン名空間はツリー構造 ノード
▫ 各ノードとリーフはリソース
の集まりに対応している
▫ 内部ノードとリーフノードを com jp
区別しない。両⽅方とも「ノー
ノード
ド」と呼ぶ。 example example co
ns www
リーフ
ノード
35. 35
3.1. Name space specifications and terminology
3.1. 名前空間の仕様と⽤用語
• ラベル ルート
ノード
▫ 各ノードは「ラベル」を持つ。 ラベル
"com"
””
▫ ラベルの⻑⾧長さは0オクテットから
63オクテットまで
▫ 兄弟ノードは同じラベルを持たな com jp
い。
▫ 兄弟でないノードは同じラベルを example example co
持てる。
▫ ルートのためにnullラベル(⻑⾧長さ ns www
0)が予約されている。
36. 36
3.1. Name space specifications and terminology
3.1. 名前空間の仕様と⽤用語
• ドメイン名
▫ ノードのドメイン名はそのノードか
らルートノードまでのパス上のラベ
ルのリスト
– 例例) "www", "example", "jp", "" com jp
example example co
ns www
37. 37
3.1. Name space specifications and terminology
3.1. 名前空間の仕様と⽤用語
• ドメイン名の内部表現
▫ ドメイン名はラベルをつなげたもの
▫ ラベルはオクテットの⻑⾧長さと⽂文字列列で表
される。
– "www"の内部表現を16進数で表すと"3
77 77 77"となる。
▫ すべてのドメイン名はルートで終わり、
ルートのラベルはnull⽂文字であるため、 com jp
内部表現はドメイン名の終わりに0バイ
トの⻑⾧長さを使う。
– www.example.jp.の内部表現 example example co
3 77 77 77 8 65 78 61 6d 70 6c 65 2
6a 70 0 ns www
• ドメイン名の⻑⾧長さ
▫ ドメイン名のオクテット数は255まで
38. 38
3.1. Name space specifications and terminology
3.1. 名前空間の仕様と⽤用語
• ⼤大⽂文字⼩小⽂文字
▫ ドメイン名の⽐比較の際には⼤大⽂文字⼩小⽂文字を区別し
ない。
▫ ドメイン名を受け取ったときには⼤大⽂文字⼩小⽂文字を
維持すべき
• RFC 4343 "Domain Name System (DNS)
Case Insensitivity Clarification"
39. 39
3.1. Name space specifications and terminology
3.1. 名前空間の仕様と⽤用語
• ドメイン名の⼊入⼒力力は表⽰示上の表現 ルート
ノード
▫ ラベルの⻑⾧長さを省省き、ラベル ””
を"."で分ける。
– 例例)www.example.jp.
▫ ドメイン名はルート(空の)ラベ com jp
ルで終わるため、ドットで終わる
形式になる。 example example co
– 例例)www.example.jp."空のラベ
ル(⾮非表⽰示)" ns www
40. 40
3.1. Name space specifications and terminology
3.1. 名前空間の仕様と⽤用語
• 絶対ドメイン名と相対ドメイン名 www.example.jp.
絶対ドメイン名
com jp
example example co
ns www
www
相対ドメイン名
41. 41
3.1. Name space specifications and terminology
3.1. 名前空間の仕様と⽤用語
• 相対ドメイン名とオリジンや検索索リ
スト
▫ 相対ドメイン名はオリジン(注:マス
ターファイルのオリジン)や検索索リス
ト(注:リゾルバーの検索索リスト)に
対して相対。 com jp
▫ オリジンや検索索リストのメンバーとし
てルート"."が解釈される。⼊入⼒力力を省省略略 example example co
するために最後の"."がよく省省かれる。
– 例例)www.example.jp ns www
– →FQDN(Fully Qualified Domain
Name、完全修飾ドメイン名)?
42. 42
3.1. Name space specifications and terminology
3.1. 名前空間の仕様と⽤用語
• FQDN(Fully Qualified Domain
Name、完全修飾ドメイン名)
▫ トップレベルドメインまでを含んだド
メイン名
– 例例: www.example.jp
▫ この⽂文法を⽰示した明確な定義はない?
▫ RFC 1594 FYI on Questions and com jp
Answers -‐‑‒ Answers to Commonly
asked "New Internet User"
Questions example example co
– 5.2 What is a Fully Qualified
Domain Name? ns www
▫ RFC 1983 Internet Users' Glossary
– Fully Qualified Domain Name
(FQDN)
48. 48
3.6. Resource Records ドメイン名空間
3.6. リソースレコード
• リソースレコード
▫ ドメイン名はノードを識識別す com jp
る。
▫ 各ノードはリソース情報の集 example example co
まりを持つ。空でもよい。
▫ 特定の名前に関連づけられた ns www
リソース情報の集まりは別々
のリソースレコード(RRs) リソースレコード
から構成される。 example.jp. IN SOA ns.exampele.jp. ..
▫ 集まりの中のRRsの順番は指 example.jp. IN NS ns.example.jp.
定できないし、維持される必
要も無い。
ns.example.jp. IN A 192.0.2.1
ドメイン名 タイプ
49. 49
3.6. Resource Records
3.6. リソースレコード
• リソースレコードの⽤用語
▫ owner(オーナー)
– そのRRがあるドメイン名
▫ type(タイプ)
– このリソースレコードのリソースのタイプを識識別する符
号化された16ビットの値。タイプは抽象的なリソースを
参照する。
– A, CNAME, HINFO, MX, NS, PTR, SOA
▫ class
– プロトコルファミリーを識識別する符号化された16ビット
の数
– IN(the Internet system), CH(the Chaos system)
50. 50
3.6. Resource Records
3.6. リソースレコード
• リソースレコードの⽤用語
▫ TTL
– RRの⽣生存期間。このフィールドは秒単位の32ビット整
数。リゾルバーがキャッシュするときに使う。TTLはRR
が破棄されるまでにキャッシュしてよい期間を⽰示す。
– RFC 2181 Clarifications to the DNS Specification
"8. Time to Live (TTL)"
– 符号無し整数
– 最⼩小値: 0
– 最⼤大値: 2147483647 (2^31 -‐‑‒ 1)
– 最上位ビットが1であるときにはTTLを0と扱うべき
▫ RDATA
– タイプとクラスに依存するデータ。
51. 51
3.6.1. Textual expression of RRs
3.6.1. RRsのテキスト表現
• RRのテキスト表現の形式
▫ RRは1⾏行行で⽰示される。複数⾏行行になる場合には括弧を使
う。
example.com. 172800 IN NS a.iana-servers.net.
example.com. 3600 IN SOA dns1.icann.org. (
hostmaster.icann.org.
2012080872 7200 3600 1209600 3600 )
▫ ⾏行行の先頭はRRのオーナー。
example.com. 172800 IN NS a.iana-servers.net.
▫ 空⽩白で始まる⾏行行は、オーナーが前のRRと同じと想定
される。
example.com. 172800 IN NS a.iana-servers.net.
172800 IN NS b.iana-servers.net.
59. 59
4. NAME SERVERS
4. ネームサーバー
• 4.1. Introduction
はじめに
• 4.2. How the database is divided into zones
データベースのゾーンの分割⽅方法
• 4.3. Name server internals
ネームサーバーの内部
60. 60
4章の位置づけ
ネームサーバー ゾーン転送 ネームサーバー ロード
(権威サーバー) (権威サーバー) マスター
ファイル
ゾーン内のリソース
メッセージ レコードを記述
ドメイン名空間
ネームサーバー
(フルサービス
リソースレコード
リゾルバー)
example.jp. IN SOA ns.exampele.jp. ..
example.jp. IN NS ns.example.jp.
メッセージ com jp
ns.example.jp. IN A 192.0.2.1
ドメイン名 タイプ
リゾルバー example example co
ns www
62. 62
4.2. How the database is divided into zones
4.2. データベースをゾーンに分割する⽅方法
• 概要
▫ データベースをゾーンに分割する⽅方法について説
明する。
63. 63
4.2. How the database is divided into zones
4.2. データベースをゾーンに分割する⽅方法
• 名前空間の分割は2つの隣隣接した
ノードの間で⾏行行われる。
▫ 左記の例例ではexampleとjpの間
• 接続された名前空間の各グループ
は別々のゾーンとなる。
• ゾーンは領領域内のすべての名前の
com jp
権威となる。
• RFC 2181 Clarifications to the
example example co
DNS Specification "6. Zone ns www
Cuts"に詳細に説明あり
64. 64
4.2.1. Technical considerations
4.2.1. 技術的な考慮
• ゾーンを記述するデータは4つの部分
を持つ
▫ ゾーン内のすべてのノードの権威デー
タ com jp
▫ ゾーンのトップノードを定義するデー
タ example example co
▫ 委任したサブゾーンを記述するデータ。
すなわち、ゾーンの最下部の切切断。 sub ns www
▫ サブゾーンのネームサーバーにアクセ
スをさせるデータ ns www
(グルー"glue"データと呼ばれる。)
72. 72
4.3.4. Negative response caching (Optional)
4.3.4. ⽐比例例応答のキャッシュ (付加機能)
• 否定応答をキャッシュすることについての説明
• 誤りあり
▫ The method is that a name server may add an
SOA RR to the additional section of a response
when that response is authoritative.
• RFC 2181 Clarifications to the DNS
Specification
"7.1. Placement of SOA RRs in authoritative
answers"により訂正
▫ リソースが存在しないときにレスポンスに含めるSOA
レコードはadditionalセクションではなくauthorityセ
クションに置く。
76. 76
5章の位置づけ
ネームサーバー ゾーン転送 ネームサーバー ロード
(権威サーバー) (権威サーバー) マスター
ファイル
ゾーン内のリソース
メッセージ レコードを記述
ドメイン名空間
ネームサーバー
(フルサービス
リソースレコード
リゾルバー)
example.jp. IN SOA ns.exampele.jp. ..
example.jp. IN NS ns.example.jp.
メッセージ com jp
ns.example.jp. IN A 192.0.2.1
ドメイン名 タイプ
リゾルバー example example co
ns www
83. 83
RFC 1035の⽬目次
• 1. STATUS OF THIS MEMO
この⽂文書の位置づけ
• 2. INTRODUCTION
はじめに
• 3. DOMAIN NAME SPACE AND RR DEFINITIONS
ドメイン名空間とリソースレコードの定義
• 4. MESSAGES
メッセージ
• 5. MASTER FILES
マスターファイル
• 6. NAME SERVER IMPLEMENTATION
ネームサーバーの実装
• 7. RESOLVER IMPLEMENTATION
リゾルバーの実装
• 8. MAIL SUPPORT
メールのサポート
• 9. REFERENCES and BIBLIOGRAPHY
出典と参考⽂文献
93. 93
2.3.1. Preferred name syntax
2.3.1. 名前の構⽂文
• 概要
▫ ドメイン名の構⽂文
▫ ラベルの構⽂文
• ドメイン名の構⽂文
▫ <domain> ::= <subdomain> | " "
▫ <subdomain> ::= <label> | <subdomain> "." <label>
▫ <label> ::= <letter> [ [ <ldh-‐‑‒str> ] <let-‐‑‒dig> ]
▫ <ldh-‐‑‒str> ::= <let-‐‑‒dig-‐‑‒hyp> | <let-‐‑‒dig-‐‑‒hyp> <ldh-‐‑‒str>
▫ <let-‐‑‒dig-‐‑‒hyp> ::= <let-‐‑‒dig> | "-‐‑‒"
▫ <let-‐‑‒dig> ::= <letter> | <digit>
▫ <letter> ::= any one of the 52 alphabetic characters A
through Z in
▫ upper case and a through z in lower case
▫ <digit> ::= any one of the ten digits 0 through 9
94. 94
2.3.1. Preferred name syntax
2.3.1. 名前の構⽂文
• ラベル
▫ ラベルはホスト名の規則に従う。
– 英⽂文字で始まる → 英⽂文字あるいは数字で始まる(RFC
1123)
– 英⽂文字あるいは数字で終わる
– 間の⽂文字は英⽂文字、数字、ハイフンが使える
▫ 当時のホスト名の仕様
– RFC 952 DOD INTERNET HOST TABLE
SPECIFICATION
▫ RFC 1123 Requirements for Internet Hosts -‐‑‒-‐‑‒
Application and Support によりホスト名の仕様が変
更更された
▫ ラベルは63⽂文字未満
98. 98
3. DOMAIN NAME SPACE AND RR DEFINITIONS
3. ドメイン名空間とRRの定義
• 3.1. Name space definitions
名前空間の定義
• 3.2. RR definitions
RRの定義
• 3.3. Standard RRs
標準のRRs
• 3.4. ARPA Internet specific RRs
Internet特有のRRs
• 3.5. IN-‐‑‒ADDR.ARPA domain
IN-‐‑‒ADDR.ARPAドメイン
• 3.6. Defining new types, classes, and special
namespaces
新しいタイプ、クラス、特別な名前空間の定義⽅方法
99. 99
3章の位置づけ
ネームサーバー ゾーン転送 ネームサーバー ロード
(権威サーバー) (権威サーバー) マスター
ファイル
ゾーン内のリソース
メッセージ レコードを記述
ドメイン名空間
ネームサーバー
(フルサービス
リソースレコード
リゾルバー)
example.jp. IN SOA ns.exampele.jp. ..
example.jp. IN NS ns.example.jp.
メッセージ com jp
ns.example.jp. IN A 192.0.2.1
ドメイン名 タイプ
リゾルバー example example co
ns www
105. 105
3.2.1. Format
3.2.1. フォーマット
• 間違い
▫ "SOA records are always distributed with a
zero TTL to prohibit caching."
• RFC 2181 Clarifications to the DNS
Specification "7.2. TTLs on SOA RRs"
▫ どこにも⾔言及されていないし、そのような実装は
⾏行行われていない。実装はTTLが0であることを想
定すべきではないし、0のTTLを持つSOAレコー
ドを送信することを要求してもいけない。
106. 106
3.2.2. TYPE values
3.2.2. TYPEの値
TYPE value meaning
A 1 a host address
NS 2 a host address
CNAME 5 the canonical name for an alias
SOA 6 marks the start of a zone of authority
WKS 11 a well known service description
PTR 12 a domain name pointer
MX 15 mail exchange
TXT 16 text strings
107. 107
3.2.3. QTYPE values
3.2.3. QTYPEの値
• QTYPEは問い合わせのquestionパートで出てくる。
• QTYPEはTYPEのスーパーセット。
• QTYPEの"MAILB"と"MAILA"は使われていない。
QTYPE value meaning
AXFR 252 A request for a transfer of an entire zone
* 255 A request for all records
108. 108
3.2.4. CLASS values
3.2.4. CLASSの値
CLASS value meaning
mnemonics
IN 1 the Internet
CS 2 the CSNET class (Obsolete)
CH 3 the CHAOS class
HS 4 Hesiod
109. 109
3.2.5. QCLASS values
3.2.5. QCLASSの値
• QCLASSは問い合わせのquestionセクションで出てくる。
• QCLASSはCLASSのスーパーセット
QCLASS value meaning
mnemonics
* 255 any class
111. 111
3.3.1. CNAME RDATA format
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
/ CNAME /
/ /
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
where:
CNAME A <domain-name> which specifies the canonical or primary
name for the owner. The owner name is an alias.
CNAME RRs cause no additional section processing, but name servers may
choose to restart the query at the canonical name in certain cases. See
the description of name server logic in [RFC-1034] for details.
112. 112
3.3.9. MX RDATA format
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
| PREFERENCE |
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
/ EXCHANGE /
/ /
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
where:
PREFERENCE A 16 bit integer which specifies the preference given to
this RR among others at the same owner. Lower values
are preferred.
EXCHANGE A <domain-name> which specifies a host willing to act as
a mail exchange for the owner name.
MX records cause type A additional section processing for the host
specified by EXCHANGE. The use of MX RRs is explained in detail in
[RFC-974].
113. 113
3.3.11. NS RDATA format
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
/ NSDNAME /
/ /
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
where:
NSDNAME A <domain-name> which specifies a host which should be
authoritative for the specified class and domain.
NS records cause both the usual additional section processing to locate
a type A record, and, when used in a referral, a special search of the
zone in which they reside for glue information.
114. 114
3.3.12. PTR RDATA format
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
/ PTRDNAME /
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
where:
PTRDNAME A <domain-name> which points to some location in the
domain name space.
PTR records cause no additional section processing. These RRs are used
in special domains to point to some other location in the domain space.
These records are simple data, and don't imply any special processing
similar to that performed by CNAME, which identifies aliases. See the
description of the IN-ADDR.ARPA domain for an example.
116. 116
3.3.13. SOA RDATA format
• MNAME
▫ このゾーンのデータのオリジナルあるいはプライ
マリであるネームサーバーのドメイン名。
▫ RFC 2181 Clarifications to the DNS
Specification "7.3. The SOA.MNAME field"
– SOAレコードのMNAMEフィールドはゾーンのマス
ターサーバの名前を設定する。
– ゾーン⾃自体の名前を書くべきではない。
117. 117
3.3.13. SOA RDATA format
• RNAME
▫ このゾーンの責任者のメールアドレス。
▫ 訳注)メールアドレスの"@"を"."に置き換える。
– 例例)"foo@example.com"は"foo.example.com"に。
• SERIAL
▫ ゾーンのオリジナルコピーの符号無し32ビット
バージョン番号。ゾーン転送はこの値を維持する。
この値は周回し、sequence space arithmeticを
使って⽐比較する。
▫ RFC 1982 Serial Number Arithmeticで⽐比較
について詳細な説明がある。
119. 119
3.3.13. SOA RDATA format
• MINIMUM
▫ このゾーンのRRを送信するときに指定されるTTL
の最⼩小値。符号無し32ビット。
▫ RFC 2308 Negative Caching of DNS
Queries (DNS NCACHE)により否定応答の
キャッシュのTTLとして再定義された。
120. 120
3.3.14. TXT RDATA format
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
/ TXT-DATA /
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
where:
TXT-DATA One or more <character-string>s.
TXT RRs are used to hold descriptive text. The semantics of the text
depends on the domain where it is found.
121. 121
3.4. Internet specific RRs
3.4.1. A RDATA format
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
| ADDRESS |
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
where:
ADDRESS A 32 bit Internet address.
Hosts that have multiple Internet addresses will have multiple A
records.
A records cause no additional section processing. The RDATA section of
an A line in a master file is an Internet address expressed as four
decimal numbers separated by dots without any imbedded spaces (e.g.,
"10.2.0.52" or "192.0.5.6").
125. 125
4章の位置づけ
ネームサーバー ゾーン転送 ネームサーバー ロード
(権威サーバー) (権威サーバー) マスター
ファイル
ゾーン内のリソース
メッセージ レコードを記述
ドメイン名空間
ネームサーバー
(フルサービス
リソースレコード
リゾルバー)
example.jp. IN SOA ns.exampele.jp. ..
example.jp. IN NS ns.example.jp.
メッセージ com jp
ns.example.jp. IN A 192.0.2.1
ドメイン名 タイプ
リゾルバー example example co
ns www
126. 126
4.1. Format
4.1. フォーマット
+---------------------+
| Header |
+---------------------+
| Question | the question for the name server
+---------------------+
| Answer | RRs answering the question
+---------------------+
| Authority | RRs pointing toward an authority
+---------------------+
| Additional | RRs holding additional information
+---------------------+
139. 139
4.2.1. UDP usage
• メッセージは512バイトに制限される。
• 512バイトより⼤大きいメッセージは切切り詰めら
れ、ヘッダーにTCビットを⽴立立てる。
• RFC 2181 Clarifications to the DNS
Specification "9 The TC (truncated) header
bit"にTCビットがどういうときにセットされる
かについての説明がある。
• RFC 2671 Extension Mechanisms for DNS
(EDNS0) により、UDPで512バイトより⼤大きい
メッセージを送ることが可能である。
140. 140
4.2.2. TCP usage
• RFC 5966 DNS Transport over TCP -‐‑‒
Implementation RequirementsによりDNS
over TCPの仕様が更更新されている。
141. 141
5. MASTER FILES
5. マスターファイル
• 5.1. Format
• 5.2. Use of master files to define zones
• 5.3. Master file example
142. 142
5章の位置づけ
ネームサーバー ゾーン転送 ネームサーバー ロード
(権威サーバー) (権威サーバー) マスター
ファイル
ゾーン内のリソース
メッセージ レコードを記述
ドメイン名空間
ネームサーバー
(フルサービス
リソースレコード
リゾルバー)
example.jp. IN SOA ns.exampele.jp. ..
example.jp. IN NS ns.example.jp.
メッセージ com jp
ns.example.jp. IN A 192.0.2.1
ドメイン名 タイプ
リゾルバー example example co
ns www
145. 145
6. NAME SERVER IMPLEMENTATION
6. ネームサーバーの実装
• 6.1. Architecture
• 6.2. Standard query processing
• 6.3. Zone refresh and reload processing
• 6.4. Inverse queries (Optional)
• 6.5. Completion queries and responses
• 本章はネームサーバーの開発者向けの内容であ
り、チュートリアルには向かない内容なので、
説明は省省略略する。
146. 146
7. RESOLVER IMPLEMENTATION
7. リゾルバーの実装
• 7.1. Transforming a user request into a
query
• 7.2. Sending the queries
• 7.3. Processing responses
• 7.4. Using the cache
• 本章はネームサーバーの開発者向けの内容であ
り、チュートリアルには向かない内容なので、
説明は省省略略する。
150. 150
RFC 1123
Requirements for Internet Hosts -‐‑‒-‐‑‒ Application and Support
• タイトル
▫ Requirements for Internet Hosts -‐‑‒-‐‑‒
Application and Support
▫ インターネットホストの要求事項 –
アプリケーションとサポート
• 概要
▫ インターネットに接続するホストが満たすべき要
求事項を定めている。
▫ もちろん、ホスト名やDNSのサポートについても
151. 151
RFC 1123
Requirements for Internet Hosts -‐‑‒-‐‑‒ Application and Support
• 2.1 Host Names and Numbers
ホスト名と数
▫ ホスト名の⽂文法の改訂(RFC 952の改訂)
– ホスト名の最初の⽂文字は英⽂文字のみであったが、数字も使える
ようになった。
– ホスト名の⻑⾧長さは24⽂文字までであったが、下記のようになっ
た。
▫ ホスト名
– 英⽂文字あるいは数字で始まる
– 英⽂文字あるいは数字で終わる
– 間の⽂文字は英⽂文字、数字、ハイフンが使える
▫ ホストソフトウェアは
– 63⽂文字までのホスト名を扱わなければならない(MUST)
– 255⽂文字までのホスト名を扱うべきである(SHOULD)
152. 152
RFC 1982
Serial Number Arithmetic
• タイトル
▫ Serial Number Arithmetic
▫ シリアル番号演算
• 概要
▫ RFC 1034とRFC 1035ではゾーン転送における
SOAレコードのシリアル番号の⽐比較に"sequence
space arithmetic"を使うと記述されている。
▫ しかし、"sequence space arithmetic"そのもの
の定義がない。
▫ RFC 1982ではその定義を⾏行行う。
154. 154
RFC 1982
Serial Number Arithmetic
• シリアル番号の保守
▫ RFC 2182 "Selection and Operation of
Secondary DNS Servers"
– "7. Serial Number Maintenance"
– 間違って⼤大きすぎる番号を付けてしまった場合に、⼩小
さい番号に付け直す⽅方法が書いてある。
155. 155
RFC 2181
Clarifications to the DNS Specification
• タイトル
▫ Clarifications to the DNS Specification
▫ DNSの仕様の明確化
• 概要
▫ この⽂文書はDNSの仕様の問題として確認されてい
る分野について考察し、確認された⽋欠陥の改善を
提案する。
156. 156
RFC 2181
Clarifications to the DNS Specification
• 4. Server Reply Source Address Selection
▫ マルチホームのサーバにおける応答の送信元アド
レスの選択⽅方法
• 4.1. UDP Source Address Selection
– 問い合わせの宛先アドレスを応答の送信元アドレス
としてセットする。
• 4.2. Port Number Selection
– 問い合わせの送信元ポート番号を応答の宛先ポート
番号として使う。
– 応答は指⽰示されたポート番号から送信される。
– DNSのウェルノウンポート、53
157. 157
RFC 2181
Clarifications to the DNS Specification
• 5. Resource Record Sets
▫ 同じラベル、クラス、タイプのリソースレコード
の集まりを「リソースレコードセット」
(RRset)と定義する。
▫ 問い合わせに対して、関連するRRが複数あるとき
には、RRsetのすべてのRRを返す。
▫ RRsetのすべてのRRは同じTTLを使う。
158. 158
RFC 2181
Clarifications to the DNS Specification
• 5.4.1. Ranking data
▫ データの信頼性の順位について論論じている。下に⾏行行くほど低い。
– Data from a primary zone file, other than glue data,
– Data from a zone transfer, other than glue,
– The authoritative data included in the answer section of an
authoritative reply.
– Data from the authority section of an authoritative answer,
– Glue from a primary zone, or glue from a zone transfer,
– Data from the answer section of a non-‐‑‒authoritative answer,
and non-‐‑‒authoritative data from the answer section of
authoritative answers,
– Additional information from an authoritative answer,
Data from the authority section of a non-‐‑‒authoritative
answer,
Additional information from non-‐‑‒authoritative answers.
159. 159
RFC 2181
Clarifications to the DNS Specification
• 6. Zone Cuts
▫ zone
▫ zone cut
▫ "child" zone
▫ "parent" zone
▫ zone's "origin"
• 6.1. Zone authority
▫ ゾーンの権威について
161. 161
RFC 2181
Clarifications to the DNS Specification
• 7.1. Placement of SOA RRs in authoritative
answers
▫ RFC 1034 "4.3.4 Negative response caching
(Optional)"の内容が間違っている。
– The method is that a name server may add an
SOA RR to the additional section of a response
when that response is authoritative.
▫ ネガティブキャッシュのときにもSOAレコードを
authorityセクションにおいて回答する。
– SOA records, if added, are to be placed in the
authority section.
162. 162
RFC 2181
Clarifications to the DNS Specification
• 7.2. TTLs on SOA RRs
▫ RFC 1035 "3.2.1. Format"の内容が間違っている。
– SOA records are always distributed with a zero TTL
to prohibit caching.
• 7.2. TTLs on SOA RRs
▫ どこにも⾔言及されていないし、そのような実装は⾏行行わ
れていない。実装はTTLが0であることを想定すべき
ではないし、0のTTLを持つSOAレコードを送信する
ことを要求してもいけない。
– This is mentioned nowhere else, and has not
generally been implemented. Implementations
should not assume that SOA records will have a
TTL of zero, nor are they required to send SOA
records with a TTL of zero.
163. 163
RFC 2181
Clarifications to the DNS Specification
• 7.3. The SOA.MNAME field
▫ 仕様では明確になっているが広く無視されている。
▫ SOAレコードのMNAMEフィールドはゾーンのマ
スターサーバの名前を設定する。
▫ ゾーン⾃自体の名前を書くべきではない。
164. 164
RFC 2181
Clarifications to the DNS Specification
• 8. Time to Live (TTL)
▫ RFC 1035におけるTTLの定義
– 2.3.4. Size limits
– positive values of a signed 32 bit number.
– 3.2.1. Format
– a 32 bit signed integer that specifies the time interval
– 4.1.3. Resource record format
– a 32 bit unsigned integer that specifies the time
interval
▫ 明確にする
– 符号無し整数
– 最⼩小値: 0
– 最⼤大値: 2147483647 (2^31 -‐‑‒ 1)
– 最上位ビットが1であるときにはTTLを0と扱うべき
167. 167
RFC 2181
Clarifications to the DNS Specification
• 10.1. CNAME resource records
▫ CNAMEの意味を明確化
– CNAME ("canonical name")「正式名」は"alias
name"「別名」と関連づけるために使う
– CNAMEは「別名」を⽰示すのでなく、「別名」に対
する「正式名」を⽰示す。
– 別名 IN CNAME 正式名
168. 168
RFC 2181
Clarifications to the DNS Specification
• 10.2. PTR records
▫ PTRレコードは⼀一つだけ持つというのは誤り。
▫ PTRレコードの値には(CNAMEで定義される)
別名であってならない。
169. 169
RFC 2181
Clarifications to the DNS Specification
• 10.3. MX and NS records
▫ MXレコードとNSレコードの値は(CNAMEで定
義される)別名であってはならない。
170. 170
RFC 2181
Clarifications to the DNS Specification
• 11. Name syntax
▫ DNSはホスト名からデータへ、IPアドレスからホ
スト名へとマッピングするためだけのものではな
い。
▫ DNSは汎⽤用的な階層型データベースであり、様々
なデータを様々な⽬目的で格納できる。
171. 171
RFC 2308
Negative Caching of DNS Queries (DNS NCACHE)
• タイトル
▫ Negative Caching of DNS Queries (DNS
NCACHE)
▫ DNS問い合わせのネガティブキャッシュ
• 概要
▫ ネガティブキャッシュについての詳細な説明と再
定義を⾏行行っている。
172. 172
RFC 2308
Negative Caching of DNS Queries (DNS NCACHE)
• RFC 1034からの変更更点(8 -‐‑‒ Changes from RFC
1034)
▫ ネガティブキャッシュはoptionalであったが、RFC
2308ではキャッシュする場合は、ネガティブキャッ
シュもしなければならないよう(must)になった。
▫ AuthorityセクションのSOAレコードはキャッシュし
なければならない(MUST)。
▫ キャッシュしたSOAレコードは応答に加えなければな
らない(MUST)。
• SOA Minimumフィールド
▫ 否定応答のTTLとして使われる。
▫ 元々別の意味で定義されていたが再定義された。
173. 173
RFC 4343
Domain Name System (DNS) Case Insensitivity Clarification
• タイトル
▫ Domain Name System (DNS) Case
Insensitivity Clarification
▫ DNSの⼤大⽂文字⼩小⽂文字を区別しないことの明確化
• 概要
▫ ドメイン名の⼤大⽂文字⼩小⽂文字を区別しない。
– ASCII⽂文字が対象
▫ この⽂文書はその意味を説明し、仕様を明確にする。
174. 174
RFC 4343
Domain Name System (DNS) Case Insensitivity Clarification
• 問い合わせにおいては⼤大⽂文字⼩小⽂文字を区別すべきで
ない。
▫ 次の2つのドメイン名の問い合わせは同じ結果となる。
– foo.example.net.
– Foo.ExamplE.net.
▫ 実装
– ⽐比較前に0x61-‐‑‒0x7Aの範囲の⽂文字(⼩小⽂文字)であれば
0x20を引く。
• ⼤大⽂文字⼩小⽂文字の維持
▫ 可能な限りオリジナルの⼤大⽂文字⼩小⽂文字を維持すべきで
ある。
175. 175
RFC 4343
Domain Name System (DNS) Case Insensitivity Clarification
• ラベルのエスケープ⽅方法
▫ DNSのプロトコル上は8ビット⽂文字も使える。
▫ ⽂文字コードが0x00-‐‑‒0x20,0x2E(.),0x7F-‐‑‒0xFFである
⽂文字をバックスラッシュでエスケープする記法
– バックスラッシュ() + ⽂文字コードの3桁の⼗十進数
– バックスラッシュ() + ⽂文字(ASCII印字可能⽂文字の場
合)
▫ 例例
– バックスラッシュ"" → "092" or ""
– ピリオド"." → "046" or "."
– スペース" " → "032"
176. 176
RFC 4343
Domain Name System (DNS) Case Insensitivity Clarification
• Use of Bit 0x20 in DNS Labels to Improve
Transaction Identity
▫ というInternet Draftがかつて提案されていた。
▫ 通称"dns 0x20"
– ⼤大⽂文字のコードに対して0x20ビットを⽴立立てると⼩小
⽂文字のコードになる。
– 0x41 (A) + 0x20 = 0x61 (a)
▫ キャッシュポイズニングへの耐性を向上させるこ
とを⽬目的とする。
▫ 問い合わせとその回答において⼤大⽂文字⼩小⽂文字を維
持する仕様を利利⽤用する。
177. 177
RFC 4343
Domain Name System (DNS) Case Insensitivity Clarification
• Use of Bit 0x20 in DNS Labels to Improve
Transaction Identity
▫ リゾルバーは問い合わせに⼤大⽂文字⼩小⽂文字をランダ
ムに設定する。
– FoO.ExAmplE.nEt.
▫ 権威サーバーは問い合わせの名前を⼤大⽂文字⼩小⽂文字
を維持したままコピーして回答する。
– FoO.ExAmplE.nEt.
▫ リゾルバーは問い合わせと回答の⽂文字列列を⽐比較し
て同じであれば信⽤用する。異異なれば偽の回答と判
断する。
178. 178
RFC 5452
Measures for Making DNS More Resilient against Forged Answers
• タイトル
▫ Measures for Making DNS More Resilient
against Forged Answers
▫ DNSを偽の回答に対する耐性の強化⽅方法
• 概要
▫ DNSを不不正な応答を受け付けることに対して耐性
を強化する⽅方法について説明する。
179. 179
RFC 5452
Measures for Making DNS More Resilient against Forged Answers
• 9.1. Query Matching Rules
▫ RFC 2181 "5.4.1. Ranking data"のDNSの信頼性規則を
適応する前に
▫ リゾルバーの実装は次のような問い合わせの属性のすべて
に、応答が⼀一致していなければならない(MUST)。
– 問い合わせの宛先アドレスに対する送信元アドレス
– 問い合わせの送信元アドレスに対する宛先アドレス
– 問い合わせの送信元ポートに対する宛先ポート
– 問い合わせID
– 問い合わせの名前
– 問い合わせのクラスとタイプ
▫ ⼀一致しない応答は不不正と判断しなければならない
(MUST)。
180. 180
RFC 5452
Measures for Making DNS More Resilient against Forged Answers
• 9.2. Extending the Q-‐‑‒ID Space by Using
Ports and Addresses
▫ リゾルバーの実装(MUST):
– 外部への問い合わせには、実際に利利⽤用できて可能な
限り⼤大きい範囲のポート番号から予測不不能な送信元
ポート番号を使う
– 同時に複数の問い合わせが起こる場合には、複数の
異異なる送信元ポート番号を使う
– 外部への問い合わせには、全範囲(0-‐‑‒65535)を利利
⽤用して、予測不不能な問い合わせIDを使う。
181. 181
RFC 5452
Measures for Making DNS More Resilient against Forged Answers
• 9.3. Spoof Detection and Countermeasure
▫ リゾルバは詐称を検出したら、UDP問い合わせを
破棄し、TCPで再発⾏行行させてもよい(MAY)
– TCPは詐称に対する耐性が強い
182. 182
RFC 5936
DNS Zone Transfer Protocol (AXFR)
• タイトル
▫ DNS Zone Transfer Protocol (AXFR)
▫ DNSのゾーン転送プロトコル (AXFR)
• 概要
▫ RFC 1034とRFC 1035におけるAXFRの定義が不不
⼗十分であり、仮定して実装しなければならないと
ころがあり、相互運⽤用性を阻害している。
▫ この⽂文書はAXFRの新しい定義である。
▫ 「新しい」は相互運⽤用できるAXFR機能の正確な
定義を記録する的な意味合いで。
183. 183
RFC 5966
DNS Transport over TCP -‐‑‒ Implementation Requirements
• タイトル
▫ DNS Transport over TCP -‐‑‒ Implementation
Requirements
▫ DNSのTCP転送 – 実装と要求事項
• 概要
▫ この⽂文書はDNSのTCPでの転送の要求事項を更更新
する。
▫ TCPサポートがSHOULDであったのをMUSTにす
る。
184. 184
RFC 5966
DNS Transport over TCP -‐‑‒ Implementation Requirements
• 4. Transport Protocol Selection
▫ すべての通常の⽬目的のDNSの実装はUDPとTCPの両⽅方
をサポートしなければならない(MUST)
– 権威サーバーの実装は、応答のサイズを⼀一つのUDPパ
ケットに収めるサイズに制限しないようにTCPをサポー
トしなければならない(MUST)。
– 再帰検索索サーバー(あるいはフォワーダー)の実装は、
TCPを利利⽤用できるサーバーからの⼤大きなサイズの応答を
TCPが利利⽤用できるクライアントに達するのを妨げないよ
うに、TCPをサポートしなければならない(MUST)。
– スタブリゾルバーの実装は、⾃自⾝身のクライアントと上流流
のサーバーとの相互運⽤用性を制限しないように応答サイ
ズを、TCPをサポートしなければならない(MUST)。
185. 185
DNSの基本仕様およびアップデート(再掲)
RFC 1982 / PS RFC 4343 / PS
Serial Number Arithmetic Domain Name System
(DNS) Case Insensitivity
Clarification
RFC 1034 / STD 13
DOMAIN NAMES -‐‑‒
CONCEPTS AND RFC 2181 / PS
FACILITIES Clarifications to the DNS RFC 5452 / PS
Specification Measures for Making DNS
More Resilient against
RFC 1035 / STD 13
DOMAIN NAMES -‐‑‒ Forged Answers
IMPLEMENTATION AND
SPECIFICATION RFC 2308 / PS
Negative Caching of DNS RFC 5936 / PS
Queries (DNS NCACHE) DNS Zone Transfer
RFC 1123 / STD 3 Protocol (AXFR)
Requirements for Internet
Hosts -‐‑‒-‐‑‒ Application and
Support
RFC 3425 / PS
Obsoleting IQUERY RFC 5966 / PS
アップデート DNS Transport over TCP -‐‑‒
Implementation
参照 Requirements
187. 187
RFC 2671
Extension Mechanisms for DNS (EDNS0)
• タイトル
▫ Extension Mechanisms for DNS (EDNS0)
▫ DNSの拡張機構(EDNS0)
• 概要
▫ DNSのプロトコルを機能する。
▫ これにより、UDPで512オクテットを超えるメッ
セージを扱うことができる。
188. 188
RFC 1995
Incremental Zone Transfer in DNS
• タイトル
▫ Incremental Zone Transfer in DNS
▫ DNSの差分ゾーン転送
• 概要
▫ DNSのプロトコルにIXFR(差分ゾーン転送)機
能を提供するための拡張を提案する。
189. 189
RFC 1996
A Mechanism for Prompt Notification of Zone Changes (DNS NOTIFY)
• タイトル
▫ A Mechanism for Prompt Notification of Zone
Changes (DNS NOTIFY)
▫ ゾーン変更更の通知機能(DNS NOTIFY)
• 概要
▫ マスターサーバーがスレーブサーバーにゾーンの
変更更を通知するNOTIFY opcodeを提案する。
190. 190
RFC 2845
Secret Key Transaction Authentication for DNS (TSIG)
• タイトル
▫ Secret Key Transaction Authentication for
DNS (TSIG)
▫ DNSの秘密鍵によるトランザクション認証
(TSIG)
• 概要
▫ 共有秘密鍵を⼀一⽅方向ハッシュを使ったトランザク
ションレベルの認証を提案する。
191. 191
RFC 3645
Generic Security Service Algorithm for Secret Key Transaction
Authentication for DNS (GSS-‐‑‒TSIG)
• タイトル
▫ Generic Security Service Algorithm for Secret
Key Transaction Authentication for DNS
(GSS-‐‑‒TSIG)
▫ DNSの秘密鍵トランザクション認証のための
GSS-‐‑‒API(GSS-‐‑‒TSIG)
• 概要
▫ TSIGでGSS-‐‑‒APIを使う拡張を提案する。
193. 193
RFC 2136
Dynamic Updates in the Domain Name System (DNS UPDATE)
• タイトル
▫ Dynamic Updates in the Domain Name
System (DNS UPDATE)
▫ DNSにおける動的更更新(DNS UPDATE)
• 概要
▫ UPDATE opcodeを使って、指定したゾーンのRR
やRRsetの追加や削除を⾏行行う⽅方法を提案する。
194. 194
RFC 3007
Secure Domain Name System (DNS) Dynamic Update
• タイトル
▫ Secure Domain Name System (DNS)
Dynamic Update
▫ セキュアなDNS動的更更新
• 概要
▫ DNS動的更更新に認証機能を追加する。