feat: implement CORS support with configuration options and middleware integration

This commit is contained in:
GW_MC
2025-12-19 21:34:12 +08:00
parent d861e0cd7d
commit b0b765b8fa
7 changed files with 86 additions and 9 deletions

15
Cargo.lock generated
View File

@@ -3975,6 +3975,20 @@ dependencies = [
"tracing",
]
[[package]]
name = "tower-http"
version = "0.6.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d4e6559d53cc268e5031cd8429d05415bc4cb4aefc4aa5d6cc35fbf5b924a1f8"
dependencies = [
"bitflags 2.10.0",
"bytes",
"http",
"pin-project-lite",
"tower-layer",
"tower-service",
]
[[package]]
name = "tower-layer"
version = "0.3.3"
@@ -4713,6 +4727,7 @@ dependencies = [
"serde_json",
"tokio",
"tower",
"tower-http",
"tracing",
"tracing-subscriber",
"utoipa",