Repository navigation
v1.5.1
Every deployment should upgrade, and soon: a signed-in user who is not an admin
could chat as another user, the admin included, by sending a second spelling of the
user id (userId) that the proxy did not check. The release also makes the role
check refuse when it cannot decide instead of letting the call through, stops
agents named like a system agent from skipping it, ties file search stores and
budgets to the agent's own project, and deletes a project's integrations, budgets
and test cases with it.
Before upgrading:
- A request to
/runor/run_ssewhose body givesuser_idanduserId(or
app_nameandappName) with different values is refused. MATE's own clients
send one spelling. - With
MATE_PLUGINS_ENABLED=true, an agent built in code needs anagents_config
row, or the role check refuses it.
No migrations.
Fixed
-
Deleting a project left its integrations, budgets and test cases behind -
_delete_projectremoved the project's agents, stores, memory blocks, widget keys, triggers and alert rules, but not:- its Slack and other channel integrations, and integrations of other projects pointing at its agents, which stayed active for an agent that no longer existed;
- the rate-limit configs of the project and its agents;
- its agents' eval test cases and their results.
A new agent with a deleted one's name inherited its budget and its test cases. They are deleted with the project now; deleting a single agent still leaves them (#276)
-
The Edit Memory Block dialog had controls that did nothing (#243) - its minimize and restore buttons and its drag handle are gone, and so are six debug
console.logcalls in the agent form scripts. Thanks to @sourabh65mehta
Security
- A signed-in user could chat as someone else, the admin included - the proxy lets a user who is not an admin run an agent only as themselves, and checked the
user_idin the body of/runand/run_sse. ADK also acceptsuserIdand uses it when a body has both, so a body with the user's ownuser_idand"userId": "admin"passed the check and ran as the admin: past the agents' role checks, and into the admin's conversations, memory and profile. Both spellings are checked now, and a body where they differ is refused. The rate-limit middleware had the same blind spot withappName, which let a request be checked against one agent's budget while another agent ran; it now reads the same values ADK uses and refuses a body whose spellings disagree. Seedocs/dev/auth-and-access.md(#276) - The role check let a model call through when it couldn't decide - before each model call the RBAC callback compares the caller's roles with the agent's
allowed_for_roles, but it allowed the call, with a warning, when there was no user id in the context, no agent name, or no enabled config for the agent, which also happens when the config lookup fails on a database error. It now refuses in all three cases, as it already did when the check raised, and so does the callback chain if the check itself fails to run; the LangGraph runtime's hook refuses an agent without a config the same way. Eval and Playground runs and the system agents still skip the check. WithMATE_PLUGINS_ENABLED=truethe check runs for every LLM agent in the app, so an agent built in code needs anagents_configrow now. Seedocs/dev/auth-and-access.md(#276) - Agents named like a system agent skipped the role check - the RBAC callback skipped any agent named
mate_fallback_agent,system_agentorhealth_check_agent, and the dashboard and thecreate_agenttool accept any name, so an agent given one of them answered everyone, whatever itsallowed_for_roles. Only the fallback agent MATE builds itself when the configuration cannot load skips the check now, recognised by its class rather than by name; the other two names belonged to no agent (#276) - A chat request could pick the project its budget was checked against - the rate-limit middleware read
project_id(orprojectId) from the body of/run_sseand checked the request against that project's limits instead of the agent's, so a caller could name a project without a budget and escape the one on the agent's project. It now ignores the body's project and the rate limit service looks the project up from the agent, as the OpenAI-compatible API already did (#276) - A file search store could be assigned to an agent of another project -
assign_store_to_agent, behindPOST /dashboard/api/agents/{name}/file-search/stores/assign, checked that the agent and the store existed, not that they belonged to the same project, so an agent could be given another project's documents. It now refuses a store of another project. The dashboard already offered only the project's own stores; Clone to Project with file search still shares the source's stores on purpose (#276)