Skip to content

Make pinned CI tool downloads resilient to transient upstream failures #1137

Description

@doublewhy

Plain-language summary

  • Context: OpenRAE downloads checksum-pinned copies of Conftest, Vale, Gitleaks, and OSV Scanner before several required verification lanes.
  • Problem: A single temporary GitHub Releases disconnect or HTTP 503 fails the entire lane before project code is tested. Multiple otherwise-clean PRs have required manual reruns for the same upstream event.
  • Fix: Retry only transient transport and server failures with a small bounded backoff, while preserving the approved HTTPS origin, version, size limit, checksum, signature, and fail-closed behavior.

Evidence

On 2026-08-12, required checks for multiple independent PRs failed while acquiring Conftest, Vale, Gitleaks, or OSV Scanner. The observed failures were remote disconnects and HTTP 503 responses from GitHub Releases. The same commits passed once the upstream download succeeded, and the failures occurred before the affected verification stage could inspect project code.

Acceptance criteria

  • Share one deterministic bounded retry policy across the pinned tool downloaders where practical.
  • Cover Conftest, Vale, Gitleaks, and OSV Scanner acquisition, including checksum metadata where the owning installer uses it.
  • Retry remote disconnects, timeouts, incomplete responses, connection failures, HTTP 408/429, and HTTP 5xx only.
  • Do not retry checksum, signature, archive/type, size, identity, origin, version, or other policy failures.
  • Honor Retry-After only within the total retry/time bound.
  • Keep exact approved origins and pinned versions/digests; do not fall back to an unreviewed mirror.
  • Preserve stable final diagnostics without leaking credentials, exception text, or response bodies.
  • Add deterministic tests for success after transient failure, Retry-After, exhaustion, non-retryable HTTP failures, corrupt payloads, and the total attempt bound.
  • Keep required CI lanes fail closed when all attempts fail.

Scope

This is CI/tool-acquisition reliability only. It does not make vulnerability findings advisory, relax proof isolation, or change the verified artifacts.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions