GHSA-ghwv-vrp2-2975

Suggest an improvement
Source
https://github.com/advisories/GHSA-ghwv-vrp2-2975
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/11/GHSA-ghwv-vrp2-2975/GHSA-ghwv-vrp2-2975.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-ghwv-vrp2-2975
Aliases
Published
2026-11-10T15:56:54Z
Modified
2026-11-10T16:15:04Z
Severity
  • 6.3 (Medium) CVSS_V3 - CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:N CVSS Calculator
  • 7.2 (High) CVSS_V4 - 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 Calculator
Summary
Cocos AI Intra-handshake attested TLS implementation is vulnerable to TOCTOU Attacks
Details

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. Also, see the corresponding formal analysis.

Credits

This vulnerability for Cocos AI was found and responsibly disclosed by Muhammad Usama Sardar (TU Dresden, Germany).

Database specific
{
    "cwe_ids": [
        "CWE-367"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-11-10T15:56:54Z",
    "nvd_published_at": "2026-11-05T16:17:40Z",
    "severity": "HIGH"
}
References

Affected packages

Go / github.com/ultravioletrs/cocos

Package

Name
github.com/ultravioletrs/cocos
View open source insights on deps.dev
Purl
pkg:golang/github.com/ultravioletrs/cocos

Affected ranges

Type
SEMVER
Events
Introduced
0 Unknown introduced version / All previous versions are affected
Fixed
0.9.0

Database specific

last_known_affected_version_range
"<= 0.8.2"
source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/11/GHSA-ghwv-vrp2-2975/GHSA-ghwv-vrp2-2975.json"