Commit d9a3b474b6

d9a3b474b63800c56e83c0ecce5ed902ebe42b61

parent: bf8e6e63d6

Verified · cmc

cmc <hello@cleberg.net> · 2026-11-01 03:21 UTC

Document gh-attest as self-hosted after the hosted takedown

README: self-hosted framing, resource creation, GitHub App settings, and how
installations are recorded. SECURITY.md and PRIVACY.md describe a deployment
the operator runs. wrangler.jsonc drops the deleted database's ID.

Ref #3

Layout: unified · split

PRIVACY.md +43 −105
@@ -1,31 +1,27 @@
1# gh-attest — Privacy Policy
1# gh-attest — Data handling
22
3**Effective date:** 2026-07-19
3gh-attest is self-hosted. Audit Labs does not run an instance and receives no
4data from any deployment. Whoever deploys it operates it: the data described
5here is stored in that operator's own Cloudflare account, and the operator is
6responsible for it.
47
5gh-attest ("the App") is a GitHub App operated by Audit Labs ("we",
6"us"). It helps compliance and security teams collect
7point-in-time evidence about the security configuration of their own
8GitHub organization and map it to SOC 2 and ISO 27001 control
9identifiers. This policy explains what the App processes, why, how long
10it is kept, and your choices.
8This document describes what a deployment processes, where it is stored, and
9how long it is kept. It does not cover GitHub itself — see GitHub's Privacy
10Statement for how GitHub handles your data.
1111
12This policy covers the gh-attest App and its dashboard only. It does not
13cover GitHub itself — see GitHub's Privacy Statement for how GitHub
14handles your data.
12## What a deployment processes
1513
16## What we process
17
18The App processes data only for organizations that have installed it,
19and only within the scope of the permissions granted at installation.
14A deployment processes data only for organizations that have installed its
15GitHub App, and only within the scope of the permissions granted at
16installation.
2017
2118**Organization & installation metadata.** Installation ID, organization
22login, and installation/suspension timestamps. If you exclude repositories
23from scanning, the App stores the excluded repository names for your
24installation.
19login, and installation/suspension timestamps. If repositories are excluded
20from scanning, the excluded repository names are stored for that installation.
2521
26**Security & access-control signals (the evidence).** As your
27configuration changes and on a periodic re-sync, the App records
28point-in-time "snapshots" of security-relevant state, which may include:
22**Security & access-control signals (the evidence).** As configuration
23changes and on a periodic re-sync, the Worker records point-in-time
24"snapshots" of security-relevant state, which may include:
2925
3026- branch protection and repository ruleset configuration (enabled /
3127 disabled);
@@ -37,112 +33,54 @@ webhook payload that produced it. These payloads can contain repository
3733names, team names, and the GitHub logins of members whose access
3834changed.
3935
40**Dashboard sign-in.** When you sign in to the dashboard, the App reads
41your GitHub user ID and login and the list of installations you can
42access, solely to confirm you belong to an organization that installed
43the App. Your GitHub profile is stored only inside a signed, expiring
44session cookie in your browser — it is **not** written to our database.
36**Dashboard sign-in.** On sign-in, the Worker reads the user's GitHub user ID
37and login and the list of installations they can access, solely to confirm
38they belong to an organization that installed the App. The profile is stored
39only inside a signed, expiring session cookie in the browser — it is **not**
40written to the database.
4541
46**Exports.** Evidence exports you generate (CSV or PDF) are stored so
47you can download them, along with metadata about each export job.
42**Exports.** Evidence exports (CSV or PDF) are stored so they can be
43downloaded, along with metadata about each export job.
4844
49## What we do NOT process
45## What it does NOT process
5046
51- We do **not** store the contents of your source code.
52- We do **not** store GitHub personal access tokens. The App
47- It does **not** store the contents of source code.
48- It does **not** store GitHub personal access tokens. The Worker
5349 authenticates using short-lived installation access tokens minted per
5450 request (valid ~1 hour) and never persisted.
55- We do **not** collect passwords or payment information.
56- We do **not** sell your data or share it with third parties for
57 advertising, and we do **not** aggregate data across organizations.
58
59## How we use it
60
61Solely to provide the App's function: presenting your current security
62posture, mapping it to SOC 2 / ISO 27001 controls, and generating
63point-in-time evidence exports and access-review comparisons for your
64own organization.
51- It does **not** collect passwords or payment information.
52- It does **not** send data anywhere other than the operator's Cloudflare
53 account and GitHub's API.
6554
6655## Where it is stored and how it is protected
6756
68All data is stored on Cloudflare's platform (D1 and R2) in the
69**European Union**. Both the database and the object storage are created
70under Cloudflare's `eu` jurisdiction, which restricts them to storing and
71running within the EU.
57All data is stored in the operator's Cloudflare account (D1 and R2). The
58deployment steps in the README create both under Cloudflare's `eu`
59jurisdiction, which restricts them to storing and running within the EU.
7260
73Note that the application code itself runs on Cloudflare Workers, which
74execute at the network edge close to the requesting user. A request made
75from outside the EU is therefore processed outside the EU, even though
76the data it reads and writes is stored within the EU. We do not currently
77use Cloudflare's Regional Services to constrain where request processing
78occurs.
61The Worker itself runs on Cloudflare Workers, which execute at the network
62edge close to the requesting user. A request made from outside the EU is
63therefore processed outside the EU, even though the data it reads and writes
64is stored within the EU.
7965
8066Protections include:
8167
8268- webhook payloads are verified with HMAC-SHA256 signatures before
8369 processing;
8470- the GitHub App private key, webhook secret, and session-signing key
85 are stored as encrypted platform secrets, never in source code;
71 are stored as encrypted Worker secrets, never in source code;
8672- authentication uses short-lived installation tokens that are never
8773 stored;
8874- all stored data is scoped per installation, and the dashboard enforces
8975 that a signed-in user can access only their own organization's data.
9076
91## Subprocessors
92
93- **Cloudflare, Inc.** — hosting, database (D1), and object storage (R2),
94 under the EU jurisdiction described above.
95
96**GitHub, Inc.** is the system the data comes from. Your organization has
97its own relationship with GitHub, so GitHub is not a subprocessor we
98engage on your behalf.
99
100If we add or replace a subprocessor, we will notify installed
101organizations in advance so they have an opportunity to object.
102
103## Security incidents
104
105If we become aware of a breach affecting your organization's data, we
106will notify you without undue delay and provide the information you need
107to meet your own notification obligations.
108
10977## Data retention & deletion
11078
111Evidence snapshots are retained for 13 months, export files
112for 90 days, and all data for an organization is deleted when the App
113is uninstalled. You may also request deletion at any time.
114
115## Your choices and rights
116
117**If you administer an installing organization:**
118
119- **Uninstall** the App at any time from your organization's GitHub
120 settings to stop all processing and trigger deletion of your data.
121- **Exclude repositories** from scanning and reporting from the
122 dashboard, so the App stops collecting new evidence about them.
123- **Export** your organization's data as CSV or PDF from the dashboard
124 at any time.
125- **Request deletion** of your organization's data by contacting us.
126- Request a **Data Processing Addendum** if you need one for your own
127 compliance obligations.
128
129**If you are an individual whose GitHub login appears in an
130organization's data:** we hold that data on behalf of that organization,
131which decides how it is used. We have no direct relationship with you
132and cannot verify your identity, so please direct access, correction, or
133deletion requests to the organization. If you contact us, we will refer
134your request to them rather than acting on it ourselves.
135
136Depending on your jurisdiction (e.g., GDPR, CCPA/CPRA), you may have
137additional rights; the organization can exercise them with our
138assistance.
79Evidence snapshots are retained for 13 months, export files for 90 days, and
80all data for an organization is deleted when the App is uninstalled. The
81operator can also purge an installation through `POST /admin/purge`.
13982
14083## Contact
14184
142privacy@audit-labs.dev — Audit Labs
143
144## Changes
145
146We may update this policy. Material changes will be reflected by the
147effective date above and, where appropriate, communicated to installed
148organizations.
85Questions about the software: privacy@audit-labs.dev. Requests about data held
86by a deployment go to the organization that operates it.
README.md +40 −6
@@ -6,10 +6,13 @@
66[![Maintainability Rating](https://sonarcloud.io/api/project_badges/measure?project=audit-labs_gh-attest&metric=sqale_rating)](https://sonarcloud.io/summary/new_code?id=audit-labs_gh-attest)
77[![License: GPL v3](https://img.shields.io/badge/License-GPLv3-blue.svg)](LICENSE)
88
9Turns GitHub security settings into auditor-ready evidence. A GitHub App that
10records branch protection, scanning alerts, and organization access as they
11change, maps them to SOC 2 and ISO 27001 controls, and exports point-in-time
12CSV and PDF evidence packages.
9Turns GitHub security settings into auditor-ready evidence. A self-hosted
10GitHub App that records branch protection, scanning alerts, and organization
11access as they change, maps them to SOC 2 and ISO 27001 controls, and exports
12point-in-time CSV and PDF evidence packages.
13
14You register your own GitHub App and deploy the Worker to your own Cloudflare
15account. Audit Labs does not run a hosted instance.
1316
1417Read-only — it never modifies your repositories, permissions, or membership.
1518
@@ -38,11 +41,18 @@ webhooks never announce (protection and open alerts that predate the install,
3841whether each scanner is enabled, and current membership). Each observation is stored as a timestamped snapshot in D1.
3942Exports render off the request path via a queue, into R2.
4043
41**Stack:** Cloudflare Workers · D1 · R2 · Queues. All storage is provisioned
42under Cloudflare's `eu` jurisdiction.
44**Stack:** Cloudflare Workers · D1 · R2 · Queues. The deployment steps below
45create all storage under Cloudflare's `eu` jurisdiction.
46
47Installations are recorded only from the App's webhooks; the hourly poll covers
48installations already recorded and does not discover new ones. If the webhook
49URL or secret is wrong, every delivery is refused with a 401 and the
50installation never appears.
4351
4452## Endpoints
4553
54Routes served by a deployed Worker:
55
4656| Route | Auth | Purpose |
4757| --- | --- | --- |
4858| `GET /` | session | Dashboard: current posture, exports |
@@ -73,11 +83,35 @@ Type checking: `npm run typecheck`. Generate binding types after editing
7383
7484## Deployment
7585
86Create the storage. Jurisdiction is fixed at creation:
87
88```sh
89npx wrangler d1 create gh-attest-db-eu --jurisdiction eu
90npx wrangler r2 bucket create gh-attest-exports-eu --jurisdiction eu
91npx wrangler queues create generate-export
92```
93
94Put the `database_id` printed by `d1 create` into `wrangler.jsonc`, then:
95
7696```sh
7797npm run db:migrate:remote
7898npm run deploy
7999```
80100
101Register a GitHub App with:
102
103| Setting | Value |
104| --- | --- |
105| Webhook URL | `https://<worker>/webhooks/github` |
106| Webhook secret | same value as `GITHUB_WEBHOOK_SECRET` |
107| Callback URL | `https://<worker>/callback` |
108| Repository permissions (read-only) | Administration, Metadata, Dependabot alerts, Code scanning alerts, Secret scanning alerts |
109| Organization permissions (read-only) | Members |
110| Events | Branch protection rule, Repository ruleset, Dependabot alert, Code scanning alert, Secret scanning alert, Member, Organization, Team, Repository, Push |
111
112Install it on your organization, then confirm the `installation` delivery
113returned 200 under the App's Advanced → Recent Deliveries.
114
81115Secrets are set with `wrangler secret put <NAME>` — never in `wrangler.jsonc`:
82116
83117| Secret | Purpose |
SECURITY.md +11 −11
@@ -2,9 +2,9 @@
22
33## Supported versions
44
5gh-attest is a hosted GitHub App. There is one supported version — the
6currently deployed one. Fixes are rolled out to all installations at once;
7there is nothing for you to upgrade.
5gh-attest is self-hosted; Audit Labs does not run an instance. Only the latest
6`main` is supported. Fixes land there, and each operator deploys them to their
7own Worker.
88
99## Reporting a vulnerability
1010
@@ -16,7 +16,7 @@ Please report privately rather than opening a public issue.
1616
1717Please include enough detail to reproduce: the endpoint or component, the
1818request, and what you observed. If you have a proof of concept, use your own
19organization's installation.
19deployment.
2020
2121We aim to acknowledge within 3 working days and to keep you updated until the
2222issue is resolved. We will credit you when publishing a fix unless you prefer
@@ -28,8 +28,8 @@ otherwise. We do not currently run a paid bug bounty.
2828
2929- The Worker and its endpoints, including webhook signature verification,
3030 session handling, and the `/admin/*` bearer-guarded routes.
31- Tenant isolation — anything allowing one installation to read another's
32 evidence or exports.
31- Tenant isolation — anything allowing one installation on a deployment to
32 read another's evidence or exports.
3333- The evidence pipeline, where incorrect data could mislead an audit.
3434
3535**Out of scope**
@@ -43,13 +43,13 @@ otherwise. We do not currently run a paid bug bounty.
4343
4444## Testing guidance
4545
46Please test against an installation on an organization you control. Do not
47attempt to access data belonging to another installation; if you believe you
48have found a way to, stop and report it rather than confirming the extent.
46Please test against your own deployment and an organization you control. Do
47not attempt to access anyone else's deployment or data.
4948
5049## How gh-attest handles data
5150
5251Read-only GitHub scopes, short-lived installation tokens that are never
5352persisted, no source code or personal access tokens stored, and all data held
54in the EU. See [PRIVACY.md](PRIVACY.md) for the full description and
55[README.md](README.md) for the architecture.
53in the operator's Cloudflare account under the `eu` jurisdiction. See
54[PRIVACY.md](PRIVACY.md) for the full description and [README.md](README.md)
55for the architecture.
wrangler.jsonc +5 −4
@@ -9,14 +9,15 @@
99 "head_sampling_rate": 1
1010 },
1111
12 // Storage is pinned to the EU jurisdiction so customer data stays in the
13 // EEA. Jurisdiction is immutable: moving it means recreating these
14 // resources and migrating the data.
12 // Storage is pinned to the EU jurisdiction so evidence stays in the EEA.
13 // Jurisdiction is immutable: moving it means recreating these resources
14 // and migrating the data. Create them as in the README's Deployment section.
1515 "d1_databases": [
1616 {
1717 "binding": "DB",
1818 "database_name": "gh-attest-db-eu",
19 "database_id": "70e8b4b2-4409-4f51-a9f6-badce76f5891",
19 // From `wrangler d1 create gh-attest-db-eu --jurisdiction eu`.
20 "database_id": "00000000-0000-0000-0000-000000000000",
2021 "migrations_dir": "./migrations"
2122 }
2223 ],