Read 2026-11-03
cinnamon/kotaemon: technical due diligence, read from its repository
What Borehole read in cinnamon/kotaemon's code and history at 9ad3e4e: 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.
| Dimension | Rating |
|---|---|
| Architecture & Codebase — including AI provenance | strong |
| Engineering Process & SDLC Maturity | strong |
| Product & Engineering Maturity | adequate |
| Security & Reliability Posture | adequate |
| Observability & Operations | adequate |
| Fit with the Acquirer | not assessable |
Architecture & Codebase — including AI provenance
stronglibs/ktem/ktem/index/file/ui.py is 1,895 lines, 23× this codebase's median file
adequateThe median source file here is 80 lines. 2 files exceed 1,000 lines, the largest being 1,895. 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.
libs/ktem/ktem/index/file/ui.py:1 — 1,895 lines (23× median) |
libs/ktem/ktem/pages/chat/__init__.py:1 — 1,459 lines (18× median) |
Engineering Process & SDLC Maturity
strongNo finding.
Product & Engineering Maturity
adequate5% of bug fixes add or change a test
adequateOf 82 fixes in the last 24 months, 4 touched a test. A fix without the test that would have caught the bug can quietly come back, and the suite never learns from what went wrong.
| 4 of 82 |
Security & Reliability Posture
adequate1 Dockerfile runs the application as root
adequateNo 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.
Dockerfile — runs as root |
The build runs third-party code it does not pin
adequate14 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; 1 step pipes a download straight into a shell. 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.
.github/workflows/auto-bump-and-release.yaml:18 — action pinned by tag |
.github/workflows/auto-bump-and-release.yaml:46 — action pinned by tag |
Dockerfile:119 — download piped into a shell |
18 outbound calls can wait forever
adequate18 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.
libs/kotaemon/kotaemon/contribs/promptui/tunnel.py:43 — outbound call without a timeout |
libs/kotaemon/kotaemon/indices/retrievers/jina_web_search.py:33 — outbound call without a timeout |
libs/kotaemon/kotaemon/llms/chats/endpoint_based.py:59 — outbound call without a timeout |
4 deserialisers that can run code
adequate4 places read data with a deserialiser that executes what it reads (pickle). That is safe on data the system wrote itself and remote code execution on anything else. Ask where each one's input comes from.
libs/kotaemon/kotaemon/contribs/promptui/export.py:46 — code-executing deserialiser |
libs/kotaemon/kotaemon/contribs/promptui/export.py:56 — code-executing deserialiser |
libs/kotaemon/kotaemon/contribs/promptui/ui/chat.py:272 — code-executing deserialiser |
37 locked dependencies have published vulnerabilities, 56 high or critical in what ships
adequate37 of 429 locked dependencies match 122 published advisories in OSV, 56 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.
6 advisories against this project in the last 24 months, 3 high or critical
adequateThe newest was published on 2026-08-28. A project that publishes advisories is telling its users about its fixes, and the count and pace say how much security work it carries. The record is incomplete: NVD: 1 record names kotaemon with nothing tying it to this repository (CVE-2026-86867).
| 2026-08-28: CVE-2026-82281 (critical): Kotaemon Missing Ownership Check in Conversation Functions |
| 2026-08-04: CVE-2026-69098 (critical): kotaemon 0.12.0 Unauthenticated Remote Code Execution via Insecure Deserialization |
| 2025-11-24: CVE-2025-63914 (moderate): An issue was discovered in Cinnamon kotaemon 0.11.0. The _may_extract_zip function in the \libs\ktem\ktem\index\file\ui.py file does not check the contents of u |
| 2025-11-18: CVE-2025-56526 (moderate): Cross site scripting (XSS) vulnerability in Kotaemon 0.11.0 allowing attackers to execute arbitrary code via a crafted PDF. |
| 2025-11-18: CVE-2025-56527 (high): Plaintext password storage in Kotaemon 0.11.0 in the client's localStorage. |
Observability & Operations
adequateNo structured logging library is in use
adequateNothing 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.
| searched 357 files for 10 structured logging libraries; 0 matched |
The service logs with print: 160 calls against 52 logger calls
adequate160 `print` or `console.log` calls in the service's code, and 52 calls through a logger. Printed lines carry no level and no context, cannot be switched off, and are hard to find again in production.
libs/kotaemon/kotaemon/agents/io/base.py:71 — print used for logging |
libs/kotaemon/kotaemon/agents/react/agent.py:276 — print used for logging |
libs/kotaemon/kotaemon/agents/react/agent.py:285 — print used for logging |
One request cannot be followed through the logs
adequateNothing in the service carries a request or correlation id, and there is no tracing. When a customer reports a failure, the log lines that belong to their request cannot be picked out from everyone else's.
| no request id, correlation id or tracing found |
No error reporter is wired in
adequateNothing 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.
| no error reporter initialised |
Fit with the Acquirer
not assessableNot rated: structurally not assessable from a repository.
Read more, or read your own
The full report on cinnamon/kotaemon: 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.