Skip to content

Solution for long term memory for agent coding CLIs and to facilitate handoff between different agent vendors

Rust

fix(codeql): model wiki path confinement entry points

AkitaOnRails6a94f9aba521
diff --git a/.github/codeql/extensions/ai-memory-models/models/path-barriers.model.yml b/.github/codeql/extensions/ai-memory-models/models/path-barriers.model.yml
index ebefcf04..41273b1c 100644
--- a/.github/codeql/extensions/ai-memory-models/models/path-barriers.model.yml
+++ b/.github/codeql/extensions/ai-memory-models/models/path-barriers.model.yml
@@ -1,6 +1,9 @@
-# Every wiki filesystem path crosses `tree_path`, which rejects absolute,
-# parent, root and prefix components and inspects the in-root directory chain
-# for symbolic links or Windows reparse points before returning the path.
+# Every wiki filesystem path crosses one of these typed entry points and then
+# `tree_path`, which rejects absolute, parent, root and prefix components and
+# inspects the in-root directory chain for symbolic links or Windows reparse
+# points before returning the path. Model the entry points as well as the
+# implementation boundary: CodeQL's interprocedural summary can otherwise
+# propagate request taint through a wrapper before it reaches `tree_path`.
# Treat only the validated success value as safe for filesystem operations;
# request-derived values that reach any other path construction remain tainted.
#
@@ -11,4 +14,7 @@ extensions:
pack: codeql/rust-all
extensible: barrierModel
data:
+ - ["ai_memory_wiki::confinement::project_root", "ReturnValue.Field[core::result::Result::Ok(0)]", "path-injection", "manual"]
+ - ["ai_memory_wiki::confinement::project_path", "ReturnValue.Field[core::result::Result::Ok(0)]", "path-injection", "manual"]
+ - ["ai_memory_wiki::confinement::workspace_path", "ReturnValue.Field[core::result::Result::Ok(0)]", "path-injection", "manual"]
- ["ai_memory_wiki::confinement::tree_path", "ReturnValue.Field[core::result::Result::Ok(0)]", "path-injection", "manual"]