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

Report zonefile parsing & signing progress to the caller. #448

Draft
wants to merge 127 commits into
base: initial-nsec3-generation
Choose a base branch
from

Conversation

ximon18
Copy link
Member

@ximon18 ximon18 commented Nov 25, 2024

This allows callers to report progress, which is especially useful on very large zone files.

For example usage see NLnetLabs/dnst#35.

I'm not very happy with the inplace::Zonefile progress support, but due to the replacement of self via the Bytes split() operation, reset of the start variable and the iterator being mutably consumed by the caller, using a new position tracking variable and returning it via Entry seemed like one easy way of getting the progress information out to the iterating caller code.

Perhaps something like Iterator::enumerate() could be used instead to return the progress offset to the iteration loop?

If we keep the extra var returned with Entry it should probably be made into named struct fields instead of anonymous tuple fields, to be more self-evident what the usize value is. Also, the extra tuple field infects all call sites which is annoying as most don't care about it.

Note: This PR lacks progress notification for NSEC hashing, that should also be added.

Thoughts:

  • Progress reporting should be optional, so perhaps the callback should be Option.
  • Progress reporting has a cost, perhaps it should be emitted only every N units instead of for every unit change?

- FIX: Clear the signing buffer between uses.
- Output signed DNSKEY RRs from sign().
…e unsigned delegation NSEC3 RRs in the output.
…s been detected and with what value, so that the caller can reliably ignore apex records if needed (e.g. when updating NSEC3PARAM or ZONEMD RRs) when signing a loaded zone. This is a breaking change."

This reverts commit 605efe6.
…the RFC requirements for it to be canonical and uncompressed.
…Rs, not two separate DNSKEY RRsets (existing and new).
@ximon18 ximon18 changed the base branch from byo-signing-sorter-impl to multiple-key-signing December 19, 2024 08:25
@ximon18 ximon18 changed the base branch from multiple-key-signing to initial-nsec3-generation December 19, 2024 08:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant