Skip to main content

agent-evidence-a2a

Verify A2A agent card signatures over the bytes the server sent, and score any card verifier, canonicaliser or webhook SSRF judge on shipped corpora.

It is for authors of A2A agents, SDKs and conformance suites who need a card verdict that matches the wire, not a parsed object.

pip install agent-evidence-a2a
from agent_evidence_a2a import TrustStore, check_canonicaliser, verify_served_card
from agent_evidence_a2a.vectors import reference_canonicalize

report = check_canonicaliser(reference_canonicalize)
print(report.passed, "of", report.total)

verdict = verify_served_card(open("card.json", "rb").read(), TrustStore.from_file("trust.json"))
print(verdict.accepted)

The first print shows 57 of 57. The same check runs from the shell, and exits 1 when your canonicaliser fails a vector:

agent-evidence-a2a canonicaliser --impl yourpkg.jcs:canonicalize
agent-evidence-a2a corpus --verifier yourpkg.cards:accepts
agent-evidence-a2a ssrf --judge yourpkg.webhooks:refuses

Status

Version 0.2.0, alpha. The verifier, the 57 a2a-jcs-v01 vectors, the 43-card corpus and the 42-URL webhook corpus are complete. The packaged verifier rejects all 28 attack cards and accepts all 11 controls; 4 probes wait on the spec text of A2A#2122 and are never scored. The reference judge refuses all 30 unsafe webhook URLs and none of the 6 safe ones.

What is in the package

Piece What it does
verify_served_card Recomputes the signed payload from the served bytes (RFC 8785), rejects a repeated member name or an appended member, checks every kid against a pinned trust store with validity windows, and applies a signer threshold.
judge_signature Judges one member of a card's signatures array for four failures: a card with no RFC 8785 form or a signature made over a non-JCS form, a signature that does not verify, a malformed signature or header, and a kid that is unknown, expired or not pinned. It names the non-JCS form a failing signature verifies over. lookup takes any kid -> key function.
settle_signatures Applies the card's signer policy (distinct-signer threshold, required signers, key rotation) to the judgements of all its signatures. verify_served_card is read_signed_card, then judge_signature per signature, then this, so a verifier that calls the three reaches the same verdict on every card.
read_signed_card Reads a served card's signatures, signing payload and non-JCS forms from one parse, and says which of three things a card with nothing to judge is: unsigned, a signatures member that is not an array, or no RFC 8785 form.
verify_detached The byte-level detached JWS check under judge_signature, for a caller that resolves its key another way (an x5c leaf).
check_canonicaliser Runs the 57 vectors against your canonicaliser, and against your card-to-signing-bytes function when you pass one.
score_card_verifier Scores any served bytes -> accepted function on the card corpus: the cards it must accept, the cards it must reject, and the probes whose verdict waits on the spec.
score_ssrf_judge Scores a webhook URL judge on 42 URLs with resolved ground truth.
judge_url A reference judge: refuses a URL whose host, by RFC 3986, is or resolves to a non-global address (obfuscated IPv4, IPv4-mapped IPv6, localhost, userinfo tricks).
probe Judges an endpoint's transport: the scheme is https, the session reaches TLS 1.3, and the server's certificate chain verifies for its host name: agent-evidence-a2a tls https://agent.example/a2a.

Exit 0 means the card was accepted, the posture passed or the score is clean; 1 means it was not.

Documentation

page read it for
Card answer key what each card breaks and which check catches it
Data checksums the SHA-256 of every shipped data file
Schema table script rebuilding the Agent Card field table from a2a-sdk
Command line agent-evidence-a2a --help

Metadata

Release files for agent-evidence-a2a 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for agent-evidence-a2a 0.2.0
File Size Uploaded Provenance Actions
agent_evidence_a2a-0.2.0.tar.gz 71.2 kB Without provenance Details for agent_evidence_a2a-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for agent-evidence-a2a 0.2.0
File Interpreter ABI Platform Actions
agent_evidence_a2a-0.2.0-py3-none-any.whl Python 3 none any Details for agent_evidence_a2a-0.2.0-py3-none-any.whl

Total release size: 156.1 kB

Release files / agent_evidence_a2a-0.2.0.tar.gz

Download URL agent_evidence_a2a-0.2.0.tar.gz
Size 71.2 kB
Tags Source
SHA-256 checksum
How to use checksums
72009180243fc3e3050d683511e50230b620c0cf436d44d6bd505447e6944fa5
BLAKE2b-256 checksum
How to use checksums
3dce73e7b1329e565cf17018a703b82b2c77f0538babdd1d86392c08d96e28a3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / agent_evidence_a2a-0.2.0-py3-none-any.whl

Download URL agent_evidence_a2a-0.2.0-py3-none-any.whl
Size 84.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
07adc297c88ae34491b458130507385831a67798891bbd4e3262de0c4b99aa93
BLAKE2b-256 checksum
How to use checksums
6d2ac51f72ee03102949d369f1d12fce64937e9050d488c223cd32aa6dbbaa0d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Security for agent-evidence-a2a 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page