Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NSEC3 and multiple key signing support. #416

Open
wants to merge 410 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
410 commits
Select commit Hold shift + click to select a range
57d20d9
[validate] Correct bit offsets for flags
bal-e Oct 16, 2024
f37c862
[validate] Implement support for digests
bal-e Oct 16, 2024
7f01a5f
[validate] Enhance BIND format conversion for 'Key'
bal-e Oct 18, 2024
b4103a3
[sign] Introduce 'SigningKey'
bal-e Oct 20, 2024
81720c3
[sign] Handle errors more responsibly
bal-e Oct 21, 2024
1e00479
[sign] correct doc link
bal-e Oct 21, 2024
d26a433
[sign/openssl] Replace panics with results
bal-e Oct 23, 2024
6968cb9
remove 'sign/key'
bal-e Oct 23, 2024
99cb9ef
[sign] Introduce 'common' for abstracting backends
bal-e Oct 24, 2024
8321d50
[sign/generic] add top-level doc comment
bal-e Oct 24, 2024
a25be56
[validate] debug bind format errors
bal-e Oct 24, 2024
59650a4
[validate] more debug statements
bal-e Oct 24, 2024
0f54a8d
[validate] format DNSKEYs using 'ZonefileFmt'
bal-e Oct 24, 2024
5a3de59
Reorganize crate features in 'Cargo.toml'
bal-e Oct 25, 2024
12a70af
[sign] Add key generation support for Ring
bal-e Oct 25, 2024
2f2fb58
[sign] Make OpenSSL support optional
bal-e Oct 25, 2024
e0d68ca
FIX: DNSKEY RRs must also be canonically ordered before signing.
ximon18 Oct 28, 2024
60cff58
Extend test file with records useful for manual testing of NSEC3.
ximon18 Oct 28, 2024
735712c
Merge branch 'dnssec-key' into initial-nsec3-generation
ximon18 Oct 28, 2024
a4316b5
[sign] Rename 'generic::SecretKey' to 'KeyBytes'
bal-e Oct 29, 2024
e0a4fc0
[sign] Rename 'SecretKey' to 'KeyPair' in all impls
bal-e Oct 29, 2024
31462cc
Merge branch 'main' into dnssec-key
bal-e Oct 29, 2024
eb2ac06
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Oct 29, 2024
eaea464
Merge fixes missed from the last commit.
ximon18 Oct 29, 2024
4447cc6
Merge branch 'dnssec-key' into initial-nsec3-generation
ximon18 Oct 29, 2024
5200cfa
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Oct 29, 2024
48e178a
[sign] Rename 'KeyBytes' to 'SecretKeyBytes'
bal-e Oct 29, 2024
daa96d8
[validate] Rename 'RawPublicKey' to 'PublicKeyBytes'
bal-e Oct 29, 2024
d84e2c0
Merge branch 'dnssec-key' into initial-nsec3-generation
ximon18 Oct 29, 2024
438af22
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Oct 29, 2024
221f163
[sign/ring] Remove redundant imports
bal-e Oct 29, 2024
02c625b
Merge branch 'dnssec-key' into initial-nsec3-generation
ximon18 Oct 29, 2024
6f992d8
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Oct 29, 2024
6d3a602
Clippy.
ximon18 Oct 29, 2024
61bc3aa
[sign,validate] Add 'display_as_bind()' to key bytes types
bal-e Oct 30, 2024
55716a4
[sign,validate] remove unused imports
bal-e Oct 30, 2024
f6c8c7e
Emulate ldns-signzone -p behaviour: set NSEC3 opt-out flag but includ…
ximon18 Oct 30, 2024
8bf2c9f
Move nsec3_hash() back into the validator module per review feedback.
ximon18 Oct 30, 2024
beb8e52
Move nsec3_hash() to the validate (not validator!) module per review …
ximon18 Oct 30, 2024
7831260
[sign] Document everything
bal-e Oct 31, 2024
a04c917
Extend test file with records useful for manual testing of NSEC3.
ximon18 Oct 28, 2024
abaab27
Revert "Extend test file with records useful for manual testing of NS…
ximon18 Oct 31, 2024
7a6ec53
Review feedback.
ximon18 Oct 31, 2024
d59eab9
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Oct 31, 2024
3c53e9e
Review feedback.
ximon18 Oct 31, 2024
50433f0
Review feedback.
ximon18 Oct 31, 2024
890cd30
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Oct 31, 2024
70e998a
Review feedback inspired change (though not actually what was suggest…
ximon18 Oct 31, 2024
cefb5c1
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Oct 31, 2024
de7c13f
Add a note to self about tests to add.
ximon18 Nov 1, 2024
7e9977e
More ENT NSEC3 cases to handle.
ximon18 Nov 1, 2024
89a18b8
Merge branch 'dnssec-key' into initial-nsec3-generation
ximon18 Nov 2, 2024
443fc1d
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Nov 2, 2024
7c9ee4c
[lib] Rewrite feature flag documentation
bal-e Nov 4, 2024
cea9ae3
[workflows/ci] Use 'apt-get' instead of 'apt'
bal-e Nov 4, 2024
354bf0a
[sign] Clarify documentation as per @ximon18
bal-e Nov 4, 2024
ca10361
[sign] Use 'secrecy' to protect private keys
bal-e Nov 4, 2024
9268dd3
Display NSEC3 without trailing space if the bitmap is empty.
ximon18 Nov 4, 2024
fb7e9ef
Backport NSEC3 improvements and upstream dnssec-key branch compatibil…
ximon18 Nov 4, 2024
414ea6c
[sign,validate] Add 'display_as_bind()' to key bytes types
bal-e Oct 30, 2024
2bde7aa
[sign,validate] remove unused imports
bal-e Oct 30, 2024
98db88b
[sign] Document everything
bal-e Oct 31, 2024
8877c22
Update to work with changes in the upstream dnssec-key branch using a…
ximon18 Nov 4, 2024
40d65ac
Minor tweaks.
ximon18 Nov 4, 2024
c0fc11b
Merge branch 'dnssec-key' into initial-nsec3-generation
ximon18 Nov 4, 2024
b2158ab
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Nov 4, 2024
bdeddde
Add some Arbitrary impls to support cargo-fuzz based fuzz testing.
ximon18 Nov 6, 2024
f2cabc3
Impl Display for Nsec3HashError.
ximon18 Nov 6, 2024
109370d
Cargo fmt.
ximon18 Nov 6, 2024
0c26d94
Use a writer interface for write_with_comments().
ximon18 Nov 6, 2024
588fd0f
Fix test broken by changed input file.
ximon18 Nov 6, 2024
9cad710
Add do not add used keys to zone support.
ximon18 Nov 7, 2024
06a9f0d
Add SortedRecords::replace_soa().
ximon18 Nov 7, 2024
e1c1db8
Merge branch 'main' into initial-nsec3-generation
ximon18 Nov 8, 2024
0a79594
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Nov 8, 2024
42cbd0d
Cargo format
mozzieongit Nov 20, 2024
90aae20
Implement FromStr for zonemd Scheme and Algorithm
mozzieongit Nov 20, 2024
d390d15
Use std::fmt::Write instead of std::io::Write.
ximon18 Nov 21, 2024
e591121
Proof of concept, expected to be replaced by a better impl (a) as a s…
ximon18 Nov 22, 2024
b2a2169
Cargo fmt.
ximon18 Nov 22, 2024
250b52e
Merge branch 'main' into initial-nsec3-generation
tertsdiepraam Nov 22, 2024
0830acd
Impl Clone for Family.
ximon18 Nov 22, 2024
6b84742
Merge branch 'multiple-key-signing' into support-zonefile-fmt-with-pa…
ximon18 Nov 22, 2024
19d8d88
Bring your own signing sort impl. Allows consumers to e.g. use Rayon …
ximon18 Nov 25, 2024
a3bac8d
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Nov 25, 2024
b9782c3
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Nov 25, 2024
7890d47
Add SortedRecords record deletion and rrsig replace methods
mozzieongit Nov 27, 2024
4808c70
Return bool from record removal methods
mozzieongit Nov 27, 2024
19fac46
Clippy
mozzieongit Nov 27, 2024
967c628
Breaking change: Update ZONEMD IANA types to use the iana macros to b…
ximon18 Nov 29, 2024
2712529
Merge branch 'zonemd-from-str' into sortedrecords-zonemd-remove-replace
ximon18 Nov 29, 2024
75145f5
Merge branch 'main' into multiple-key-signing
ximon18 Nov 29, 2024
d3b9b55
Merge branch 'multiple-key-signing' into sortedrecords-zonemd-remove-…
ximon18 Nov 29, 2024
ed76ca9
Revert "Merge branch 'main' into multiple-key-signing"
ximon18 Nov 29, 2024
fef3fd5
Merge branch 'main' into initial-nsec3-generation
ximon18 Nov 29, 2024
f844bb2
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Nov 29, 2024
b0d14ed
Revert "Merge branch 'multiple-key-signing' into sortedrecords-zonemd…
ximon18 Nov 29, 2024
c71434e
Revert "Merge branch 'zonemd-from-str' into sortedrecords-zonemd-remo…
ximon18 Nov 29, 2024
82e7d2d
Merge branch 'multiple-key-signing' into sortedrecords-zonemd-remove-…
ximon18 Nov 29, 2024
f1f5417
Merge branch 'main' into initial-nsec3-generation
ximon18 Nov 29, 2024
6272b89
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Nov 29, 2024
df4992f
Merge branch 'multiple-key-signing' into sortedrecords-zonemd-remove-…
ximon18 Nov 29, 2024
498970c
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Nov 29, 2024
d733a4e
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Nov 29, 2024
48d26d8
Merge PR #444 branch zonemd-from-str into this branch.
ximon18 Dec 2, 2024
5ede42e
IANA ZONEMD algorithm mnemonics are not hyphenated.
ximon18 Dec 2, 2024
a654d95
Base use of extra signing keys on a flag, not hard-coded behaviour.
ximon18 Dec 2, 2024
c4f291d
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 2, 2024
bf3f589
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 2, 2024
727b4c3
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 2, 2024
77b32e3
Clippy.
ximon18 Dec 2, 2024
1d3261d
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 2, 2024
2136e47
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 2, 2024
5e135ce
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 2, 2024
2de0e44
Add the signature validity period to SigningKey as "important metadat…
ximon18 Dec 3, 2024
685a402
- Move sign() out of SortedRecords into a new Signer type and have it…
ximon18 Dec 3, 2024
5d4c013
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 3, 2024
b10cc2e
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 3, 2024
39e1c9d
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 3, 2024
89eb673
Cargo fmt.
ximon18 Dec 3, 2024
323a14a
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 3, 2024
62f0199
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 3, 2024
af37a8e
Delete commented out code.
ximon18 Dec 3, 2024
9f70052
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 3, 2024
94b0de2
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 3, 2024
f784b9c
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 3, 2024
ab9b219
Revert tabbed output changes in preparation to use the PR #446 approa…
ximon18 Dec 3, 2024
3ce8640
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 3, 2024
7aac5ed
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 3, 2024
623f491
Adjust key usage strategy to support LDNS default behaviour of use ZS…
ximon18 Dec 5, 2024
3efb65e
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 5, 2024
9607ba0
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 5, 2024
9325956
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 5, 2024
8c2b140
Rename strategy fns to refer to what they are selecting more accurately.
ximon18 Dec 5, 2024
12c252f
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 5, 2024
e4a5bf9
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 5, 2024
b9f9b4a
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 5, 2024
ad795a9
Merge branch 'main' into initial-nsec3-generation
ximon18 Dec 5, 2024
33178c2
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Dec 5, 2024
10193c7
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 5, 2024
5f6f7e7
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 5, 2024
254b52f
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 5, 2024
bc68b0b
Make key selection more flexible. (#464)
ximon18 Dec 6, 2024
c7f26ac
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 6, 2024
6b7321c
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 6, 2024
64da561
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 6, 2024
7503455
Merge branch 'main' into initial-nsec3-generation
ximon18 Dec 6, 2024
15b72c0
Add a tab before the RDATA as well as within it, to match LDNS tabbed…
ximon18 Dec 6, 2024
5c23fdb
Update changelog.
ximon18 Dec 6, 2024
c141bf9
Add a tab before the RDATA as well as within it, to match LDNS tabbed…
ximon18 Dec 6, 2024
660d2f2
Update changelog.
ximon18 Dec 6, 2024
8c583b5
Add a tab before the RDATA as well as within it, to match LDNS tabbed…
ximon18 Dec 6, 2024
8f97bd3
Update changelog.
ximon18 Dec 6, 2024
85ffaf7
Add a tab before the RDATA as well as within it, to match LDNS tabbed…
ximon18 Dec 6, 2024
254dc9c
Update changelog.
ximon18 Dec 6, 2024
2359531
Raise errors instead of unwrapping on missing apex.
ximon18 Dec 7, 2024
f788ba5
Add a logging related TODO.
ximon18 Dec 7, 2024
dc79547
Also log the key tag when debug logging the keys to use for signing.
ximon18 Dec 7, 2024
02f64a4
Don't emit duplicate DNSKEY RRs for zonefiles that already contain th…
ximon18 Dec 7, 2024
ca982a4
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 7, 2024
68d7141
FIX: When extending SortedRecords, don't permit duplicate RRs to cree…
ximon18 Dec 7, 2024
200f0bb
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 7, 2024
31fabac
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 7, 2024
9c1cd42
Don't attempt to sign a zone or select keys to use if no keys are pro…
ximon18 Dec 9, 2024
80007c3
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 9, 2024
7f1bcb9
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 9, 2024
55c6975
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 9, 2024
99d4fcc
Improve signing keys debug output.
ximon18 Dec 9, 2024
b92f2f4
FIX: Only sign the apex if given the apex and remove unnecessary erro…
ximon18 Dec 9, 2024
69e8415
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 9, 2024
29cc4a1
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 9, 2024
9c82849
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 9, 2024
2a80b17
Actually check that we were given THE apex, not AN apex.
ximon18 Dec 9, 2024
518b4d7
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 9, 2024
2a956f7
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 9, 2024
23031e5
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 9, 2024
605efe6
Extend zone parsing to let the caller know when the origin has been d…
ximon18 Dec 12, 2024
493e870
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 12, 2024
3320bc9
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 12, 2024
7ff0cf8
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 12, 2024
f7b9351
Revert "Extend zone parsing to let the caller know when the origin ha…
ximon18 Dec 12, 2024
0a71293
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 12, 2024
529e6e6
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 12, 2024
0600feb
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 12, 2024
c0016c1
Use the correct TTL for added DNSKEY RRs when signing.
ximon18 Dec 16, 2024
8ba17e9
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 16, 2024
931d134
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 16, 2024
54ab872
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 16, 2024
b17fb85
FIX: Don't allow duplicate RRs to be imported via `impl From`.
ximon18 Dec 16, 2024
ed4fb30
Add a comment explaining why the apex name we use for an RRSIG meets …
ximon18 Dec 16, 2024
9aa7f7c
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 16, 2024
d3b3da5
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 16, 2024
d124294
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 16, 2024
c93eae7
Merge branch 'main' into initial-nsec3-generation
ximon18 Dec 16, 2024
bb0945a
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Dec 16, 2024
8aadb43
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 16, 2024
aeb6d93
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 16, 2024
c5c422d
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 16, 2024
2034f32
FIX: Sign a merged DNSKEY RR set containing existing and new DNSKEY R…
ximon18 Dec 17, 2024
9cb5d8d
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 17, 2024
d863dba
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 17, 2024
d6a3f1d
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 17, 2024
398e70b
Clippy-suggested code improvements.
partim Dec 18, 2024
f00acc6
WIP: Use a hash provider.
ximon18 Dec 18, 2024
ae94056
Update changelog.
partim Dec 18, 2024
f0d383e
[zonefile/inplace] Handle backslashes in quoted strings
ximon18 Dec 18, 2024
3943d26
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 18, 2024
7deffd0
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 18, 2024
bd7f436
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 18, 2024
a9aa52c
Merge branch 'main' into initial-nsec3-generation
ximon18 Dec 18, 2024
8d53906
Merge branch 'initial-nsec3-generation' into multiple-key-signing
ximon18 Dec 18, 2024
6586302
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 18, 2024
3319ec6
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 18, 2024
e4a3aec
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 18, 2024
1342d4c
FIX: Don't omit DNSKEY RRs when signing if there were no pre-exisitng…
ximon18 Dec 18, 2024
29105f5
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 18, 2024
dd120bc
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 18, 2024
8af5518
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 18, 2024
222d862
Don't hard-code NSEC3 hash capture, instead use a HashProvider.
ximon18 Dec 18, 2024
427dd83
Merge branch 'multiple-key-signing' into byo-signing-sorter-impl
ximon18 Dec 19, 2024
072cc4c
Merge branch 'byo-signing-sorter-impl' into sortedrecords-zonemd-remo…
ximon18 Dec 19, 2024
a98182b
Merge branch 'sortedrecords-zonemd-remove-replace' into sortedrecords…
ximon18 Dec 19, 2024
8911c93
Cargo fmt.
ximon18 Dec 19, 2024
4ad8177
Merge branch 'sortedrecords-zonemd-remove-replace-plus-pr444' into so…
ximon18 Dec 19, 2024
822c95a
Enhanced zone signing. (#418)
ximon18 Dec 19, 2024
4c96f94
Merge branch 'multiple-key-signing' into initial-nsec3-generation
ximon18 Dec 19, 2024
ea56b58
Merge branch 'main' into initial-nsec3-generation
ximon18 Dec 20, 2024
40c678c
Correct outdated code comment.
ximon18 Dec 27, 2024
7165146
Improved/additional logging during NSEC3 generation.
ximon18 Dec 27, 2024
e0cd687
Remove commented out code.
ximon18 Dec 27, 2024
f6df4fb
Make signing work with any objects as keys as long as they can answer…
ximon18 Jan 1, 2025
340a70a
Minor import cleanup.
ximon18 Jan 1, 2025
a4492ce
Comment tweaks.
ximon18 Jan 1, 2025
880f334
FIX: Neither NSEC and NSEC3 nor hashing should include non-authoritat…
ximon18 Jan 1, 2025
c90026d
Add Rtype::is_pseudo() for use by NSEC and NSEC3 logic.
ximon18 Jan 2, 2025
03b70ca
Implement MUST constraints from RFC 4034 and RFC 5155 excluding "pseu…
ximon18 Jan 2, 2025
844418e
Replace the Signer with access to signing via new traits SignableZone…
ximon18 Jan 5, 2025
35609cc
Cargo fmt.
ximon18 Jan 5, 2025
e663e65
Fix doc tests.
ximon18 Jan 5, 2025
b868b42
RustDoc fix.
ximon18 Jan 6, 2025
c2f1fbd
Better generic type name.
ximon18 Jan 6, 2025
6162b72
More descriptive and consistent fn name.
ximon18 Jan 6, 2025
28e2144
Add sorted_records::as_slice().
ximon18 Jan 6, 2025
0dbeffb
Also allow RRsets to be signed via trait fn which is simpler than cal…
ximon18 Jan 6, 2025
79d5b91
Clippy.
ximon18 Jan 6, 2025
e6d0844
FIX: Add missing required dependency to fix broken compilation of the…
ximon18 Jan 6, 2025
33beefe
Take out references to BIND and LDNS.
ximon18 Jan 6, 2025
fc29943
De-duplicate SignableZone::sign_zone() and SignableZoneInPlace::sign_…
ximon18 Jan 6, 2025
2e761c1
Remove the confusnig OctsMut generic type.
ximon18 Jan 6, 2025
ceab294
Default TTL for newly created non-NSEC(3) RRs should be that of the S…
ximon18 Jan 6, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ zonefile = ["bytes", "serde", "std"]
# Unstable features
unstable-client-transport = ["moka", "net", "tracing"]
unstable-server-transport = ["arc-swap", "chrono/clock", "libc", "net", "siphasher", "tracing"]
unstable-sign = ["std", "dep:secrecy", "unstable-validate", "time/formatting"]
unstable-sign = ["std", "dep:secrecy", "unstable-validate", "time/formatting", "tracing"]
unstable-stelline = ["tokio/test-util", "tracing", "tracing-subscriber", "tsig", "unstable-client-transport", "unstable-server-transport", "zonefile"]
unstable-validate = ["bytes", "std", "ring"]
unstable-validator = ["unstable-validate", "zonefile", "unstable-client-transport"]
Expand Down
2 changes: 0 additions & 2 deletions Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,6 @@ Other changes
[#396]: https://github.com/NLnetLabs/domain/pull/396
[#417]: https://github.com/NLnetLabs/domain/pull/417
[#421]: https://github.com/NLnetLabs/domain/pull/421
[#424]: https://github.com/NLnetLabs/domain/pull/424
[#425]: https://github.com/NLnetLabs/domain/pull/425
[#427]: https://github.com/NLnetLabs/domain/pull/427
[#440]: https://github.com/NLnetLabs/domain/pull/440
[#441]: https://github.com/NLnetLabs/domain/pull/441
Expand Down
62 changes: 18 additions & 44 deletions examples/client-transports.rs
Original file line number Diff line number Diff line change
@@ -1,20 +1,25 @@
//! Using the `domain::net::client` module for sending a query.
use domain::base::{MessageBuilder, Name, Rtype};
use domain::net::client::protocol::{TcpConnect, TlsConnect, UdpConnect};
use domain::net::client::request::{
RequestMessage, RequestMessageMulti, SendRequest,
};
use domain::net::client::{
cache, dgram, dgram_stream, load_balancer, multi_stream, redundant,
stream,
};
/// Using the `domain::net::client` module for sending a query.
use std::net::{IpAddr, SocketAddr};
use std::str::FromStr;
#[cfg(feature = "unstable-validator")]
use std::sync::Arc;
use std::time::Duration;
use std::vec::Vec;

use domain::base::MessageBuilder;
use domain::base::Name;
use domain::base::Rtype;
use domain::net::client::cache;
use domain::net::client::dgram;
use domain::net::client::dgram_stream;
use domain::net::client::multi_stream;
use domain::net::client::protocol::{TcpConnect, TlsConnect, UdpConnect};
use domain::net::client::redundant;
use domain::net::client::request::{
RequestMessage, RequestMessageMulti, SendRequest,
};
use domain::net::client::stream;

#[cfg(feature = "tsig")]
use domain::net::client::request::SendRequestMulti;
#[cfg(feature = "tsig")]
Expand Down Expand Up @@ -201,9 +206,9 @@ async fn main() {
});

// Add the previously created transports.
redun.add(Box::new(udptcp_conn.clone())).await.unwrap();
redun.add(Box::new(tcp_conn.clone())).await.unwrap();
redun.add(Box::new(tls_conn.clone())).await.unwrap();
redun.add(Box::new(udptcp_conn)).await.unwrap();
redun.add(Box::new(tcp_conn)).await.unwrap();
redun.add(Box::new(tls_conn)).await.unwrap();

// Start a few queries.
for i in 1..10 {
Expand All @@ -216,37 +221,6 @@ async fn main() {

drop(redun);

// Create a transport connection for load balanced connections.
let (lb, transp) = load_balancer::Connection::new();

// Start the run function on a separate task.
let run_fut = transp.run();
tokio::spawn(async move {
run_fut.await;
println!("load_balancer run terminated");
});

// Add the previously created transports.
let mut conn_conf = load_balancer::ConnConfig::new();
conn_conf.set_max_burst(Some(10));
conn_conf.set_burst_interval(Duration::from_secs(10));
lb.add("UDP+TCP", &conn_conf, Box::new(udptcp_conn))
.await
.unwrap();
lb.add("TCP", &conn_conf, Box::new(tcp_conn)).await.unwrap();
lb.add("TLS", &conn_conf, Box::new(tls_conn)).await.unwrap();

// Start a few queries.
for i in 1..10 {
let mut request = lb.send_request(req.clone());
let reply = request.get_response().await;
if i == 2 {
println!("load_balancer connection reply: {reply:?}");
}
}

drop(lb);

// Create a new datagram transport connection. Pass the destination address
// and port as parameter. This transport does not retry over TCP if the
// reply is truncated. This transport does not have a separate run
Expand Down
2 changes: 1 addition & 1 deletion examples/keyset.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! Demonstrate the use of key sets.
use domain::base::Name;
use domain::sign::keyset::{
use domain::sign::keys::keyset::{
Action, Error, KeySet, KeyType, RollType, UnixTime,
};
use itertools::{Either, Itertools};
Expand Down
2 changes: 2 additions & 0 deletions src/base/iana/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ pub use self::rcode::{OptRcode, Rcode, TsigRcode};
pub use self::rtype::Rtype;
pub use self::secalg::SecAlg;
pub use self::svcb::SvcParamKey;
pub use self::zonemd::{ZonemdAlg, ZonemdScheme};

#[macro_use]
mod macros;
Expand All @@ -49,3 +50,4 @@ pub mod rcode;
pub mod rtype;
pub mod secalg;
pub mod svcb;
pub mod zonemd;
17 changes: 17 additions & 0 deletions src/base/iana/rtype.rs
Original file line number Diff line number Diff line change
Expand Up @@ -440,4 +440,21 @@ impl Rtype {
pub fn is_glue(&self) -> bool {
matches!(*self, Rtype::A | Rtype::AAAA)
}

/// Returns true if this record type represents a pseudo-RR.
///
/// The term "pseudo-RR" appears in [RFC
/// 9499](https://datatracker.ietf.org/doc/rfc9499/) Section 5 "Resource
/// Records" as an alias for "meta-RR" and is referenced by [RFC
/// 4034](https://datatracker.ietf.org/doc/rfc4034)/) in the context of
/// NSEC to denote types that "do not appear in zone data", with [RFC
/// 5155](https://datatracker.ietf.org/doc/rfc5155/) having text with
/// presumably the same goal but defined in terms of "META-TYPE" and
/// "QTYPE", the latter collectively being defined by [RFC
/// 2929](https://datatracker.ietf.org/doc/rfc2929/) and later as having
/// the decimal range 128 - 255 but with section 3.1 explicitly noting OPT
/// (TYPE 41) as an exception.
pub fn is_pseudo(&self) -> bool {
self.0 == 41 || (self.0 >= 128 && self.0 <= 255)
}
}
50 changes: 50 additions & 0 deletions src/base/iana/zonemd.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
//! ZONEMD IANA parameters.

//------------ ZonemdScheme --------------------------------------------------

int_enum! {
/// ZONEMD schemes.
///
/// This type selects the method by which data is collated and presented
/// as input to the hashing function for use with [ZONEMD].
///
/// For the currently registered values see the [IANA registration]. This
/// type is complete as of 2024-11-29.
///
/// [ZONEMD]: ../../../rdata/zonemd/index.html
/// [IANA registration]: https://www.iana.org/assignments/dns-parameters/dns-parameters.xhtml#zonemd-schemes
=>
ZonemdScheme, u8;

/// Specifies that the SIMPLE scheme is used.
(SIMPLE => 1, "SIMPLE")
}

int_enum_str_decimal!(ZonemdScheme, u8);
int_enum_zonefile_fmt_decimal!(ZonemdScheme, "scheme");

//------------ ZonemdAlg -----------------------------------------------------

int_enum! {
/// ZONEMD algorithms.
///
/// This type selects the algorithm used to hash domain names for use with
/// the [ZONEMD].
///
/// For the currently registered values see the [IANA registration]. This
/// type is complete as of 2024-11-29.
///
/// [ZONEMD]: ../../../rdata/zonemd/index.html
/// [IANA registration]: https://www.iana.org/assignments/dns-parameters/dns-parameters.xhtml#zonemd-hash-algorithms
=>
ZonemdAlg, u8;

/// Specifies that the SHA-384 algorithm is used.
(SHA384 => 1, "SHA384")

/// Specifies that the SHA-512 algorithm is used.
(SHA512 => 2, "SHA512")
}

int_enum_str_decimal!(ZonemdAlg, u8);
int_enum_zonefile_fmt_decimal!(ZonemdAlg, "hash algorithm");
5 changes: 0 additions & 5 deletions src/net/client/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,6 @@
//! transport connections. The [redundant] transport favors the connection
//! with the lowest response time. Any of the other transports can be added
//! as upstream transports.
//! * [load_balancer] This transport distributes requests over a collecton of
//! transport connections. The [load_balancer] transport favors connections
//! with the shortest outstanding request queue. Any of the other transports
//! can be added as upstream transports.
//! * [cache] This is a simple message cache provided as a pass through
//! transport. The cache works with any of the other transports.
#![cfg_attr(feature = "tsig", doc = "* [tsig]:")]
Expand Down Expand Up @@ -226,7 +222,6 @@
pub mod cache;
pub mod dgram;
pub mod dgram_stream;
pub mod load_balancer;
pub mod multi_stream;
pub mod protocol;
pub mod redundant;
Expand Down
Loading
Loading