[GH-ISSUE #1491] Update requests to BIND9 fail with FORMERR due to EDNS #684

Closed
opened 2026-03-15 23:48:14 +03:00 by kerem · 1 comment
Owner

Originally created by @astro on GitHub (May 19, 2021).
Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/1491

Describe the bug
I am using tdns-cli's tsig implementation to send updates to a BIND9 server. If I use tdns-cli's update_message module this works. When I use trust-dns-client directly, the server replies with FORMERR.

To Reproduce
Steps to reproduce the behavior:

  • Prepare update requests
  • Add TSIG signatures
  • Send to BIND9 server

Expected behavior
The difference between tdns-cli and trust-dns-client boils down to this workaround:

diff --git crates/client/src/op/update_message.rs crates/client/src/op/update_message.rs
index d61794be..5d7a1fcf 100644
--- crates/client/src/op/update_message.rs
+++ crates/client/src/op/update_message.rs
@@ -480,11 +480,11 @@ pub fn delete_rrset(mut record: Record, zone_origin: Name) -> Message {
     message.add_update(record);
 
-    // Extended dns
-    {
-        let edns = message.edns_mut();
-        edns.set_max_payload(MAX_PAYLOAD_LEN);
-        edns.set_version(0);
-    }
 
     message
 }

Following up
Would it be a good idea to make this configurable? Where/how?

Originally created by @astro on GitHub (May 19, 2021). Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/1491 **Describe the bug** I am using **tdns-cli**'s [tsig implementation](https://github.com/rotty/tdns-cli/blob/master/src/tsig.rs) to send updates to a BIND9 server. If I use **tdns-cli**'s `update_message` module this works. When I use **trust-dns-client** directly, the server replies with `FORMERR`. **To Reproduce** Steps to reproduce the behavior: * Prepare update requests * Add TSIG signatures * Send to BIND9 server **Expected behavior** The difference between **tdns-cli** and **trust-dns-client** boils down to this workaround: ```patch diff --git crates/client/src/op/update_message.rs crates/client/src/op/update_message.rs index d61794be..5d7a1fcf 100644 --- crates/client/src/op/update_message.rs +++ crates/client/src/op/update_message.rs @@ -480,11 +480,11 @@ pub fn delete_rrset(mut record: Record, zone_origin: Name) -> Message { message.add_update(record); - // Extended dns - { - let edns = message.edns_mut(); - edns.set_max_payload(MAX_PAYLOAD_LEN); - edns.set_version(0); - } message } ``` **Following up** Would it be a good idea to make this configurable? Where/how?
kerem closed this issue 2026-03-15 23:48:19 +03:00
Author
Owner

@bluejekyll commented on GitHub (May 19, 2021):

Yes. I think we’d want the client to be configurable to disable EDNS. I’d probably start by adding the configuration option to the client, and then following that through to here (which might get messy). I’d have to look at the code in more detail.

<!-- gh-comment-id:844376432 --> @bluejekyll commented on GitHub (May 19, 2021): Yes. I think we’d want the client to be configurable to disable EDNS. I’d probably start by adding the configuration option to the client, and then following that through to here (which might get messy). I’d have to look at the code in more detail.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hickory-dns#684
No description provided.