Skip to content

mcp_schema: a re-baseline must be distinguishable from a first sighting #146

Closed

Description

@blitzcrieg1

The gap

#142 made a baseline computed under an older FINGERPRINT_VERSION re-baseline as new rather than reporting changed. That stops a fleet-wide false rug pull on upgrade day, which was the failure I was aiming at.

It creates a quieter one. @Santoshkumarpuppala, on #103:

Alerting on every tool is the false rug pull you named. Silently re-baselining is worse, and less visible: the first listing after upgrade becomes the trusted baseline.

If a server was already poisoned before the upgrade, the re-baseline trusts the poisoned state and says nothing about it. The event does fire, with status: new, and that is indistinguishable from a server nobody had ever listed before.

This is the same trust-on-first-use hole raised earlier about installation timing: a recorder installed after a swap has a permanently clean trail. #142 reintroduced it at a different moment, the upgrade rather than the install, and for every server at once.

What is missing

A first sighting and a re-baseline carry different amounts of evidence, and the trail currently gives them the same word.

  • new should mean "we had never seen this server"
  • something else, rebaselined or status: new, reason: fingerprint_version_changed, should mean "we had a baseline, our hashing changed, and this is the first observation under the new hashing"

An operator reading a quiet week must be able to tell "unchanged since we started watching" from "we started watching again on Tuesday and cannot speak for what came before".

That distinction already exists elsewhere here. Hook coverage reports four states rather than a boolean so unknown cannot be read as fine, and a failed listing emits unavailable rather than nothing. This is the same principle applied to the one case where it was skipped.

Proposal

  • Add a distinct status for a version-driven re-baseline, carried in the mcp_schema event and in the store record.
  • Say plainly in the event reason that the new baseline is trust-on-first-use and was not compared against anything.
  • Consider surfacing a count in doctor or the heartbeat: how many servers currently hold a baseline that was never verified against a prior one.
  • Test that a re-baseline event is distinguishable from a first sighting, which is the assertion missing from test_mcp_meta_fingerprint.py today. That file checks the verdict is new, and new was exactly the wrong thing to be satisfied by.

Source

@Santoshkumarpuppala in #103, correcting the migration shipped in #142. The first version of that fix traded a loud false positive for a silent false negative, which is the worse trade for a recorder.

Activity

  1. added a commit that references this issue on Sep 4, 2026
    9dc7ff5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions