Borehole · Project · free tier
codeberg.org/forgejo/forgejo
Free reading: not for reliance
994e539 · 25,849 commits · 8,256 files
Read 2026-11-08

codeberg.org/forgejo/forgejo: technical due diligence, read from its repository

What Borehole read in codeberg.org/forgejo/forgejo's code and history at 994e539: its licence, security advisories, releases, review practice, tests, dependencies and operations. Every finding cites the file and line it rests on. The full report also covers the team and asks the questions the code cannot answer.

DimensionRating
Architecture & Codebase — including AI provenanceadequate
Engineering Process & SDLC Maturitystrong
Product & Engineering Maturityadequate
Security & Reliability Postureadequate
Observability & Operationsstrong
Fit with the Acquirernot assessable

What the repository says

  • Releases are cut from another branch than the one surveyed
  • LICENSE: Relicensed: MIT → BSD-3-Clause (2014-03-25) → MIT (2014-11-06) → GPL-3.0 (2024-08-22)

Architecture & Codebase — including AI provenance

adequate
01.6

routers/web/repo/issue.go is 3,886 lines, 42× this codebase's median file

adequate

The median source file here is 92 lines. 30 files exceed 1,000 lines, the largest being 3,886. Size is not a defect on its own — some problems genuinely live in one place — but these are where merge conflicts, review fatigue and single-owner knowledge concentrate, and they are the first thing that slows an inheriting engineer down.

Evidence
routers/web/repo/issue.go:1 — 3,886 lines (42× median)
modules/setting/disposable_email_domain_data.go:1 — 3,812 lines (41× median)
modules/emoji/emoji_data.go:1 — 3,405 lines (37× median)
routers/web/repo/pull.go:1 — 2,092 lines (22× median)
routers/api/v1/repo/action.go:1 — 1,996 lines (21× median)
01.25

1 base image floats: no version, or `latest`

adequate

1 of 3 `FROM` lines in product Dockerfiles name an image without a version, or with `latest`. Each build pulls whatever the registry serves that day, so the image that ships can change without a commit, and last month's build cannot be reproduced. Pin a version, or a digest.

Evidence
Dockerfile:1 — base image without a version

Engineering Process & SDLC Maturity

strong
02.16

Tests are retried until they pass

adequate

The suite is configured to retry failing tests (playwright.config.ts). A retry turns a flaky test green without saying why it failed, so a green build means the tests passed eventually. Ask how many retries a typical run needs, and which tests need them.

Evidence
playwright.config.ts:32 — test retry

Product & Engineering Maturity

adequate
04.3

107 direct dependencies in a single manifest

adequate

go.mod declares 107 direct dependencies. Each one is a maintenance obligation, a supply-chain surface and a potential licence question that transfers with the asset. The count says nothing about whether any given dependency was a good choice; it says how many such choices a buyer inherits.

Evidence
go.mod — 107 declared
package.json — 74 declared
web_src/fomantic/package.json — 1 declared
04.38

6 files still carry code deprecated more than two years ago

adequate

6 files were marked deprecated over two years ago and still are, the oldest since Jan 2022. A deprecation is a promise to remove. Ask what still depends on these, and whether removing them is scheduled.

Evidence
modules/structs/org_team.go — deprecated since Jan 2022
modules/structs/repo_branch.go — deprecated since Jan 2023
routers/api/packages/chef/chef.go — deprecated since Feb 2023
modules/structs/repo.go — deprecated since May 2023
routers/api/actions/artifact.pb.go — deprecated since Mar 2024
04.62

Releases are cut from another branch than the one surveyed

adequate

The newest release, v17.0.1, is not on the branch this survey read; the newest release on it is v0.9.99. The shipped product may differ from what this report describes. Survey the release branch too.

Evidence
tag v17.0.1

Security & Reliability Posture

adequate
05.5

3 credential-shaped strings exist in the history

adequate

Matches for JWT were committed at some point across 20,000 commits examined (the scan stopped at its limit, so older history was not read). The files that held them are no longer in the working tree — but removal from a file is not removal from the history, and the history is what transfers with the asset. What matters is whether each was rotated after it was committed. The code cannot tell whether any of them is live, and that decides whether this matters: none sits in production configuration, and none is in a format its provider keeps for live keys. Is any of these live? Show that each was rotated after it was committed, and when. 5 other matchs set aside: expired tokens, licence tokens a vendor verifies with a public key, or placeholder text where a key would go. None grants access to anything.

Evidence
3 cited: JWT pattern added here
05.6

1 Dockerfile runs the application as root

adequate

No USER instruction switches away from root, so the process runs with full privileges inside the container. It is a one-line fix and an ordinary expectation, which is why its absence is worth asking about: it usually says more about whether anyone has reviewed the deployment than about this container specifically.

Evidence
Dockerfile — runs as root
05.13

3 outbound calls can wait forever

adequate

3 HTTP calls use a client with no timeout (Python `requests` without `timeout=`, or Go's default client). When a dependency slows down, each one holds a worker until the connection gives up, and enough of them take the service down with the dependency.

Evidence
modules/uri/uri.go:32 — outbound call without a timeout
routers/web/auth/oauth.go:1290 — outbound call without a timeout
services/migrations/dump.go:312 — outbound call without a timeout
05.20

48 SQL statements built from strings

adequate

48 places in product code build SQL by formatting or joining strings rather than passing parameters. 1 of them put a value into the string; in the rest, what the code shows going in is a table or column name, a constant, or something the line does not show. Ask whether any value reaches these strings, rather than a parameter.

Evidence
models/user/redirect.go:109 — SQL built from a string
models/db/convert.go:30 — SQL built from a string
models/db/convert.go:40 — SQL built from a string
05.48

35 places insert HTML from a variable without sanitising it

adequate

35 places set HTML from a value that is neither a literal nor passed through a sanitiser. Where the value can come from a user, that is stored cross-site scripting, and it is the first thing a buyer's security review looks for in a frontend.

05.60

Relicensed: MIT → BSD-3-Clause (2014-03-25) → MIT (2014-11-06) → GPL-3.0 (2024-08-22)

adequate

The root licence changed 3 time(s). The latest terms restrict what users, hosts or a buyer may do in ways the earlier ones did not. Code taken under the old terms stays under them, so both matter in diligence.

Evidence
LICENSE — MIT from 2014-02-12
LICENSE — BSD-3-Clause from 2014-03-25
LICENSE — MIT from 2014-11-06
LICENSE — GPL-3.0 from 2024-08-22
05.65

10 advisories against this project in the last 24 months, 2 high or critical

adequate

The newest was published on 2026-10-30. A project that publishes advisories is telling its users about its fixes, and the count and pace say how much security work it carries. Whether 10 of them are fixed in the code you ship could not be told from this history: its version is only known to be at least 0.9.99. Answer lives in: the release you run, set against each fixed version. The record is incomplete: GitHub's advisories hold no record for this host; NVD: 1 record names forgejo with nothing tying it to this repository (CVE-2026-58370).

Evidence
2026-10-30: CVE-2026-119545 (moderate): Forgejo through 15.0.11, 16.0.0 through 16.0.7, and 17.0.0 through 17.0.1 contains a server-side request forgery vulnerability that allows unauthenticated attac
2026-10-30: CVE-2026-119546 (moderate): Forgejo through 15.0.11, 16.0.0 through 16.0.7, and 17.0.0 through 17.0.1 contains a path traversal vulnerability in restore-repo that allows attackers to read
2026-10-30: CVE-2026-119547 (moderate): Forgejo through 15.0.11, 16.0.0 through 16.0.7, and 17.0.0 through 17.0.1 contains an information disclosure vulnerability in the GetPublicKey API handler that
2026-09-13: CVE-2026-90679 (moderate): Forgejo 13.0.0 through 16.0.4, when "[federation] ENABLED = true" is set, has a spoofing issue that affects identity integrity but does not allow account takeov
2026-09-11: CVE-2026-89151 (low): Forgejo before 16.0.4 allows use of restricted API tokens for unintended access to the "allow maintainer edit" feature.

Observability & Operations

strong
06.9

No error reporter is wired in

adequate

Nothing in the service initialises an error reporter (Sentry, Rollbar, Bugsnag, Honeybadger or an APM agent). An exception in production reaches a person only if someone is reading the logs, which usually means a customer reports it first.

Evidence
no error reporter initialised

Fit with the Acquirer

not assessable

Not rated: structurally not assessable from a repository.

Read more, or read your own

The full report on codeberg.org/forgejo/forgejo: every dimension, the questions for the room, and the audit log.

Survey a repository: free on public repositories. Private code is read on your own machine by a collector whose source you can read first.