diff --git a/bottlecap/Cargo.lock b/bottlecap/Cargo.lock index 3475b27e9..9b2cef9c4 100644 --- a/bottlecap/Cargo.lock +++ b/bottlecap/Cargo.lock @@ -35,15 +35,6 @@ version = "0.2.21" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "683d7910e743518b0e34f1186f92494becacb047c7b6bf616c96772180fef923" -[[package]] -name = "android_system_properties" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae221649c9976a6f6c56ae1facf410f3ddb33cc661c4b7b61020a912d4237fbc" -dependencies = [ - "libc", -] - [[package]] name = "anyhow" version = "1.0.103" @@ -332,7 +323,7 @@ dependencies = [ "http 1.4.0", "http-body 1.0.1", "http-body-util", - "hyper 1.8.1", + "hyper 1.12.0", "hyper-util", "itoa", "matchit", @@ -513,11 +504,11 @@ dependencies = [ "http-body 1.0.1", "http-body-util", "httpmock", - "hyper 1.8.1", + "hyper 1.12.0", "hyper-http-proxy", "hyper-rustls", "hyper-util", - "indexmap 2.13.0", + "indexmap", "itertools 0.14.0", "lazy_static", "libdd-capabilities", @@ -528,6 +519,7 @@ dependencies = [ "libdd-trace-stats", "libdd-trace-utils", "libddwaf", + "libddwaf-sys", "log", "mime", "mock_instant", @@ -572,15 +564,6 @@ dependencies = [ "zstd", ] -[[package]] -name = "bs58" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf88ba1141d185c399bee5288d850d63b8369520c1eafc32a0430b5b6c287bf4" -dependencies = [ - "tinyvec", -] - [[package]] name = "buf_redux" version = "0.8.4" @@ -680,10 +663,8 @@ version = "0.4.44" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c673075a2e0e5f4a1dde27ce9dee1ea4558c7ffe648f576438a20ca1d2acc4b0" dependencies = [ - "iana-time-zone", "num-traits", "serde", - "windows-link", ] [[package]] @@ -851,44 +832,10 @@ dependencies = [ "syn 2.0.117", ] -[[package]] -name = "darling" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25ae13da2f202d56bd7f91c25fba009e7717a1e4a1cc98a76d844b65ae912e9d" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9865a50f7c335f53564bb694ef660825eb8610e0a53d3e11bf1b0d3df31e03b0" -dependencies = [ - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 2.0.117", -] - -[[package]] -name = "darling_macro" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3984ec7bd6cfa798e62b4a642426a5be0e68f9401cfc2a01e3fa9ea2fcdb8d" -dependencies = [ - "darling_core", - "quote", - "syn 2.0.117", -] - [[package]] name = "datadog-agent-config" version = "0.1.0" -source = "git+https://github.com/DataDog/serverless-components?rev=5859602d609405a9de4d32638673a643caf37534#5859602d609405a9de4d32638673a643caf37534" +source = "git+https://github.com/DataDog/serverless-components?rev=e462105e918904e6b1ad2ebc153ae561cebe5a34#e462105e918904e6b1ad2ebc153ae561cebe5a34" dependencies = [ "datadog-opentelemetry", "dogstatsd", @@ -906,12 +853,12 @@ dependencies = [ [[package]] name = "datadog-agent-trace-sampler" version = "0.1.0" -source = "git+https://github.com/DataDog/serverless-components?rev=5859602d609405a9de4d32638673a643caf37534#5859602d609405a9de4d32638673a643caf37534" +source = "git+https://github.com/DataDog/serverless-components?rev=e462105e918904e6b1ad2ebc153ae561cebe5a34#e462105e918904e6b1ad2ebc153ae561cebe5a34" [[package]] name = "datadog-fips" version = "0.1.0" -source = "git+https://github.com/DataDog/serverless-components?rev=5859602d609405a9de4d32638673a643caf37534#5859602d609405a9de4d32638673a643caf37534" +source = "git+https://github.com/DataDog/serverless-components?rev=e462105e918904e6b1ad2ebc153ae561cebe5a34#e462105e918904e6b1ad2ebc153ae561cebe5a34" dependencies = [ "aws-lc-rs", "reqwest", @@ -922,17 +869,19 @@ dependencies = [ [[package]] name = "datadog-opentelemetry" -version = "0.5.2" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd2cc0474d0b32827fd8cff077e618c8ebd2d41f42515fc9a0505739d807a99c" +checksum = "012c23ac630133bda8f22b5b3ced2e9301a80d7bebda6777a070c91cde982cb9" dependencies = [ "anyhow", "arc-swap", "async-trait", + "bumpalo", "ctor", "foldhash 0.1.5", "hashbrown 0.15.5", - "hyper 1.8.1", + "hostname", + "hyper 1.12.0", "libc", "libdd-capabilities-impl", "libdd-common", @@ -943,11 +892,12 @@ dependencies = [ "libdd-shared-runtime", "libdd-telemetry", "libdd-tinybytes", + "libdd-trace-model", "libdd-trace-utils", "lru", - "opentelemetry", - "opentelemetry-semantic-conventions 0.32.1", - "opentelemetry_sdk", + "opentelemetry 0.33.0", + "opentelemetry-semantic-conventions 0.33.0", + "opentelemetry_sdk 0.33.0", "percent-encoding", "rand 0.8.6", "rustc_version_runtime", @@ -955,6 +905,7 @@ dependencies = [ "serde_json", "thiserror 1.0.69", "tokio", + "tracing", "uuid", ] @@ -983,37 +934,6 @@ dependencies = [ "smallvec", ] -[[package]] -name = "defmt" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2953bfe4f93bbd20cc71198842756f77d161884c99ebbabc41d80231ded88d1" -dependencies = [ - "bitflags 1.3.2", - "defmt-macros", -] - -[[package]] -name = "defmt-macros" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bad9c72e7ca2137e0dc3813245a0d282fd6daad32fd800af018306a9169b5fe8" -dependencies = [ - "defmt-parser", - "proc-macro2", - "quote", - "syn 2.0.117", -] - -[[package]] -name = "defmt-parser" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10d60334b3b2e7c9d91ef8150abfb6fa4c1c39ebbcf4a81c2e346aad939fee3e" -dependencies = [ - "thiserror 2.0.18", -] - [[package]] name = "deranged" version = "0.5.8" @@ -1091,7 +1011,7 @@ dependencies = [ [[package]] name = "dogstatsd" version = "0.1.0" -source = "git+https://github.com/DataDog/serverless-components?rev=5859602d609405a9de4d32638673a643caf37534#5859602d609405a9de4d32638673a643caf37534" +source = "git+https://github.com/DataDog/serverless-components?rev=e462105e918904e6b1ad2ebc153ae561cebe5a34#e462105e918904e6b1ad2ebc153ae561cebe5a34" dependencies = [ "datadog-protos", "ddsketch-agent", @@ -1118,12 +1038,6 @@ version = "1.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813" -[[package]] -name = "dyn-clone" -version = "1.0.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0881ea181b1df73ff77ffaaf9c7544ecc11e82fba9b5f27b262a3c73a332555" - [[package]] name = "either" version = "1.15.0" @@ -1152,7 +1066,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" dependencies = [ "libc", - "windows-sys 0.61.2", + "windows-sys 0.59.0", ] [[package]] @@ -1254,7 +1168,6 @@ checksum = "bc74ac4d8359ae70623506d512209619e5cf8f347124910440dbc221714b328e" dependencies = [ "borrow-or-share", "ref-cast", - "serde", ] [[package]] @@ -1472,19 +1385,13 @@ dependencies = [ "futures-core", "futures-sink", "http 1.4.0", - "indexmap 2.13.0", + "indexmap", "slab", "tokio", "tokio-util", "tracing", ] -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" - [[package]] name = "hashbrown" version = "0.13.2" @@ -1516,6 +1423,17 @@ dependencies = [ "foldhash 0.2.0", ] +[[package]] +name = "hashbrown" +version = "0.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a" +dependencies = [ + "allocator-api2", + "equivalent", + "foldhash 0.2.0", +] + [[package]] name = "headers" version = "0.4.1" @@ -1576,6 +1494,17 @@ dependencies = [ "windows-sys 0.61.2", ] +[[package]] +name = "hostname" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "617aaa3557aef3810a6369d0a99fac8a080891b68bd9f9812a1eeda0c0730cbd" +dependencies = [ + "cfg-if", + "libc", + "windows-link", +] + [[package]] name = "http" version = "0.2.12" @@ -1696,9 +1625,9 @@ dependencies = [ [[package]] name = "hyper" -version = "1.8.1" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ab2d4f250c3d7b1c9fcdff1cece94ea4e2dfbec68614f7b87cb205f24ca9d11" +checksum = "2c3e324da4c95177d6291d4c8730197c0d1822f8a9766814a4a44fa5ab797c9c" dependencies = [ "atomic-waker", "bytes", @@ -1711,7 +1640,6 @@ dependencies = [ "httpdate", "itoa", "pin-project-lite", - "pin-utils", "smallvec", "tokio", "want", @@ -1727,7 +1655,7 @@ dependencies = [ "futures-util", "headers", "http 1.4.0", - "hyper 1.8.1", + "hyper 1.12.0", "hyper-rustls", "hyper-util", "pin-project-lite", @@ -1744,7 +1672,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e3c93eb611681b207e1fe55d5a71ecf91572ec8a6705cdb6857f7d8d5242cf58" dependencies = [ "http 1.4.0", - "hyper 1.8.1", + "hyper 1.12.0", "hyper-util", "rustls", "rustls-native-certs", @@ -1761,7 +1689,7 @@ version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2b90d566bffbce6a75bd8b09a05aa8c2cb1fabb6cb348f8840c9e4c90a0d83b0" dependencies = [ - "hyper 1.8.1", + "hyper 1.12.0", "hyper-util", "pin-project-lite", "tokio", @@ -1780,41 +1708,17 @@ dependencies = [ "futures-util", "http 1.4.0", "http-body 1.0.1", - "hyper 1.8.1", + "hyper 1.12.0", "ipnet", "libc", "percent-encoding", "pin-project-lite", - "socket2 0.6.3", + "socket2 0.5.10", "tokio", "tower-service", "tracing", ] -[[package]] -name = "iana-time-zone" -version = "0.1.65" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e31bc9ad994ba00e440a8aa5c9ef0ec67d5cb5e5cb0cc7f8b744a35b389cc470" -dependencies = [ - "android_system_properties", - "core-foundation-sys", - "iana-time-zone-haiku", - "js-sys", - "log", - "wasm-bindgen", - "windows-core", -] - -[[package]] -name = "iana-time-zone-haiku" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" -dependencies = [ - "cc", -] - [[package]] name = "icu_collections" version = "2.1.1" @@ -1902,12 +1806,6 @@ version = "2.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3d3067d79b975e8844ca9eb072e16b31c3c1c36928edf9c6789548c524d0d954" -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - [[package]] name = "idna" version = "1.1.0" @@ -1929,17 +1827,6 @@ dependencies = [ "icu_properties", ] -[[package]] -name = "indexmap" -version = "1.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" -dependencies = [ - "autocfg", - "hashbrown 0.12.3", - "serde", -] - [[package]] name = "indexmap" version = "2.13.0" @@ -1998,59 +1885,6 @@ version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682" -[[package]] -name = "jiff" -version = "0.2.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "668b7183bd07af9a4885f5c35b0cc5c83c4607a913c16b7e17291832910d2dcc" -dependencies = [ - "defmt", - "jiff-core", - "jiff-static", - "jiff-tzdb-platform", - "log", - "portable-atomic", - "portable-atomic-util", - "serde_core", - "windows-link", -] - -[[package]] -name = "jiff-core" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7feca88439efe53da3754500c1851dedf3cb36c524dd5cf8225cc0794de95d09" -dependencies = [ - "defmt", -] - -[[package]] -name = "jiff-static" -version = "0.2.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a69dcb3a21cfb32ce1cd056169337ca284af0766dd766e7878819b251a49204" -dependencies = [ - "jiff-core", - "proc-macro2", - "quote", - "syn 2.0.117", -] - -[[package]] -name = "jiff-tzdb" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "142bd39932ad231f10513df9ab62661fead8719872150b7ad02a2df79f4e141e" - -[[package]] -name = "jiff-tzdb-platform" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "875a5a69ac2bab1a891711cf5eccbec1ce0341ea805560dcd90b7a2e925132e8" -dependencies = [ - "jiff-tzdb", -] - [[package]] name = "jni" version = "0.21.1" @@ -2181,23 +2015,23 @@ checksum = "b5b646652bf6661599e1da8901b3b9522896f01e736bad5f723fe7a3a27f899d" [[package]] name = "libdd-capabilities" -version = "3.0.1" +version = "4.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae15be1f4fa5e6e1b36a985c763d168ea419d725d029564bd1a0c64b3258e9af" +checksum = "ebd351a5b324c0dc9eaca9a78a6c86660e01154fc1bfbd3f8995365342a13861" dependencies = [ "anyhow", "bytes", "futures-channel", "futures-util", "http 1.4.0", - "thiserror 1.0.69", + "thiserror 2.0.18", ] [[package]] name = "libdd-capabilities-impl" -version = "4.0.0" +version = "9.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fc1d0afa0f84914ec64f5d206c37a2f4ff625109e6c081f7a82adb849e69e2b" +checksum = "1e8eca6041d5a63754d507f8ac5583a2c1be9bb1a79aaf0bf5b3843c7c65c410" dependencies = [ "anyhow", "bytes", @@ -2210,22 +2044,20 @@ dependencies = [ [[package]] name = "libdd-common" -version = "5.2.0" +version = "10.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "350fb68fd76193dceecbadd8add17732f5f2ca0b0c7806d62da0bd110af53410" +checksum = "03efb40c494f1fbbea365f94f82bfd6d15a92a342914372e873cc4724a1269e0" dependencies = [ "anyhow", + "arc-swap", "bytes", - "cc", "const_format", "futures", - "futures-core", - "futures-util", "hex", "http 1.4.0", "http-body 1.0.1", "http-body-util", - "hyper 1.8.1", + "hyper 1.12.0", "hyper-rustls", "hyper-util", "libc", @@ -2233,22 +2065,22 @@ dependencies = [ "pin-project", "regex", "rustls", - "rustls-native-certs", "rustls-platform-verifier", "serde", "static_assertions", - "thiserror 1.0.69", + "thiserror 2.0.18", "tokio", - "tokio-rustls", "tower-service", + "webpki-root-certs", + "webpki-roots 1.0.10", "windows-sys 0.52.0", ] [[package]] name = "libdd-data-pipeline" -version = "8.0.0" +version = "14.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecfc85fff58f2589e473af6a81e9ff4c19fe5386aad4c72ab787a7bb889b60d9" +checksum = "a9e45d08f743601ecba1990c52ab6511d85a866a25145c4b78a5b27618823f81" dependencies = [ "anyhow", "arc-swap", @@ -2256,47 +2088,69 @@ dependencies = [ "bytes", "either", "futures", - "getrandom 0.2.17", + "h2", "http 1.4.0", "http-body-util", + "hyper 1.12.0", + "hyper-util", "libdd-capabilities", "libdd-capabilities-impl", "libdd-common", + "libdd-data-pipeline-core", "libdd-ddsketch", "libdd-dogstatsd-client", "libdd-shared-runtime", "libdd-telemetry", "libdd-tinybytes", - "libdd-trace-normalization", "libdd-trace-obfuscation", "libdd-trace-protobuf", "libdd-trace-stats", "libdd-trace-utils", + "prost 0.14.3", + "rand 0.8.6", "rmp-serde", "serde", "serde_json", "sha2", "tokio", "tokio-util", + "tonic 0.14.5", "tracing", "uuid", "web-time", ] +[[package]] +name = "libdd-data-pipeline-core" +version = "5.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99c74647e52b55794232aa36734cc511b955f8765f6fc7f2507a091af71822bb" +dependencies = [ + "anyhow", + "http 1.4.0", + "libdd-capabilities", + "libdd-common", + "libdd-trace-obfuscation", + "libdd-trace-stats", + "libdd-trace-utils", + "serde_json", + "thiserror 2.0.18", +] + [[package]] name = "libdd-ddsketch" -version = "1.1.1" +version = "1.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "827db9addada0e19a8371241e54fe4f27e9101c5a1dc30a13cf42dea5220e3f0" +checksum = "5dd02b4bd64a7fe7871c85fc1a00b37971da6ec248499d08a1daed59de810ff6" dependencies = [ "prost 0.14.3", ] [[package]] name = "libdd-dogstatsd-client" -version = "5.0.0" +version = "10.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74c277a83676a4897e5fc3331758d34adda6db6ac5b9e51c1918eba067b2c127" +checksum = "80aa498ae7f9e4c3f76348660d2a617a5ff13490c353566995497a1dcd69d5de" dependencies = [ "anyhow", "async-trait", @@ -2311,9 +2165,9 @@ dependencies = [ [[package]] name = "libdd-library-config" -version = "3.0.0" +version = "5.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab46ec324c1b916ca06c4a369da171a08eb9f112620e6f6f004860e589892715" +checksum = "acd8d640c921896ba2e93e250323de2891709d66b037578e9b95e613a127651e" dependencies = [ "anyhow", "libc", @@ -2321,30 +2175,33 @@ dependencies = [ "memfd", "prost 0.14.3", "rand 0.8.6", - "rmp", "rmp-serde", "serde", - "serde_yaml", + "yaml_serde", ] [[package]] name = "libdd-remote-config" -version = "2.0.0" +version = "9.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca0de524c2d9716d6352edb2e46bec6c920fc6c9836cf20eca8e1d31c5445a82" +checksum = "7a1efafad36c617717f1306a302f1d8e87c9146152680148a5af086ab99b371c" dependencies = [ "anyhow", "base64 0.22.1", + "bytes", + "futures", "futures-util", - "hashbrown 0.15.5", + "getrandom 0.2.17", + "hashbrown 0.17.1", "http 1.4.0", "http-body-util", + "libdd-capabilities", + "libdd-capabilities-impl", "libdd-common", "libdd-trace-protobuf", "manual_future", "serde", "serde_json", - "serde_with", "sha2", "strum", "strum_macros", @@ -2358,9 +2215,9 @@ dependencies = [ [[package]] name = "libdd-sampling" -version = "6.0.0" +version = "10.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e709eca79e8f161d915947dc5d83b23081f28ca7f6f1bb0abdb4d646a4e016da" +checksum = "9e52b94dd62af71cfb8ed62926462e5274b85f7707ddae414dac47a8ef86d6d8" dependencies = [ "libdd-common", "lru", @@ -2370,9 +2227,9 @@ dependencies = [ [[package]] name = "libdd-shared-runtime" -version = "3.0.0" +version = "8.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "55749d4e255a4fd6544036338f895235418e530198e2ecb2e4b493267d0c6397" +checksum = "e243e75cd2ceb2840c3c44d0f35b65662a8cf65d1c478badf67a0e42572fe177" dependencies = [ "async-trait", "futures", @@ -2388,17 +2245,16 @@ dependencies = [ [[package]] name = "libdd-telemetry" -version = "7.0.0" +version = "12.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "004aebda20a6ca15304c3129f997bce6756bfa5b4980163716761d72ef3630f2" +checksum = "3a4ddc50d66693bce21132dc117b256039a8e6fd81f30e5fec0d99942a55ea69" dependencies = [ "anyhow", "async-trait", "base64 0.22.1", "bytes", "futures", - "getrandom 0.2.17", - "hashbrown 0.15.5", + "hashbrown 0.17.1", "http 1.4.0", "libc", "libdd-capabilities", @@ -2420,18 +2276,25 @@ dependencies = [ [[package]] name = "libdd-tinybytes" -version = "1.1.2" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d3e6ade71c21b86ab81fa8d905f9f26733336f1a904bb826b9ac1972b3c8289" +checksum = "13cc057099a83139204f195f8af629c82b1aa6f89fef18de449d767901e79fa6" dependencies = [ + "libdd-trace-model", "serde", ] +[[package]] +name = "libdd-trace-model" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b5f9e207fa4eb1f2b8dbedf2b687706968341addd7092b57d8ad5b6d6c51d15a" + [[package]] name = "libdd-trace-normalization" -version = "3.0.1" +version = "4.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a643220a54228ef837631b5036f34fc13fc8ee2e307a74ac011232c062393fc5" +checksum = "31ceafaba82e03add2e5b95a101c13c6a212b5712fe22d87b19b1e5e297610c8" dependencies = [ "anyhow", "libdd-trace-protobuf", @@ -2439,26 +2302,28 @@ dependencies = [ [[package]] name = "libdd-trace-obfuscation" -version = "6.0.0" +version = "12.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b5709cd8d3e058e5d9056affbf6aae7464b49eb461afc49945576285d1f457b" +checksum = "d16ec4123b5a147ff54a40188a6dea72252f009c1a1339a5970753946efcb53d" dependencies = [ "anyhow", "fluent-uri", "libdd-common", + "libdd-trace-model", "libdd-trace-protobuf", "libdd-trace-utils", "log", "percent-encoding", "serde", "serde_json", + "thiserror 2.0.18", ] [[package]] name = "libdd-trace-protobuf" -version = "4.0.1" +version = "5.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b1bc3bd67115bec00669d84a29b7b52ef1d61f36dfb49b273b2fee3346bf18f" +checksum = "393dffe95ff0982bcd5fb6a92fbf245791483115ea7ce1e49004c5b3e52ce75c" dependencies = [ "prost 0.14.3", "serde", @@ -2467,15 +2332,15 @@ dependencies = [ [[package]] name = "libdd-trace-stats" -version = "7.0.0" +version = "13.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23d3cc84f8d144752fa51abe59d3a7a3a956b9a479897fb9689a2e1bac458ac2" +checksum = "864a9475628e3b1dbccaf69b1a1249a6c9f502227aae12b828c11a0c27add7e5" dependencies = [ "anyhow", "arc-swap", "async-trait", "futures", - "hashbrown 0.15.5", + "hashbrown 0.17.1", "http 1.4.0", "libdd-capabilities", "libdd-capabilities-impl", @@ -2490,33 +2355,36 @@ dependencies = [ "rmp-serde", "serde", "tokio", - "tokio-util", "tracing", "web-time", ] [[package]] name = "libdd-trace-utils" -version = "10.1.0" +version = "16.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f5dcd936e7be2edbde4e9cd11af0f1a227e5af239205e56ee8f137e8bb2869f" +checksum = "a247012a16d7d04c1a132cb7f7e91e52154bbb9f9eb63c3f50fc5de1243ff13c" dependencies = [ + "allocator-api2", "anyhow", "base64 0.22.1", "bytes", + "crossbeam-channel", "flate2", "futures", "getrandom 0.2.17", + "hashbrown 0.17.1", "hex", "http 1.4.0", "http-body 1.0.1", "http-body-util", - "indexmap 2.13.0", + "indexmap", "itoa", "libdd-capabilities", "libdd-capabilities-impl", "libdd-common", "libdd-tinybytes", + "libdd-trace-model", "libdd-trace-normalization", "libdd-trace-protobuf", "prost 0.14.3", @@ -2529,15 +2397,16 @@ dependencies = [ "serde-transcode", "serde_json", "thin-vec", - "tokio", + "thread_local", "tracing", + "zrip", "zstd", ] [[package]] name = "libddwaf" -version = "1.28.1" -source = "git+https://github.com/DataDog/libddwaf-rust?rev=d1534a158d976bd4f747bf9fcc58e0712d2d17fc#d1534a158d976bd4f747bf9fcc58e0712d2d17fc" +version = "2.1.0" +source = "git+https://github.com/DataDog/libddwaf-rust?rev=bbada5255bf8e9105c06b03ce6d5d63a7c337e2a#bbada5255bf8e9105c06b03ce6d5d63a7c337e2a" dependencies = [ "libddwaf-sys", "serde", @@ -2545,8 +2414,8 @@ dependencies = [ [[package]] name = "libddwaf-sys" -version = "1.28.1" -source = "git+https://github.com/DataDog/libddwaf-rust?rev=d1534a158d976bd4f747bf9fcc58e0712d2d17fc#d1534a158d976bd4f747bf9fcc58e0712d2d17fc" +version = "2.1.0" +source = "git+https://github.com/DataDog/libddwaf-rust?rev=bbada5255bf8e9105c06b03ce6d5d63a7c337e2a#bbada5255bf8e9105c06b03ce6d5d63a7c337e2a" dependencies = [ "bindgen", "flate2", @@ -2555,6 +2424,7 @@ dependencies = [ "reqwest", "rustls", "tar", + "yoke-derive", "zstd", ] @@ -2580,6 +2450,12 @@ dependencies = [ "redox_syscall 0.7.3", ] +[[package]] +name = "libyaml-rs" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2e126dda6f34391ab7b444f9922055facc83c07a910da3eb16f1e4d9c45dc777" + [[package]] name = "linux-raw-sys" version = "0.4.15" @@ -2823,6 +2699,19 @@ dependencies = [ "tracing", ] +[[package]] +name = "opentelemetry" +version = "0.33.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6cdb0b1b267eb9db3331b434ed9ddab10d50e280a9adf9d13e5233e2002b61b5" +dependencies = [ + "futures-core", + "futures-sink", + "js-sys", + "pin-project-lite", + "thiserror 2.0.18", +] + [[package]] name = "opentelemetry-proto" version = "0.32.0" @@ -2831,8 +2720,8 @@ checksum = "56d658ba1faf63f7b9c492cfbe6e0ec365440a16132d3270c1065f7b33f1b638" dependencies = [ "base64 0.22.1", "const-hex", - "opentelemetry", - "opentelemetry_sdk", + "opentelemetry 0.32.0", + "opentelemetry_sdk 0.32.1", "prost 0.14.3", "serde", "tonic 0.14.5", @@ -2847,9 +2736,9 @@ checksum = "83d059a296a47436748557a353c5e6c5705b9470ef6c95cfc52c21a8814ddac2" [[package]] name = "opentelemetry-semantic-conventions" -version = "0.32.1" +version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c913ac17a6c451661ee255f4625d143e51647ae78ebd969b75e41c4442f4fe47" +checksum = "d288b1e1bc3590052fbb8f0f635ef248dd9022cf1fbaeb6582b7ad6081a17b87" [[package]] name = "opentelemetry_sdk" @@ -2860,7 +2749,23 @@ dependencies = [ "futures-channel", "futures-executor", "futures-util", - "opentelemetry", + "opentelemetry 0.32.0", + "percent-encoding", + "portable-atomic", + "rand 0.9.4", + "thiserror 2.0.18", +] + +[[package]] +name = "opentelemetry_sdk" +version = "0.33.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb39533d9d1c912123efd7d41d7e0c29d16917b60ce15b4c8d87cb1af7f67520" +dependencies = [ + "futures-channel", + "futures-executor", + "futures-util", + "opentelemetry 0.33.0", "percent-encoding", "portable-atomic", "rand 0.9.4", @@ -2959,7 +2864,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b4c5cc86750666a3ed20bdaf5ca2a0344f9c67674cae0515bec2da16fbaa47db" dependencies = [ "fixedbitset", - "indexmap 2.13.0", + "indexmap", ] [[package]] @@ -3052,15 +2957,6 @@ version = "1.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c33a9471896f1c69cecef8d20cbe2f7accd12527ce60845ff44c153bb2a21b49" -[[package]] -name = "portable-atomic-util" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10ab3eb7f3becc3a1cbc4f2c6f20267996cfc1a6467a873763411b136a122715" -dependencies = [ - "portable-atomic", -] - [[package]] name = "potential_utf" version = "0.1.4" @@ -3169,7 +3065,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "be769465445e8c1474e9c5dac2018218498557af32d9ed057325ec9a41ae81bf" dependencies = [ "heck", - "itertools 0.14.0", + "itertools 0.11.0", "log", "multimap", "once_cell", @@ -3189,7 +3085,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a56d757972c98b346a9b766e3f02746cde6dd1cd1d1d563472929fdd74bec4d" dependencies = [ "anyhow", - "itertools 0.14.0", + "itertools 0.11.0", "proc-macro2", "quote", "syn 2.0.117", @@ -3202,7 +3098,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "27c6023962132f4b30eb4c172c91ce92d933da334c59c23cddee82358ddafb0b" dependencies = [ "anyhow", - "itertools 0.14.0", + "itertools 0.11.0", "proc-macro2", "quote", "syn 2.0.117", @@ -3260,7 +3156,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b4aeaa1f2460f1d348eeaeed86aea999ce98c1bded6f089ff8514c9d9dbdc973" dependencies = [ "anyhow", - "indexmap 2.13.0", + "indexmap", "log", "protobuf", "protobuf-support", @@ -3297,7 +3193,7 @@ dependencies = [ "quinn-udp", "rustc-hash", "rustls", - "socket2 0.6.3", + "socket2 0.5.10", "thiserror 2.0.18", "tokio", "tracing", @@ -3335,9 +3231,9 @@ dependencies = [ "cfg_aliases", "libc", "once_cell", - "socket2 0.6.3", + "socket2 0.5.10", "tracing", - "windows-sys 0.60.2", + "windows-sys 0.59.0", ] [[package]] @@ -3548,7 +3444,7 @@ dependencies = [ "http 1.4.0", "http-body 1.0.1", "http-body-util", - "hyper 1.8.1", + "hyper 1.12.0", "hyper-rustls", "hyper-util", "js-sys", @@ -3665,7 +3561,7 @@ dependencies = [ "errno", "libc", "linux-raw-sys 0.12.1", - "windows-sys 0.61.2", + "windows-sys 0.59.0", ] [[package]] @@ -3733,7 +3629,7 @@ dependencies = [ "security-framework", "security-framework-sys", "webpki-root-certs", - "windows-sys 0.61.2", + "windows-sys 0.59.0", ] [[package]] @@ -3811,30 +3707,6 @@ dependencies = [ "windows-sys 0.61.2", ] -[[package]] -name = "schemars" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4cd191f9397d57d581cddd31014772520aa448f65ef991055d7f61582c65165f" -dependencies = [ - "dyn-clone", - "ref-cast", - "serde", - "serde_json", -] - -[[package]] -name = "schemars" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "687274d293b6cdc6e73e0fee520bf2049650090d7164f87672d212a3c530cf4a" -dependencies = [ - "dyn-clone", - "ref-cast", - "serde", - "serde_json", -] - [[package]] name = "scopeguard" version = "1.2.0" @@ -3953,7 +3825,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b2f2d7ff8a2140333718bb329f5c40fc5f0865b84c426183ce14c97d2ab8154f" dependencies = [ "form_urlencoded", - "indexmap 2.13.0", + "indexmap", "itoa", "serde_core", ] @@ -3964,7 +3836,6 @@ version = "1.0.149" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "83fc039473c5595ace860d8c4fafa220ff474b3fc6bfdb4293327f1a37e94d86" dependencies = [ - "indexmap 2.13.0", "itoa", "memchr", "serde", @@ -4005,46 +3876,13 @@ dependencies = [ "serde", ] -[[package]] -name = "serde_with" -version = "3.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee78f1fbe43ac4a0e47aadb3dbd357b69eb0d3793e948624cd03dd2750ab1c0a" -dependencies = [ - "base64 0.22.1", - "bs58", - "chrono", - "hex", - "indexmap 1.9.3", - "indexmap 2.13.0", - "jiff", - "schemars 0.9.0", - "schemars 1.2.2", - "serde_core", - "serde_json", - "serde_with_macros", - "time", -] - -[[package]] -name = "serde_with_macros" -version = "3.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8705578779c2b6bd90d84d66eb2e206b708b1a4d7b9f17641b293545bf1c7e46" -dependencies = [ - "darling", - "proc-macro2", - "quote", - "syn 2.0.117", -] - [[package]] name = "serde_yaml" version = "0.9.34+deprecated" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6a8b1a1a2ebf674015cc02edccce75287f1a0130d394307b36743c2f5d504b47" dependencies = [ - "indexmap 2.13.0", + "indexmap", "itoa", "ryu", "serde", @@ -4198,12 +4036,6 @@ dependencies = [ "precomputed-hash", ] -[[package]] -name = "strsim" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" - [[package]] name = "strum" version = "0.26.3" @@ -4302,7 +4134,7 @@ dependencies = [ "getrandom 0.4.2", "once_cell", "rustix 1.1.4", - "windows-sys 0.61.2", + "windows-sys 0.59.0", ] [[package]] @@ -4552,7 +4384,7 @@ dependencies = [ "http 1.4.0", "http-body 1.0.1", "http-body-util", - "hyper 1.8.1", + "hyper 1.12.0", "hyper-timeout", "hyper-util", "percent-encoding", @@ -4611,7 +4443,7 @@ checksum = "ebe5ef63511595f1344e2d5cfa636d973292adc0eec1f0ad45fae9f0851ab1d4" dependencies = [ "futures-core", "futures-util", - "indexmap 2.13.0", + "indexmap", "pin-project-lite", "slab", "sync_wrapper", @@ -4859,9 +4691,9 @@ dependencies = [ [[package]] name = "want" -version = "0.3.1" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" +checksum = "ec4cdd0dd910afe868b7ef477227d8d538b46b3075031afee8a9f2acb0a2ed0b" dependencies = [ "try-lock", ] @@ -4966,7 +4798,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bb0e353e6a2fbdc176932bbaab493762eb1255a7900fe0fea1a2f96c296cc909" dependencies = [ "anyhow", - "indexmap 2.13.0", + "indexmap", "wasm-encoder", "wasmparser", ] @@ -4979,7 +4811,7 @@ checksum = "47b807c72e1bac69382b3a6fb3dbe8ea4c0ed87ff5629b8685ae6b9a611028fe" dependencies = [ "bitflags 2.11.0", "hashbrown 0.15.5", - "indexmap 2.13.0", + "indexmap", "semver", ] @@ -5064,7 +4896,7 @@ version = "0.1.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" dependencies = [ - "windows-sys 0.61.2", + "windows-sys 0.59.0", ] [[package]] @@ -5082,65 +4914,12 @@ dependencies = [ "windows-targets 0.48.5", ] -[[package]] -name = "windows-core" -version = "0.62.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb" -dependencies = [ - "windows-implement", - "windows-interface", - "windows-link", - "windows-result", - "windows-strings", -] - -[[package]] -name = "windows-implement" -version = "0.60.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.117", -] - -[[package]] -name = "windows-interface" -version = "0.59.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.117", -] - [[package]] name = "windows-link" version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5" -[[package]] -name = "windows-result" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5" -dependencies = [ - "windows-link", -] - -[[package]] -name = "windows-strings" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091" -dependencies = [ - "windows-link", -] - [[package]] name = "windows-sys" version = "0.45.0" @@ -5168,15 +4947,6 @@ dependencies = [ "windows-targets 0.52.6", ] -[[package]] -name = "windows-sys" -version = "0.60.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb" -dependencies = [ - "windows-targets 0.53.5", -] - [[package]] name = "windows-sys" version = "0.61.2" @@ -5225,30 +4995,13 @@ dependencies = [ "windows_aarch64_gnullvm 0.52.6", "windows_aarch64_msvc 0.52.6", "windows_i686_gnu 0.52.6", - "windows_i686_gnullvm 0.52.6", + "windows_i686_gnullvm", "windows_i686_msvc 0.52.6", "windows_x86_64_gnu 0.52.6", "windows_x86_64_gnullvm 0.52.6", "windows_x86_64_msvc 0.52.6", ] -[[package]] -name = "windows-targets" -version = "0.53.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3" -dependencies = [ - "windows-link", - "windows_aarch64_gnullvm 0.53.1", - "windows_aarch64_msvc 0.53.1", - "windows_i686_gnu 0.53.1", - "windows_i686_gnullvm 0.53.1", - "windows_i686_msvc 0.53.1", - "windows_x86_64_gnu 0.53.1", - "windows_x86_64_gnullvm 0.53.1", - "windows_x86_64_msvc 0.53.1", -] - [[package]] name = "windows_aarch64_gnullvm" version = "0.42.2" @@ -5267,12 +5020,6 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9d8416fa8b42f5c947f8482c43e7d89e73a173cead56d044f6a56104a6d1b53" - [[package]] name = "windows_aarch64_msvc" version = "0.42.2" @@ -5291,12 +5038,6 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" -[[package]] -name = "windows_aarch64_msvc" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9d782e804c2f632e395708e99a94275910eb9100b2114651e04744e9b125006" - [[package]] name = "windows_i686_gnu" version = "0.42.2" @@ -5315,24 +5056,12 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" -[[package]] -name = "windows_i686_gnu" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "960e6da069d81e09becb0ca57a65220ddff016ff2d6af6a223cf372a506593a3" - [[package]] name = "windows_i686_gnullvm" version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" -[[package]] -name = "windows_i686_gnullvm" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa7359d10048f68ab8b09fa71c3daccfb0e9b559aed648a8f95469c27057180c" - [[package]] name = "windows_i686_msvc" version = "0.42.2" @@ -5351,12 +5080,6 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" -[[package]] -name = "windows_i686_msvc" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e7ac75179f18232fe9c285163565a57ef8d3c89254a30685b57d83a38d326c2" - [[package]] name = "windows_x86_64_gnu" version = "0.42.2" @@ -5375,12 +5098,6 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" -[[package]] -name = "windows_x86_64_gnu" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c3842cdd74a865a8066ab39c8a7a473c0778a3f29370b5fd6b4b9aa7df4a499" - [[package]] name = "windows_x86_64_gnullvm" version = "0.42.2" @@ -5399,12 +5116,6 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ffa179e2d07eee8ad8f57493436566c7cc30ac536a3379fdf008f47f6bb7ae1" - [[package]] name = "windows_x86_64_msvc" version = "0.42.2" @@ -5423,12 +5134,6 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" -[[package]] -name = "windows_x86_64_msvc" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650" - [[package]] name = "winver" version = "1.0.0" @@ -5466,7 +5171,7 @@ checksum = "b7c566e0f4b284dd6561c786d9cb0142da491f46a9fbed79ea69cdad5db17f21" dependencies = [ "anyhow", "heck", - "indexmap 2.13.0", + "indexmap", "prettyplease", "syn 2.0.117", "wasm-metadata", @@ -5497,7 +5202,7 @@ checksum = "9d66ea20e9553b30172b5e831994e35fbde2d165325bec84fc43dbf6f4eb9cb2" dependencies = [ "anyhow", "bitflags 2.11.0", - "indexmap 2.13.0", + "indexmap", "log", "serde", "serde_derive", @@ -5516,7 +5221,7 @@ checksum = "ecc8ac4bc1dc3381b7f59c34f00b67e18f910c2c0f50015669dde7def656a736" dependencies = [ "anyhow", "id-arena", - "indexmap 2.13.0", + "indexmap", "log", "semver", "serde", @@ -5542,6 +5247,19 @@ dependencies = [ "rustix 1.1.4", ] +[[package]] +name = "yaml_serde" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "33b729a08a9a6be689bbad3e2bf8015926db54b6622cc89c3a5f7dc174b9e918" +dependencies = [ + "indexmap", + "itoa", + "libyaml-rs", + "ryu", + "serde", +] + [[package]] name = "yansi" version = "1.0.1" @@ -5561,9 +5279,9 @@ dependencies = [ [[package]] name = "yoke-derive" -version = "0.8.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b659052874eb698efe5b9e8cf382204678a0086ebf46982b79d6ca3182927e5d" +checksum = "de844c262c8848816172cef550288e7dc6c7b7814b4ee56b3e1553f275f1858e" dependencies = [ "proc-macro2", "quote", @@ -5657,29 +5375,64 @@ version = "1.0.21" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b8848ee67ecc8aedbaf3e4122217aff892639231befc6a1b58d29fff4c2cabaa" +[[package]] +name = "zrip" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "964fe9f1ea10a0d183fc143a7525266cbe16978883dbe304725da34b314c04cf" +dependencies = [ + "zrip-core", + "zrip-decode", + "zrip-encode", +] + +[[package]] +name = "zrip-core" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cbc201ba56175f86e67cc88bdaf1a7af9c061815c7dde719c7a6a1ed5aaa186b" + +[[package]] +name = "zrip-decode" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "038f795e49887bdeaab197fff84c8165644484a98dc3f2354e5df3d2e5f4f978" +dependencies = [ + "zrip-core", +] + +[[package]] +name = "zrip-encode" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3dfdcbb503db2045716492d5ab31cd82f2852d0d93d8edf6a9235653d9da685" +dependencies = [ + "zrip-core", +] + [[package]] name = "zstd" -version = "0.13.3" +version = "0.14.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e91ee311a569c327171651566e07972200e76fcfe2242a4fa446149a3881c08a" +checksum = "db3ae9bf90af6e40197bef767eeefc46ad6397420fe873830bd85e5fbbfb3c70" dependencies = [ "zstd-safe", ] [[package]] name = "zstd-safe" -version = "7.2.4" +version = "8.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f49c4d5f0abb602a93fb8736af2a4f4dd9512e36f7f570d66e65ff867ed3b9d" +checksum = "ded520f16b29e1a9b771c722221b2b0a0398c2316d9bb3c42b458a5414d7434b" dependencies = [ "zstd-sys", ] [[package]] name = "zstd-sys" -version = "2.0.16+zstd.1.5.7" +version = "2.1.2+zstd.1.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91e19ebc2adc8f83e43039e79776e3fda8ca919132d68a1fed6a5faca2683748" +checksum = "481ada9c543b2323cbb7bbdbb5249177fbf0188ed959ed2c15e4b22421c84ed3" dependencies = [ "cc", "pkg-config", diff --git a/bottlecap/Cargo.toml b/bottlecap/Cargo.toml index 26ec8582a..bf5a520b3 100644 --- a/bottlecap/Cargo.toml +++ b/bottlecap/Cargo.toml @@ -60,7 +60,7 @@ rand = { version = "0.8", default-features = false } prost = { version = "0.14", default-features = false } tonic = { version = "0.14", features = ["transport", "codegen", "server", "channel", "router"], default-features = false } tonic-types = { version = "0.14", default-features = false } -zstd = { version = "0.13.3", default-features = false } +zstd = { version = "0.14.3", default-features = false } futures = { version = "0.3.31", default-features = false } serde-aux = { version = "4.7", default-features = false } serde_html_form = { version = "0.2", default-features = false } @@ -84,22 +84,23 @@ indexmap = {version = "2.11.0", default-features = false} # be found in the clippy.toml file adjacent to this Cargo.toml. datadog-protos = { version = "0.1.0", default-features = false, git = "https://github.com/DataDog/saluki/", rev = "f863626dbfe3c59bb390985fa6530b0621c2a0a2"} ddsketch-agent = { version = "0.1.0", default-features = false, git = "https://github.com/DataDog/saluki/", rev = "f863626dbfe3c59bb390985fa6530b0621c2a0a2"} -# These are pinned to the same crates.io versions that dd-trace-rs's datadog-opentelemetry -# depends on, so cargo unifies them instead of compiling duplicate copies. Re-check with -# `cargo tree --duplicates | grep ^libdd-` when bumping either side. -libdd-capabilities = "3.0.0" -libdd-common = { version = "5.2.0", default-features = false } -libdd-trace-protobuf = "4.0.1" -libdd-trace-utils = { version = "10.1.0", default-features = false, features = ["mini_agent"] } -libdd-trace-normalization = "3.0.1" -libdd-trace-obfuscation = { version = "6.0.0", default-features = false } -libdd-trace-stats = { version = "7.0.0", default-features = false } -datadog-opentelemetry = { version = "0.5.2", default-features = false, features = ["_unstable_propagation"] } -dogstatsd = { git = "https://github.com/DataDog/serverless-components", rev = "5859602d609405a9de4d32638673a643caf37534", default-features = false } -datadog-fips = { git = "https://github.com/DataDog/serverless-components", rev = "5859602d609405a9de4d32638673a643caf37534", default-features = false } -datadog-agent-config = { git = "https://github.com/DataDog/serverless-components", rev = "5859602d609405a9de4d32638673a643caf37534", default-features = false } -datadog-agent-trace-sampler = { git = "https://github.com/DataDog/serverless-components", rev = "5859602d609405a9de4d32638673a643caf37534", default-features = false } -libddwaf = { version = "1.28.1", git = "https://github.com/DataDog/libddwaf-rust", rev = "d1534a158d976bd4f747bf9fcc58e0712d2d17fc", default-features = false, features = ["serde"] } +# Pin the libdd crates used by Bottlecap's trace pipeline to the release line +# required by serverless-components PR #196. +libdd-capabilities = "4.0.1" +libdd-common = { version = "10.0.0", default-features = false } +libdd-trace-protobuf = "5.1.1" +libdd-trace-utils = { version = "16.0.0", default-features = false, features = ["mini_agent"] } +libdd-trace-normalization = "4.3.1" +libdd-trace-obfuscation = { version = "12.0.0", default-features = false } +libdd-trace-stats = { version = "13.0.0", default-features = false } +datadog-opentelemetry = { version = "0.6.0", default-features = false, features = ["_unstable_propagation"] } +dogstatsd = { git = "https://github.com/DataDog/serverless-components", rev = "e462105e918904e6b1ad2ebc153ae561cebe5a34", default-features = false } +datadog-fips = { git = "https://github.com/DataDog/serverless-components", rev = "e462105e918904e6b1ad2ebc153ae561cebe5a34", default-features = false } +datadog-agent-config = { git = "https://github.com/DataDog/serverless-components", rev = "e462105e918904e6b1ad2ebc153ae561cebe5a34", default-features = false } +datadog-agent-trace-sampler = { git = "https://github.com/DataDog/serverless-components", rev = "e462105e918904e6b1ad2ebc153ae561cebe5a34", default-features = false } +libddwaf = { version = "2.1.0", git = "https://github.com/DataDog/libddwaf-rust", rev = "bbada5255bf8e9105c06b03ce6d5d63a7c337e2a", default-features = false, features = ["serde"] } +# Enables the crypto provider libddwaf-sys needs to download prebuilt WAF binaries. +libddwaf-sys = { version = "2.1.0", git = "https://github.com/DataDog/libddwaf-rust", rev = "bbada5255bf8e9105c06b03ce6d5d63a7c337e2a", default-features = false, features = ["aws-lc-rs"] } [dev-dependencies] figment = { version = "0.10", default-features = false, features = ["yaml", "env", "test"] } diff --git a/bottlecap/LICENSE-3rdparty.csv b/bottlecap/LICENSE-3rdparty.csv index 07ec6ff60..3d80131f9 100644 --- a/bottlecap/LICENSE-3rdparty.csv +++ b/bottlecap/LICENSE-3rdparty.csv @@ -3,7 +3,6 @@ adler2,https://github.com/oyvindln/adler2,0BSD OR MIT OR Apache-2.0,"Jonas Schie ahash,https://github.com/tkaitchuck/ahash,MIT OR Apache-2.0,Tom Kaitchuck aho-corasick,https://github.com/BurntSushi/aho-corasick,Unlicense OR MIT,Andrew Gallant allocator-api2,https://github.com/zakarumych/allocator-api2,MIT OR Apache-2.0,Zakarum -android_system_properties,https://github.com/nical/android_system_properties,MIT OR Apache-2.0,Nicolas Silva anyhow,https://github.com/dtolnay/anyhow,MIT OR Apache-2.0,David Tolnay arc-swap,https://github.com/vorner/arc-swap,MIT OR Apache-2.0,Michal 'vorner' Vaner async-trait,https://github.com/dtolnay/async-trait,MIT OR Apache-2.0,David Tolnay @@ -20,14 +19,12 @@ bit-vec,https://github.com/contain-rs/bit-vec,Apache-2.0 OR MIT,Alexis Beingessn bitflags,https://github.com/bitflags/bitflags,MIT OR Apache-2.0,The Rust Project Developers block-buffer,https://github.com/RustCrypto/utils,MIT OR Apache-2.0,RustCrypto Developers borrow-or-share,https://github.com/yescallop/borrow-or-share,MIT-0,Scallop Ye -bs58,https://github.com/Nullus157/bs58-rs,MIT OR Apache-2.0,The bs58 Authors buf_redux,https://github.com/abonander/buf_redux,MIT OR Apache-2.0,Austin Bonander bumpalo,https://github.com/fitzgen/bumpalo,MIT OR Apache-2.0,Nick Fitzgerald bytemuck,https://github.com/Lokathor/bytemuck,Zlib OR Apache-2.0 OR MIT,Lokathor byteorder,https://github.com/BurntSushi/byteorder,Unlicense OR MIT,Andrew Gallant bytes,https://github.com/tokio-rs/bytes,MIT,"Carl Lerche , Sean McArthur " cadence,https://github.com/56quarters/cadence,Apache-2.0 OR MIT,Nick Pillitteri -cc,https://github.com/rust-lang/cc-rs,MIT OR Apache-2.0,Alex Crichton cesu8,https://github.com/emk/cesu8-rs,Apache-2.0 OR MIT,Eric Kidd cfg-if,https://github.com/rust-lang/cfg-if,MIT OR Apache-2.0,Alex Crichton chacha20,https://github.com/RustCrypto/stream-ciphers,MIT OR Apache-2.0,RustCrypto Developers @@ -45,31 +42,23 @@ crossbeam-channel,https://github.com/crossbeam-rs/crossbeam,MIT OR Apache-2.0,Th crossbeam-utils,https://github.com/crossbeam-rs/crossbeam,MIT OR Apache-2.0,The crossbeam-utils Authors crypto-common,https://github.com/RustCrypto/traits,MIT OR Apache-2.0,RustCrypto Developers ctor,https://github.com/mmastrac/rust-ctor,Apache-2.0 OR MIT,Matt Mastracci -darling,https://github.com/TedDriggs/darling,MIT,Ted Driggs -darling_core,https://github.com/TedDriggs/darling,MIT,Ted Driggs -darling_macro,https://github.com/TedDriggs/darling,MIT,Ted Driggs datadog-agent-config,https://github.com/DataDog/serverless-components,Apache-2.0,The datadog-agent-config Authors datadog-agent-trace-sampler,https://github.com/DataDog/serverless-components,Apache-2.0,The datadog-agent-trace-sampler Authors datadog-fips,https://github.com/DataDog/serverless-components,Apache-2.0,The datadog-fips Authors datadog-opentelemetry,https://github.com/DataDog/dd-trace-rs/tree/main/datadog-opentelemetry,Apache-2.0,Datadog Inc. datadog-protos,https://github.com/DataDog/saluki,Apache-2.0,The datadog-protos Authors ddsketch-agent,https://github.com/DataDog/saluki,Apache-2.0,The ddsketch-agent Authors -defmt,https://github.com/knurling-rs/defmt,MIT OR Apache-2.0,The Knurling-rs developers -defmt-macros,https://github.com/knurling-rs/defmt,MIT OR Apache-2.0,The Knurling-rs developers -defmt-parser,https://github.com/knurling-rs/defmt,MIT OR Apache-2.0,The Knurling-rs developers deranged,https://github.com/jhpratt/deranged,MIT OR Apache-2.0,Jacob Pratt derive_more,https://github.com/JelteF/derive_more,MIT,Jelte Fennema derive_more-impl,https://github.com/JelteF/derive_more,MIT,Jelte Fennema digest,https://github.com/RustCrypto/traits,MIT OR Apache-2.0,RustCrypto Developers displaydoc,https://github.com/yaahc/displaydoc,MIT OR Apache-2.0,Jane Lusby dogstatsd,https://github.com/DataDog/serverless-components,Apache-2.0,The dogstatsd Authors -dyn-clone,https://github.com/dtolnay/dyn-clone,MIT OR Apache-2.0,David Tolnay either,https://github.com/rayon-rs/either,MIT OR Apache-2.0,bluss equivalent,https://github.com/indexmap-rs/equivalent,Apache-2.0 OR MIT,The equivalent Authors errno,https://github.com/lambda-fairy/rust-errno,MIT OR Apache-2.0,"Chris Wong , Dan Gohman " fastrand,https://github.com/smol-rs/fastrand,Apache-2.0 OR MIT,Stjepan Glavina figment,https://github.com/SergioBenitez/Figment,MIT OR Apache-2.0,Sergio Benitez -find-msvc-tools,https://github.com/rust-lang/cc-rs,MIT OR Apache-2.0,The find-msvc-tools Authors flate2,https://github.com/rust-lang/flate2-rs,MIT OR Apache-2.0,"Alex Crichton , Josh Triplett " float-cmp,https://github.com/mikedilger/float-cmp,MIT,Mike Dilger fluent-uri,https://github.com/yescallop/fluent-uri-rs,MIT,Scallop Ye @@ -89,11 +78,13 @@ generic-array,https://github.com/fizyk20/generic-array,MIT,"Bartłomiej Kamińsk getrandom,https://github.com/rust-random/getrandom,MIT OR Apache-2.0,The Rand Project Developers h2,https://github.com/hyperium/h2,MIT,"Carl Lerche , Sean McArthur " hashbrown,https://github.com/rust-lang/hashbrown,MIT OR Apache-2.0,Amanieu d'Antras +hashbrown,https://github.com/rust-lang/hashbrown,MIT OR Apache-2.0,The hashbrown Authors headers,https://github.com/hyperium/headers,MIT,Sean McArthur headers-core,https://github.com/hyperium/headers,MIT,Sean McArthur heck,https://github.com/withoutboats/heck,MIT OR Apache-2.0,The heck Authors hex,https://github.com/KokaKiwi/rust-hex,MIT OR Apache-2.0,KokaKiwi hmac,https://github.com/RustCrypto/MACs,MIT OR Apache-2.0,RustCrypto Developers +hostname,https://github.com/djc/hostname,MIT,The hostname Authors http,https://github.com/hyperium/http,MIT OR Apache-2.0,"Alex Crichton , Carl Lerche , Sean McArthur " http-body,https://github.com/hyperium/http-body,MIT,"Carl Lerche , Lucio Franco , Sean McArthur " http-body-util,https://github.com/hyperium/http-body,MIT,"Carl Lerche , Lucio Franco , Sean McArthur " @@ -104,8 +95,6 @@ hyper-http-proxy,https://github.com/metalbear-co/hyper-http-proxy,MIT,MetalBear hyper-rustls,https://github.com/rustls/hyper-rustls,Apache-2.0 OR ISC OR MIT,The hyper-rustls Authors hyper-timeout,https://github.com/hjr3/hyper-timeout,MIT OR Apache-2.0,Herman J. Radtke III hyper-util,https://github.com/hyperium/hyper-util,MIT,Sean McArthur -iana-time-zone,https://github.com/strawlab/iana-time-zone,MIT OR Apache-2.0,"Andrew Straw , René Kijewski , Ryan Lopopolo " -iana-time-zone-haiku,https://github.com/strawlab/iana-time-zone,MIT OR Apache-2.0,René Kijewski icu_collections,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Project Developers icu_locale_core,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Project Developers icu_normalizer,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Project Developers @@ -114,26 +103,18 @@ icu_properties,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Projec icu_properties_data,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Project Developers icu_provider,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Project Developers id-arena,https://github.com/fitzgen/id-arena,MIT OR Apache-2.0,"Nick Fitzgerald , Aleksey Kladov " -ident_case,https://github.com/TedDriggs/ident_case,MIT OR Apache-2.0,Ted Driggs idna,https://github.com/servo/rust-url,MIT OR Apache-2.0,The rust-url developers idna_adapter,https://github.com/hsivonen/idna_adapter,Apache-2.0 OR MIT,The rust-url developers -indexmap,https://github.com/bluss/indexmap,Apache-2.0 OR MIT,The indexmap Authors indexmap,https://github.com/indexmap-rs/indexmap,Apache-2.0 OR MIT,The indexmap Authors inlinable_string,https://github.com/fitzgen/inlinable_string,Apache-2.0 OR MIT,Nick Fitzgerald ipnet,https://github.com/krisprice/ipnet,MIT OR Apache-2.0,Kris Price iri-string,https://github.com/lo48576/iri-string,MIT OR Apache-2.0,YOSHIOKA Takuma itertools,https://github.com/rust-itertools/itertools,MIT OR Apache-2.0,bluss itoa,https://github.com/dtolnay/itoa,MIT OR Apache-2.0,David Tolnay -jiff,https://github.com/BurntSushi/jiff,Unlicense OR MIT,Andrew Gallant -jiff-core,https://github.com/BurntSushi/jiff,Unlicense OR MIT,Andrew Gallant -jiff-static,https://github.com/BurntSushi/jiff,Unlicense OR MIT,Andrew Gallant -jiff-tzdb,https://github.com/BurntSushi/jiff,Unlicense OR MIT,Andrew Gallant -jiff-tzdb-platform,https://github.com/BurntSushi/jiff,Unlicense OR MIT,Andrew Gallant jni,https://github.com/jni-rs/jni-rs,MIT OR Apache-2.0,Josh Chase jni-sys,https://github.com/jni-rs/jni-sys,MIT OR Apache-2.0,Steven Fackler jni-sys,https://github.com/jni-rs/jni-sys,MIT OR Apache-2.0,"Steven Fackler , Robert Bragg " jni-sys-macros,https://github.com/jni-rs/jni-sys,MIT OR Apache-2.0,Robert Bragg -jobserver,https://github.com/rust-lang/jobserver-rs,MIT OR Apache-2.0,Alex Crichton js-sys,https://github.com/wasm-bindgen/wasm-bindgen/tree/master/crates/js-sys,MIT OR Apache-2.0,The wasm-bindgen Developers lazy_static,https://github.com/rust-lang-nursery/lazy-static.rs,MIT OR Apache-2.0,Marvin Löbel leb128fmt,https://github.com/bluk/leb128fmt,MIT OR Apache-2.0,Bryant Luk @@ -142,6 +123,7 @@ libdd-capabilities,https://github.com/DataDog/libdatadog/tree/main/libdd-capabil libdd-capabilities-impl,https://github.com/DataDog/libdatadog/tree/main/libdd-capabilities-impl,Apache-2.0,The libdd-capabilities-impl Authors libdd-common,https://github.com/DataDog/libdatadog/tree/main/datadog-common,Apache-2.0,The libdd-common Authors libdd-data-pipeline,https://github.com/DataDog/libdatadog/tree/main/libdd-data-pipeline,Apache-2.0,The libdd-data-pipeline Authors +libdd-data-pipeline-core,https://github.com/DataDog/libdatadog/tree/main/libdd-data-pipeline-core,Apache-2.0,The libdd-data-pipeline-core Authors libdd-ddsketch,https://github.com/DataDog/libdatadog/tree/main/libdd-ddsketch,Apache-2.0,The libdd-ddsketch Authors libdd-dogstatsd-client,https://github.com/DataDog/libdatadog/tree/main/libdd-dogstatsd-client,Apache-2.0,The libdd-dogstatsd-client Authors libdd-library-config,https://github.com/DataDog/libdatadog/tree/main/libdd-library-config,Apache-2.0,The libdd-library-config Authors @@ -150,6 +132,7 @@ libdd-sampling,https://github.com/DataDog/libdatadog/tree/main/libdd-sampling,Ap libdd-shared-runtime,https://github.com/DataDog/libdatadog/tree/main/libdd-shared-runtime,Apache-2.0,The libdd-shared-runtime Authors libdd-telemetry,https://github.com/DataDog/libdatadog/tree/main/libdd-telemetry,Apache-2.0,The libdd-telemetry Authors libdd-tinybytes,https://github.com/DataDog/libdatadog/tree/main/libdd-tinybytes,Apache-2.0,The libdd-tinybytes Authors +libdd-trace-model,https://github.com/DataDog/libdatadog/tree/main/libdd-trace-model,Apache-2.0,Datadog Inc. libdd-trace-normalization,https://github.com/DataDog/libdatadog/tree/main/libdd-trace-normalization,Apache-2.0,David Lee libdd-trace-obfuscation,https://github.com/DataDog/libdatadog/tree/main/libdd-trace-obfuscation,Apache-2.0,Datadog Inc. libdd-trace-protobuf,https://github.com/DataDog/libdatadog/tree/main/libdd-trace-protobuf,Apache-2.0,The libdd-trace-protobuf Authors @@ -157,6 +140,7 @@ libdd-trace-stats,https://github.com/DataDog/libdatadog/tree/main/libdd-trace-st libdd-trace-utils,https://github.com/DataDog/libdatadog/tree/main/libdd-trace-utils,Apache-2.0,The libdd-trace-utils Authors libddwaf,https://github.com/DataDog/libddwaf-rust,Apache-2.0,"DataDog, Inc. " libddwaf-sys,https://github.com/DataDog/libddwaf-rust,Apache-2.0,"DataDog, Inc. " +libyaml-rs,https://github.com/yaml/libyaml-rs,MIT,"David Tolnay , YAML Organization " linux-raw-sys,https://github.com/sunfishcode/linux-raw-sys,Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT,Dan Gohman litemap,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Project Developers lock_api,https://github.com/Amanieu/parking_lot,MIT OR Apache-2.0,Amanieu d'Antras @@ -192,9 +176,7 @@ percent-encoding,https://github.com/servo/rust-url,MIT OR Apache-2.0,The rust-ur pin-project,https://github.com/taiki-e/pin-project,Apache-2.0 OR MIT,The pin-project Authors pin-project-internal,https://github.com/taiki-e/pin-project,Apache-2.0 OR MIT,The pin-project-internal Authors pin-project-lite,https://github.com/taiki-e/pin-project-lite,Apache-2.0 OR MIT,The pin-project-lite Authors -pin-utils,https://github.com/rust-lang-nursery/pin-utils,MIT OR Apache-2.0,Josef Brandl portable-atomic,https://github.com/taiki-e/portable-atomic,Apache-2.0 OR MIT,The portable-atomic Authors -portable-atomic-util,https://github.com/taiki-e/portable-atomic-util,Apache-2.0 OR MIT,The portable-atomic-util Authors potential_utf,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Project Developers powerfmt,https://github.com/jhpratt/powerfmt,MIT OR Apache-2.0,Jacob Pratt ppv-lite86,https://github.com/cryptocorrosion/cryptocorrosion,MIT OR Apache-2.0,The CryptoCorrosion Contributors @@ -246,7 +228,6 @@ rusty-fork,https://github.com/altsysrq/rusty-fork,MIT OR Apache-2.0,Jason Lingle ryu,https://github.com/dtolnay/ryu,Apache-2.0 OR BSL-1.0,David Tolnay safemem,https://github.com/abonander/safemem,MIT OR Apache-2.0,Austin Bonander schannel,https://github.com/steffengy/schannel-rs,MIT,"Steven Fackler , Steffen Butzer " -schemars,https://github.com/GREsau/schemars,MIT,Graham Esau scopeguard,https://github.com/bluss/scopeguard,MIT OR Apache-2.0,bluss security-framework,https://github.com/kornelski/rust-security-framework,MIT OR Apache-2.0,"Steven Fackler , Kornel " security-framework-sys,https://github.com/kornelski/rust-security-framework,MIT OR Apache-2.0,"Steven Fackler , Kornel " @@ -262,13 +243,10 @@ serde_html_form,https://github.com/jplatte/serde_html_form,MIT,The serde_html_fo serde_json,https://github.com/serde-rs/json,MIT OR Apache-2.0,"Erick Tryzelaar , David Tolnay " serde_path_to_error,https://github.com/dtolnay/path-to-error,MIT OR Apache-2.0,David Tolnay serde_urlencoded,https://github.com/nox/serde_urlencoded,MIT OR Apache-2.0,Anthony Ramine -serde_with,https://github.com/jonasbb/serde_with,MIT OR Apache-2.0,"Jonas Bushart, Marcin Kaźmierczak" -serde_with_macros,https://github.com/jonasbb/serde_with,MIT OR Apache-2.0,Jonas Bushart serde_yaml,https://github.com/dtolnay/serde-yaml,MIT OR Apache-2.0,David Tolnay sha1,https://github.com/RustCrypto/hashes,MIT OR Apache-2.0,RustCrypto Developers sha2,https://github.com/RustCrypto/hashes,MIT OR Apache-2.0,RustCrypto Developers sharded-slab,https://github.com/hawkw/sharded-slab,MIT,Eliza Weisman -shlex,https://github.com/comex/rust-shlex,MIT OR Apache-2.0,"comex , Fenhl , Adrian Taylor , Alex Touchet , Daniel Parks , Garrett Berg " signal-hook-registry,https://github.com/vorner/signal-hook,MIT OR Apache-2.0,"Michal 'vorner' Vaner , Masaki Hara " simd-adler32,https://github.com/mcountryman/simd-adler32,MIT,Marvin Countryman slab,https://github.com/tokio-rs/slab,MIT,Carl Lerche @@ -276,7 +254,6 @@ smallvec,https://github.com/servo/rust-smallvec,MIT OR Apache-2.0,The Servo Proj socket2,https://github.com/rust-lang/socket2,MIT OR Apache-2.0,"Alex Crichton , Thomas de Zeeuw " stable_deref_trait,https://github.com/storyyeller/stable_deref_trait,MIT OR Apache-2.0,Robert Grosse static_assertions,https://github.com/nvzqz/static-assertions-rs,MIT OR Apache-2.0,Nikolai Vazquez -strsim,https://github.com/rapidfuzz/strsim-rs,MIT,"Danny Guo , maxbachmann " strum,https://github.com/Peternator7/strum,MIT,Peter Glotfelty strum_macros,https://github.com/Peternator7/strum,MIT,Peter Glotfelty subtle,https://github.com/dalek-cryptography/subtle,BSD-3-Clause,"Isis Lovecruft , Henry de Valence " @@ -348,32 +325,18 @@ web-time,https://github.com/daxpedda/web-time,MIT OR Apache-2.0,The web-time Aut webpki-root-certs,https://github.com/rustls/webpki-roots,CDLA-Permissive-2.0,The webpki-root-certs Authors webpki-roots,https://github.com/rustls/webpki-roots,CDLA-Permissive-2.0,The webpki-roots Authors windows,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft -windows-core,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows-core Authors -windows-implement,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows-implement Authors -windows-interface,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows-interface Authors windows-link,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows-link Authors -windows-result,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows-result Authors -windows-strings,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows-strings Authors windows-sys,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft windows-sys,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows-sys Authors windows-targets,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft -windows-targets,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows-targets Authors windows_aarch64_gnullvm,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft -windows_aarch64_gnullvm,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows_aarch64_gnullvm Authors windows_aarch64_msvc,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft -windows_aarch64_msvc,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows_aarch64_msvc Authors windows_i686_gnu,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft -windows_i686_gnu,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows_i686_gnu Authors windows_i686_gnullvm,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft -windows_i686_gnullvm,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows_i686_gnullvm Authors windows_i686_msvc,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft -windows_i686_msvc,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows_i686_msvc Authors windows_x86_64_gnu,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft -windows_x86_64_gnu,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows_x86_64_gnu Authors windows_x86_64_gnullvm,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft -windows_x86_64_gnullvm,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows_x86_64_gnullvm Authors windows_x86_64_msvc,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,Microsoft -windows_x86_64_msvc,https://github.com/microsoft/windows-rs,MIT OR Apache-2.0,The windows_x86_64_msvc Authors winver,https://github.com/rhysd/winver,MIT,rhysd wit-bindgen,https://github.com/bytecodealliance/wit-bindgen,Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT,Alex Crichton wit-bindgen-core,https://github.com/bytecodealliance/wit-bindgen,Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT,Alex Crichton @@ -382,6 +345,7 @@ wit-bindgen-rust-macro,https://github.com/bytecodealliance/wit-bindgen,Apache-2. wit-component,https://github.com/bytecodealliance/wasm-tools/tree/main/crates/wit-component,Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT,Peter Huene wit-parser,https://github.com/bytecodealliance/wasm-tools/tree/main/crates/wit-parser,Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT,Alex Crichton writeable,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Project Developers +yaml_serde,https://github.com/yaml/yaml-serde,MIT OR Apache-2.0,YAML Organization yansi,https://github.com/SergioBenitez/yansi,MIT OR Apache-2.0,Sergio Benitez yoke,https://github.com/unicode-org/icu4x,Unicode-3.0,Manish Goregaokar yoke-derive,https://github.com/unicode-org/icu4x,Unicode-3.0,Manish Goregaokar @@ -394,6 +358,10 @@ zerotrie,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Project Deve zerovec,https://github.com/unicode-org/icu4x,Unicode-3.0,The ICU4X Project Developers zerovec-derive,https://github.com/unicode-org/icu4x,Unicode-3.0,Manish Goregaokar zmij,https://github.com/dtolnay/zmij,MIT,David Tolnay -zstd,https://github.com/gyscos/zstd-rs,MIT,Alexandre Bury -zstd-safe,https://github.com/gyscos/zstd-rs,MIT OR Apache-2.0,Alexandre Bury -zstd-sys,https://github.com/gyscos/zstd-rs,MIT OR Apache-2.0,Alexandre Bury +zrip,https://github.com/paddor/zrip,MIT,The zrip Authors +zrip-core,https://github.com/paddor/zrip,MIT,The zrip-core Authors +zrip-decode,https://github.com/paddor/zrip,MIT,The zrip-decode Authors +zrip-encode,https://github.com/paddor/zrip,MIT,The zrip-encode Authors +zstd,https://github.com/gyscos/zstd-rs,BSD-3-Clause,Alexandre Bury +zstd-safe,https://github.com/gyscos/zstd-rs,BSD-3-Clause,Alexandre Bury +zstd-sys,https://github.com/gyscos/zstd-rs,BSD-3-Clause,Alexandre Bury diff --git a/bottlecap/deny.toml b/bottlecap/deny.toml index 6f0ee7270..2a5184055 100644 --- a/bottlecap/deny.toml +++ b/bottlecap/deny.toml @@ -39,26 +39,12 @@ unsound = "workspace" # once a FIPS-certified aws-lc-rs is available. Trivy reports # RUSTSEC-2026-0285 as GHSA-2mjx-qc3c-rqvc, ignored in .trivyignore.yaml. # -# The zstd advisories cover APIs this graph does not call: bottlecap, the -# serverless-components crates and libdd-trace-utils compress through -# `stream::write::Encoder` / the bulk API; the only decoding is -# `stream::read::Decoder` on the embedded AppSec ruleset and `decode_all` in -# a test helper, both excluded by RUSTSEC-2026-0403. Only libddwaf-sys's build -# script enables zstd's default (legacy) features; build-dependency features -# resolve separately, so the shipped binary has no legacy-frame support. -# zstd-safe 7.2.4 also has unsound notices RUSTSEC-2026-0395 to 0406 that the -# `workspace` scope does not report; the same zstd 0.14 / zstd-safe 8.2 bump -# fixes them (needs the same bump in serverless-components and libdatadog); -# drop these ignores with it. ignore = [ { id = "RUSTSEC-2026-0285", reason = "rustls fix needs aws-lc-rs >= 1.18 (AWS-LC-FIPS 4.x, uncertified)" }, { id = "RUSTSEC-2026-0346", reason = "rustls fix needs aws-lc-rs >= 1.18 (AWS-LC-FIPS 4.x, uncertified)" }, { id = "RUSTSEC-2026-0348", reason = "rustls fix needs aws-lc-rs >= 1.18 (AWS-LC-FIPS 4.x, uncertified)" }, { id = "RUSTSEC-2026-0349", reason = "rustls fix needs aws-lc-rs >= 1.18 (AWS-LC-FIPS 4.x, uncertified)" }, { id = "RUSTSEC-2026-0382", reason = "rustls-webpki fix needs aws-lc-rs ^1.18 (AWS-LC-FIPS 4.x, uncertified)" }, - { id = "RUSTSEC-2026-0391", reason = "zstd `with_context` is not used anywhere in the graph; fix is zstd 0.14" }, - { id = "RUSTSEC-2026-0398", reason = "zstd-safe `seekable` feature is not enabled; fix is zstd 0.14" }, - { id = "RUSTSEC-2026-0403", reason = "only `stream::read::Decoder` and `decode_all` are used, which the advisory excludes; runtime zstd-sys is built without the `legacy` feature" }, { id = "RUSTSEC-2026-0410", reason = "wasm32 only; the extension ships on Linux" }, { id = "RUSTSEC-2023-0050", reason = "multipart 0.18 is unmaintained; it parses AppSec multipart request bodies; no maintained replacement is chosen yet" }, { id = "RUSTSEC-2025-0134", reason = "rustls-pemfile is unmaintained; replace with rustls-pki-types PEM parsing (code change, not a version bump)" }, diff --git a/bottlecap/src/appsec/processor/context.rs b/bottlecap/src/appsec/processor/context.rs index 94f237ae1..19350201b 100644 --- a/bottlecap/src/appsec/processor/context.rs +++ b/bottlecap/src/appsec/processor/context.rs @@ -6,7 +6,9 @@ use std::time::Duration; use bytes::{Buf, Bytes}; use libdd_trace_protobuf::pb::Span; use libddwaf::object::{Keyed, WafMap, WafObject}; -use libddwaf::{Context as WafContext, Handle, RunError, RunOutput, RunResult, waf_map}; +use libddwaf::{ + Context as WafContext, Handle, RunError, RunOutput, RunResult, RunnableContext, waf_map, +}; use mime::Mime; use multipart::server::Multipart; use tracing::{debug, info, warn}; @@ -56,7 +58,7 @@ impl Context { (TagName::AppsecEnabled, TagValue::Metric(1.0)), ( TagName::AppsecWafVersion, - TagValue::Always(libddwaf::get_version().to_string_lossy().to_string()), + TagValue::Always(libddwaf::version().to_string_lossy().to_string()), ), ]); if !ruleset_version.is_empty() { @@ -185,7 +187,7 @@ impl Context { }; // Evaluate the WAF ruleset and handle the result. - match self.waf.run(Some(address_data), None, self.waf_timeout) { + match self.waf.run(address_data, self.waf_timeout) { Ok(RunResult::Match(result) | RunResult::NoMatch(result)) => { self.process_result(result); } @@ -218,7 +220,7 @@ impl Context { ("extract-schema", true) }) }; - match self.waf.run(Some(address_data), None, self.waf_timeout) { + match self.waf.run(address_data, self.waf_timeout) { Ok(RunResult::Match(result) | RunResult::NoMatch(result)) => { self.process_result(result); } @@ -454,7 +456,7 @@ impl Context { let value = if let Some(value) = item.to_str() { value.to_string() } else { - match serde_json::to_string(item.inner()) { + match serde_json::to_string(item.value()) { Ok(value) => value, Err(e) => { warn!( @@ -649,7 +651,8 @@ fn to_address_data(payload: &dyn InvocationPayload) -> Option { ($field:ident[] => $name:literal) => { let value = payload.$field(); if !value.is_empty() { - let mut waf_value = libddwaf::object::WafMap::new(value.len() as u64); + let mut waf_value = libddwaf::object::WafMap::new(value.len()) + .expect("WAF map length is representable"); for (idx, (key, item)) in value.iter().enumerate() { waf_value[idx] = (key.as_str(), item.as_str()).into(); } @@ -661,9 +664,11 @@ fn to_address_data(payload: &dyn InvocationPayload) -> Option { ($field:ident[][] => $name:literal) => { let value = payload.$field(); if !value.is_empty() { - let mut waf_value = libddwaf::object::WafMap::new(value.len() as u64); + let mut waf_value = libddwaf::object::WafMap::new(value.len()) + .expect("WAF map length is representable"); for (idx, (key, elements)) in value.iter().enumerate() { - let mut waf_elements = libddwaf::object::WafArray::new(elements.len() as u64); + let mut waf_elements = libddwaf::object::WafArray::new(elements.len()) + .expect("WAF array length is representable"); for (idx, elt) in elements.iter().enumerate() { waf_elements[idx] = elt.as_str().into(); } @@ -692,7 +697,7 @@ fn to_address_data(payload: &dyn InvocationPayload) -> Option { return None; } - let mut result = WafMap::new(addresses.len() as u64); + let mut result = WafMap::new(addresses.len()).expect("WAF map length is representable"); for (idx, item) in addresses.into_iter().enumerate() { result[idx] = item; } @@ -717,7 +722,7 @@ fn try_parse_body_with_mime(body: impl Read, mime_type: Mime) -> Result { let pairs: Vec<(String, String)> = serde_html_form::from_reader(body)?; - let mut res = WafMap::new(pairs.len() as u64); + let mut res = WafMap::new(pairs.len()).expect("WAF map length is representable"); for (i, (key, value)) in pairs.into_iter().enumerate() { res[i] = (key.as_str(), value.as_str()).into(); } @@ -758,7 +763,7 @@ fn try_parse_body_with_mime(body: impl Read, mime_type: Mime) -> Result::default(); + let mut diagnostics = WafOwnedDefaultAllocator::::default(); if !builder.add_or_update_config("rules", &rules, Some(&mut diagnostics)) { return Err(Error::WafRulesetLoadingError(diagnostics)); } - let ruleset_version = - if let Some(version) = diagnostics.get(b"ruleset_version").and_then(|o| o.to_str()) { - debug!("aap: loaded ruleset version {version}"); - version.to_string() - } else { - String::new() - }; + let ruleset_version = if let Some(version) = diagnostics + .get_bstr(b"ruleset_version") + .and_then(|o| o.to_str()) + { + debug!("aap: loaded ruleset version {version}"); + version.to_string() + } else { + String::new() + }; let Some(handle) = builder.build() else { return Err(Error::WafInitializationFailed); @@ -299,7 +301,7 @@ pub enum Error { WafRulesetParseError(serde_json::Error), /// The App & API Protection ruleset could not be loaded into the WAF #[error("aap: failed to load configured WAF ruleset: {0:?}")] - WafRulesetLoadingError(WafOwned), + WafRulesetLoadingError(WafOwnedDefaultAllocator), /// The WAF initialization produced a [`None`] handle (this happens when the /// configured ruleset contains no active rule nor processor) #[error( diff --git a/bottlecap/src/config/propagation_wrapper.rs b/bottlecap/src/config/propagation_wrapper.rs index f2688de5d..8431d84f4 100644 --- a/bottlecap/src/config/propagation_wrapper.rs +++ b/bottlecap/src/config/propagation_wrapper.rs @@ -1,6 +1,8 @@ use std::sync::Arc; -use datadog_opentelemetry::configuration::TracePropagationBehaviorExtract; +use datadog_opentelemetry::configuration::{ + TracePropagationBehaviorExtract, TracePropagationStyle as OtelTracePropagationStyle, +}; use datadog_opentelemetry::propagation::PropagationConfig; use crate::config::{Config, TracePropagationStyle}; @@ -11,39 +13,70 @@ use crate::config::{Config, TracePropagationStyle}; /// wrapper is the local type the impl can attach to. Callers that need a /// propagator hand it an `Arc` instead of an `Arc`. #[derive(Debug, Clone)] -pub struct PropConfig(Arc); +pub struct PropConfig { + config: Arc, + trace_propagation_style: Vec, + trace_propagation_style_extract: Vec, +} impl PropConfig { #[must_use] pub fn new(config: Arc) -> Arc { - Arc::new(Self(config)) + Arc::new(Self { + trace_propagation_style: config + .trace_propagation_style + .iter() + .copied() + .map(convert_trace_propagation_style) + .collect(), + trace_propagation_style_extract: config + .trace_propagation_style_extract + .iter() + .copied() + .map(convert_trace_propagation_style) + .collect(), + config, + }) + } +} + +const fn convert_trace_propagation_style( + style: TracePropagationStyle, +) -> OtelTracePropagationStyle { + match style { + TracePropagationStyle::Datadog => OtelTracePropagationStyle::Datadog, + TracePropagationStyle::TraceContext => OtelTracePropagationStyle::TraceContext, + TracePropagationStyle::Baggage => OtelTracePropagationStyle::Baggage, + TracePropagationStyle::B3Multi => OtelTracePropagationStyle::B3Multi, + TracePropagationStyle::B3SingleHeader => OtelTracePropagationStyle::B3SingleHeader, + TracePropagationStyle::None => OtelTracePropagationStyle::None, } } impl PropagationConfig for PropConfig { - fn trace_propagation_style(&self) -> Option<&[TracePropagationStyle]> { - if self.0.trace_propagation_style.is_empty() { + fn trace_propagation_style(&self) -> Option<&[OtelTracePropagationStyle]> { + if self.trace_propagation_style.is_empty() { None } else { - Some(&self.0.trace_propagation_style) + Some(&self.trace_propagation_style) } } - fn trace_propagation_style_extract(&self) -> Option<&[TracePropagationStyle]> { - if self.0.trace_propagation_style_extract.is_empty() { + fn trace_propagation_style_extract(&self) -> Option<&[OtelTracePropagationStyle]> { + if self.trace_propagation_style_extract.is_empty() { None } else { - Some(&self.0.trace_propagation_style_extract) + Some(&self.trace_propagation_style_extract) } } - fn trace_propagation_style_inject(&self) -> Option<&[TracePropagationStyle]> { + fn trace_propagation_style_inject(&self) -> Option<&[OtelTracePropagationStyle]> { // Bottlecap does not configure injection styles separately. None } fn trace_propagation_extract_first(&self) -> bool { - self.0.trace_propagation_extract_first + self.config.trace_propagation_extract_first } fn trace_propagation_behavior_extract(&self) -> TracePropagationBehaviorExtract { diff --git a/bottlecap/src/lifecycle/invocation/processor.rs b/bottlecap/src/lifecycle/invocation/processor.rs index 91856ea21..26a9fe417 100644 --- a/bottlecap/src/lifecycle/invocation/processor.rs +++ b/bottlecap/src/lifecycle/invocation/processor.rs @@ -2292,7 +2292,7 @@ mod tests { let trace_sender = Arc::new(SendingTraceProcessor { appsec: None, processor: Arc::new(trace_processor::ServerlessTraceProcessor { - obfuscation_config: Arc::new(ObfuscationConfig::new().expect("Failed to create ObfuscationConfig")), + obfuscation_config: Arc::new(ObfuscationConfig::default()), error_sampler: trace_processor::enabled_error_sampler(), error_rare_sample_tracer_drop: false, }), @@ -2402,9 +2402,7 @@ mod tests { let trace_sender = Arc::new(SendingTraceProcessor { appsec: None, processor: Arc::new(trace_processor::ServerlessTraceProcessor { - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), error_sampler: trace_processor::enabled_error_sampler(), error_rare_sample_tracer_drop: false, }), @@ -2971,8 +2969,8 @@ mod tests { fn test_extract_span_context_priority_order() { let config = Arc::new(config::Config { trace_propagation_style_extract: vec![ - datadog_opentelemetry::propagation::TracePropagationStyle::Datadog, - datadog_opentelemetry::propagation::TracePropagationStyle::TraceContext, + config::TracePropagationStyle::Datadog, + config::TracePropagationStyle::TraceContext, ], ..config::Config::default() }); @@ -3009,8 +3007,8 @@ mod tests { fn test_extract_span_context_no_request_headers() { let config = Arc::new(config::Config { trace_propagation_style_extract: vec![ - datadog_opentelemetry::propagation::TracePropagationStyle::Datadog, - datadog_opentelemetry::propagation::TracePropagationStyle::TraceContext, + config::TracePropagationStyle::Datadog, + config::TracePropagationStyle::TraceContext, ], ..config::Config::default() }); @@ -3042,9 +3040,7 @@ mod tests { Arc::new(SendingTraceProcessor { appsec: None, processor: Arc::new(trace_processor::ServerlessTraceProcessor { - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), error_sampler: trace_processor::enabled_error_sampler(), error_rare_sample_tracer_drop: false, }), @@ -3625,9 +3621,7 @@ mod tests { let sender = Arc::new(SendingTraceProcessor { appsec: None, processor: Arc::new(trace_processor::ServerlessTraceProcessor { - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), error_sampler: trace_processor::enabled_error_sampler(), error_rare_sample_tracer_drop: false, }), diff --git a/bottlecap/src/lifecycle/invocation/processor_service.rs b/bottlecap/src/lifecycle/invocation/processor_service.rs index 093ca8bba..a77e888bd 100644 --- a/bottlecap/src/lifecycle/invocation/processor_service.rs +++ b/bottlecap/src/lifecycle/invocation/processor_service.rs @@ -841,7 +841,7 @@ mod tests { let trace_sender = Arc::new(SendingTraceProcessor { appsec: None, processor: Arc::new(ServerlessTraceProcessor { - obfuscation_config: Arc::new(ObfuscationConfig::new().expect("ObfuscationConfig")), + obfuscation_config: Arc::new(ObfuscationConfig::default()), error_sampler, error_rare_sample_tracer_drop: false, }), diff --git a/bottlecap/src/lifecycle/invocation/span_inferrer.rs b/bottlecap/src/lifecycle/invocation/span_inferrer.rs index 3afa1a789..c0a17cb6d 100644 --- a/bottlecap/src/lifecycle/invocation/span_inferrer.rs +++ b/bottlecap/src/lifecycle/invocation/span_inferrer.rs @@ -480,10 +480,9 @@ pub fn extract_generated_span_context( #[cfg(test)] mod tests { use super::*; - use crate::config::LambdaConfig; + use crate::config::{LambdaConfig, TracePropagationStyle}; use crate::lifecycle::invocation::triggers::test_utils::read_json_file; use crate::traces::propagation::DatadogCompositePropagator; - use datadog_opentelemetry::propagation::TracePropagationStyle; use serde_json::json; use std::sync::Arc; use tokio::time::Instant; diff --git a/bottlecap/src/startup.rs b/bottlecap/src/startup.rs index 4c1aa9355..cf12b0939 100644 --- a/bottlecap/src/startup.rs +++ b/bottlecap/src/startup.rs @@ -15,7 +15,9 @@ use std::{env, sync::Arc}; use dogstatsd::api_key::ApiKeyFactory; +use libdd_common::regex_engine::{Regex, Replacer}; use libdd_trace_obfuscation::obfuscation_config; +use libdd_trace_obfuscation::replacer::ReplaceRule; use tokio::sync::{Mutex as TokioMutex, mpsc::Sender}; use tokio_util::sync::CancellationToken; use tracing::{error, warn}; @@ -51,6 +53,27 @@ pub struct TraceAgentPipeline { pub trace_aggregator_handle: TraceAggregatorHandle, } +fn build_tag_replace_rules(config: &Config) -> Vec { + config + .apm_replace_tags + .as_ref() + .map_or_else(Vec::new, |rules| { + rules + .iter() + .map(|rule| { + let replacement = rule.repl.clone(); + ReplaceRule { + name: rule.name.clone(), + re: Regex::new(rule.re.as_str()) + .expect("agent config has already validated replacement tag patterns"), + no_expansion: Replacer::no_expansion(&mut replacement.as_str()).is_some(), + repl: replacement, + } + }) + .collect() + }) +} + /// Builds the full trace-processing pipeline (trace + stats + proxy /// aggregators, services, flushers) and the [`trace_agent::TraceAgent`] that /// owns the HTTP listener. Spawns the aggregator/concentrator/dedup services @@ -126,9 +149,9 @@ pub fn build_trace_agent( )); let obfuscation_config = obfuscation_config::ObfuscationConfig { - tag_replace_rules: config.apm_replace_tags.clone(), + tag_replace_rules: build_tag_replace_rules(config), http: obfuscation_config::HttpConfig { - remove_paths_with_digits: config.apm_config_obfuscation_http_remove_paths_with_digits, + remove_path_digits: config.apm_config_obfuscation_http_remove_paths_with_digits, remove_query_string: config.apm_config_obfuscation_http_remove_query_string, }, ..Default::default() @@ -237,3 +260,40 @@ pub fn start_trace_agent( pipeline } + +#[cfg(test)] +mod tests { + use libdd_trace_obfuscation::replacer::{parse_rules_from_string, replace_span_tags}; + use libdd_trace_protobuf::pb::Span; + + use super::{Config, build_tag_replace_rules}; + + #[test] + fn build_tag_replace_rules_preserves_literal_and_capture_replacements() { + let mut config = Config::default(); + assert!(build_tag_replace_rules(&config).is_empty()); + + config.apm_replace_tags = Some( + parse_rules_from_string( + r#"[ + {"name":"literal","pattern":"secret","repl":"[REDACTED]"}, + {"name":"capture","pattern":"token=([^&]+)","repl":"value=$1"} + ]"#, + ) + .expect("valid replacement rules"), + ); + + let rules = build_tag_replace_rules(&config); + assert!(rules[0].no_expansion); + assert!(!rules[1].no_expansion); + + let mut span = Span::default(); + span.meta.insert("literal".to_owned(), "secret".to_owned()); + span.meta + .insert("capture".to_owned(), "token=example".to_owned()); + replace_span_tags(&mut span, &rules, &mut String::new()); + + assert_eq!(span.meta["literal"], "[REDACTED]"); + assert_eq!(span.meta["capture"], "value=example"); + } +} diff --git a/bottlecap/src/traces/http_client.rs b/bottlecap/src/traces/http_client.rs index 0c4cb1187..5980c95e5 100644 --- a/bottlecap/src/traces/http_client.rs +++ b/bottlecap/src/traces/http_client.rs @@ -57,7 +57,7 @@ impl HttpClientCapability for HttpClient { } #[allow(clippy::expect_used)] - fn new_without_connection_pooling() -> Self { + fn new_periodic() -> Self { // `create_client` always disables connection pooling (see its comment above), so // this is equivalent to `new_client()`. Self::new_client() diff --git a/bottlecap/src/traces/propagation/mod.rs b/bottlecap/src/traces/propagation/mod.rs index 0d591a303..5a8207369 100644 --- a/bottlecap/src/traces/propagation/mod.rs +++ b/bottlecap/src/traces/propagation/mod.rs @@ -96,7 +96,7 @@ impl DatadogCompositePropagator { mod tests { use std::collections::HashMap; - use datadog_opentelemetry::propagation::TracePropagationStyle; + use crate::config::TracePropagationStyle; use super::*; diff --git a/bottlecap/src/traces/stats_concentrator_service.rs b/bottlecap/src/traces/stats_concentrator_service.rs index 1166bbc14..f980569f3 100644 --- a/bottlecap/src/traces/stats_concentrator_service.rs +++ b/bottlecap/src/traces/stats_concentrator_service.rs @@ -434,7 +434,6 @@ impl StatsConcentratorService { // Span meta keys included as additional aggregation dimensions, from // DD_TRACE_STATS_ADDITIONAL_TAGS (only set when experimental_features_enabled). additional_metric_tag_keys, - // Resource key obfuscation is handled separately in this extension; not used here. None, ); // After construction, so the kept keys can be read back off the concentrator rather than @@ -478,11 +477,9 @@ impl StatsConcentratorService { ) { let flush_result = self.concentrator.flush(SystemTime::now(), force_flush); let collapsed_spans = flush_result.collapsed_spans; - // Obfuscation is excluded at the feature level: bottlecap's `libdd-trace-stats` - // dependency does not enable `stats-obfuscation`, so every bucket ends up in - // `unobfuscated_buckets`; combine both to stay correct if that ever changes. Start - // from `unobfuscated_buckets` since it's normally the only non-empty one, avoiding a - // reallocation to grow the (usually empty) `obfuscated_buckets` vec. + // No obfuscation config is supplied to the concentrator, so buckets normally remain + // unobfuscated. Combine both vectors in case that configuration is added. Start from + // `unobfuscated_buckets` to avoid reallocating for the normally empty obfuscated vector. let mut stats_buckets = flush_result.unobfuscated_buckets; stats_buckets.extend(flush_result.obfuscated_buckets); self.report_collapse(&stats_buckets, collapsed_spans); diff --git a/bottlecap/src/traces/trace_agent.rs b/bottlecap/src/traces/trace_agent.rs index c8112e923..bb7bdf6cf 100644 --- a/bottlecap/src/traces/trace_agent.rs +++ b/bottlecap/src/traces/trace_agent.rs @@ -1144,7 +1144,7 @@ mod tests { let (dedup_svc, dedup_handle) = DedupService::new(); tokio::spawn(dedup_svc.run()); let trace_processor = Arc::new(trace_processor::ServerlessTraceProcessor { - obfuscation_config: Arc::new(ObfuscationConfig::new().expect("ObfuscationConfig")), + obfuscation_config: Arc::new(ObfuscationConfig::default()), error_sampler: trace_processor::new_error_sampler(false), error_rare_sample_tracer_drop: false, }); diff --git a/bottlecap/src/traces/trace_processor.rs b/bottlecap/src/traces/trace_processor.rs index 265748858..0ceb2ec92 100644 --- a/bottlecap/src/traces/trace_processor.rs +++ b/bottlecap/src/traces/trace_processor.rs @@ -19,7 +19,7 @@ use datadog_agent_trace_sampler::{ ErrorSamplerConfig, ErrorSamplerMode, ErrorsSampler, SampleDecision, SpanView, TraceView, }; use libdd_common::Endpoint; -use libdd_trace_obfuscation::obfuscate::obfuscate_span; +use libdd_trace_obfuscation::obfuscate::obfuscate_pb_span; use libdd_trace_obfuscation::obfuscation_config; use libdd_trace_protobuf::pb; use libdd_trace_protobuf::pb::Span; @@ -337,7 +337,7 @@ impl TraceChunkProcessor for ChunkProcessor { span.meta.insert("origin".to_string(), "lambda".to_string()); span.meta .insert("_dd.origin".to_string(), "lambda".to_string()); - obfuscate_span(span, &self.obfuscation_config); + obfuscate_pb_span(span, &self.obfuscation_config); } if let Some(span) = chunk.spans.get_mut(root_span_index) { @@ -862,9 +862,7 @@ mod tests { &HashMap::from([("function_arn".to_string(), "test-arn".to_string())]), )); let processor = ServerlessTraceProcessor { - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), error_sampler, error_rare_sample_tracer_drop, }; @@ -958,9 +956,7 @@ mod tests { }; let trace_processor = ServerlessTraceProcessor { - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), error_sampler: enabled_error_sampler(), error_rare_sample_tracer_drop: false, }; @@ -1220,9 +1216,7 @@ mod tests { let mut processor = ChunkProcessor { config: config.clone(), - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), tags_provider: Arc::new(Provider::new( config, "lambda".to_string(), @@ -1305,9 +1299,7 @@ mod tests { let mut processor = ChunkProcessor { config: config.clone(), - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), tags_provider: Arc::new(Provider::new( config, "lambda".to_string(), @@ -1389,9 +1381,7 @@ mod tests { let mut processor = ChunkProcessor { config: config.clone(), - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), tags_provider: Arc::new(Provider::new( config, "lambda".to_string(), @@ -2149,9 +2139,7 @@ mod tests { let tags_provider = create_tags_provider(config.clone()); ChunkProcessor { config, - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), tags_provider, span_pointers: None, client_computed_stats, @@ -2625,9 +2613,7 @@ mod tests { let sender = SendingTraceProcessor { appsec: None, processor: Arc::new(ServerlessTraceProcessor { - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), error_sampler: enabled_error_sampler(), error_rare_sample_tracer_drop: false, }), diff --git a/bottlecap/tests/apm_integration_test.rs b/bottlecap/tests/apm_integration_test.rs index ed85ada51..33565cc48 100644 --- a/bottlecap/tests/apm_integration_test.rs +++ b/bottlecap/tests/apm_integration_test.rs @@ -374,9 +374,7 @@ async fn run_processor_pipeline_with_settings( let sender = SendingTraceProcessor { appsec: None, processor: Arc::new(ServerlessTraceProcessor { - obfuscation_config: Arc::new( - ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"), - ), + obfuscation_config: Arc::new(ObfuscationConfig::default()), error_sampler: new_error_sampler(true), error_rare_sample_tracer_drop, }), diff --git a/bottlecap/tests/appsec_processor_test.rs b/bottlecap/tests/appsec_processor_test.rs index 2a18f8092..cc36b6b16 100644 --- a/bottlecap/tests/appsec_processor_test.rs +++ b/bottlecap/tests/appsec_processor_test.rs @@ -138,7 +138,7 @@ async fn test_processor() { } } } - let waf_version = libddwaf::get_version().to_string_lossy().to_string(); + let waf_version = libddwaf::version().to_string_lossy().to_string(); /// Marker for metrics we can't statically know the value of, but must be present & > 0... const ANY_POSITIVE_VALUE_IS_FINE: f64 = f64::NAN; for (rid, expected) in [ @@ -311,7 +311,7 @@ async fn test_processor() { "_dd.appsec.fp.http.header": "hdr-0000000010-40b52535-5-1e6648af", "_dd.appsec.fp.http.network": "net-1-1000000000", "_dd.appsec.fp.session": "ssn--45f15964-7f506709-", - "_dd.appsec.json": r#"{"triggers":[{"rule":{"id":"ua0-600-12x","name":"Arachni","on_match":[],"tags":{"capec":"1000/118/169","category":"attack_attempt","confidence":"1","cwe":"200","module":"waf","tool_name":"Arachni","type":"attack_tool"}},"rule_matches":[{"operator":"match_regex","operator_value":"^Arachni\\/v","parameters":[{"address":"server.request.headers.no_cookies","highlight":["Arachni/v"],"key_path":["user-agent","0"],"value":"Arachni/v2"}]}]}]}"#, + "_dd.appsec.json": r#"{"triggers":[{"rule":{"id":"ua0-600-12x","name":"Arachni","on_match":[],"tags":{"capec":"1000/118/169","category":"attack_attempt","confidence":"1","cwe":"200","module":"waf","tool_name":"Arachni","type":"attack_tool"}},"rule_matches":[{"operator":"match_regex","operator_value":"^Arachni\\/v","parameters":[{"address":"server.request.headers.no_cookies","highlight":["Arachni/v"],"key_path":["user-agent",0],"value":"Arachni/v2"}]}]}]}"#, "_dd.appsec.s.req.body": r#"[{"hello":[8]}]"#, "_dd.appsec.s.req.cookies": r#"[{"cookie1":[[[8]],{"len":1}],"cookie2":[[[8]],{"len":1}]}]"#, "_dd.appsec.s.req.headers": r#"[{"accept":[[[8]],{"len":1}],"content-length":[[[8]],{"len":1}],"host":[[[8]],{"len":1}],"user-agent":[[[8]],{"len":1}],"x-amzn-trace-id":[[[8]],{"len":1}],"x-datadog-parent-id":[[[8]],{"len":1}],"x-datadog-sampling-priority":[[[8]],{"len":1}],"x-datadog-trace-id":[[[8]],{"len":1}],"x-forwarded-for":[[[8]],{"len":1}],"x-forwarded-port":[[[8]],{"len":1}],"x-forwarded-proto":[[[8]],{"len":1}]}]"#,