From 4cc661096b748db8ba8b0630a5149a4d0e99425f Mon Sep 17 00:00:00 2001 From: Song GUO Date: Tue, 4 Apr 2023 01:29:33 +0800 Subject: [PATCH] [nat64] enable upstream DNS forwarding when NAT64 is enabled (#1806) --- .github/workflows/border_router.yml | 16 ++++++++-------- script/_otbr | 6 ++++++ third_party/openthread/repo | 2 +- 3 files changed, 15 insertions(+), 9 deletions(-) diff --git a/.github/workflows/border_router.yml b/.github/workflows/border_router.yml index 58b1d663518..7778daf6360 100644 --- a/.github/workflows/border_router.yml +++ b/.github/workflows/border_router.yml @@ -50,56 +50,56 @@ jobs: matrix: include: - name: "Border Router (mDNSResponder)" - otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=OFF" + otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=OFF -DOTBR_DNS_UPSTREAM_QUERY=ON" border_routing: 1 nat64: 0 otbr_mdns: "mDNSResponder" cert_scripts: ./tests/scripts/thread-cert/border_router/*.py packet_verification: 1 - name: "Border Router (Avahi)" - otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=OFF" + otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=OFF -DOTBR_DNS_UPSTREAM_QUERY=ON" border_routing: 1 nat64: 0 otbr_mdns: "avahi" cert_scripts: ./tests/scripts/thread-cert/border_router/*.py packet_verification: 1 - name: "Border Router TREL (mDNSResponder)" - otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=ON" + otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=ON -DOTBR_DNS_UPSTREAM_QUERY=ON" border_routing: 1 nat64: 0 otbr_mdns: "mDNSResponder" cert_scripts: ./tests/scripts/thread-cert/border_router/*.py packet_verification: 2 - name: "Border Router TREL (Avahi)" - otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=ON" + otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=ON -DOTBR_DNS_UPSTREAM_QUERY=ON" border_routing: 1 nat64: 0 otbr_mdns: "avahi" cert_scripts: ./tests/scripts/thread-cert/border_router/*.py packet_verification: 2 - name: "Border Router MATN (mDNSResponder)" - otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=OFF" + otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=OFF -DOTBR_DNS_UPSTREAM_QUERY=ON" border_routing: 1 nat64: 0 otbr_mdns: "mDNSResponder" cert_scripts: ./tests/scripts/thread-cert/border_router/MATN/*.py packet_verification: 1 - name: "Border Router NAT64 (mDNSResponder)" - otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=OFF" + otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=OFF -DOTBR_DNS_UPSTREAM_QUERY=ON" border_routing: 1 nat64: 1 otbr_mdns: "mDNSResponder" cert_scripts: ./tests/scripts/thread-cert/border_router/nat64/*.py packet_verification: 1 - name: "Backbone Router" - otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=OFF" + otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_TREL=OFF -DOTBR_DNS_UPSTREAM_QUERY=ON" border_routing: 0 nat64: 0 otbr_mdns: "mDNSResponder" cert_scripts: ./tests/scripts/thread-cert/backbone/*.py packet_verification: 1 - name: "Border Router TREL with FEATURE_FLAG (avahi)" - otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_FEATURE_FLAGS=ON -DOTBR_TREL=ON" + otbr_options: "-DOT_DUA=ON -DOT_ECDSA=ON -DOT_MLR=ON -DOT_SERVICE=ON -DOT_SRP_SERVER=ON -DOTBR_COVERAGE=ON -DOTBR_DUA_ROUTING=ON -DOTBR_FEATURE_FLAGS=ON -DOTBR_TREL=ON -DOTBR_DNS_UPSTREAM_QUERY=ON" border_routing: 1 nat64: 0 otbr_mdns: "avahi" diff --git a/script/_otbr b/script/_otbr index 372ffb98a9e..37f1d894ffd 100644 --- a/script/_otbr +++ b/script/_otbr @@ -122,6 +122,12 @@ otbr_install() ) fi + if with NAT64; then + otbr_options+=( + "-DOTBR_DNS_UPSTREAM_QUERY=ON" + ) + fi + (./script/cmake-build "${otbr_options[@]}" \ && cd "${OTBR_TOP_BUILDDIR}" \ && ninja \ diff --git a/third_party/openthread/repo b/third_party/openthread/repo index 2c8a0af2443..fa6824c9cbe 160000 --- a/third_party/openthread/repo +++ b/third_party/openthread/repo @@ -1 +1 @@ -Subproject commit 2c8a0af24433dd802414ae1832a3f3e5948514b7 +Subproject commit fa6824c9cbe57d03fcec3aacece5a1daebef36df