llama-stack-mirror/llama_stack/providers/inline
Derek Higgins 4610c29d1e fix(files): Enforce DELETE action permission for file deletion (#4275)
Previously, file deletion only checked READ permission via the
_lookup_file_id() method. This meant any user with READ access to a file
could also delete it, making it impossible to configure read-only file
access.

This change adds an 'action' parameter to fetch_all() and fetch_one() in
AuthorizedSqlStore, defaulting to Action.READ for backward
compatibility. The openai_delete_file() method now passes Action.DELETE,
ensuring proper RBAC enforcement.

With this fix, access policies can now distinguish between Users who can
read/list files but not delete them

Closes: #4274

Signed-off-by: Derek Higgins <derekh@redhat.com>
(cherry picked from commit 4ff0c25c52)

# Conflicts:
#	llama_stack/providers/inline/files/localfs/files.py
#	llama_stack/providers/remote/files/s3/files.py
#	src/llama_stack/providers/remote/files/openai/files.py
2025-12-02 19:08:54 +00:00
..
agents feat(stores)!: use backend storage references instead of configs (#3697) 2025-10-20 13:20:09 -07:00
batches feat(stores)!: use backend storage references instead of configs (#3697) 2025-10-20 13:20:09 -07:00
datasetio feat(stores)!: use backend storage references instead of configs (#3697) 2025-10-20 13:20:09 -07:00
eval feat(stores)!: use backend storage references instead of configs (#3697) 2025-10-20 13:20:09 -07:00
files/localfs fix(files): Enforce DELETE action permission for file deletion (#4275) 2025-12-02 19:08:54 +00:00
inference chore: Updating how default embedding model is set in stack (#3818) 2025-10-20 14:22:45 -07:00
ios/inference feat(tools)!: substantial clean up of "Tool" related datatypes (#3627) 2025-10-02 15:12:03 -07:00
post_training fix: update dangling references to llama download command (#3763) 2025-10-09 18:35:02 -07:00
safety chore!: Safety api refactoring to use OpenAIMessageParam (#3796) 2025-10-12 08:01:00 -07:00
scoring feat(api)!: BREAKING CHANGE: support passing extra_body through to providers (#3777) 2025-10-10 16:21:44 -07:00
telemetry chore: skip shutdown if otel_endpoint is not set (#3865) 2025-10-20 15:48:37 -07:00
tool_runtime revert: "chore(cleanup)!: remove tool_runtime.rag_tool" (#3877) 2025-10-21 11:22:06 -07:00
vector_io fix: Vector store persistence across server restarts (backport #3977) (#4225) 2025-11-24 11:30:21 -08:00
__init__.py impls -> inline, adapters -> remote (#381) 2024-11-06 14:54:05 -08:00