# How to independently verify CAIN 42's convergence evidence

This bundle contains three real, live pieces of evidence produced this
session, closing gaps every prior CAIN 37-41 session explicitly flagged as
NOT ATTEMPTED:

## 1. Real MCP integration

`cain_mcp_demo_server_42.py` is a real MCP server built on the official
`mcp` Python SDK (v2.2.0). `cain42_mcp_chain.jsonl` records one real tool
invocation through CAIN's MCP Security Fabric (DISCOVER→TRUST→AUTHORIZE→
EXECUTE), captured live.

```
python3 cain_37_independent_verifier.py verify-chain cain42_mcp_chain.jsonl
python3 cain_37_independent_verifier.py verify-checkpoint cain42_mcp_chain.jsonl cain42_mcp_checkpoints.jsonl
```
Expect `VALID` both times.

## 2. Real A2A integration

`cain_a2a_demo_agent_42.py` is this session's own implementation of the
public A2A message shapes (no official Python SDK was available in this
environment). `cain42_a2a_chain.jsonl` records one real task invocation
through CAIN's A2A Security Fabric.

```
python3 cain_37_independent_verifier.py verify-chain cain42_a2a_chain.jsonl
python3 cain_37_independent_verifier.py verify-checkpoint cain42_a2a_chain.jsonl cain42_a2a_checkpoints.jsonl
```
Expect `VALID` both times.

## 3. Supply-chain provenance manifest

`cain42_provenance_manifest.json` chains git commit + dependency-lock hash
+ constitution hash (all independently recomputable from a checkout of
this repo) plus an ATTESTED (not independently recomputable without
pulling the image) container digest.

```python
import json
from cain_42_provenance_verifier import verify_provenance_manifest

manifest = json.load(open("cain42_provenance_manifest.json"))
result = verify_provenance_manifest(manifest, "/path/to/your/clone/of/cain-studio-platform")
print(result["overall_verdict"])   # VALID if your checkout matches
for link in result["links"]:
    print(link["stage"], link["verdict"])
```
`SOURCE`, `DEPENDENCY_LOCK`, and `CONFIGURATION` should show `VERIFIED`
(independently recomputed from your own checkout and matched); `IMAGE`
correctly shows `ATTESTED`, not `VERIFIED` -- this bundle does not claim to
prove the container image without you separately pulling and hashing it.

## What this does and does not prove

- Proves: CAIN's MCP and A2A trust gates work against real, live protocol
  implementations (not mocks), and this session's own supply-chain claims
  about the source/dependencies/configuration are independently
  recomputable by anyone with a clone of this repo.
- Does NOT prove: that these gates have been tested against any real
  third-party MCP server or A2A agent in the wild, or that the container
  image itself has been independently re-verified (it is attested, not
  re-derived). See `CAIN_42_LIMITATIONS.md` for the full scope.
