[package]
name = "hickory-recursor"

# A short blurb about the package. This is not rendered in any format when
# uploaded to crates.io (aka this is not markdown)
description = """
*WARNING* This library is experimental

Hickory DNS Recursor is a safe and secure DNS recursive resolver with DNSSEC support.
 Hickory DNS is based on the Tokio and Futures libraries, which means
 it should be easily integrated into other software that also use those
 libraries. This library can be used as in the server and binary for performing recursive lookups.
"""

# These URLs point to more information about the repository
documentation = "https://docs.rs/hickory-recursor"

# This points to a file in the repository (relative to this Cargo.toml). The
# contents of this file are stored and indexed in the registry.
readme = "README.md"

version.workspace = true
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
homepage.workspace = true
repository.workspace = true
keywords.workspace = true
categories.workspace = true
license.workspace = true

[badges]
codecov = { repository = "hickory-dns/hickory-dns", branch = "main", service = "github" }
maintenance = { status = "actively-developed" }

[features]
#backtrace = ["dep:backtrace", "hickory-proto/backtrace", "hickory-resolver/backtrace"]

dnssec-openssl = [
    "dnssec",
    "hickory-proto/dnssec-openssl",
    "hickory-resolver/dnssec-openssl",
]
dnssec-ring = [
    "dnssec",
    "hickory-proto/dnssec-ring",
    "hickory-resolver/dnssec-ring",
]
dnssec = []

# TODO: Need to figure out how to be consistent with ring/openssl usage...
dns-over-https-rustls = [
    "dns-over-https",
    "hickory-proto/dns-over-https-rustls",
    "hickory-resolver/dns-over-https-rustls",
    "dns-over-rustls",
]
dns-over-https = ["hickory-proto/dns-over-https"]
dns-over-quic = [
    "dns-over-rustls",
    "hickory-proto/dns-over-quic",
    "hickory-resolver/dns-over-quic",
]
dns-over-h3 = [
    "dns-over-rustls",
    "hickory-proto/dns-over-h3",
    "hickory-resolver/dns-over-h3",
]

# TODO: migrate all tls and tls-openssl features to dns-over-tls, et al
dns-over-native-tls = [
    "dns-over-tls",
    "hickory-proto/dns-over-native-tls",
    "hickory-resolver/dns-over-native-tls",
]
dns-over-openssl = [
    "dns-over-tls",
    "dnssec-openssl",
    "hickory-proto/dns-over-openssl",
    "hickory-resolver/dns-over-openssl",
]
dns-over-rustls = [
    "dns-over-tls",
    "dnssec-ring",
    "hickory-proto/dns-over-rustls",
    "hickory-resolver/dns-over-rustls",
]
dns-over-tls = []

# This is a deprecated feature...
tls-openssl = ["dns-over-openssl"]
tls = ["dns-over-openssl"]

serde-config = [
    "serde",
    "hickory-proto/serde-config",
    "hickory-resolver/serde-config",
]

testing = []

[lib]
name = "hickory_recursor"
path = "src/lib.rs"

[dependencies]
async-trait.workspace = true
async-recursion.workspace = true
#backtrace = { version = "0.3.50", optional = true }
bytes.workspace = true
cfg-if.workspace = true
enum-as-inner.workspace = true
futures-util = { workspace = true, default-features = false, features = [
    "std",
] }
lru-cache.workspace = true
parking_lot.workspace = true
serde = { workspace = true, features = ["derive"], optional = true }
thiserror.workspace = true
tracing.workspace = true
tokio = { workspace = true, features = ["net"] }
hickory-proto.workspace = true
hickory-resolver = { workspace = true, features = ["tokio-runtime"] }

[dev-dependencies]
tokio = { workspace = true, features = ["macros", "rt"] }
tracing-subscriber = { workspace = true, features = [
    "std",
    "fmt",
    "env-filter",
] }

[package.metadata.docs.rs]
all-features = true
default-target = "x86_64-unknown-linux-gnu"
targets = ["x86_64-apple-darwin", "x86_64-pc-windows-msvc"]
rustdoc-args = ["--cfg", "docsrs"]
