# CVE-2026-119345: Cocos AI Intra-handshake attested TLS implementation is vulnerable to TOCTOU Attacks

- **Severity:** HIGH 7.2
- **CVSS:** 7.2 (v4.0, GitHub) `CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Attack requirements: Present; Privileges required: Low; User interaction: None; Confidentiality impact: High; Integrity impact: High; Availability impact: None; Confidentiality impact on other systems: None; Integrity impact on other systems: None; Availability impact on other systems: None
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.12% (percentile 1, 2026-11-28)
- **CWE:** CWE-367
- **Aliases:** GHSA-ghwv-vrp2-2975, GO-2026-6965
- **Published:** 2026-11-10T15:56:54.000Z
- **Modified:** 2026-11-23T20:30:13.562Z

## Who should check

- Projects that depend on Go package github.com/ultravioletrs/cocos (\<= 0.8.2)

## Description

\#\#\# Summary
An attacker who can modify the attested workload’s code, memory-backed state, or configuration after the initial attestation — but without necessarily terminating the existing TLS connection — can cause the peer to continue trusting the connection as if the originally attested state were still running.

\#\#\# Details
Once attestation is successfully appraised and connection is established, there is a window of vulnerability from the establishment of connection to the termination of connection where an attacker can modify the state of the workload and platform at runtime on the TLS endpoint acting as the Attester. Workload state includes code, data, and configuration. Other examples of state changes at the workload level include cases where a new device (such as a GPU) is connected, or where a connected device is disconnected, since the connection establishment.

In Cocos AI, there is no mechanism for the peer to know that some state has changed in the Attester after the connection establishment. The vulnerability is particularly concerning for long-lived connections.

In short, this vulnerability was possible because Cocos AI performs attestation only once in the lifetime of the connection (at connection establishment time) and the verifying peer continues to believe that the state is the same as in initial Evidence throughout, whereas it could be stale at some point in time.

This vulnerability for Cocos AI was found and demonstrated by Muhammad Usama Sardar via formal analysis. Formal analysis was performed in the state-of-the-art tool, ProVerif.

\#\#\# Workarounds
The proposed workaround is to allow re-attestation of the workload after periodic or user-defined intervals using post-handshake attestation.

\#\#\# Background and General Technical Details
For background and general (not specific to Cocos AI) technical details on this vulnerability, please see \`G-RA2: Freshness of Evidence\` in Sec. 5.1.1 of \[Identity Crisis in Confidential Computing: Formal Analysis of Attested TLS\](https://doi.org/10.1145/3779208.3785387). Also, see the corresponding \[formal analysis\](https://github.com/CCC-Attestation/formal-spec-id-crisis).

\#\#\# Credits
This vulnerability for Cocos AI was found and \_responsibly\_ disclosed by Muhammad Usama Sardar (TU Dresden, Germany).

## Affected and fixed versions

- Go `github.com/ultravioletrs/cocos`: affected \<= 0.8.2; fixed 0.9.0 (ghsa)

## Technologies

Go modules

## Mitigation

- Upgrade github.com/ultravioletrs/cocos to 0.9.0 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2026-119345. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-119345.md
Affected: github.com/ultravioletrs/cocos <= 0.8.2
Fixed in: 0.9.0

Steps:
1. Search this machine and project for github.com/ultravioletrs/cocos (Go): dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2026-119345 being exploited?

There is no confirmed exploitation: CVE-2026-119345 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.12% chance of exploitation in the next 30 days (as of 2026-11-28).

### How serious is CVE-2026-119345?

High: CVSS 7.2 (v4.0, scored by GitHub). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2026-119345?

github.com/ultravioletrs/cocos \<= 0.8.2.

### Is there a fix for CVE-2026-119345?

Yes. Fixed in 0.9.0. Upgrade github.com/ultravioletrs/cocos to 0.9.0 or later.

### How do I check if I'm affected by CVE-2026-119345?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- vendor: <https://github.com/ultravioletrs/cocos/security/advisories/GHSA-ghwv-vrp2-2975>
- vendor: <https://nvd.nist.gov/vuln/detail/CVE-2026-119345>
- patch: <https://github.com/ultravioletrs/cocos/pull/582>
- patch: <https://github.com/ultravioletrs/cocos/commit/80bf813c48300f02259b338b91f844c71be582ea>
- other: <https://dl.acm.org/doi/10.1145/3779208.3785387>
- other: <https://github.com/CCC-Attestation/formal-spec-id-crisis>
- other: <https://github.com/ultravioletrs/cocos/releases/tag/v0.9.0>
- other: <https://github.com/advisories/GHSA-ghwv-vrp2-2975>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- GitHub Advisory Database: CC-BY 4.0 <https://github.com/advisories/GHSA-ghwv-vrp2-2975> (license: <https://creativecommons.org/licenses/by/4.0/>)
- OSV: CC-BY 4.0 <https://osv.dev/vulnerability/GO-2026-6965> (license: <https://creativecommons.org/licenses/by/4.0/>)
- FIRST EPSS: EPSS scores by FIRST <https://www.first.org/epss/>

HTML: <https://flawdb.com/CVE-2026-119345> · JSON: <https://flawdb.com/api/v1/entries/CVE-2026-119345>
