diff --git a/pkg/util/options.go b/pkg/util/options.go index 4f174b5..b462a18 100644 --- a/pkg/util/options.go +++ b/pkg/util/options.go @@ -18,8 +18,12 @@ type Options struct { TLSHost string `json:"tlsHost" example:""` // EDNS Options EDNS + + // HTTPS options :) + HTTPSOptions + // DNS request :) - Request Request + Request // Verbosity levels, see [logawl.AllLevels] Verbosity int `json:"-" example:"0"` @@ -53,7 +57,6 @@ type Options struct { TLSNoVerify bool `json:"tlsNoVerify" example:"false"` // Use DNS-over-HTTPS to make the query HTTPS bool `json:"dnsOverHTTPS" example:"false"` - HTTPSOptions // Use DNS-over-QUIC to make the query //nolint:tagliatelle // QUIC is an acronym QUIC bool `json:"dnsOverQUIC" example:"false"` @@ -66,13 +69,14 @@ type Options struct { IPv6 bool `json:"forceIPv6" example:"false"` } +// HTTPSOptions are options exclusively for DNS-over-HTTPS queries. type HTTPSOptions struct { + // URL endpoint + Endpoint string `json:"endpoint" example:"/dns-query"` + // True, make GET request. // False, make POST request. Get bool `json:"get" example:"false"` - - // URL endpoint - Endpoint string `json:"endpoint" example:"/dns-query"` } // HeaderFlags are the flags that are in DNS headers.