fix(tools): harden pushover security and validation

This commit is contained in:
Chummy 2026-02-17 18:25:40 +08:00
parent 82790735cf
commit d00c1140d9
3 changed files with 212 additions and 25 deletions

View file

@ -143,7 +143,10 @@ pub fn all_tools_with_runtime(
security.clone(),
workspace_dir.to_path_buf(),
)),
Box::new(PushoverTool::new(workspace_dir.to_path_buf())),
Box::new(PushoverTool::new(
security.clone(),
workspace_dir.to_path_buf(),
)),
];
if browser_config.enabled {
@ -264,6 +267,7 @@ mod tests {
let names: Vec<&str> = tools.iter().map(|t| t.name()).collect();
assert!(!names.contains(&"browser_open"));
assert!(names.contains(&"schedule"));
assert!(names.contains(&"pushover"));
}
#[test]
@ -301,6 +305,7 @@ mod tests {
);
let names: Vec<&str> = tools.iter().map(|t| t.name()).collect();
assert!(names.contains(&"browser_open"));
assert!(names.contains(&"pushover"));
}
#[test]