Skip to content

Report whether a typed source is actually verifying anything - #16

Merged
garethx merged 1 commit into
mainfrom
fix/verify-named-source-types
Aug 12, 2026
Merged

Report whether a typed source is actually verifying anything#16
garethx merged 1 commit into
mainfrom
fix/verify-named-source-types

Conversation

@garethx

@garethx garethx commented Aug 12, 2026

Copy link
Copy Markdown
Collaborator

Both follow-ups from the live-testing pass.

The finding

Setting a source's type to STRIPE or GITHUB does not switch verification on. The provider's own signing secret must be set on the source, and until it is the source accepts anything. All four quadrants measured against a real project:

Setup Request Result
GITHUB source, no secret unsigned accepted, event created
GITHUB source, no secret sha256=deadbeef accepted, event created
STRIPE source, secret set unsigned VERIFICATION_FAILED, 0 events
STRIPE source, secret set real signed Stripe delivery verified: true → agent run

setup mentions the manual step once in its own output. The README stated the verification as a flat benefit, and nothing raised it again.

What doctor can and cannot know

The interesting constraint: a source with a secret configured is byte-identical to one without, over the API. config.auth is absent and verification is null either way — confirmed against a source whose secret was definitely set (screenshot + verified: true on its requests). So there is nothing to read on the source itself.

What the API does expose is verified on each inbound request. So the check reads observed traffic:

  • some unverified → fail, and say the secret is missing or mismatched
  • all verified → confirm, naming the count it saw
  • no requests → say "verification is unconfirmed", and explicitly not "fine"

That third case is the one worth care. With no traffic there is genuinely no signal, and reporting the source as healthy would be the one answer certain to be wrong. It passes rather than fails, because unknowable is not broken.

Plain WEBHOOK sources are left alone — they verify with the project's own signing secret, which the adapter already checks, so the warning would be noise.

Also

README corrected in both places it made the claim: the comparison table now says "once the provider's secret is set on the source", and the How-it-works section spells out that setup cannot set it and points at doctor.

Verified

313 tests, ruff clean. Both guards mutation-checked: treating unverified traffic as fine, and nagging plain WEBHOOK sources, each fail the suite.

Ships in the wheel (cli.py, api.py) — patch release when convenient.

Setting a source's type to STRIPE or GITHUB does not switch verification on.
The provider's own signing secret has to be set on the source, and until it is
the source accepts anything. Measured against a real project: a GITHUB source
with no secret accepted an unsigned request *and* one carrying
`sha256=deadbeef`, and produced events from both. With the secret set, an
unsigned request came back VERIFICATION_FAILED with no event, and a genuine
signed Stripe delivery passed.

`setup` says the secret is a manual step, once, in its own output. The README
stated the verification as a flat benefit, and nothing mentioned it again.

doctor now reports it, and the interesting part is what it can and cannot know.
A source with a secret configured is byte-identical to one without over the
API — `config.auth` is absent and `verification` is null either way, confirmed
against a source whose secret was definitely set. So there is nothing to read
on the source itself. What the API does expose is `verified` on each inbound
request, so the check reads observed traffic:

* some requests unverified -> fail, and say the secret is missing or mismatched
* all verified            -> confirm, naming the count it saw
* no requests at all      -> say "unconfirmed", not "fine"

The third case is the one worth being careful about. With no traffic there is
genuinely no signal, and claiming the source is fine would be the one answer
certain to be wrong.

Plain WEBHOOK sources are left alone: they verify with the project's own
signing secret, which the adapter already checks, so the warning would be noise.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@garethx
garethx merged commit e677b8b into main Aug 12, 2026
8 checks passed
@garethx
garethx deleted the fix/verify-named-source-types branch August 12, 2026 15:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant