The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.
Rust agent-orchestrationai-agentsai-assistantdesktopllmlocal-firstmcppersonal-aiprivacyrustsecond-braintauri
fix: guard privileged integration routes
Steven Enamakel324c4c2a9f4d
diff --git a/crates/openhuman-core/src/integrations/client/requests.rs b/crates/openhuman-core/src/integrations/client/requests.rsindex 8722227e10..a8d9092c9e 100644--- a/crates/openhuman-core/src/integrations/client/requests.rs+++ b/crates/openhuman-core/src/integrations/client/requests.rs@@ -8,11 +8,13 @@ pub(super) fn managed_budget_applies_to_path(path: &str) -> bool {path != "/agent-integrations/pricing" && path.starts_with("/agent-integrations/")}-fn reject_backend_webhook_path(method: &str, path: &str) -> anyhow::Result<()> {+fn reject_privileged_backend_path(method: &str, path: &str) -> anyhow::Result<()> {let route = path.split('?').next().unwrap_or(path);if route.split('/')- .any(|segment| segment.eq_ignore_ascii_case("webhooks"))+ .any(|segment| {+ segment.eq_ignore_ascii_case("webhooks") || segment.eq_ignore_ascii_case("admin")+ }){anyhow::bail!("route is intentionally not exposed by the SDK: {} {}",@@ -119,7 +121,7 @@ impl IntegrationClient {path: &str,body: Option<&serde_json::Value>,) -> anyhow::Result<T> {- reject_backend_webhook_path(method.as_str(), path)?;+ reject_privileged_backend_path(method.as_str(), path)?;enforce_backend_egress(path)?;emit_backend_egress(path);self.ensure_budget_available(path).await?;@@ -162,7 +164,7 @@ impl IntegrationClient {path: &str,form: reqwest::multipart::Form,) -> anyhow::Result<T> {- reject_backend_webhook_path("POST", path)?;+ reject_privileged_backend_path("POST", path)?;enforce_backend_egress(path)?;emit_backend_egress(path);self.ensure_budget_available(path).await?;