大网数据广告活动
服务器运维问答

Should (or can) master and slave DNS servers have different RRSIG entries?

· 52CE 我爱测

I've just configured DNSSEC on my master DNS server and in testing with dig from each server to the other, I found that while each server had RRSIG entries they were different. Is this expected behaviour? I see that each server h…

问题原文

原帖链接 · John Moffitt · CC BY-SA 4.0

I've just configured DNSSEC on my master DNS server and in testing with dig from each server to the other, I found that while each server had RRSIG entries they were different.

Is this expected behaviour? I see that each server has different times in the signature, so is that causing it? Is this even an issue?

master result:

example.com.           600 IN RRSIG NS 5 2 600 (
                                20181225201200 20181125193702 47985 example.com.
                                PNY/8BLZrBZ6Ax27MsblQg/QGPyIrS/uK/xAJY9DXw+s
                                nexXcvRXbEG+3E4yotVtay/ACN4+qMto4Ny87yyM7XFI
                                t0cBHnRx6n1DqU0jX0ARNWWDjaNRW/PlYrTKeqyXesVj
                                Cew44FJDXSd+65PxFlvQRDw6ZIdSbDYdXF1OYMw= )

slave result:

example.com.           600 IN RRSIG NS 5 2 600 (
                                20181225193928 20181125191401 47985 example.com.
                                b034jrblNOi/Rmm7o34pRMLwH2Qa4dPuJ7ssTGWam/7z
                                b8JTaCtgKwrglzBXzcGaUfcxfCTNeBV0o6HXDvQ7kmx4
                                pZVt8Igvsw/ansIJOsvG+k+nS+ZHTACsgFaOgOegTnNb
                                +SMspj5n54s/mdMhAMreMKYXBPyVEfN0PFVv574= )

已采纳解答

原帖链接 · Patrick Mevzek · CC BY-SA 4.0

This is expected: it is expected that if anything changes in the record, like begin/end dates then the signature itself will change as it is computed over it. It may or may not be expected to see different RRSIG reports at different nameservers of a zone, but this depends a lot on the setup and here it is not described in enough details.

But it happens, see the following.

Same key (key tag 34505) but each one of the 5 authoritative nameservers provide a different RRSIG (if you compare the sleep for 2 seconds with the signature inception timestamp you can see they are computed on-line at the time of query):

$ for ns in `dig NS cloudflare.com. +short` ; do echo -n $ns " " ; dig @$ns cloudflare.com. A +dnssec +short|grep ' 34505 '; sleep 2s; done
ns4.cloudflare.com.  A 13 2 600 20190412164722 20190410144722 34505 cloudflare.com. i7WphUbWNj+0sfA0Mp3gLueKvgDvTDF+p4HuD/x+Weu1Cuglp7Cmx/v/ b0icIaYNsUKzm6OCgDnGQNH27SD8lg==
ns5.cloudflare.com.  A 13 2 600 20190412164724 20190410144724 34505 cloudflare.com. L9/aRuVFtDunNqowLBgYZzahiWhTw7Y82LeEdseBL0ZgJlQSZj8YjB36 Dj89ozZ4KK6zRxPbFmM5VRwwV/rI3Q==
ns7.cloudflare.com.  A 13 2 600 20190412164726 20190410144726 34505 cloudflare.com. khYsYMwEwH/2obxbibonU0gYveHknrtU+pZ6CFr7sLhV2Xv7/DaTKwM7 ABI2mxApVKlEhEz3rQG6XKg/6MPKFg==
ns6.cloudflare.com.  A 13 2 600 20190412164728 20190410144728 34505 cloudflare.com. gJZXNyYpTe7WqjJwaA08M/2ysFkoHze5GEV/XpoWU/y6pOLmt4DhzL4I e/PuEvWQ6agBvtdqzGzSb10p6DQx1A==
ns3.cloudflare.com.  A 13 2 600 20190412164730 20190410144730 34505 cloudflare.com. N0DwRjQKkagAoWn4WuFekvKhPL/juxzGrrn/lOEOpX7Sqmmt+ibaZJf/ YTsSFPtuCgI2hdMBvr/+b9B6rjv4Bg==

The RRSIG record's signature is computed over everything you see (except the signature itself of course), including hence the owner (that is the domain name on the left) as well as the record types (NS here), algorithm (5 which is "Elliptic Curve [ECC]"), number of label (2 because example.com has 2 labels), original TTL (600), signature expiration (20181225193928) and signature inception (20181125191401), keytag (47985) and signer's name (example.com). Plus the data in the record being signed (that is the whole content of example.com. NS resource record set)

See RFC 4034 that defines the RRSIG record.

Section 3.1 shows:

+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|        Type Covered           |  Algorithm    |     Labels    |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                         Original TTL                          |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                      Signature Expiration                     |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                      Signature Inception                      |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|            Key Tag            |                               /
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+         Signer's Name         /
/                                                               /
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
/                                                               /
/                            Signature                          /
/                                                               /
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

and 3.1.8 says:

The Signature field contains the cryptographic signature that covers
the RRSIG RDATA (excluding the Signature field) and the RRset
specified by the RRSIG owner name, RRSIG class, and RRSIG Type
Covered field. The format of this field depends on the algorithm in
use, and these formats are described in separate companion documents.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2018-11-26)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。