]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
dnsdist: use "replace" instead of "overwrite" 15610/head
authorSamir Aguiar <sjorgedeaguiar@netskope.com>
Thu, 5 Jun 2025 13:21:48 +0000 (13:21 +0000)
committerSamir Aguiar <sjorgedeaguiar@netskope.com>
Thu, 5 Jun 2025 13:23:16 +0000 (13:23 +0000)
pdns/dnsdistdist/dnsdist-response-actions-definitions.yml
pdns/dnsdistdist/docs/reference/actions.rst
regression-tests.dnsdist/test_Responses.py

index 17f20ee2b33636141dfa0d11e740b3ee1ab6d995..d04f2c7036f97039c9070fc6e60a1b166a310c71 100644 (file)
@@ -173,7 +173,7 @@ The function will be invoked in a per-thread Lua state, without access to the gl
       default: true
       description: "A list of ``name``=``key`` pairs, for meta-data to be added to Protocol Buffer message"
 - name: "SetEDNSOption"
-  description: "Add arbitrary EDNS option and data to the response. Any existing EDNS content with the same option code will be overwritten. Subsequent rules are processed after this action"
+  description: "Add arbitrary EDNS option and data to the response. Any existing EDNS content with the same option code will be replaced. Subsequent rules are processed after this action"
   parameters:
     - name: "code"
       type: "u32"
index 31b74c2031e30c2dc768c3b932909dce75f7c963..41b4c2f20fa36d9cf7056b3354aa59348e8ffb9e 100644 (file)
@@ -597,7 +597,7 @@ The following actions exist.
 
   .. versionadded:: 1.9.11
 
-  Add arbitrary EDNS option and data to the response. Any existing EDNS content with the same option code will be overwritten.
+  Add arbitrary EDNS option and data to the response. Any existing EDNS content with the same option code will be replaced.
   Subsequent rules are processed after this action.
 
   :param int option: The EDNS option number
index 13d4e99cefa3b53fe4f3c7a0b6fd119fd76e68a7..846ce295459d93146b07dd424a2d015d01bbec16 100644 (file)
@@ -605,7 +605,7 @@ class TestAdvancedSetEDNSOptionResponseAction(DNSDistTest):
 
     def testAdvancedSetEDNSOptionResponseOverwrite(self):
         """
-        Responses: Set EDNS Option in response overwrites existing option
+        Responses: Set EDNS Option in response replaces existing option
         """
         name = 'setednsoptionresponse-overwrite.responses.tests.powerdns.com.'
         initialECO = cookiesoption.CookiesOption(b'aaaaaaaa', b'bbbbbbbb')
@@ -619,9 +619,9 @@ class TestAdvancedSetEDNSOptionResponseAction(DNSDistTest):
                                     '127.0.0.1')
         response.answer.append(rrset)
 
-        overWrittenECO = cookiesoption.CookiesOption(b'deadbeef', b'deadc0de')
+        replacementECO = cookiesoption.CookiesOption(b'deadbeef', b'deadc0de')
         expectedResponse = dns.message.make_response(query)
-        expectedResponse.use_edns(edns=True, payload=512, options=[overWrittenECO])
+        expectedResponse.use_edns(edns=True, payload=512, options=[replacementECO])
         expectedResponse.answer.append(rrset)
 
         for method in ("sendUDPQuery", "sendTCPQuery"):