WEB: bounded opt-in wildcard host routing added

This commit is contained in:
Alexey
2026-10-17 23:42:26 +03:00
parent b2b088495d
commit 9738244285
67 changed files with 2572 additions and 239 deletions
+6
View File
@@ -129,6 +129,7 @@ fn runtime_config_with_carriers_and_deadlines(
host: "proxy.example.com".to_string(),
capability,
shared: Arc::new(crate::config::WebRuntimeProfileShared {
derivation_context: [0; 32],
public_addr: "203.0.113.10:443".parse().unwrap(),
user: "alice".to_string(),
secret_mode: WebSecretMode::Plain,
@@ -158,6 +159,7 @@ fn runtime_config_with_carriers_and_deadlines(
index: "index.html".to_string(),
});
let vhost = Arc::new(WebRuntimeVhost {
wildcard: None,
host: "proxy.example.com".to_string(),
base: base.to_string(),
decoy_fasttrack_mode: WebDecoyFastTrackMode::Off,
@@ -171,6 +173,7 @@ fn runtime_config_with_carriers_and_deadlines(
vhosts.insert(
"other.example.com".to_string(),
Arc::new(WebRuntimeVhost {
wildcard: None,
host: "other.example.com".to_string(),
base: "/".to_string(),
decoy_fasttrack_mode: WebDecoyFastTrackMode::Off,
@@ -193,6 +196,9 @@ fn runtime_config_with_carriers_and_deadlines(
config.web.limits.max_bootstraps_per_ip = 1;
config.web.timeouts.shutdown_secs = 1;
config.web.runtime = Some(Arc::new(WebRuntimeConfig {
snapshot_id: 0,
wildcards: Default::default(),
catch_all: None,
vhosts,
profiles: vec![profile],
capabilities: vec![capability].into_boxed_slice(),