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

Set nsec3param: first increase the serial and then rectify #14325

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
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
20 changes: 11 additions & 9 deletions pdns/ws-auth.cc
Original file line number Diff line number Diff line change
Expand Up @@ -894,15 +894,7 @@ static void updateDomainSettingsFromDocument(UeberBackend& backend, DomainInfo&
}

if (shouldRectify && !isPresigned) {
// Rectify
if (isZoneApiRectifyEnabled(domainInfo)) {
string info;
string error_msg;
if (!dnssecKeeper.rectifyZone(zonename, error_msg, info, false) && !domainInfo.isSecondaryType()) {
// for Secondary zones, it is possible that rectifying was not needed (example: empty zone).
throw ApiException("Failed to rectify '" + zonename.toString() + "' " + error_msg);
}
}
// First increase the serial (which removes the ordername from the SOA RR) if configured. And then rectify.

// Increase serial
string soa_edit_api_kind;
Expand All @@ -923,6 +915,16 @@ static void updateDomainSettingsFromDocument(UeberBackend& backend, DomainInfo&
}
}
}

// Rectify
if (isZoneApiRectifyEnabled(domainInfo)) {
string info;
string error_msg;
if (!dnssecKeeper.rectifyZone(zonename, error_msg, info, false) && !domainInfo.isSecondaryType()) {
// for Secondary zones, it is possible that rectifying was not needed (example: empty zone).
throw ApiException("Failed to rectify '" + zonename.toString() + "' " + error_msg);
}
}
}

if (!document["master_tsig_key_ids"].is_null()) {
Expand Down
Loading