Borehole · Project · free tier
openfoodfoundation/openfoodnetwork
Free reading: not for reliance
4339314 · 37,205 commits · 4,120 files
Read 2026-10-04

openfoodfoundation/openfoodnetwork: technical due diligence, read from its repository

What Borehole read in openfoodfoundation/openfoodnetwork's code and history at 4339314: 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 provenancestrong
Engineering Process & SDLC Maturitystrong
Product & Engineering Maturitystrong
Security & Reliability Postureadequate
Observability & Operationsadequate
Fit with the Acquirernot assessable

Architecture & Codebase — including AI provenance

strong
01.6

db/schema.rb is 1,287 lines, 34× this codebase's median file

adequate

The median source file here is 37 lines. 1 file exceed 1,000 lines, the largest being 1,287. 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
db/schema.rb:1 — 1,287 lines (34× median)

Engineering Process & SDLC Maturity

strong

No finding.

Product & Engineering Maturity

strong
04.5

Effort is shifting from building to rewriting

adequate

Deleted lines per line added rose from 0.50 to 0.81 between the first and second halves of this history. Rework is normal and often healthy, but a rising ratio means an increasing share of the team's time is spent replacing code that already exists rather than building what does not. Whether that is deliberate repayment or churn is a question for the team.

Evidence
first half 0.50, second half 0.81 (split 2019-06-27)

Security & Reliability Posture

adequate
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.25

1 environment file is committed

adequate

.env is tracked in git. Environment files are where credentials usually live, and committing one usually means nobody decided how secrets reach the running application. Whatever is in it is in the history for good. Check 05.1 says whether it holds anything credential-shaped.

Evidence
.env — committed environment file
05.27

The build runs third-party code it does not pin

adequate

4 third-party CI actions are referenced by a tag or branch rather than a commit, so they run whatever that tag points to on the day. Tags have been moved to malicious commits in real supply-chain attacks, and a piped script is whatever the server returns that minute. Pinning to a commit is the fix, and it is small.

Evidence
.github/workflows/auto-author-assign.yml:16 — action pinned by tag
.github/workflows/build.yml:81 — action pinned by tag
05.26

19 locked dependencies have published vulnerabilities, 17 high or critical

adequate

19 of 1,303 locked dependencies match 37 published advisories in OSV, 17 of them rated high or critical. A lockfile says which version is installed, not whether the flawed code is reachable from this product, so each needs a look. Most are fixed by an upgrade, and the advisory names the version. This lockfile pins development tools alongside what ships and does not say which is which, so some of these may never reach a user.

Evidence
yarn.lock — swiper 11.2.10: GHSA-hmx5-qpq5-p643 (critical), fixed in 12.1.2
Gemfile.lock — css_parser 2.1.0: GHSA-9pmc-p236-855h (high), fixed in 3.0.0
Gemfile.lock — rubyzip 3.2.2: GHSA-47m2-wp7j-p9vc (high), fixed in 3.4.0
05.9

4 vendored components with no licence

adequate

Third-party code is committed into this repository without any statement of the terms it arrived under. Unknown terms are harder to deal with than inconvenient ones: an awkward licence can be complied with, an absent one cannot. Each of these needs its origin established before the code changes hands.

Evidence
engines/dfc_provider/vendor/facets.json — 1 tracked files, no licence file
engines/dfc_provider/vendor/measures.json — 1 tracked files, no licence file
engines/dfc_provider/vendor/productTypes.json — 1 tracked files, no licence file
engines/dfc_provider/vendor/vocabulary.json — 1 tracked files, no licence file
05.65

9 advisories against this project in the last 24 months, 6 high or critical

adequate

The newest was published on 2026-09-22. A project that publishes advisories is telling its users about its fixes, and the count and pace say how much security work it carries. None of them affects the surveyed version.

Evidence
2026-09-22: GHSA-w3vw-4237-fp75 (high), fixed in v5.7.13: Stored XSS in Packing Report Customer Header
2026-09-22: GHSA-5hh6-q39m-h8mp (high), fixed in v5.7.13: Stored XSS in Shipping Method Description
2026-09-15: GHSA-3f4x-grmj-89vx (moderate), fixed in v5.7.12: Customer update authorizes on the record's current enterprise_id while permitting enterprise_id as a mass-assignable attribute, allowing cross-enterprise re-ass
2026-09-14: GHSA-g347-rpvg-vq66 (moderate), fixed in v5.7.12: Admin variant search (/admin/variants/search.json) leaks full platform catalog across enterprise/tenant boundaries
2026-09-14: GHSA-qmm8-966w-pm55 (moderate), fixed in v5.7.12: Broken access control: EnterpriseFees#bulk_update updates arbitrary enterprises' fees

Observability & Operations

adequate
06.2

No structured logging library is in use

adequate

Nothing references a structured logging library. Logs that are written to be read by a person are not searchable by a machine, which means incident response here is proportional to how well someone remembers the codebase rather than to what the tooling can find.

Evidence
searched 3,017 files for 10 structured logging libraries; 0 matched
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 openfoodfoundation/openfoodnetwork: 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.