reconfig_server "reconfiguring the server to use plain HTTP/DoH over PROXYv2" named-http-plain-proxy.conf.in
run_dig_multitest_expect_success "$testing: a query over plain HTTP/DoH over PROXYv2" +http-plain +proxy
+reconfig_server "reconfiguring the server back to use TLS/DoT" named-tls.conf.in
+run_dig_multitest_expect_success "$testing: a query over TLS/DoT" +tls
+
+reconfig_server "reconfiguring the server back to use HTTPS/DoH" named-https.conf.in
+run_dig_multitest_expect_success "$testing: a query over HTTPS/DoH" +https
+
echo_i "exit status: $status"
[ $status -eq 0 ] || exit 1
same_listener_type(ns_interface_t *ifp, ns_listenelt_t *new_le) {
bool same_transport_type = false;
- if (new_le->is_http && new_le->sslctx != NULL &&
- ifp->http_secure_listensocket != NULL)
- {
- /* HTTPS/DoH */
- same_transport_type = true;
- } else if (new_le->is_http && new_le->sslctx == NULL &&
- ifp->http_listensocket != NULL)
- {
- /* HTTP/plain DoH */
- same_transport_type = true;
+ /* See 'interface_setup()' above */
+ if (new_le->is_http) {
+ /* HTTP/DoH */
+ same_transport_type = (new_le->sslctx != NULL &&
+ ifp->http_secure_listensocket != NULL) ||
+ (new_le->sslctx == NULL &&
+ ifp->http_listensocket != NULL);
} else if (new_le->sslctx != NULL && ifp->tlslistensocket != NULL) {
/* TLS/DoT */
same_transport_type = true;