diff --git a/apps/ai-game-creator-shell/src-tauri/src/ui_editor/html_renderer/assets.rs b/apps/ai-game-creator-shell/src-tauri/src/ui_editor/html_renderer/assets.rs index 2ba1c5913..12e9a5178 100644 --- a/apps/ai-game-creator-shell/src-tauri/src/ui_editor/html_renderer/assets.rs +++ b/apps/ai-game-creator-shell/src-tauri/src/ui_editor/html_renderer/assets.rs @@ -20,6 +20,7 @@ pub(super) fn asset_url(path: &str) -> Result { let path = path.trim(); if path.is_empty() || path.starts_with('/') + || path.contains('\\') || path.split('/').any(|part| part == "..") || path.chars().any(|character| { character.is_control() || matches!(character, '\'' | '"' | '`' | '(' | ')')