Skip to content

Network, privacy and tokens ​

relgap sends requests only to the hosts on this page, and only to look up the tools you ask about or the pins it scanned. It has no telemetry and no update check. relgap pins and relgap drift without --latest read files only and make no request at all.

Scanned files name git hosts and image registries, so relgap contacts only the ones it knows: bitbucket.org, gitlab.com and the hosts in gitlab.hosts for git sources, and Docker Hub, ghcr.io, registry.k8s.io, quay.io, public.ecr.aws, mcr.microsoft.com and the hosts in images.registries for images and for Helm charts behind an oci:// URL that Artifact Hub doesn't list. A pin on any other host stays unresolved or skipped, and relgap runs no git ls-remote against it.

Hosts ​

HostWhat relgap asks forWhenToken
api.github.comreleases, tags, files and repository search (REST and GraphQL), the index.yaml of a GitHub Pages Helm repository, and the pull request comment of relgap notifyevery command that looks up a toolthe GitHub token, when one is found
api.bitbucket.orgtags, files and the top directory of Bitbucket Cloud repositoriesbitbucket: pins and inputs, from Terraform module sources on bitbucket.orgBITBUCKET_API_TOKEN, when set
gitlab.comtags, releases, files and the top directory of projectsgitlab: pins and inputs, from Terraform module sources on gitlab.comGITLAB_TOKEN, then GITLAB_ACCESS_TOKEN, when GITLAB_HOST names this host (default gitlab.com); CI_JOB_TOKEN when CI_SERVER_HOST does
a host in gitlab.hoststags, releases, files and the top directory of projectsgitlab:<host>/... pins and inputsthe entry's token_env, else as for gitlab.com
endoflife.daterelease cycles and their end-of-life datesa tool whose registry entry names an endoflife.date productno
api.osv.devknown vulnerabilities of the pinned versions, their fix target candidates and the latest versions (what OSV receives)audit, and outdated for every pin it checksno
www.cisa.govthe CISA Known Exploited Vulnerabilities catalog, one file per dayaudit and outdated with --kev or vulns.kevno
api.first.orgthe EPSS scores of the CVE IDs of the advisories foundaudit and outdated with --epss or vulns.epssno
registry.terraform.ioprovider versions and source repositoriestfprovider: pins and inputsno
artifacthub.iochart versions and source repositorieschart: pins and inputsno
registry.npmjs.orgpackage repositoriesnpm: inputsno
pypi.orgpackage repositoriespypi: inputsno
registry-1.docker.ioimage tags, manifests and image configs, with an anonymous pull token when the registry asks for oneimage: pins and inputs, and oci:// charts, on Docker Huban anonymous pull token
auth.docker.ioanonymous pull tokens for Docker Hubimage: pins and inputs, and oci:// charts, on Docker Hubno
ghcr.ioimage tags, manifests and image configs, with an anonymous pull token when the registry asks for oneimage: pins and inputs, and oci:// charts, on this registryan anonymous pull token
registry.k8s.ioimage tags, manifests and image configs, with an anonymous pull token when the registry asks for oneimage: pins and inputs, and oci:// charts, on this registryan anonymous pull token
quay.ioimage tags, manifests and image configs, with an anonymous pull token when the registry asks for oneimage: pins and inputs, and oci:// charts, on this registryan anonymous pull token
public.ecr.awsimage tags, manifests and image configs, with an anonymous pull token when the registry asks for oneimage: pins and inputs, and oci:// charts, on this registryan anonymous pull token
mcr.microsoft.comimage tags, manifests and image configs, with an anonymous pull token when the registry asks for oneimage: pins and inputs, and oci:// charts, on this registryan anonymous pull token
a registry in images.registriesimage tags, manifests and image configs, with an anonymous pull token when the registry asks for oneimage: pins and inputs, and oci:// charts, on this registryan anonymous pull token
the host a registry or its token URL redirects tothe same answer, such as a blob from storagea registry that redirects, as registry.k8s.io doesno; a redirect to another domain gets no token
api.adoptium.netrelease-note pagesa registry entry with a web-doc, structured-json or upgrade-guide source on this hostno
docs.python.orgrelease-note pagesa registry entry with a web-doc, structured-json or upgrade-guide source on this hostno
go.devrelease-note pagesa registry entry with a web-doc, structured-json or upgrade-guide source on this hostno
api.anthropic.comthe summary prompt--summarize with llm.provider: anthropic and no llm.base_urlthe API key
bedrock-mantle.<region>.api.awsthe summary prompt--summarize with llm.provider: bedrock-mantle and no llm.base_urlthe API key
the Bedrock Runtime endpoint of the AWS regionthe summary prompt--summarize with llm.provider: bedrockAWS credentials
the host of llm.base_urlthe summary prompt--summarize with llm.provider: openai-compatible, or any provider with llm.base_url setthe API key

www.cisa.gov and api.first.org are off by default. With --kev relgap downloads the whole KEV catalog and matches it locally, so CISA learns nothing about your pins. With --epss relgap sends the CVE IDs of the advisories it found, which tells FIRST which vulnerabilities your pins have.

Every request goes through one HTTP client with retries, a per-host limit and the on-disk cache. Pages of release notes come from GitHub through the API. Web pages come only from these hosts, and relgap registry lint rejects an entry whose URL points anywhere else:

  • api.adoptium.net
  • docs.python.org
  • go.dev

What OSV receives ​

relgap audit and relgap outdated ask api.osv.dev about every pin they can check, with no token. The table lists every value those requests carry. It comes from the list in relgap's source that a test compares with the requests the OSV client sends:

RequestFieldWhat it holds
POST /v1/querybatchqueries[].package.ecosystemThe OSV ecosystem: Go, npm, PyPI, crates.io, RubyGems, NuGet, GIT, GitHub Actions, or the one a curated osv list names.
POST /v1/querybatchqueries[].package.nameThe package name as the pin or the registry entry writes it (PyPI names normalized); a Go module path, every prefix of a go: path while relgap looks for the module, or the main module of an executable under outdated --binaries; the URL of a github.com or gitlab.com repository for GIT; owner/repo of an action. A repository you named only when its forge says it is public, and never a module path that GOPRIVATE names.
POST /v1/querybatchqueries[].versionThe version relgap checks: an exact pin, the version a pin marked ≈ stands for, or a fix target candidate or latest release. Left out when relgap looks for a go: module or asks about an action.
POST /v1/querybatchqueries[].page_tokenThe token OSV returned for the next page of an answer.
GET /v1/vulns/{id}idThe ID of an advisory that OSV returned, or a GHSA alias of one.

relgap never sends OSV a file path, a pin's location, the name of the repository that pins a tool, or a token. It never queries a tool on a host it doesn't send to: Bitbucket, a self-managed GitLab host, a github.host other than github.com, an image registry, or a package name with : or @ after the npm scope. Those pins are unchecked with reason private-source or no-advisory-source (Unchecked pins).

Private repositories and modules ​

A repository can be private on github.com or gitlab.com too, so relgap decides what may go to OSV as follows (relgap ADR-0020, details 39 to 42):

  • A repository from the relgap, mise or aqua registry, the Terraform registry, npm or PyPI is public: those registries list public projects only.
  • A repository you named goes to OSV only when its forge says it is public. These are a github: or gitlab: pin, a tools.<name>.repo entry, a --guess and a GitHub Action. With a GitHub token relgap asks isPrivate in one GraphQL query per 100 repositories; without one it reads GET /repos/{owner}/{repo}, which answers only for a public repository. On gitlab.com it reads GET /projects/:id and its visibility. A repository the forge calls private or internal, or doesn't find, is private-source; a failed lookup is failed.
  • A Go module path that GOPRIVATE, GONOPROXY or GONOSUMDB names never goes to OSV, matched the way the go command matches it. relgap reads each variable, else the file go env -w writes. This covers a curated Go package, a go: backend, the repository of a github.com or gitlab.com tool or action (as github.com/<owner>/<repo>) and the main module of an executable.
  • outdated --binaries sends the main module of an executable only when the tool's repository is public by the rules above. The standard library at the binary's Go version always goes.
  • An npm package that a Renovate comment or report names with a registryUrl other than registry.npmjs.org is private-source: relgap asks neither registry.npmjs.org nor OSV about it.

A go: pin or an npm package that no registry knows resolves to no tool, so it never reaches OSV either. relgap looks an npm: name up on registry.npmjs.org first, which answers 404 for a private package.

To leave a tool out of every report and every request, add an ignore rule for it. relgap drops ignored pins before any request:

yaml
ignore:
  - tool: deploy-cli

Programs relgap runs ​

ProgramCommandWhen
gitgit ls-fileslisting the files of a repository, so .gitignore applies
gitgit rev-parse and git archivereading the pins at another commit with digest --base or --pull-request
misemise registry --jsonmapping tool names to repositories, when mise is on PATH
misemise whichoutdated --binaries, finding the installed executables
ghgh auth tokenlooking up the GitHub token in gh's keyring, after the other places

Without git, relgap walks the directories itself. Without mise, it uses the embedded copy of mise's registry (registry snapshots).

Tokens ​

Each token goes only to the host it belongs to. relgap never sends one host's token to another, never writes a token to the cache or the logs, and names in the debug log only whether a client has a token and which variable it came from.

GitHub ​

relgap looks for a token the way gh does, and takes the first it finds:

  1. the GH_TOKEN environment variable
  2. the GITHUB_TOKEN environment variable
  3. gh's config file (hosts.yml)
  4. gh auth token, which reads gh's keyring

relgap adds the token only to requests to api.github.com. A token with no scopes reads public repositories; a private repository needs a token that can read its contents. relgap notify needs a token that can write pull request comments.

Without a token, relgap uses the REST API only, sends at most 2 requests at once, and GitHub allows 60 requests an hour. relgap warns on the first GitHub request, and again when the remaining requests run low. A token raises the limit to GitHub's authenticated one and lets relgap batch release bodies into GraphQL queries.

Bitbucket Cloud ​

relgap sends BITBUCKET_API_TOKEN to api.bitbucket.org only, as Authorization: Bearer. A user API token with the read:repository:bitbucket scope works, and so do repository, project and workspace access tokens. relgap reads no username or email, because a Bearer token needs none. Without a token, relgap warns once, and Bitbucket allows 60 anonymous requests an hour per IP; a private repository then answers 404.

GitLab ​

relgap reads GitLab tokens the way glab does and sends each to one host:

  1. the variable that a gitlab.hosts entry names in token_env, to that entry's host
  2. GITLAB_TOKEN, then GITLAB_ACCESS_TOKEN, to the host in GITLAB_HOST (default gitlab.com)
  3. CI_JOB_TOKEN, to the host in CI_SERVER_HOST, when that host has no other token

A personal, project or group token goes in PRIVATE-TOKEN and needs read_api. A CI job token goes in JOB-TOKEN; it reads tags, releases and raw files of projects whose job token allowlist has the calling project, but not the directory listing that finds a changelog file. Without a token, gitlab.com allows 500 requests a minute per IP, and relgap warns when the remaining requests run low.

Image registries ​

relgap reads no Docker credentials. When a registry answers 401 with a Bearer challenge, relgap asks the token URL in the challenge for an anonymous pull token and keeps it in memory for the run. A private image therefore stays skipped. Reading an image's source label costs one manifest request, which Docker Hub counts as a pull.

The cache ​

Answers are cached under $XDG_CACHE_HOME/relgap/http, or the cache.dir you set. The cache keeps response bodies and the headers needed to revalidate them. It never stores request headers, so Authorization, PRIVATE-TOKEN and JOB-TOKEN stay out, and it never stores cookies, rate-limit headers or the answers that carry an anonymous registry token. --offline answers from the cache only, --no-cache neither reads nor writes it, and relgap cache clear deletes it.

Summaries from a model ​

--summarize is off unless you configure llm.provider and llm.model, and relgap never adds it on its own. With it, relgap sends the digest's listed entries to the provider you configured and nothing else. The summary is advisory: it never changes --fail-on, the exit code or SARIF.

The API key comes from the environment variable that llm.api_key_env names. relgap never reads a key from a file and never writes one to the cache or the logs.