Masked namespace vulnerability in Temporal
The ExecuteMultiOperation endpoint authorised the outer namespace but used the inner operation's namespace for policy and schema preparation, allowing an attacker to make the server resolve another tenant's configuration. This broke tenant isolation and let a developer override organisational policies with a permissive namespace.
depthfirst.com
Published on depthfirst.com
Developers love "bundled" APIs. They offer atomicity and efficiency, allowing you to chain complex state changes into a single network request.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
The server performed authorisation on the outer namespace but then trusted the untrusted inner namespace when preparing policies and schema, creating two sources of truth for identity.
Impact
An attacker could cross tenant boundaries to make the server touch another tenant's configuration, and a developer could execute workflows inside a corporate namespace while ignoring the organisation's policies.
What the attacker needed
A valid account in one namespace; ability to send ExecuteMultiOperation requests; knowledge of a target namespace name
The fix
Temporal v1.27 was fixed by rejecting any inner operation whose namespace does not match the outer authorised namespace.
How it was found
- Create a namespace with a unique private schema or permissive policies.
- Send an ExecuteMultiOperation request authorised for your own namespace.
- Include an inner startWorkflow operation whose namespace field names the victim or corporate namespace.
- Observe that the server validates the request against the inner namespace's configuration while saving under the outer namespace.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
Temporal is a system that runs background jobs reliably. A request can bundle several actions, and the server checked permission only for the outer label but then used a different label inside the bundle to look up rules. An attacker could therefore make the server read another customer's private settings, or use their own loose settings while acting inside a strict company account.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.