# git-changes attestor

Source: https://www.testifysec.com/docs/cilock/attestors/git-changes/

Records which paths a commit changed, as a proof a verifier recomputes from the pushed commit and its trees. It is a sibling of the git attestor, not a new version of it.

Records which paths a commit changed, as a proof a verifier recomputes from the pushed commit and its trees. It is a sibling of the [`git`](https://www.testifysec.com/docs/cilock/attestors/git) attestor, not a new version of it.

 

| Field | Value |
| --- | --- |
| Name | `git-changes` |
| Predicate type | `https://aflock.ai/attestations/git-changes/v0.1` |
| Lifecycle | `prematerial` |
| Default binary? | **Yes** (registered by the same plugin as `git`) |

 

## What it captures

 

- `version`, `hash`: the proof version and the object format; `sha1` is the only one supported.
 - `status`: `complete` or `incomplete`. When `incomplete`, `reason` is one of `shallow`, `base_unresolved`, `target_unresolved`, `tree_unreadable`, `git_unavailable` or `no_commit`.
 - `commit`, `tree`: the head commit and its tree.
 - `base`, `base_tree`: the merge-base of `HEAD` and the target branch tip as the clone last fetched it, and its tree.
 - `target`: `{ ref, tip }`, diagnostic only. A verifier never reads it for a decision.
 - `changes[]`: `{ path, old_path, status }` for each changed path.
 - `delta`, `head_trees`: the encoded proof data. `head_trees` is filled only with `--attestor-git-changes-embed-head-trees`.

 

Nothing here is trusted on its own. A verifier checks every field against the pushed commit, a base the forge picks, and the hashes of the trees. A wrong claim makes the observation incomplete, which applies every review class. The predicate is capped at 64 KiB.

 

## When to use

 

In the push-metadata step of a gated push, where a policy needs the set of changed paths to decide which reviews apply. Request it by name; detection never selects it.

 

## Flags

 

| Flag | Default | Purpose |
| --- | --- | --- |
| `--attestor-git-changes-target-ref` | origin's default branch | Branch the push will land on, such as `main` or `origin/main`. |
| `--attestor-git-changes-embed-head-trees` | `false` | Carry every head tree the proof walks, so the attestation verifies without the pushed pack or a repository. About 44 KB at the median. |

 

## Gotchas

 

- There is no detector. Pass `-a git-changes`.
 - A shallow clone cannot produce a complete proof; it signs `incomplete` with reason `shallow`.

 

## See also

 

- [Catalog row](https://www.testifysec.com/docs/cilock/reference/attestor-catalog)
 - [`git`](https://www.testifysec.com/docs/cilock/attestors/git)

Reference generated from the product documentation. Match commands and support details to your installed release.
