INFRASTRUCTURE LEARNINGINFRASTRUCTURE LEARNING
インフラ大全インフラ大全IT INFRASTRUCTURE / LEARNING
Infrastructure learning guide
Find a lesson or lab/

Esc to close · Search terms stay on your device

LEARNING日本語

Topic lessonTopic: CI/CD design: from checks to release and recovery

CI/CD supply-chain security: verify dependencies, digests and provenance

A delivered artifact comes through source, dependencies, build processes and storage. Distinguish matching bytes, trusted origin and required safety checks. Use GitHub artifact attestations—signed statements of build provenance—to examine modification and substitution.

What you will learn

Distinguish byte digests from signed provenance and explain why a consumer rejects artifacts outside its policy.

Prerequisite

An artifact is produced output. A digest is computed from bytes; signatures help validate the association between a statement and a trusted identity. Cases supply fictional verification observations; no real signatures or workflows are created.

Inputs beyond source affect delivered output

Four checkpoints along an artifact’s supply chain
SOURCE
Source and dependencies

Review changes and dependency revisions.

BUILD
Build execution

Inspect workflow, runner, privileges and inputs.

ARTIFACT
Stored artifact

Associate produced bytes with provenance.

CONSUMER
Consumer verification

Evaluate expected identity, source and bytes.

Supply-chain boundaries, not a claim that passing through these areas makes software safe.

Third-party actions, reusable workflows, packages and build images are code or inputs. Inspect indirect dependencies as well as direct references. Review operations that can reach powerful tokens or shared runner state in terms of their possible impact.

A matching digest does not identify who built it

Suppose a trusted record stores the digest computed from artifact B. A different fetched digest means different bytes. But if an attacker can replace both a file and its adjacent checksum, their agreement does not connect either to a trusted origin.

S1: the source of the comparison record matters
ObservationConclusion
Fetched digest differs from trusted B digestDo not use it as B; investigate substitution or modification.
Fetched file matches a checksum from the same untrusted siteThe pair agrees; trusted origin remains unestablished.
Fetched bytes match trusted B digestByte identity is supported; harmless behavior remains a separate question.

Verify signed provenance against consumer policy

GitHub artifact attestations bind artifacts to signed build-provenance statements. Consumers must verify them before using that provenance in a decision. Generating a statement does not complete consumer verification.

Fictional consumer policy S2 requires candidate bytes B, the expected repository, a reviewed signer workflow and the intended source revision. A valid signature from another repository or a test-only workflow is insufficient. A/B are short teaching labels, not actual digest values.

S2: decide from supplied verification observations
ObservationPolicy decisionRemaining checks
B bytes; valid signature; expected repository, signer and revisionProvenance conditions matchReview content, dependencies, tests and release conditions.
Modified bytes; statement identifies original BStop: subject mismatchInvestigate retrieval, storage and transfer.
B bytes; valid signature; another repositoryStop: outside trusted originDo not silently broaden the trusted source.
B bytes; same repository but another test workflowStop: outside signer policyIdentify the workflow authorized to produce candidates.

Distinguish identities validated through the verification certificate from descriptive fields controlled by a workflow. For reusable workflows, match the signer identity to that structure. Repository-only verification is not the same policy as constraining the signer workflow and source.

Documented CLI shape; not executed on this page
gh attestation verify PATH/TO/ARTIFACT --repo OWNER/REPOSITORY
# Minimal repository-scoped verification shape only.
# Add the intended signer/source constraints to match your policy.

Check availability and the limits of the claim

The GitHub.com documentation checked on 2026-10-25 limits attestations on Free/Pro/Team to public repositories; private/internal use requires Enterprise Cloud, and legacy plans are excluded. Check availability for the intended repository before adopting the feature.

Control dependency identity and review updates

Tags and branches can move. When pinning an action to a reviewed full commit, inspect origin, code, dependencies and privileges, then review update differences. Keeping an old version forever does not address vulnerabilities.

GitHub also documents workflow dependency lockfiles in public preview. They lock direct and transitive action dependencies and repository identity; dependencies inside a reusable workflow belong to its defining repository’s lockfile. Preview behavior can change: verify support before adopting it. No extension is installed and no settings are changed here.

  1. Inventory source, dependencies, workflows, runners and storage.
  2. Define trusted and rejected cases as a consumer.
  3. Verify artifact bytes against signer and source policy.
  4. Check rejection for modification, another repository/workflow and stale source.
  5. Continue content review and release checks after provenance matches.

Interpret artifact verification

Choose an option to see the result and explanation.

A file matches a checksum from the same untrusted site. What follows?
Read the answer and reason

Answer: The pair agrees; trusted origin remains unverified. · Trusted comparison evidence or provenance verification is still needed.

S2 signature validation succeeds, but the repository differs. What next?
Read the answer and reason

Answer: Stop and verify the intended origin. · Both signature validation and consumer trust policy must hold.

B has a defect despite matching provenance. Is that contradictory?
Read the answer and reason

Answer: No; matching provenance does not guarantee defect-free behavior. · Separate build/source origin from behavioral quality.

Assume artifact attestations are available in private repositories on Free/Pro/Team?
Read the answer and reason

Answer: No; check the current availability conditions. · At the documented review date, private/internal use requires Enterprise Cloud.

Check, then explain in your own words

  1. Limit conclusions from a matching digest.
  2. Distinguish S2 modification, repository and workflow mismatches.
  3. Separate matching provenance from safety.
  4. Check feature availability and review dependency updates.
Check your understanding: An attestation was generated. May deployment consume B without checking it?

No. The consumer must verify fetched bytes against trusted repository, signer workflow and required source conditions. Content, dependencies, tests and release decisions remain separate checks.

Having a statement differs from a consumer verifying the conditions it needs.

Sources and conditions checked

The official references used in this lesson are collected here with their scope, conditions and corresponding sections. Independent expert review and live AWS comparison have not been performed.