Cap'n Proto serialization/RPC system - core tools and C++ library
This report summarizes scanner evidence for capnproto/capnproto, a C++ project with 13,213 GitHub stars. SynthScan examined 88,662 lines of code across 212 source files, recording 613 pattern matches distributed across 9 syntactic categories. The legacy adjusted pattern signal is 6.8 (Moderate pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Can maintainers explain intent, assumptions, and trade-offs? 596 finding(s).
Are imports declared and package/API names verified? 7 finding(s).
Are wrappers, guards, and repeated structures necessary? 10 finding(s).
Which changes need focused human review? 613 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 613 distinct pattern matches across 9 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | mega-test.py | 1 | #! /usr/bin/env python | COMMENT |
| LOW | super-test.sh | 421 | COMMENT | |
| LOW | c++/CMakeLists.txt | 141 | COMMENT | |
| LOW | c++/ekam-build.sh | 61 | # errors in the benchmarks directory. Note that it's tricky to link against an installed copy | COMMENT |
| LOW | c++/samples/CMakeLists.txt | 1 | # A Cap'n Proto sample project. | COMMENT |
| LOW | c++/src/benchmark/capnproto-common.h | 1 | // Copyright (c) 2013-2014 Sandstorm Development Group, Inc. and contributors | COMMENT |
| LOW | c++/src/benchmark/capnproto-common.h | 21 | COMMENT | |
| LOW | c++/src/benchmark/null-common.h | 1 | // Copyright (c) 2013-2014 Sandstorm Development Group, Inc. and contributors | COMMENT |
| LOW | c++/src/benchmark/protobuf-common.h | 1 | // Copyright (c) 2013-2014 Sandstorm Development Group, Inc. and contributors | COMMENT |
| LOW | c++/src/benchmark/common.h | 1 | // Copyright (c) 2013-2014 Sandstorm Development Group, Inc. and contributors | COMMENT |
| LOW | c++/src/benchmark/common.h | 21 | COMMENT | |
| LOW | c++/src/kj/time.h | 1 | // Copyright (c) 2014 Google Inc. (contributed by Remy Blank <rblank@google.com>) | COMMENT |
| LOW | c++/src/kj/time.h | 81 | // cannot be used to determine the current calendar date. | COMMENT |
| LOW | c++/src/kj/time.h | 101 | // a reasonable operating system the difference is usually negligible. | COMMENT |
| LOW | c++/src/kj/main.h | 1 | // Copyright (c) 2013-2014 Sandstorm Development Group, Inc. and contributors | COMMENT |
| LOW | c++/src/kj/main.h | 41 | KJ_NORETURN(virtual void exit()) = 0; | COMMENT |
| LOW | c++/src/kj/main.h | 61 | // easy for commands to explicitly ensure all output is flushed before exiting, and it is | COMMENT |
| LOW | c++/src/kj/main.h | 81 | // it could crash, the OS could decide to kill it off, or the machine it is running on could | COMMENT |
| LOW | c++/src/kj/main.h | 101 | // has no state anyway. | COMMENT |
| LOW | c++/src/kj/main.h | 161 | mutable std::atomic_bool hadErrors = false; | COMMENT |
| LOW | c++/src/kj/main.h | 181 | MainClass mainObject(context); \ | COMMENT |
| LOW | c++/src/kj/main.h | 201 | // information you provide to the builder as you define each flag. | COMMENT |
| LOW | c++/src/kj/main.h | 221 | // return "Output file must have extension .foo."; | COMMENT |
| LOW | c++/src/kj/main.h | 301 | // builder.addOption({'a', "all"}, KJ_BIND_METHOD(*this, showAll), "Show all files."); | COMMENT |
| LOW | c++/src/kj/main.h | 321 | // Like `addOption()`, but adds an option which accepts an argument. `argumentTitle` is used in | COMMENT |
| LOW | c++/src/kj/main.h | 341 | // | COMMENT |
| LOW | c++/src/kj/main.h | 361 | MainBuilder& expectZeroOrMoreArgs(StringPtr title, Function<Validity(StringPtr)> callback); | COMMENT |
| LOW | c++/src/kj/main.h | 381 | // builder.expectArg("<baz>", ...); | COMMENT |
| LOW | c++/src/kj/async-coroutine-alloc.h | 1 | // Copyright (c) 2026 Cloudflare, Inc. and contributors | COMMENT |
| LOW | c++/src/kj/filesystem.h | 1 | // Copyright (c) 2015 Sandstorm Development Group, Inc. and contributors | COMMENT |
| LOW | c++/src/kj/filesystem.h | 41 | COMMENT | |
| LOW | c++/src/kj/filesystem.h | 61 | // and then would have interpreted ".." relative to that. In practice, the kernel's behavior is | COMMENT |
| LOW | c++/src/kj/filesystem.h | 101 | // is NOT accepted -- if that is a problem, you probably want `eval()`. Trailing '/'s are | COMMENT |
| LOW | c++/src/kj/filesystem.h | 121 | COMMENT | |
| LOW | c++/src/kj/filesystem.h | 181 | // - Backslashes can be used as path separators. | COMMENT |
| LOW | c++/src/kj/filesystem.h | 201 | // This throws if the path would have unexpected special meaning or is otherwise invalid on | COMMENT |
| LOW | c++/src/kj/filesystem.h | 301 | // | COMMENT |
| LOW | c++/src/kj/filesystem.h | 361 | // Hint which can be used to determine if two FsNode instances point to the same underlying | COMMENT |
| LOW | c++/src/kj/filesystem.h | 381 | // Not currently included: | COMMENT |
| LOW | c++/src/kj/filesystem.h | 421 | virtual Array<const byte> mmap(uint64_t offset, uint64_t size) const = 0; | COMMENT |
| LOW | c++/src/kj/filesystem.h | 461 | // Notifies the implementation that the given bytes have changed. For some implementations this | COMMENT |
| LOW | c++/src/kj/filesystem.h | 501 | virtual Own<const WritableFileMapping> mmapWritable(uint64_t offset, uint64_t size) const = 0; | COMMENT |
| LOW | c++/src/kj/filesystem.h | 541 | // filesystems, this is just as fast as listNames(), but on others it may require stat()ing each | COMMENT |
| LOW | c++/src/kj/filesystem.h | 561 | COMMENT | |
| LOW | c++/src/kj/filesystem.h | 581 | COMMENT | |
| LOW | c++/src/kj/filesystem.h | 601 | // At least one of CREATE or MODIFY must be specified. Optionally, the two flags can be combined | COMMENT |
| LOW | c++/src/kj/filesystem.h | 621 | // been specified at all. If the path refers to a broken symlink, the file at the target of the | COMMENT |
| LOW | c++/src/kj/filesystem.h | 681 | // | COMMENT |
| LOW | c++/src/kj/filesystem.h | 701 | // all), so the KJ filesystem implementation is forced to remember the full path and needs to | COMMENT |
| LOW | c++/src/kj/filesystem.h | 721 | // is atomically moved to its final path when you call `commit()`. If you destroy the Replacer | COMMENT |
| LOW | c++/src/kj/filesystem.h | 741 | // Commit the replacement. | COMMENT |
| LOW | c++/src/kj/filesystem.h | 761 | // what it claims. Some examples of possible problems include: | COMMENT |
| LOW | c++/src/kj/filesystem.h | 801 | // is there already. See `Replacer<T>` for details. | COMMENT |
| LOW | c++/src/kj/filesystem.h | 821 | COMMENT | |
| LOW | c++/src/kj/filesystem.h | 861 | // | COMMENT |
| LOW | c++/src/kj/filesystem.h | 881 | // everything at the destination. This race condition is not present in the Unix | COMMENT |
| LOW | c++/src/kj/filesystem.h | 901 | }; | COMMENT |
| LOW | c++/src/kj/filesystem.h | 941 | #if __linux__ | COMMENT |
| LOW | c++/src/kj/filesystem.h | 961 | // - The backing store is not sparse and never gets smaller even if you truncate the file. | COMMENT |
| LOW | c++/src/kj/sticky-flag.h | 1 | // Copyright (c) 2026 Cloudflare, Inc. and contributors | COMMENT |
| 526 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | release.sh | 166 | # ====================================================================================== | COMMENT |
| MEDIUM | release.sh | 202 | # ====================================================================================== | COMMENT |
| MEDIUM | release.sh | 244 | # ====================================================================================== | COMMENT |
| MEDIUM | release.sh | 280 | # ====================================================================================== | COMMENT |
| MEDIUM | release.sh | 313 | # ====================================================================================== | COMMENT |
| MEDIUM | release.sh | 341 | # ====================================================================================== | COMMENT |
| MEDIUM | release.sh | 347 | # ====================================================================================== | COMMENT |
| MEDIUM | c++/src/capnp/compiler/capnp-test.sh | 52 | # ======================================================================================== | COMMENT |
| MEDIUM | c++/src/capnp/compiler/capnp-test.sh | 87 | # ======================================================================================== | COMMENT |
| MEDIUM | c++/src/capnp/compiler/capnp-test.sh | 105 | # ======================================================================================== | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | c++/src/kj/common.h | 855 | // that type. This is useful to use as e.g. a parameter to a function because it will be robust | COMMENT |
| MEDIUM | c++/src/kj/common.h | 860 | // of that type. This is useful to use as e.g. a parameter to a function because it will be robust | COMMENT |
| MEDIUM | c++/src/kj/async-inl.h | 158 | // potentially other objects that commonly live on the end of a promise chain can also leverage | COMMENT |
| MEDIUM | c++/src/kj/async-inl.h | 1645 | // to a dangling pointer. Essentially, WeakFulfiller is reference counted, although the | COMMENT |
| MEDIUM | c++/src/capnp/serialize-text.h | 38 | // This format is useful for debugging or human input, but it is not a robust alternative | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | doc/cxx.md | 69 | alicePhones[0].setNumber("555-1212"); | CODE |
| LOW⚡ | doc/cxx.md | 78 | bobPhones[0].setNumber("555-4567"); | CODE |
| LOW⚡ | doc/cxx.md | 80 | bobPhones[1].setNumber("555-7654"); | CODE |
| LOW | doc/cxx.md | 523 | phone0.set("number", "555-1212"); | CODE |
| LOW | doc/cxx.md | 537 | bobPhones[0].setNumber("555-4567"); | CODE |
| LOW | doc/cxx.md | 539 | bobPhones[1].setNumber("555-7654"); | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | c++/src/kj/main.h | 205 | // Example usage: | COMMENT |
| LOW | c++/src/kj/async.h | 431 | // Example usage: | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | doc/cxxrpc.md | 27 | Cap'n Proto's RPC is based on the [KJ library](cxx.html#kj-library)'s event-driven concurrency | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | c++/src/kj/array.h | 417 | // TODO: implement for complex T types without creating `size` instances first. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | release.sh | 113 | echo "Don't forget to push changes:" | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | doc/_plugins/capnp_lexer.py | 4 | CODE |