instance_id
stringlengths
10
65
repo
stringlengths
5
59
pr_number
int64
1
313k
task_type
stringclasses
1 value
base_commit
stringlengths
40
40
review_commit
stringlengths
40
40
title
stringlengths
2
282
body
stringlengths
7
3k
patch
stringlengths
202
204k
n_defects
int64
1
72
n_supported
int64
1
65
n_major
int64
0
32
defects
stringlengths
140
18.8k
certifier_count
int64
trpc__trpc__6547
trpc/trpc
6,547
defect
1eccc1171fba8b1bdb4d8acd83ab37d1e0a98b22
fe0a8cccb958f5be4322e912e3ebd259a3790f7c
fix(wsLink): wsLink should await for connectionParams before sending …
## 🎯 Changes Added a test case to ensure wsLink awaits urlConnectionParams before sending any messages. urlConnectionParams resolution is now handled at the wsConnection level. The wsClient can use the WebSocket once the connection parameters are sent. ## ✅ Checklist - [x] I have followed the steps listed in ...
diff --git a/packages/client/src/links/wsLink/wsClient/wsClient.ts b/packages/client/src/links/wsLink/wsClient/wsClient.ts index 6937c75624c..a2f04e9b2c2 100644 --- a/packages/client/src/links/wsLink/wsClient/wsClient.ts +++ b/packages/client/src/links/wsLink/wsClient/wsClient.ts @@ -20,11 +20,7 @@ import type { WebSoc...
4
1
1
[{"id": "G0", "claim": "After this change, when the client reconnects after a network loss the pending subscriptions are restored before the connection message (connectionParams) is sent on the new connection, resulting in authentication errors.", "category": "correctness", "verdict": "supported", "priority": "P1", "sc...
null
trpc__trpc__6569
trpc/trpc
6,569
defect
5bdc9dc2ce552aace89ebf110e77ecd2d084fe4a
f7f92f759da1cfba5d66695c39b3a8b8c89186ef
fix(`server/aws-lambda`): Update cookie splitting for lambda adapter
Closes #6456 ## 🎯 Changes Updated to use cookie-es to correctly handle the splitting safely for values with expiry. Also the initial test cases weren't actually valid cookies as they by minimum needed the = sign so updated them. ## ✅ Checklist - [x] I have followed the steps listed in the [Contributing gu...
diff --git a/packages/server/package.json b/packages/server/package.json index e3187048195..49590c91844 100644 --- a/packages/server/package.json +++ b/packages/server/package.json @@ -126,6 +126,7 @@ "@types/react": "^19.0.0", "@types/react-dom": "^19.0.0", "@types/ws": "^8.2.0", + "cookie-es": "^1.2...
1
1
1
[{"id": "G0", "claim": "Do not make the lambda adapter depend on the cookie-es library: remove the added dependency and the import from 'cookie-es' and instead implement the splitting without a library or vendor the needed part, since the import won't resolve unless the consumer installs cookie-es.", "category": "desig...
null
trpc__trpc__6640
trpc/trpc
6,640
defect
662da0bb0a2766125e3f7eced3576f05a850a069
8ee2af54c4ba053a74883b94b4a18c1adbdf2574
fix(client): Websocket not reconnecting when lazy is enabled
## 🎯 Changes Fixes a bug where a websocket **won't** reconnect when it is closed unexpectedly when lazy mode is enabled ## Reasoning 💭 If your tRPC server goes down and you have a client that uses lazy mode, it won't attempt to reconnect. Clients that use lazy mode should be able to gracefully reconnect. ...
diff --git a/packages/client/src/links/wsLink/wsClient/wsClient.ts b/packages/client/src/links/wsLink/wsClient/wsClient.ts index e162ac8acf5..b9cb3d609c7 100644 --- a/packages/client/src/links/wsLink/wsClient/wsClient.ts +++ b/packages/client/src/links/wsLink/wsClient/wsClient.ts @@ -330,7 +330,10 @@ export class WsCli...
5
3
1
[{"id": "G0", "claim": "The test comment on line 1452 misspells \"recieve\" and should read \"receive\".", "category": "documentation", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The reconnect condition redundantly re-checks lazyMode; it is equivalent to the simpler !this.l...
null
trpc__trpc__6767
trpc/trpc
6,767
defect
7fbf03ccf13dd7a7e3f8217521a3007704878c9c
e0d2e78b76db56dcf0e0c84e2eb5330959541c22
Expose meta on procedures
Closes # ## 🎯 Changes What changes are made in this PR? Is it a feature or a bug fix? <!-- Note: once you create a Pull request, we will automatically fix auto-fixable lint issues in your branch --> ## ✅ Checklist - [ ] I have followed the steps listed in the [Contributing guide](https://github.com/tr...
diff --git a/packages/server/src/unstable-core-do-not-import/procedure.ts b/packages/server/src/unstable-core-do-not-import/procedure.ts index be6af789bc5..1aefbe2fe1c 100644 --- a/packages/server/src/unstable-core-do-not-import/procedure.ts +++ b/packages/server/src/unstable-core-do-not-import/procedure.ts @@ -8,6 +8,...
1
1
1
[{"id": "G0", "claim": "The new meta-exposure test uses empty arrow functions on lines 520 and 524 that trigger @typescript-eslint/no-empty-function ESLint errors and cause lint pipeline failures, so they should be replaced (e.g. with non-empty callbacks) to make CI pass.", "category": "maintainability", "verdict": "su...
null
trpc__trpc__6770
trpc/trpc
6,770
defect
377527514bcacbf30b7c64676a2fa234515ae229
a6f291789d32f5bfe5abdfed7b3538fabd4df2dd
useSubscription should abort when input changes
Closes # ## 🎯 Changes What changes are made in this PR? Is it a feature or a bug fix? <!-- Note: once you create a Pull request, we will automatically fix auto-fixable lint issues in your branch --> ## ✅ Checklist - [ ] I have followed the steps listed in the [Contributing guide](https://github.com/tr...
diff --git a/packages/tanstack-react-query/test/__helpers.tsx b/packages/tanstack-react-query/test/__helpers.tsx index eaa55b27c0f..7c5ddda9c46 100644 --- a/packages/tanstack-react-query/test/__helpers.tsx +++ b/packages/tanstack-react-query/test/__helpers.tsx @@ -3,7 +3,7 @@ import '@testing-library/jest-dom/vitest'; ...
3
1
0
[{"id": "G0", "claim": "The `RenderResult` import in packages/tanstack-react-query/test/__helpers.tsx is only used as a type, so it should use TypeScript's type-only import syntax.", "category": "maintainability", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The `input` impor...
null
trpc__trpc__6793
trpc/trpc
6,793
defect
95e12af62304ef50ea7d96a36a077ea01759f884
8268357120270be51dcec658fd8a582569136058
fix(tanstack-react-query): skip inferring `initialData`
Closes #6792 Closes #6791 ## 🎯 Changes What changes are made in this PR? Is it a feature or a bug fix? <!-- Note: once you create a Pull request, we will automatically fix auto-fixable lint issues in your branch --> ## ✅ Checklist - [ ] I have followed the steps listed in the [Contributing guide](htt...
diff --git a/packages/tanstack-react-query/src/internals/queryOptions.ts b/packages/tanstack-react-query/src/internals/queryOptions.ts index a656e055692..a52517f8124 100644 --- a/packages/tanstack-react-query/src/internals/queryOptions.ts +++ b/packages/tanstack-react-query/src/internals/queryOptions.ts @@ -55,7 +55,7 ...
1
1
1
[{"id": "G0", "claim": "Verify that the initialData inference fix also works when combined with a select that changes the type, ideally as a persistent test.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
trpc__trpc__6806
trpc/trpc
6,806
defect
836788f4fea787be31bbec1ab2e692fa38297ad0
b8e4c4ec989be199aff5fd777da0619b492d4e0e
feat(client): add `localLink`
Closes #3768 Closes #6733 ## 🎯 Changes Adds a `localLink` https://www-git-issues-3768-locallink-trpc.vercel.app/docs/client/links/localLink ## ✅ Checklist - [x] I have followed the steps listed in the [Contributing guide](https://github.com/trpc/trpc/blob/main/CONTRIBUTING.md). - [x] If necessary, I h...
diff --git a/packages/client/src/internals/signals.ts b/packages/client/src/internals/signals.ts index fd001d18fc2..5e93016b9eb 100644 --- a/packages/client/src/internals/signals.ts +++ b/packages/client/src/internals/signals.ts @@ -52,3 +52,19 @@ export function raceAbortSignals( return ac.signal; } + +export fu...
12
4
2
[{"id": "G0", "claim": "The retryable error codes are defined twice — once in server rpc/codes.ts and once in client retryLink.ts — so the client duplicate should be removed and the server-side definition imported to keep a single source of truth.", "category": "maintainability", "verdict": "supported", "priority": "P2...
null
trpc__trpc__6842
trpc/trpc
6,842
defect
fcf4b4a2f6f9af98ab318bef8a82c5a9392a8fe0
d630505f924917e8263d59939935311d78215cc0
fix(server): fix `MaxListenersExceededWarning` when socket is reused in fastify adapter
Closes #6837 ## 🎯 Changes - [x] bump fastify - [x] make repro - [x] fix repro ### Attempt to Repro ```bash # terminal 1 p i && p build # builds trpc cd examples/fastify-server p dev:server # terminal 2 px autocannon -c 200 -d 10 -p 10 http://localhost:2022/trpc/posts.list ``` <!-- This is a...
diff --git a/.github/workflows/release-tmp.yml b/.github/workflows/release-tmp.yml index d86d7925db6..87dd374b3ce 100644 --- a/.github/workflows/release-tmp.yml +++ b/.github/workflows/release-tmp.yml @@ -5,7 +5,7 @@ on: branches: # Replace this with the branch you want to release from # 👇👇👇👇👇👇...
8
3
1
[{"id": "G0", "claim": "After raising the dev-dep to fastify@^5, consider declaring fastify ^5.0.0 in @trpc/server's peerDependencies so consumers do not inadvertently install v4 and hit runtime/type mismatches.", "category": "design", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "clai...
null
trpc__trpc__6987
trpc/trpc
6,987
defect
7e0b882ab61b8494724f4ac9fa5f4e413f273b24
133ef59dbd0e1626f1f1e4cfd294866f81dd7c27
Prefix query key 2
- prefix always a string (but added as an array, we can make it more flexible at a later point) - force setting a query key on provider - get rid of that `readonly string[]`
diff --git a/packages/tanstack-react-query/src/internals/Context.tsx b/packages/tanstack-react-query/src/internals/Context.tsx index b938bb66860..ab375db5f18 100644 --- a/packages/tanstack-react-query/src/internals/Context.tsx +++ b/packages/tanstack-react-query/src/internals/Context.tsx @@ -10,14 +10,19 @@ export inte...
2
1
0
[{"id": "G0", "claim": "The provider prop name `queryKeyPrefix` is not strictly correct because it also prefixes the mutation key, and a name like `keyPrefix` might be better, though the reviewer was unsure that would not confuse users since it is not TanStack Query terminology.", "category": "maintainability", "verdic...
null
trpc__trpc__7037
trpc/trpc
7,037
defect
e5a037eca3fb69b916ae23dc2d8e53f5eabb04ad
6194059d3a4bd164878215c38a8d3e1da25e298e
fix(server): pass maxDurationMs timeout signal to subscription handlers
## Summary When using `httpSubscriptionLink` with `maxDurationMs`, the timeout was not being propagated to the subscription handler's `opts.signal`. This caused subscriptions that wait for the signal to abort (without yielding values) to hang indefinitely, as described in #6991. **The fix:** - Creates a combined `Abo...
diff --git a/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts b/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts index d9086e9a684..d96490eb737 100644 --- a/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts +++ b/packages/server/src/unstable-core-do-no...
7
6
2
[{"id": "G0", "claim": "The comment added after the procedure call references a timeoutId variable that no longer exists and should be updated to describe the current AbortController-based timeout behavior.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "cl...
null
trpc__trpc__7097
trpc/trpc
7,097
defect
cd2d22ccb86ec57bf9f62e4b2f46c98c944076ef
95dc8ff4d6a581046097a85d5b69496f1980d772
feat(server): add `batchIndex` to procedures and middleware in batched requests
Closes #7096 ## 🎯 Changes **Feature:** Expose `callIndex` to procedures and middleware for batched requests. When using `httpBatchLink` or `httpBatchStreamLink`, multiple procedure calls are batched into a single HTTP request. This PR adds a `callIndex` property that indicates the position of each call within t...
diff --git a/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts b/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts index 299cc754596..609f0907f1a 100644 --- a/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts +++ b/packages/server/src/unstable-core-do-no...
3
1
1
[{"id": "G0", "claim": "The JSDoc added for the new callIndex/batchIndex field on ProcedureResolverOptions and MiddlewareFunction should state that the index is 0-based and describe its value for non-batched requests instead of leaving users to read the implementation.", "category": "documentation", "verdict": "uncerta...
null
trpc__trpc__7174
trpc/trpc
7,174
defect
d741166ade638431fe8bb7ab36b8ef6330aa48ed
fdec708228e5c0d96639cc481bf04937a853b8e8
docs: fix zod v4 zAsyncIterable generic order in subscriptions guide
## Summary Fix the `zod v4` output-validation snippet in the subscriptions docs to use the correct `ZodType<Output, Input>` generic order. ## What changed - In `/www/docs/server/subscriptions.md` (zod v4 section): - `yield` changed from `z.ZodType<TYieldIn, TYieldOut>` to `z.ZodType<TYieldOut, TYieldIn>` - `return...
diff --git a/www/docs/server/subscriptions.md b/www/docs/server/subscriptions.md index cad01f1719b..21bbd898861 100644 --- a/www/docs/server/subscriptions.md +++ b/www/docs/server/subscriptions.md @@ -272,12 +272,12 @@ export function zAsyncIterable< /** * Validate the value yielded by the async generator */...
5
1
1
[{"id": "G0", "claim": "The PR swaps the zod v4 generic parameters in the wrong direction: the docs snippet should read z.ZodType<TYieldIn, TYieldOut> and z.ZodType<TReturnIn, TReturnOut>, reverting to the pre-PR order to stay consistent with the final cast.", "category": "correctness", "verdict": "opposed", "priority"...
null
trpc__trpc__7190
trpc/trpc
7,190
defect
6c03ce43f883726ce9ab4150461ae527989f8bd2
1222d8921d192a85e915972a4afa287afb688d5f
fix(tanstack-react-query): useSuspenseInfiniteQuery shows skipToken type error when getNextPageParam is not provided
Closes #6701 ## 🎯 Changes #6701 provides a helpful codesandbox reproducing `useSuspenseInfiniteQuery` showing a skipToken type-check error. This seems to be Typescript taking the wrong method overload for `infiniteQueryOptions` because 1 overload has the second parameter object set as optional, and that overload...
diff --git a/packages/tanstack-react-query/src/internals/infiniteQueryOptions.ts b/packages/tanstack-react-query/src/internals/infiniteQueryOptions.ts index 7d4264f9c3b..a0bcf3c7b35 100644 --- a/packages/tanstack-react-query/src/internals/infiniteQueryOptions.ts +++ b/packages/tanstack-react-query/src/internals/infinit...
2
2
0
[{"id": "G0", "claim": "The `@ts-expect-error` comments at lines 208 and 217 of packages/tanstack-react-query/test/queryOptions.test.tsx reference `useSuspenseQuery` but sit inside `useSuspenseQueries` calls, so both should say `useSuspenseQueries`.", "category": "documentation", "verdict": "supported", "priority": "P2...
null
trpc__trpc__7191
trpc/trpc
7,191
defect
6c03ce43f883726ce9ab4150461ae527989f8bd2
45a11ed5e828e351f84432ee796518911984f0d1
feat(server): max batch size
Closes #7153 ## 🎯 Changes Adds maxBatchSize to server adapters, validating at the earliest point possible during batch deserialisation <!-- Note: once you create a Pull request, we will automatically fix auto-fixable lint issues in your branch --> ## ✅ Checklist - [ ] I have followed the steps listed ...
diff --git a/packages/server/src/unstable-core-do-not-import/http/contentType.ts b/packages/server/src/unstable-core-do-not-import/http/contentType.ts index e44e9365e65..191a97db5bb 100644 --- a/packages/server/src/unstable-core-do-not-import/http/contentType.ts +++ b/packages/server/src/unstable-core-do-not-import/htt...
6
2
2
[{"id": "G0", "claim": "The maxBatchSize check runs even when the request is not a batch call, so a limit below the path count (e.g. maxBatchSize: 0) would reject normal single requests despite the option being documented as applying to batch calls; gate the check behind isBatchCall (or clarify that the option applies ...
null
trpc__trpc__7207
trpc/trpc
7,207
defect
f489af012c77c29ffef4ae14f5edd8186f42b460
40c8c8fd4d687ab32037b7db559c56863d2ebc8a
fix: SSE subscriptions don't reconnect after maxDurationMs (#7094)
Fixes #7094 When `maxDurationMs` is set, SSE subscriptions should end after the timeout and the client should reconnect automatically. Instead, the connection hangs silently and the client never reconnects. ## Root cause The server never actually ends the HTTP response. When `maxDurationMs` fires, it aborts `combine...
diff --git a/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts b/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts index 06f5a40f8bd..e3dbbb2de1a 100644 --- a/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts +++ b/packages/server/src/unstable-core-do-no...
6
4
0
[{"id": "G0", "claim": "Use `await using ctx = testServerAndClientResource(...)` directly in the new test setup instead of initializing the fixture through `run(...)`, keeping `deferred`, `results` and `onConnection` as local helpers, per the repo's test coding guidelines.", "category": "maintainability", "verdict": "s...
null
trpc__trpc__7233
trpc/trpc
7,233
defect
a2c5fed0652a2a8da8274acca28f76e35994a5e3
e67c2badef17df23e3c5b80deea24f202c745d1a
fix: preserve buffered chunks on stream close in httpBatchStreamLink
## Summary Fixes #7209 When using `httpBatchStreamLink`, normal stream completion was causing buffered chunks to be silently discarded because both `close` and `abort` handlers called `controller.error()` via `closeOrAbort`. Per the [WHATWG Streams spec](https://streams.spec.whatwg.org/#rs-default-controller-error),...
diff --git a/packages/server/src/unstable-core-do-not-import/stream/jsonl.test.ts b/packages/server/src/unstable-core-do-not-import/stream/jsonl.test.ts index aa10b6da42b..69c4dd97852 100644 --- a/packages/server/src/unstable-core-do-not-import/stream/jsonl.test.ts +++ b/packages/server/src/unstable-core-do-not-import/...
2
2
1
[{"id": "G0", "claim": "If the source stream closes normally before any data is sent (e.g. an empty response), handleClose only calls streamManager.closeAll() and never touches headDeferred, so the caller awaiting the head may hang forever; consider resolving headDeferred with an empty result or rejecting it when the s...
null
trpc__trpc__7241
trpc/trpc
7,241
defect
0929b25afb3d977b671787cb49fe54d2116d5754
b540049146ffe6f0fdc061460397bd0f3d203a02
feat: add `streamHeader` option to httpBatchStreamLink
Closes https://github.com/trpc/trpc/issues/7240 ## 🎯 Changes Adds a `streamHeader` option to `httpBatchStreamLink` that controls which HTTP header signals the server to respond with a streaming format. - `'trpc-accept'` (default): sends the custom `trpc-accept: application/jsonl` header (current behavior) - ...
diff --git a/packages/client/src/links/httpBatchStreamLink.ts b/packages/client/src/links/httpBatchStreamLink.ts index 290472c172b..317232d64a3 100644 --- a/packages/client/src/links/httpBatchStreamLink.ts +++ b/packages/client/src/links/httpBatchStreamLink.ts @@ -1,6 +1,7 @@ import type { AnyRouter, ProcedureType } f...
3
3
2
[{"id": "G0", "claim": "The appended `accept` query parameter can be shadowed when the base URL already contains an `accept` query param, silently disabling query-mode streaming; it should be set via URLSearchParams for deterministic precedence.", "category": "correctness", "verdict": "supported", "priority": "P1", "sc...
null
trpc__trpc__7262
trpc/trpc
7,262
defect
346868cca36c26c4d12ad5ba30dbcf6ed9dc96c5
8849448a6181b1b8ee3ef6b4ca23836fabf5135b
fix(server): use correct call index in batch stream error handling
Closes # ## 🎯 Changes Fix hardcoded `info.calls[0]` in the streaming batch response handler (`resolveResponse.ts`). When a batch request contains multiple calls and the 2nd+ call errors, the error shape incorrectly uses the first call's `path`, `input`, and `type`. The non-streaming batch handler in the same file c...
diff --git a/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts b/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts index d37479e7e1d..7e4fc35f866 100644 --- a/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts +++ b/packages/server/src/unstable-core-do-no...
4
3
0
[{"id": "G0", "claim": "Rename the regression test file to `batchStreamErrorCallIndex.test.ts` to satisfy the `unicorn/filename-case` lint rule.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Switch the test's `import { z } from 'zod'` to the na...
null
trpc__trpc__7280
trpc/trpc
7,280
defect
e971f84240eca55a274e1ad6992d26ece7bcee2e
314d0b7db4bc80ea46f9714b60b169a902306def
fix: error handling with Node VM
Closes #7272 ## 🎯 Changes Fixed error handling when tRPC is used with Node VM by attempting to show the error message for implicitly thrown errors. ## ✅ Checklist - [x] I have followed the steps listed in the [Contributing guide](https://github.com/trpc/trpc/blob/main/CONTRIBUTING.md). - [ ] If necessary,...
diff --git a/packages/server/src/unstable-core-do-not-import/error/TRPCError.ts b/packages/server/src/unstable-core-do-not-import/error/TRPCError.ts index 7feb8609200..fe005075475 100644 --- a/packages/server/src/unstable-core-do-not-import/error/TRPCError.ts +++ b/packages/server/src/unstable-core-do-not-import/error/...
4
1
1
[{"id": "G0", "claim": "Object.assign only copies enumerable own properties, so wrapping a cross-realm or error-like object drops non-enumerable properties like stack, losing the stack trace; copy stack explicitly when it is a string.", "category": "correctness", "verdict": "uncertain", "priority": "P1", "scope": "intr...
null
trpc__trpc__7286
trpc/trpc
7,286
defect
f6e839f2b127b394fa1e9eb26bfe0c75c47fcbf2
3a315db187afbcee8622faf0d974d5b450cc7b60
fix(server): unwrap error from cause for streaming onError
## Summary The `onError` callback in `resolveResponse.ts` receives a `{ error, path }` object from jsonl.ts but passes the entire wrapper to `getTRPCErrorFromUnknown(cause)` instead of `cause.error`. This causes `getCauseFromUnknown` to create an `UnknownCauseError` with an empty message (`""`), which then short-circu...
diff --git a/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts b/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts index 05d18e6399d..44fe5454e19 100644 --- a/packages/server/src/unstable-core-do-not-import/http/resolveResponse.ts +++ b/packages/server/src/unstable-core-do-no...
2
1
0
[{"id": "G0", "claim": "The new test's name says it should preserve the error message and path, but its assertions only cover the message/cause, so either assert the relevant path info (e.g. serverErrorOpts.path) or remove the 'and preserve ... path' portion to keep the test intent accurate.", "category": "testing", "v...
null
trpc__trpc__7336
trpc/trpc
7,336
defect
c188dab0822caf3615199e4ac95147bc7560d26f
8ad94871da650034b28d05535735065ae7ce818c
fix(server): handle React 19 proxy coercion in createInnerProxy
## Problem React 19 can coerce a proxy object to a primitive by calling `valueOf()`, `toString()`, or `toJSON()` on it — for example during rendering, string interpolation, or console logging. When these methods are called on the proxy returned by `createInnerProxy()`, the current `get` trap simply returns *another pr...
diff --git a/packages/server/src/unstable-core-do-not-import/createProxy.test.ts b/packages/server/src/unstable-core-do-not-import/createProxy.test.ts index 5af8899a625..a0e7bdce6e6 100644 --- a/packages/server/src/unstable-core-do-not-import/createProxy.test.ts +++ b/packages/server/src/unstable-core-do-not-import/cre...
5
4
3
[{"id": "G0", "claim": "Special-casing valueOf/toString/toJSON in the get trap makes those path segments unchainable, so a router or procedure named like a coercion key (e.g. caller.toString.query()) would break.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1",...
null
trpc__trpc__7350
trpc/trpc
7,350
defect
37917335d97f4799dc9924ca78b16e299388bdd0
d4df651b4077ab924577edb4b0510097937bdc0b
chore: upgrade pnpm to 10.33.1
<!-- CURSOR_AGENT_PR_BODY_BEGIN --> Closes # ## 🎯 Changes - upgrade the monorepo's pnpm version pins to `10.33.1` - align shared/example GitHub workflows that explicitly install pnpm so CI uses the same version everywhere ## ✅ Checklist - [x] I have followed the steps listed in the [Contributing guide](https://git...
diff --git a/.github/setup/action.yml b/.github/setup/action.yml index 1d94977ceec..85184a62cd4 100644 --- a/.github/setup/action.yml +++ b/.github/setup/action.yml @@ -4,6 +4,8 @@ runs: using: 'composite' steps: - uses: pnpm/action-setup@v5 + with: + version: 10.33.1 - uses: actions/setup-n...
1
1
0
[{"id": "G0", "claim": "Question whether the explicit `version: 10.33.1` input passed to pnpm/action-setup@v5 in .github/setup/action.yml is needed, implying it should be dropped if redundant.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
trufflesecurity__trufflehog__1550
trufflesecurity/trufflehog
1,550
defect
f8f2485c6dab7ffd5d0bd30ca8d6a9ab412965e4
8f0059c868476622a89ccf698548d9aeeb0f82fd
Improve MongoDB connection string matching
This mostly fixes #1512, although it would be valuable to add real secrets to test verification of multiple hosts, connection options, etc.
diff --git a/pkg/detectors/mongodb/mongodb.go b/pkg/detectors/mongodb/mongodb.go index 8593fae014b5..892df7408abc 100644 --- a/pkg/detectors/mongodb/mongodb.go +++ b/pkg/detectors/mongodb/mongodb.go @@ -2,6 +2,7 @@ package mongodb import ( "context" + "errors" "net/url" "strings" "time" @@ -12,7 +13,6 @@ imp...
1
1
0
[{"id": "G0", "claim": "In the FromData verification block the newly added SetVerificationError call should pass the renamed verificationErr variable instead of the stale err, which the surrounding lines were just changed away from.", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introd...
null
trufflesecurity__trufflehog__1958
trufflesecurity/trufflehog
1,958
defect
f3479194d29dfa77d9e179d81036d913354301df
89522f188c414880dfaf9995d18103ca3066bb14
Detector-Competition-Feat: Adding Azure Container Registry Password Detector
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: Explain the purpose of the PR. ### Checklist: * [ ] Tests passing (`make test-commun...
diff --git a/pkg/detectors/azurecontainerregistry/azurecontainerregistry.go b/pkg/detectors/azurecontainerregistry/azurecontainerregistry.go new file mode 100644 index 000000000000..def259eb2bf6 --- /dev/null +++ b/pkg/detectors/azurecontainerregistry/azurecontainerregistry.go @@ -0,0 +1,97 @@ +package azurecontainerre...
4
3
2
[{"id": "G0", "claim": "The password regex needs boundary characters, otherwise this part can get a lot of matches.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The new code needs to be formatted with `go fmt -w`.", "category": "maintainability", ...
null
trufflesecurity__trufflehog__2206
trufflesecurity/trufflehog
2,206
defect
d1a2d9e83264da0a75410cd1736576c47a8f87a4
3d576419e8c0e5d839fb839067bb34f30b1d7aa2
Update GitParse logic to handle edge case.
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This PR has a few changes. - Fixes #2109. - Passes the repository origin URL to gi...
diff --git a/pkg/gitparse/gitparse.go b/pkg/gitparse/gitparse.go index 39a72d399c046..c5797212e0199 100644 --- a/pkg/gitparse/gitparse.go +++ b/pkg/gitparse/gitparse.go @@ -4,6 +4,7 @@ import ( "bufio" "bytes" "fmt" + "github.com/go-logr/logr" "io" "os" "os/exec" @@ -92,6 +93,7 @@ func (state ParseState) St...
1
1
1
[{"id": "G0", "claim": "When there is no remoteURL, ScanCommits should put the path into the context so that the context always has some repo info.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
trufflesecurity__trufflehog__2347
trufflesecurity/trufflehog
2,347
defect
76fcdae3a0ed1b71feb3fe599dd4d3e82de5757d
09836383104003b80615e19a34a3f8b7274be780
Create Azure OpenAI detector
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This fixes #1939. ### Checklist: * [x] Tests passing (`make test-community`)? * [ ]...
diff --git a/pkg/detectors/azure_openai/azure_openai.go b/pkg/detectors/azure_openai/azure_openai.go new file mode 100644 index 0000000000000..f5fd1c1a1b617 --- /dev/null +++ b/pkg/detectors/azure_openai/azure_openai.go @@ -0,0 +1,161 @@ +package azure_openai + +import ( + "context" + "encoding/json" + "fmt" + "io" + "...
2
2
1
[{"id": "G0", "claim": "The base URL should be passed in RawV2 (key+url) so findings deduplicate, rather than being returned as ExtraData.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G2", "claim": "Confirm the auth header name used in the verification request i...
null
trufflesecurity__trufflehog__2381
trufflesecurity/trufflehog
2,381
defect
a22874f9f05cdf526357a7b1d921daa7de03e2fa
fbbbc6d7b3a48eded7d29f026809bc3e31693d11
added flyio detector
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: Explain the purpose of the PR. ### Checklist: * [ ] Tests passing (`make test-commun...
diff --git a/pkg/detectors/flyio/flyio.go b/pkg/detectors/flyio/flyio.go new file mode 100644 index 000000000000..9672855f01d4 --- /dev/null +++ b/pkg/detectors/flyio/flyio.go @@ -0,0 +1,104 @@ +package flyio + +import ( + "context" + "fmt" + "io" + "net/http" + + regexp "github.com/wasilibs/go-re2" + + "github.com/tru...
4
2
0
[{"id": "G0", "claim": "Fly.io tokens generated by the reviewer start with fo1_, so the detector should probably add the fo1_ prefix to its regex and to its keywords.", "category": "correctness", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The detector should be renamed to f...
null
trufflesecurity__trufflehog__2391
trufflesecurity/trufflehog
2,391
defect
02fe9e189b4c0ff25cbe4750f6ebeef23624d216
e37b84cbdad84a842ae5789ca108ab0f4a80f8d8
Update GitParse to handle quoted binary filenames
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This fixes #2384. ~I figured that a regexp would be more robust than checking multiple i...
diff --git a/pkg/gitparse/gitparse.go b/pkg/gitparse/gitparse.go index 1462b5c9397a..c558c897e7d1 100644 --- a/pkg/gitparse/gitparse.go +++ b/pkg/gitparse/gitparse.go @@ -458,10 +458,17 @@ func (c *Parser) FromReader(ctx context.Context, stdOut io.Reader, diffChan chan case isBinaryLine(latestState, line): lates...
2
2
0
[{"id": "G0", "claim": "The PR should use bytes.Split instead of the regexp for extracting the binary-file path, for performance (minimal) and simplicity, since it seems easy enough to handle quoted and unquoted cases.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1"...
null
trufflesecurity__trufflehog__2585
trufflesecurity/trufflehog
2,585
defect
fd7e7e6e296c13ede7642002eb254ad8144ef736
551583a94a9a134f9ce962d6c5fffe6fecf8de2d
Make Git work with escaped unicode characcters
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This fixes #2418. The issue appears to be that converting `[]byte` -> `string` does not ...
diff --git a/pkg/gitparse/gitparse.go b/pkg/gitparse/gitparse.go index 3c364644aa84a..11eddc4623b15 100644 --- a/pkg/gitparse/gitparse.go +++ b/pkg/gitparse/gitparse.go @@ -424,7 +424,7 @@ func (c *Parser) FromReader(ctx context.Context, stdOut io.Reader, diffChan chan case isBinaryLine(latestState, line): lates...
3
2
1
[{"id": "G0", "claim": "Add a comment explaining the pitfall avoided by decoding with strconv.Unquote on a concatenated quoted string instead of sprintf.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The string concatenation may be unnecessary — ...
null
trufflesecurity__trufflehog__2653
trufflesecurity/trufflehog
2,653
defect
0d3023fe746163edf4a33c1cca8c9c74e6f94fd6
75a23ef0df4a42f9dbdbc2f659585a79ea8b4b38
Improve handling of Gist URLs
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This is a follow-up to #2625. It fixes #2640 (at least based on my testing) and should a...
diff --git a/pkg/sources/github/github.go b/pkg/sources/github/github.go index 757668b32f6b5..2f7c102b651c2 100644 --- a/pkg/sources/github/github.go +++ b/pkg/sources/github/github.go @@ -427,11 +427,14 @@ RepoLoop: continue } - if strings.EqualFold(urlParts[0], "gist.github.com") { + if isGistUrl(urlPa...
3
2
0
[{"id": "G0", "claim": "The 4-segment case has an extra `!`, and a `gist` segment should only be expected for the `github.com` host, so the condition should read `!(strings.EqualFold(urlParts[0], \"github.com\") && strings.EqualFold(urlParts[1], \"gist\"))`.", "category": "correctness", "verdict": "opposed", "priority"...
null
trufflesecurity__trufflehog__2713
trufflesecurity/trufflehog
2,713
defect
3d04b5c58eb8aca88fd657809cb12253f74230b3
cf9ccef244c7cc4ee7b34da0cd5f8eb1bf8e6a6b
Scan commit metadata
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This fixes #2683. It scans the commit author, committer (which is typically `GitHub <nor...
diff --git a/pkg/gitparse/gitparse.go b/pkg/gitparse/gitparse.go index 0923646eee2c6..6bfd3a92c7402 100644 --- a/pkg/gitparse/gitparse.go +++ b/pkg/gitparse/gitparse.go @@ -106,11 +106,12 @@ func (d *Diff) finalize() error { // Commit contains commit header info and diffs. type Commit struct { - Hash string - Au...
7
2
1
[{"id": "G0", "claim": "The pre-canned pretty formats that the new `--pretty=fuller` output relies on might change in the future.", "category": "design", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The doc comment above isMessageStartLine should be updated from `Date` to `Comm...
null
trufflesecurity__trufflehog__2845
trufflesecurity/trufflehog
2,845
defect
9095845958d9cabdc354ddf372123b5399a5d334
7ffd2533c3dbdd43ea2e28e746745791eec28f47
Update HubSpot detectors
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This changes the HubSpot v1 detector to tri-state verification and adds two other common...
diff --git a/pkg/detectors/hubspot_apikey/v1/hubspot_apikey_v1.go b/pkg/detectors/hubspot_apikey/v1/hubspot_apikey_v1.go new file mode 100644 index 0000000000000..a4138a08b408a --- /dev/null +++ b/pkg/detectors/hubspot_apikey/v1/hubspot_apikey_v1.go @@ -0,0 +1,107 @@ +package v1 + +import ( + "context" + "fmt" + "io" +...
2
1
0
[{"id": "G0", "claim": "A commented-out `// \"log\"` import was left in the new v1 and v2 detector source files and should be removed.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The extra blank line splitting the import block in the v2 integ...
null
trufflesecurity__trufflehog__2882
trufflesecurity/trufflehog
2,882
defect
5102e3ae1178e320e749ca14ac94b4073165c975
beab6aec5386fdcde850b352f87660b1d056f667
feat: support docker image history scanning
### Description > [!NOTE] > This PR has been created to help illustrate a possible fix for #2881. I'd be grateful for any feedback, and if this is useful, I'll follow the guidance to ready it for merge. Enables the `docker` scanner to send image history records to the scanner. These records are generally the com...
diff --git a/pkg/sources/docker/docker.go b/pkg/sources/docker/docker.go index 7088dcbceb57..698bc0a49422 100644 --- a/pkg/sources/docker/docker.go +++ b/pkg/sources/docker/docker.go @@ -108,7 +108,24 @@ func (s *Source) Chunks(ctx context.Context, chunksChan chan *sources.Chunk, _ . } ctx = context.WithValue...
4
2
0
[{"id": "G0", "claim": "On an error while processing a single history entry, the scan should deliberately choose between returning early and continuing with the next entry.", "category": "design", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Since no additional context is added...
null
trufflesecurity__trufflehog__2976
trufflesecurity/trufflehog
2,976
defect
86a0ea74ef01f02553f0112467c916b65dd6acd3
398ff9f94a1fcecc2ae90ef8fcfa9e95d06bb7e9
Add UUIDs to false positive checker
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This fixes #1953 by adding a list of UUID false positives. It also renames the lists so ...
diff --git a/pkg/detectors/falsepositives.go b/pkg/detectors/falsepositives.go index 896312c1c14d8..fb220d69a36f0 100644 --- a/pkg/detectors/falsepositives.go +++ b/pkg/detectors/falsepositives.go @@ -12,7 +12,10 @@ import ( "github.com/trufflesecurity/trufflehog/v3/pkg/context" ) -var DefaultFalsePositives = []Fa...
2
2
0
[{"id": "G0", "claim": "The false-positives test does not rely on 'real' values, so it should not be behind the 'detectors' build tag and should run in `make test` and `make test-community`.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "pre_existing"}, {"id": "G1", "claim": "IsKnownFalseP...
null
trufflesecurity__trufflehog__3414
trufflesecurity/trufflehog
3,414
defect
aa17b8eba486bbdf19bc77aedb3c56f9cb00e1ac
1fcff0a807ae847e87f24de0b6e05bda579655cc
[detector] feat: added rootly detector
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: Explain the purpose of the PR. Relates to #3396 I have verified the tests for rootly ...
diff --git a/pkg/detectors/rootly/rootly.go b/pkg/detectors/rootly/rootly.go new file mode 100644 index 000000000000..7244ea27f4ce --- /dev/null +++ b/pkg/detectors/rootly/rootly.go @@ -0,0 +1,77 @@ +package rootly + +import ( + "context" + "net/http" + "strings" + + regexp "github.com/wasilibs/go-re2" + + "github.com/...
6
6
2
[{"id": "G0", "claim": "Keywords() should return []string{\"rootly_\"} instead of []string{\"rootly\"}.", "category": "performance", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The detector's logic is old and does not conform to current best practices and should follow the a...
null
trufflesecurity__trufflehog__3437
trufflesecurity/trufflehog
3,437
defect
e6c43ca86341970e67441b3c2c7bd9a8547dfc6d
7b6339fcad62947d633391cffdecbc33958e35c0
fix: added correct verification endpoint & validation logic for alegra
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: Fixes #3436 <img width="722" alt="Screenshot 2024-10-21 at 3 22 10 PM" src="https://...
diff --git a/pkg/detectors/alegra/alegra.go b/pkg/detectors/alegra/alegra.go index 1fcbfcb2bdce..be8c44831fbf 100644 --- a/pkg/detectors/alegra/alegra.go +++ b/pkg/detectors/alegra/alegra.go @@ -60,7 +60,7 @@ func (s Scanner) FromData(ctx context.Context, verify bool, data []byte) (result } if verify { - r...
2
2
0
[{"id": "G0", "claim": "The idPat regex's 25-30 character length constraint fails to detect valid user IDs (emails shorter than 25 characters), so the regex should be tested and adjusted to cover valid email lengths.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "pre_existing"}, {"id":...
null
trufflesecurity__trufflehog__3447
trufflesecurity/trufflehog
3,447
defect
e6c43ca86341970e67441b3c2c7bd9a8547dfc6d
15c45b8f22d964562c653347130eb62602664d30
fix: fixed autoklose verification endpoint
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: Fixes #3446 <img width="596" alt="Screenshot 2024-10-17 at 2 20 23 PM" src="https://gi...
diff --git a/pkg/detectors/autoklose/autoklose.go b/pkg/detectors/autoklose/autoklose.go index 9ee8fde5d3c0..c6c7b561dd2b 100644 --- a/pkg/detectors/autoklose/autoklose.go +++ b/pkg/detectors/autoklose/autoklose.go @@ -4,11 +4,12 @@ import ( "context" "encoding/json" "fmt" - regexp "github.com/wasilibs/go-re2" ...
4
4
0
[{"id": "G0", "claim": "When the result is verified, the email of the user associated with the token (returned by the /api/me/ endpoint) should be added to the result's ExtraData field.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The API documentation...
null
trufflesecurity__trufflehog__3470
trufflesecurity/trufflehog
3,470
defect
871a2b0f06f602899f8c928ce19d2737a3758e6c
8734bdc58dbafcee5b0384e161d979e89a3318dd
fix: fixed verification endpoint and verification logic for brand fetch
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: In this PR, we have added version 2 of the brandfetch detector. The following are the ch...
diff --git a/pkg/detectors/brandfetch/brandfetch.go b/pkg/detectors/brandfetch/brandfetch.go index 6dc6c3eabb9cd..7805e8c6cebbd 100644 --- a/pkg/detectors/brandfetch/brandfetch.go +++ b/pkg/detectors/brandfetch/brandfetch.go @@ -2,10 +2,11 @@ package brandfetch import ( "context" - regexp "github.com/wasilibs/go-r...
4
4
3
[{"id": "G0", "claim": "The comment announcing the upgraded API says 'new API doc:' but the documentation link itself is missing.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Since the v1 APIs with old tokens still work, the pull request should ...
null
trufflesecurity__trufflehog__3478
trufflesecurity/trufflehog
3,478
defect
6e055ea578367a481497533b6302c86682ea5568
7f31ba6bbfb5cd80ff4c7a0e2adcf973962b51b9
fix: fixed verifcation pattern logic for `bulksms`
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: Fixes #3477 <img width="689" alt="Screenshot 2024-10-19 at 1 51 50 PM" src="https://...
diff --git a/pkg/detectors/bulksms/bulksms.go b/pkg/detectors/bulksms/bulksms.go index b543fd5a7fed..43c6f0b28f8e 100644 --- a/pkg/detectors/bulksms/bulksms.go +++ b/pkg/detectors/bulksms/bulksms.go @@ -4,16 +4,17 @@ import ( "context" b64 "encoding/base64" "fmt" - regexp "github.com/wasilibs/go-re2" "net/http"...
4
4
0
[{"id": "G0", "claim": "Instead of manually encoding the key and ID for basic authentication, the detector could leverage the SetBasicAuth function to simplify the process.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "claim": "The verified check coul...
null
trufflesecurity__trufflehog__3484
trufflesecurity/trufflehog
3,484
defect
6e055ea578367a481497533b6302c86682ea5568
d6cc793675101c2c840ebfa8365f262b97b5a17f
feat: added `v3` API version for the detector `captaindatago`
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: Fixes #3483 ### Checklist: * [x] Tests passing (`make test-community`)? * [x] Lint...
diff --git a/pkg/detectors/captaindata/captaindata.go b/pkg/detectors/captaindata/v2/captaindata.go similarity index 100% rename from pkg/detectors/captaindata/captaindata.go rename to pkg/detectors/captaindata/v2/captaindata.go diff --git a/pkg/detectors/captaindata/captaindata_test.go b/pkg/detectors/captaindata/v2/c...
2
2
2
[{"id": "G0", "claim": "The new versioned detector does not implement the versioning interface (the same issue rgmz raised in PRs #3414 and #3427), so when running trufflehog a \"possible duplicate detector configured\" warning is displayed for CaptainData.", "category": "design", "verdict": "supported", "priority": "P...
null
trufflesecurity__trufflehog__4252
trufflesecurity/trufflehog
4,252
defect
62faf2e85e4a73c7a616175d402a77063f23869c
43f280c0649873832a54d70a58555ab2e99d41bf
Salesforce OAuth2 Detector
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This pull request introduces a new detector for Salesforce OAuth2 Client Credentials. Th...
diff --git a/pkg/detectors/salesforceoauth2/salesforceoauth2.go b/pkg/detectors/salesforceoauth2/salesforceoauth2.go new file mode 100644 index 000000000000..906f42553d73 --- /dev/null +++ b/pkg/detectors/salesforceoauth2/salesforceoauth2.go @@ -0,0 +1,165 @@ +package salesforceoauth2 + +import ( + "context" + "encodin...
2
1
1
[{"id": "G0", "claim": "Reconsider whether an invalid_grant response should be treated as a verification error, i.e. whether the credentials in that case are meaningful.", "category": "design", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Handle the case where the hostname cann...
null
trufflesecurity__trufflehog__4276
trufflesecurity/trufflehog
4,276
defect
9c7e578f84154929732874e87fd658127343aabd
b532f11b0b49a739e9c6ed3a38c62faf6c6097dd
Added support for scanning images from the docker daemon
- Now you can scan an image directly after building it with `docker build` by using the `docker://` prefix. This is ideal for local development and CI/CD pipelines that want to ensure images do not contain leaked secrets before pushing to an image registry. - Resolves #4275 <!-- Please create an issue to collect f...
diff --git a/README.md b/README.md index 115e461252cd5..4438adc3b2143 100644 --- a/README.md +++ b/README.md @@ -280,7 +280,14 @@ trufflehog gcs --project-id=<project-ID> --cloud-environment --results=verified, Use the `--image` flag multiple times to scan multiple images. ```bash +# to scan from a remote registry ...
2
2
1
[{"id": "G0", "claim": "extractImageNameTagDigest takes imageInfo by value, so the base and tag it sets are not propagated back to the caller and that metadata is lost; remove the unused parameter and return a fresh imageInfo from the function.", "category": "correctness", "verdict": "supported", "priority": "P1", "sco...
null
trufflesecurity__trufflehog__4296
trufflesecurity/trufflehog
4,296
defect
e365bcf512db9aef63178658ad3cb58432d5a274
58d5daef867c7ddd11a43c79225c760c49c5ce5b
Add additional unicode escape support
### Description: Currently TruffleHog supports 3 unicode escape formats: ``` \u0041 \\u0041 U+0041 ``` This PR adds support for several other common formats: ``` \u{41} \U00000041 \x{41} \41 &#x41; %u0041 ``` Unittests were added to ensure proper decoding of each new format, and benchmark tests w...
diff --git a/pkg/decoders/escaped_unicode.go b/pkg/decoders/escaped_unicode.go index 31899ba1d7d2..f3f6462b357b 100644 --- a/pkg/decoders/escaped_unicode.go +++ b/pkg/decoders/escaped_unicode.go @@ -23,6 +23,33 @@ var ( // Common escape sequence used in programming languages. escapePat = regexp.MustCompile(`(?i:\...
3
1
0
[{"id": "G0", "claim": "The pull request leaves a large commented-out implementation (decodeHexEscape, its call site and its benchmark) in the decoder; the reviewer asks whether that is intentional and says he is not a fan of leaving large chunks of code commented out.", "category": "maintainability", "verdict": "uncer...
null
trufflesecurity__trufflehog__4300
trufflesecurity/trufflehog
4,300
defect
7907482dec76235ae4c2f6c9199bd9e422cdfc5f
dbc76d1622fe7495e23bdb92f2966a8b6317371a
Added v2 for CircleCI Detector
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This PR adds a new version for CircleCI detector ### Checklist: * [x] Tests passing ...
diff --git a/pkg/detectors/circleci/v1/circleci.go b/pkg/detectors/circleci/v1/circleci.go new file mode 100644 index 000000000000..3785f791428c --- /dev/null +++ b/pkg/detectors/circleci/v1/circleci.go @@ -0,0 +1,111 @@ +package circleci + +import ( + "context" + "fmt" + "io" + "net/http" + + regexp "github.com/wasili...
2
2
0
[{"id": "G0", "claim": "In VerifyCircleCIToken, use the http.MethodGet constant and http.NoBody instead of the \"GET\" string literal and a nil request body.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Add the detector version number to the E...
null
trufflesecurity__trufflehog__4309
trufflesecurity/trufflehog
4,309
defect
8d5986d13039c081c25769e1f4c98c77ef17017a
5f32a6ee3bb00224c07ea4c267561326a4b54ece
Updated and Fixed CircleCI Source
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This pull request updates the implementation of the CircleCI source and also fixes issue...
diff --git a/pkg/sources/circleci/circleci.go b/pkg/sources/circleci/circleci.go index d89b4b2315283..ef5882d896c2c 100644 --- a/pkg/sources/circleci/circleci.go +++ b/pkg/sources/circleci/circleci.go @@ -4,7 +4,9 @@ import ( "bytes" "encoding/json" "fmt" + "io" "net/http" + "strings" "sync/atomic" "githu...
22
22
3
[{"id": "G0", "claim": "The variable `projBuilds` should be renamed to `projectBuilds` (and similar naming refactors applied elsewhere), as a personal preference.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The counter `projectsScanned` shoul...
null
trufflesecurity__trufflehog__4312
trufflesecurity/trufflehog
4,312
defect
ab136f6e9d4fecd5197843fce9a439c6f42e8380
cc51c6de6cac5e257eebe65f8dbfc1189f99b363
Added Anypoint API OAuth2 Detector
### Description: Anypoint uses OAuth2 credentials for authentication. [Reference](https://anypoint.mulesoft.com/exchange/portals/anypoint-platform/f1e97bc6-315a-4490-82a7-23abe036327a.anypoint-platform/access-management-api/minor/1.0/pages/Authentication/). This PR adds a new detector for Anypoint's OAuth2 credenti...
diff --git a/pkg/detectors/anypointoauth2/anypointoauth2.go b/pkg/detectors/anypointoauth2/anypointoauth2.go new file mode 100644 index 000000000000..63e11fd5a785 --- /dev/null +++ b/pkg/detectors/anypointoauth2/anypointoauth2.go @@ -0,0 +1,128 @@ +package anypointoauth2 + +import ( + "context" + "fmt" + "io" + "net/ht...
1
1
0
[{"id": "G0", "claim": "The nested id-secret loop should avoid re-processing secrets that were already validated successfully for an earlier ID, because ID and secret are paired one-to-one.", "category": "performance", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
trufflesecurity__trufflehog__4441
trufflesecurity/trufflehog
4,441
defect
1e8671c6de6d721636e672b3066c6773e4ab6d0b
1388f5fc85dc2073aee6dc730ba39d651e5691ff
Add generic JWT detection and verification
### Description: This adds a generic detector and verifier for generic JWTs. Detection is simple using regular expressions. However, this will produce many false positives. JWT verification is performed using the `github.com/golang-jwt/jwt/v5` package, performing the usual checks (proper decoding, checking timestam...
diff --git a/pkg/detectors/alchemy/alchemy_test.go b/pkg/detectors/alchemy/alchemy_test.go index 6473aebcffde0..ce397c3635bec 100644 --- a/pkg/detectors/alchemy/alchemy_test.go +++ b/pkg/detectors/alchemy/alchemy_test.go @@ -32,12 +32,12 @@ func TestAlchemy_Pattern(t *testing.T) { name: "valid pattern - xml", i...
9
7
4
[{"id": "G0", "claim": "The sporadic TestDetectorValidations failure is probably caused by iterating over a map in the pre-existing custom detector code and should be fixed.", "category": "testing", "verdict": "uncertain", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "claim": "Unit tests should be added for...
null
trufflesecurity__trufflehog__4538
trufflesecurity/trufflehog
4,538
defect
fa512d5084712f11c5cfe3bf9570e1aeb0589a6c
a61492bd74bc39299d1a3a9030ff61aad3497d8f
Fix Github Wiki Page Links
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This PR fixes a bug with link generation for GH wiki pages. - Current (incorrect) Ge...
diff --git a/pkg/giturl/giturl.go b/pkg/giturl/giturl.go index 3270c72ab464..6c9b3aeba30b 100644 --- a/pkg/giturl/giturl.go +++ b/pkg/giturl/giturl.go @@ -159,6 +159,19 @@ func GenerateLink(repo, commit, file string, line int64) string { baseLink += "#L" + strconv.FormatInt(line, 10) } } + } else if str...
3
3
1
[{"id": "G0", "claim": "Remove the stray blank line at the end of the new wiki-link branch in GenerateLink.", "category": "style", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The code assumes wiki files are markdown and hardcodes trimming the \".md\" extension; the author ag...
null
trufflesecurity__trufflehog__4560
trufflesecurity/trufflehog
4,560
defect
df31a0e53a1efa49f2396699d51254455bb81868
b5a66d503ff8ea4acb1d91eb76c805447235d6d3
[INS-104] Support units in S3 source
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This PR supersedes #4270. The original contributor is no longer available to sign the CL...
diff --git a/pkg/sources/s3/s3.go b/pkg/sources/s3/s3.go index f708376aac8d..c1d622f5b2a7 100644 --- a/pkg/sources/s3/s3.go +++ b/pkg/sources/s3/s3.go @@ -62,6 +62,7 @@ type Source struct { var _ sources.Source = (*Source)(nil) var _ sources.SourceUnitUnmarshaller = (*Source)(nil) var _ sources.Validator = (*Source)...
8
8
2
[{"id": "G0", "claim": "The 'Resuming bucket scan' log does not show which bucket the scan is resuming on, since the bucket is only added to the context later in s.scanBucket.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "claim": "The 'Enumerating buc...
null
trufflesecurity__trufflehog__4590
trufflesecurity/trufflehog
4,590
defect
8d144c2ba305fdcf2765b85c7ac08b6a7705a61b
9b9960ee01af9d330cdc72cc18416c04d4eab2e9
[INS-37] Fixed the issue of ftp connection ignoring the detector's co…
### 🛠 Summary of Fixes - **Resolved timeout issue**: The verification logic was unintentionally using the default timeout because the detector context's remaining time wasn’t being forwarded. Updated the implementation to pass the **remaining context deadline** into `verifyFTP`, ensuring correct timeout b...
diff --git a/pkg/detectors/ftp/ftp.go b/pkg/detectors/ftp/ftp.go index dff83faba2b4..8b177866dcea 100644 --- a/pkg/detectors/ftp/ftp.go +++ b/pkg/detectors/ftp/ftp.go @@ -80,7 +80,13 @@ func (s Scanner) FromData(ctx context.Context, verify bool, data []byte) (result if verify { timeout := s.verificationTimeout ...
3
2
0
[{"id": "G0", "claim": "ftp.Dial can still hang for a longer time than the timeout, so the reviewer asks the author to test the change against that case.", "category": "correctness", "verdict": "uncertain", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The FTP connection opened in verifyFTP is never ...
null
trufflesecurity__trufflehog__4610
trufflesecurity/trufflehog
4,610
defect
8c1219a4f0f586f3e730fbd3ae0ddc68fcab3636
9d79d08d1ba0763631bdb0aeadab03234fd1439d
[INS-232] Fix S3 Source "panic: runtime error: index out of range" bug
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: Recently a bug was reported in our slack community workspace related to S3 scanning. The...
diff --git a/pkg/sources/s3/checkpointer.go b/pkg/sources/s3/checkpointer.go index 4e121f72d680..a6df6586c97f 100644 --- a/pkg/sources/s3/checkpointer.go +++ b/pkg/sources/s3/checkpointer.go @@ -70,7 +70,7 @@ const defaultMaxObjectsPerPage = 1000 // NewCheckpointer creates a new checkpointer for S3 scanning operatio...
1
1
1
[{"id": "G0", "claim": "Bumping the S3 GetObjectWithContext timeout from 30 seconds to 30 minutes looks like a significant difference whose reason should be explained (it was in fact unintended).", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
trufflesecurity__trufflehog__4612
trufflesecurity/trufflehog
4,612
defect
a633174c3b2242aa1b6f8941d2ad6a99e0305964
0eb8260b079399f49f51b19c6b1ef789d092f970
[INS-228] Add ignorePattern configuration support to Postgres and Sqlserver detectors
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This PR adds ignorePattern configuration support to the Postgres and Sqlserver detectors...
diff --git a/pkg/detectors/postgres/postgres.go b/pkg/detectors/postgres/postgres.go index f22291a6e699..3a7449e052f5 100644 --- a/pkg/detectors/postgres/postgres.go +++ b/pkg/detectors/postgres/postgres.go @@ -55,6 +55,33 @@ var ( type Scanner struct { detectors.DefaultMultiPartCredentialProvider detectLoopback b...
1
1
1
[{"id": "G0", "claim": "Add a couple of tests where the SQLServer/Postgres scanners are created without calling .New, to confirm the ignorePattern behaviour works OK without it, since wiring .New in EE would be a separate change.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
trufflesecurity__trufflehog__4649
trufflesecurity/trufflehog
4,649
defect
a1d997362d636325de3acbb6318517a6e16ed766
05bb16dd5b1830ce24c402824253306404a8e056
[INS-246] Add Google Gemini API key detector
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: This PR closes #4623 by introducing the Google Gemini API Key detector All Google Gem...
diff --git a/pkg/detectors/googlegemini/googlegemini.go b/pkg/detectors/googlegemini/googlegemini.go new file mode 100644 index 000000000000..cdf4c163dc45 --- /dev/null +++ b/pkg/detectors/googlegemini/googlegemini.go @@ -0,0 +1,101 @@ +package googlegemini + +import ( + "context" + "fmt" + "io" + "net/http" + "strings...
5
4
3
[{"id": "G0", "claim": "Consider a more explicit detector type name such as GoogleGeminiApiKey or GoogleGeminiToken instead of the generic GoogleGemini, since Gemini supports several kinds of credentials (suggestion, not a blocker).", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"...
null
trufflesecurity__trufflehog__4655
trufflesecurity/trufflehog
4,655
defect
4e02afb0159d0de9be6ceaa2064177f1b16f5033
6b7cdb9970605682cc8e839f04fbded4bb2c5c63
[INS-249] Updated Gitlab client from v0.129.0 to v1.12.0(latest)
### Description: This pull request introduces the following changes: 1. Dependency Update - Updated the gitlab.com/gitlab-org/api/client-go dependency from `v0.129.0` to `v1.12.0` in **go.mod**. 2. Test Adjustments - Fixed the test crashing in `filesystem_integration_test.go` and `gitlab_integration_test.go` ...
diff --git a/go.mod b/go.mod index 290a6db5935b..eadbeb4eab2b 100644 --- a/go.mod +++ b/go.mod @@ -101,7 +101,7 @@ require ( github.com/trufflesecurity/disk-buffer-reader v0.2.1 github.com/wasilibs/go-re2 v1.9.0 github.com/xo/dburl v0.23.8 - gitlab.com/gitlab-org/api/client-go v0.129.0 + gitlab.com/gitlab-org/api...
1
1
1
[{"id": "G0", "claim": "The replace directive pinning client-go to v0.129.0 in go.mod must be removed as well, otherwise the build keeps using v0.129.0 regardless of the version listed below.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}]
null
trufflesecurity__trufflehog__4684
trufflesecurity/trufflehog
4,684
defect
4da563af5a6037c9b53b7b21b93cb58113956e31
8b9e3aa3709d44ad8eb8b1f09c2ea872780d7f57
Added detector for JFrog Artifactory Reference Tokens
## Summary Adds a new detector for JFrog Artifactory Reference Tokens. Unlike JWT tokens (which start with `eyJ`), reference tokens are base64-encoded strings with a predictable structure: ``` reftkn:01:<expiry>:<random_data> ``` When base64-encoded, this always produces a token starting with `cmVmdGtu`. ## D...
diff --git a/pkg/detectors/artifactoryreferencetoken/artifactoryreferencetoken.go b/pkg/detectors/artifactoryreferencetoken/artifactoryreferencetoken.go new file mode 100644 index 0000000000000..4e8a4547aa045 --- /dev/null +++ b/pkg/detectors/artifactoryreferencetoken/artifactoryreferencetoken.go @@ -0,0 +1,168 @@ +pac...
2
2
1
[{"id": "G0", "claim": "Deleting the url from `uniqueUrls` while iterating over it in the nested loop serves no value, might lead to unexpected behavior, and causes subsequent tokens to skip that URL, missing token-URL combinations.", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introd...
null
trufflesecurity__trufflehog__4689
trufflesecurity/trufflehog
4,689
defect
5e900a52f9514842f3fd2a62ccfe8fc197694e06
43bbdf3bc96b42ea98e5716d48a121b97617e60b
OpenAI Admin Key Detector
### Description: This PR adds OpenAI Admin Key Detector and enhances the pre-existing OpenAI detector to skip Admin Key verification Closes #4698 ### Checklist: * [x] Tests passing (`make test-community`)? * [x] Lint passing (`make lint` this requires [golangci-lint](https://golangci-lint.run/welcome/install/#...
diff --git a/pkg/detectors/openai/openai.go b/pkg/detectors/openai/openai.go index 433b21d42b56..5a3f75066334 100644 --- a/pkg/detectors/openai/openai.go +++ b/pkg/detectors/openai/openai.go @@ -28,7 +28,7 @@ var ( defaultClient = common.SaneHttpClient() // The magic string T3BlbkFJ is the base64-encoded string: ...
6
5
3
[{"id": "G0", "claim": "Having `T3BlbkFJ` as a keyword in the openaiadmin detector would also cause non-admin keys to fall into this detector.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The updated openai detector regex still matches admin keys;...
null
trufflesecurity__trufflehog__4697
trufflesecurity/trufflehog
4,697
defect
94fdf01214232715294e27e66eab2a6dad568d21
c03a57c1fd9ef92dd2b172ad7dcfacc21820722f
[INS-285] Fix custom detectors line number reporting to match the full regex instead of capture group
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: #### Problem Currently for custom detectors, line number reporting works by looking f...
diff --git a/pkg/custom_detectors/custom_detectors.go b/pkg/custom_detectors/custom_detectors.go index 2ba4d89cad40..de43d978c724 100644 --- a/pkg/custom_detectors/custom_detectors.go +++ b/pkg/custom_detectors/custom_detectors.go @@ -66,6 +66,9 @@ func NewWebhookCustomRegex(pb *custom_detectorspb.CustomRegex) (*Custom...
5
5
1
[{"id": "G0", "claim": "Since the primary regex is now always set programmatically, reconsider exposing primary_regex_name as a user-configurable option, document in code how and why the primary regex is always used for full matches, and document in the README that the custom detector line number points to the full mat...
null
trufflesecurity__trufflehog__4714
trufflesecurity/trufflehog
4,714
defect
b3b1d4180ac3e2ef42a11eb8acc1cdf6cabb2783
f12e1c987b4a11f33bbfc9623dd6dacad47de54f
Fix pre-receive hook hangs and missing logs by flushing logs on signal and using CommandContext for git commands
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: Fix missing log output on timeout, When TruffleHog times out in pre-receive hooks, i...
diff --git a/main.go b/main.go index b7eb8f2f1bc3..89b0fd7b2cbe 100644 --- a/main.go +++ b/main.go @@ -14,7 +14,7 @@ import ( "strings" "sync" "syscall" - + "time" "github.com/alecthomas/kingpin/v2" "github.com/fatih/color" "github.com/felixge/fgprof" @@ -61,6 +61,7 @@ var ( results = cli.Flag...
4
3
1
[{"id": "G0", "claim": "The comment says WaitDelay is a grace period but per the os/exec docs it is an additional timeout, and hard-coding a five-second timeout inside the generic executeCommand takes control away from callers, so the delay should be added as a parameter instead of being hard-coded.", "category": "desi...
null
trufflesecurity__trufflehog__4726
trufflesecurity/trufflehog
4,726
defect
a450544f0b7c12e99bd78b4f02fe67d5c5e56711
589e821c18a63056ed0879993f9e5d5d1d93cf0a
[INS-307] Added unspecified(0.0.0.0) check to DetectorHttpClientWithNoLocalAddresses
### Description: The current` isLocalIP` check used by `DetectorHttpClientWithNoLocalAddresses` does not account for **unspecified IP addresses (0.0.0.0 / ::)**. This can result in the unspecified/wildcard ip (0.0.0.0) to be resolved into local address which can be used for **SSRF attacks**. This PR updates the loc...
diff --git a/pkg/detectors/http.go b/pkg/detectors/http.go index 43ad5052ce2a..28f121e32972 100644 --- a/pkg/detectors/http.go +++ b/pkg/detectors/http.go @@ -94,7 +94,7 @@ func NewDetectorTransport(T http.RoundTripper) http.RoundTripper { } func isLocalIP(ip net.IP) bool { - if ip.IsLoopback() || ip.IsLinkLocalUni...
1
1
0
[{"id": "G0", "claim": "Add a check for the IPv6 wildcard address \"::\" too, asking whether it is as easy as specifying `tcp6` to `DialContext` in the test.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
trufflesecurity__trufflehog__4744
trufflesecurity/trufflehog
4,744
defect
6961f2bace57ab32b23b3ba40f8f420f6bc7e004
bdc52c48a5b26f03f35ea2693d4a939dfdb2d2a4
Base64 decoding depth assessment
### Description: This PR introduces an iterative decoding pipeline, allowing decoders (e.g., Base64, UTF-16) to chain their outputs. Previously, decoders ran independently on the original chunk, missing secrets hidden behind layered encoding (e.g., base64 within UTF-16, or double-base64-encoded values). The `scannerWo...
diff --git a/main.go b/main.go index abf477a57d8e..888cba15a4d4 100644 --- a/main.go +++ b/main.go @@ -65,6 +65,7 @@ var ( filterUnverified = cli.Flag("filter-unverified", "Only output first unverified result per chunk per detector if there are more than one results.").Bool() filterEntropy = ...
8
5
0
[{"id": "G0", "claim": "Skipping the PLAIN decoder at depth > 0 means chained decoder output misses the extractSubstrings normalization step, so some secrets in nested encodings are never matched.", "category": "correctness", "verdict": "opposed", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The ite...
null
trufflesecurity__trufflehog__4797
trufflesecurity/trufflehog
4,797
defect
ef63d66d58bb7317d9b220b02af5beae569835ee
b908401abfe08f91298acd098dac9da21eb8d031
Stop growing filesystem resume data
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: #4742 (4563dde124c011b7ab615dbe531b45f3a6193b96) introduced a change to the filesystem s...
diff --git a/pkg/sources/filesystem/filesystem.go b/pkg/sources/filesystem/filesystem.go index e93ac6154621..6b991b7123f1 100644 --- a/pkg/sources/filesystem/filesystem.go +++ b/pkg/sources/filesystem/filesystem.go @@ -5,6 +5,7 @@ import ( "io" "os" "path/filepath" + "strings" "github.com/go-errors/errors" ...
4
1
1
[{"id": "G0", "claim": "Removing the per-directory resume logic means that with concurrency > 1 the encodedResumeInfo can be updated by a file that finishes before earlier-traversed files complete, so if a crash occurs mid-scan those earlier still-scanned files will be skipped on resume.", "category": "correctness", "v...
null
trufflesecurity__trufflehog__4807
trufflesecurity/trufflehog
4,807
defect
6c05c4a00b91aa542267d8e32a8254774799d68d
53ad3dd9b822a01c62036489a151fbf50e3ceb2f
Confine symlink state handling to scanSymlink in Filesystem source
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Description: Tracking depth was scattered throughout the Filesystem source. This PR confines it to `s...
diff --git a/pkg/sources/filesystem/filesystem.go b/pkg/sources/filesystem/filesystem.go index e54ccc22070a5..cf715d6e50675 100644 --- a/pkg/sources/filesystem/filesystem.go +++ b/pkg/sources/filesystem/filesystem.go @@ -14,7 +14,7 @@ import ( "google.golang.org/protobuf/types/known/anypb" "github.com/trufflesecu...
2
1
1
[{"id": "G0", "claim": "In Chunks the root-symlink branch still passes initialDepth := 1 while scanSymlink now increments depth internally, so the effective starting depth is 2 instead of 1 (ChunkUnit was correctly updated to 0), causing premature \"max symlink depth reached\" errors, especially breaking when maxSymlin...
null
trufflesecurity__trufflehog__4825
trufflesecurity/trufflehog
4,825
defect
afd5336caad0f61da51750ffe39869974b27b0db
fc7a9df7ad9bdf9b55e7595843dd65ccf1113f33
[INS-403] Support Custom endpoint config in hashicorpvaultauth Detector
### Description: This PR enabled **custom endpoint configuration** for the existing **hashicorpvaultauth** detector. It enables custom endpoint configuration by making the detector comply to `detectors.EndpointCustomizer` interface and updating to default client to `detectors.DetectorHttpClientWithNoLocalAddresses`...
diff --git a/pkg/detectors/hashicorpvaultauth/hashicorpvaultauth.go b/pkg/detectors/hashicorpvaultauth/hashicorpvaultauth.go index 87fed3374d01..777c1fdc7468 100644 --- a/pkg/detectors/hashicorpvaultauth/hashicorpvaultauth.go +++ b/pkg/detectors/hashicorpvaultauth/hashicorpvaultauth.go @@ -11,20 +11,22 @@ import ( ...
3
2
1
[{"id": "G0", "claim": "The per-result URL-check loop in TestHashiCorpVaultAuth_WithCustomEndpoint is redundant and of questionable value, because the trailing cmp.Diff already asserts the same URLs.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The ch...
null
trufflesecurity__trufflehog__4840
trufflesecurity/trufflehog
4,840
defect
586f66d7886cd0b037c7c245d4a6e34ef357ab10
2e42a112205a5f2ae3fd7f2163f06ae2cfd9a19e
Add HTML decoder for secret detection in HTML-formatted sources
## Summary - Adds a new `HTML` decoder to the decoder pipeline that extracts clean text from HTML content, enabling secret detection in sources like MS Teams and Confluence that emit HTML rather than plain text. - Parses HTML to extract text nodes, high-signal attribute values (`href`, `src`, `value`, `xlink:href`,...
diff --git a/pkg/decoders/decoders.go b/pkg/decoders/decoders.go index c49eee403ff2..3cac3c36c833 100644 --- a/pkg/decoders/decoders.go +++ b/pkg/decoders/decoders.go @@ -12,6 +12,7 @@ func DefaultDecoders() []Decoder { &Base64{}, &UTF16{}, &EscapedUnicode{}, + &HTML{}, } } diff --git a/pkg/decoders/html...
7
7
4
[{"id": "G0", "claim": "url.QueryUnescape converts '+' to a space, which can corrupt secrets in all high-signal attribute values; use url.PathUnescape instead so %XX sequences decode while '+' stays literal.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "cla...
null
trufflesecurity__trufflehog__4864
trufflesecurity/trufflehog
4,864
defect
bff3d2670b362bbb4a0bcdeffea146cbc2ad3abd
c63f58d9c00cf347f12ead6fea95967c9bb5184e
Fix nil pointer panics in GitHub analyzer gist/repo binding functions
## Problem A panic was caught in the GitHub analyzer worker: ``` runtime error: invalid memory address or nil pointer dereference github.com/trufflesecurity/trufflehog/v3/pkg/analyzer/analyzers/github.secretInfoToGistBindings pkg/analyzer/analyzers/github/github.go:129 ``` The GitHub API returns `descrip...
diff --git a/pkg/analyzer/analyzers/github/github.go b/pkg/analyzer/analyzers/github/github.go index e84d958fd76c..63ab8b9f3523 100644 --- a/pkg/analyzer/analyzers/github/github.go +++ b/pkg/analyzer/analyzers/github/github.go @@ -83,11 +83,11 @@ func secretInfoToUserBindings(info *common.SecretInfo) []analyzers.Bindin...
2
2
1
[{"id": "G0", "claim": "secretInfoToRepoBindings passes repo.Owner to userToResource without the nil-owner guard the PR adds for gists, so after this PR a nil repo.Owner silently produces a corrupt parent resource with empty Name/Type and FullyQualifiedName \"github.com/\".", "category": "correctness", "verdict": "supp...
null
trufflesecurity__trufflehog__4872
trufflesecurity/trufflehog
4,872
defect
bff3d2670b362bbb4a0bcdeffea146cbc2ad3abd
195f1a9c4d4c71472618dc66f2466e0401678824
[INS-402] Add Jira Data Center PAT Detector
<!-- Please create an issue to collect feedback prior to feature additions. Please also reference that issue in any PRs. If possible try to keep PRs scoped to one feature, and add tests for new features. --> ### Summary Adds a new detector for [Jira Data Center Personal Access Tokens (PATs)](https://confluence.a...
diff --git a/pkg/detectors/jiradatacenterpat/jiradatacenterpat.go b/pkg/detectors/jiradatacenterpat/jiradatacenterpat.go new file mode 100644 index 000000000000..450f13d8eede --- /dev/null +++ b/pkg/detectors/jiradatacenterpat/jiradatacenterpat.go @@ -0,0 +1,147 @@ +package jiradatacenterpat + +import ( + "context" + "...
9
8
4
[{"id": "G0", "claim": "The patPat regex uses \\b word boundaries around a class containing + and /, so valid base64 PATs beginning or ending with + or / are silently missed.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "On an HTTP 200 response who...
null
trufflesecurity__trufflehog__4883
trufflesecurity/trufflehog
4,883
defect
88c7519a4728f4d8daddc01da8a1406d354f0dfe
1a0626e6c6aaececba36363f0d9b0994835d76d5
[INS-399] Added Bitbucket data center(on prem) PAT detector
### Description This PR adds the **Bitbucket Data Center Personal Access Token (PAT) Detector** for TruffleHog. It scans for Bitbucket Data Center (on-prem) personal access tokens (prefix `BBDC-`) and optionally verifies them against the On-prem Bitbucket REST API. **Regex**: `\b(BBDC-[A-Za-z0-9+/@_-]{40,50}...
diff --git a/pkg/detectors/bitbucketdatacenter/bitbucketdatacenter.go b/pkg/detectors/bitbucketdatacenter/bitbucketdatacenter.go new file mode 100644 index 000000000000..a307429fbb95 --- /dev/null +++ b/pkg/detectors/bitbucketdatacenter/bitbucketdatacenter.go @@ -0,0 +1,140 @@ +package bitbucketdatacenter + +import ( +...
5
4
2
[{"id": "G0", "claim": "The trailing `\\b` in the userPat regex fails to match when a BBDC token ends with one of the non-word characters the class allows (+, /, @, -), so such valid tokens would be silently missed.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G...
null
trufnetwork__kwil-db__1369
trufnetwork/kwil-db
1,369
defect
660a744981c9eda51135fce5384c3b1297f4dc92
8fe3986abefb6bec49779f6470d219859d8ab0ce
kwild: re-add extension config flags
It seems like we forgot to re-add the ability to [configure extensions from the command line](<https://prerelease.kwil.com/docs/daemon/config/settings#configuration-source-priority>). This re-adds that
diff --git a/app/node/start.go b/app/node/start.go index 5a25a61c4..46cdbf6cd 100644 --- a/app/node/start.go +++ b/app/node/start.go @@ -2,6 +2,7 @@ package node import ( "fmt" + "strings" "github.com/spf13/cobra" @@ -27,7 +28,6 @@ func StartCmd() *cobra.Command { CompletionOptions: cobra.CompletionOption...
1
1
1
[{"id": "G0", "claim": "The newly added parseExtensionFlags function is never called, so it needs to be called in the StartCmd RunE.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
trufnetwork__kwil-db__1370
trufnetwork/kwil-db
1,370
defect
9c0f4393e203e06d2e268eab53a1ae657cfa312b
6da8b51a03e153b8dbdeb97381cc38825439ff6d
erc20: extension info syncing pt 2
This PR standardizes rewards to always use uint256 values (rather than the scaled down values). It also optionally gives the ability to scale down / up based on a synced reward instances decimals. This PR also reworks some of the evmsync logic to allow for us to sync many different logs from the same connection. It ...
diff --git a/core/types/decimal.go b/core/types/decimal.go index 62381b101..787193c74 100644 --- a/core/types/decimal.go +++ b/core/types/decimal.go @@ -204,6 +204,60 @@ func (d *Decimal) String() string { return d.dec.String() } +// FullString returns the full string representation of the decimal. +// It will nev...
2
2
1
[{"id": "G0", "claim": "The precompile parameters that take a user-supplied amount should use the raw uint256 (bigint) numeric type instead of text, as previously discussed.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "pre_existing"}, {"id": "G1", "claim": "The public handlers that accept...
null
trufnetwork__kwil-db__1435
trufnetwork/kwil-db
1,435
defect
e5f20ebe76103e4f60cec5db8545c651bc0bd655
5d08ee60e87f8e3bc3de5c00dfd2cbcbab08c282
order transactions announcements in the order they are received
This PR ensures the FIFO consistency to the outgoing transaction announcements to maintain the nonce ordering. So all the transaction announcements are routed through a TxQueue to enforce this order.
diff --git a/node/node.go b/node/node.go index e25c327135..449ffc65f2 100644 --- a/node/node.go +++ b/node/node.go @@ -144,10 +144,20 @@ type Node struct { blkPropHandling chan struct{} + txQueue chan orderedTxn // enforces ordering in the tx broadcasts to the network. + wg sync.WaitGroup log log.Logger } ...
4
3
2
[{"id": "G0", "claim": "startOrderedTxQueueAnns should pass the caller's ctx (the system-level context from Start) to announceRawTx instead of context.Background().", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "If the channel buffer fills, the bloc...
null
trufnetwork__kwil-db__1439
trufnetwork/kwil-db
1,439
defect
73e7cc21b3ce2a1b87dda40d76b92aae5bb9407c
89dc1ee20e7996bf8e252f100697b368c7d99d8e
Notices
This PR adds `NOTICE` calls to the transaction execution / call result. It also separates execution errors (which are created by calling `ERROR()` or by things like primary key conflicts) from internal errors (like the DB being OOM). When calling a view action, it returns this as a separate field. When executing an ...
diff --git a/app/shared/display/message.go b/app/shared/display/message.go index 92eaaba33..2aca624aa 100644 --- a/app/shared/display/message.go +++ b/app/shared/display/message.go @@ -4,6 +4,7 @@ import ( "encoding/hex" "encoding/json" "fmt" + "strings" "github.com/kwilteam/kwil-db/core/types" ) @@ -33,15 +...
2
2
2
[{"id": "G0", "claim": "Treating any error whose message contains \"SQLSTATE\" as a user-logic error is wrong because serious postgres errors such as database failures and corruption also carry SQLSTATE, so those would be misclassified; the reviewer suggests checking error codes, e.g. via node/types/sql.IsFatalDBError....
null
trufnetwork__kwil-db__1500
trufnetwork/kwil-db
1,500
defect
410dd2b6bb1f8acd688b68c5e9b4e4ab4df2ff56
f7ac6d7fb7d22f2137e30628cba9d01897ea3a5d
data race accessing ce.leader
This PR fixes a data race issue in the consensus engine that occurs when accessing the `ce.leader` field. The issue arises when block proposal handling and role updates happen concurrently. Specifically, `ce.leader` is incorrectly accessed in `NotifyBlockProposal` to set the block proposal's sender as the current leade...
diff --git a/node/consensus.go b/node/consensus.go index a0d977561..1422522f0 100644 --- a/node/consensus.go +++ b/node/consensus.go @@ -30,11 +30,12 @@ type ( ) type blockProp struct { - Height int64 - Hash types.Hash - PrevHash types.Hash - Stamp int64 - LeaderSig []byte + Height int64 + Hash ...
2
1
0
[{"id": "G0", "claim": "The PR description and/or commit message should be updated to state the data-race scenario, which CE design patterns led to it, whether it was a problem in production or just a test where the notify function was called manually, and whether the message structure change affects the wire (p2p) pro...
null
trufnetwork__kwil-db__1536
trufnetwork/kwil-db
1,536
defect
ef41ebdf59123a7900e48da5cebb68992566eb79
4efae4fb4cdbbf908c2c6d65ef19c9ecf7245d0b
feat: support extension loading during Kwil Testing
<!--- Provide a general summary of your changes in the Title above --> ## Description <!--- Describe your changes in detail --> ## Related Issue <!--- If this pull requests links to an issue, please link to it here: --> resolves: https://github.com/trufnetwork/kwil-db/issues/1535 ## Motivation and Context...
diff --git a/extensions/encoding/borsh/go.mod b/extensions/encoding/borsh/go.mod index 106d34b7c..1943ae01a 100644 --- a/extensions/encoding/borsh/go.mod +++ b/extensions/encoding/borsh/go.mod @@ -7,13 +7,13 @@ replace github.com/trufnetwork/kwil-db/core => ../../../core replace github.com/trufnetwork/kwil-db => ../.....
2
1
1
[{"id": "G0", "claim": "Instead of copying extension-loading logic selectively into the testing package, the PR should export what needs to be tested from node/engine/interpreter (including the storedExtension type under the name ExtensionConfig, reading better than a private alias) and also export unregisterExtensionI...
null
trufnetwork__kwil-db__1555
trufnetwork/kwil-db
1,555
defect
cc585a3c9151591215c47c6ba923f38630eb1f65
12fcb7a5f9161141c84c26796b72e0efbd65045b
fix: prevent permanent announcement of bad transactions
Orphaned nodes that fall behind the main chain would previously accept transactions against stale blockchain state and continuously reannounce them every 30 seconds indefinitely. This occurred because: 1. During block sync, orphaned nodes receive ErrBlkNotFound from peers 2. They incorrectly assume sync is comple...
diff --git a/node/consensus/blocksync.go b/node/consensus/blocksync.go index 175601c57..1b12e5880 100644 --- a/node/consensus/blocksync.go +++ b/node/consensus/blocksync.go @@ -121,6 +121,10 @@ SYNC: } if errors.Is(err, types.ErrBlkNotFound) || errors.Is(err, types.ErrNotFound) { + // Recheck all mempool t...
2
1
0
[{"id": "G0", "claim": "Remove the duplicate initialization of ce.state.lc in TestReplayBlockFromNetwork_CallsRecheckTxsOnErrBlkNotFound, which is set identically on lines 56-64 and 67-75.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The fix m...
null
trufnetwork__kwil-db__1574
trufnetwork/kwil-db
1,574
defect
9c64977f370c252ed3ee36729e9eb7608909c39f
35c1c27edfb4542c548d18954f40239b270bfa50
chore: auto-blacklist peers that exhaust connection retries
Automatically blacklist peers that exhaust connection attempts to prevent infinite retry cycles and resource waste from PEX rediscovery. - Add auto-blacklist logic to maintainMinPeers() retry exhaustion handler - Permanently blacklist peers with reason "connection_exhaustion" when maxedOut() - Only activate when b...
diff --git a/node/peers/blacklist_test.go b/node/peers/blacklist_test.go index 3b925ca8e..df6704e83 100644 --- a/node/peers/blacklist_test.go +++ b/node/peers/blacklist_test.go @@ -317,3 +317,142 @@ func TestBlacklistExpiredEntryHandling(t *testing.T) { require.Len(t, entries, 0) } } + +func TestAutoBlacklistOnMa...
12
4
3
[{"id": "G0", "claim": "In the AutoBlacklistEnabled subtest, explicitly allow the test peer and assert IsAllowed before blacklisting, because as written IsAllowed may already be false (e.g. empty whitelist) so the final assertion could pass without exercising blacklist-aware gating.", "category": "testing", "verdict": ...
null
trufnetwork__kwil-db__1575
trufnetwork/kwil-db
1,575
defect
7478d3a955abd445bcceabeeef205166a054d5f4
8d95e8e9c09fb3840356dcd56fe184dbd071863d
feat: view structured logging and metrics for blacklist operation
Implement comprehensive observability for blacklist operations through structured logging and OpenTelemetry metrics integration. - Add structured JSON logging for all blacklist operations (add, remove, auto-blacklist) - Implement 4 new OpenTelemetry metrics: operations counter, peer count gauge, auto-blacklist even...
diff --git a/app/blacklist/TESTING.md b/app/blacklist/TESTING.md index 7c610f4e8..49f11338d 100644 --- a/app/blacklist/TESTING.md +++ b/app/blacklist/TESTING.md @@ -161,6 +161,178 @@ enable = true ./kwild admin peers -s 127.0.0.1:8585 # Should show node1 again ``` +### 5. Observability and Metrics Testing + +**Obj...
4
1
1
[{"id": "G0", "claim": "The unlock/re-acquire pattern added around logging and metrics in RemoveFromBlacklist conflicts with the deferred Unlock, apparently unlocking the mutex twice and opening a window where the blacklist state could change between the delete and the re-acquisition; apply the suggested fix to correct...
null
trufnetwork__kwil-db__1580
trufnetwork/kwil-db
1,580
defect
411502a7ae9685f3fa6864ecc09375e76681c5b7
b61e3dc7b1747ef701325fa3803e909661a60b77
fix: nodes in blacklist-only mode can now connect to peers
resolves: https://github.com/trufnetwork/kwil-db/issues/1579 @outerlook can you check if this resolves the issue now? <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * Bug Fixes * Blacklist-only mode permits unknown peers while blocking blacklisted ones. * Pr...
diff --git a/node/peers/blacklist_only_mode_regression_test.go b/node/peers/blacklist_only_mode_regression_test.go new file mode 100644 index 000000000..e919f82b0 --- /dev/null +++ b/node/peers/blacklist_only_mode_regression_test.go @@ -0,0 +1,205 @@ +package peers + +import ( + "path/filepath" + "testing" + "time" + +...
5
1
1
[{"id": "G0", "claim": "Add a regression test covering private-mode dynamic whitelist updates from PeerMan (calling pm.AllowPersistent on a new peer) propagating to the shared Host gater's decisions, as called out in the linked issue.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduc...
null
trufnetwork__kwil-db__1582
trufnetwork/kwil-db
1,582
defect
885634ef77ebb4b2041bfb3fade6eb0dd987531f
c850ae0f47745ae5e45977b93416dcb1b688e417
feat: support INT4 data type for enhanced storage efficiency
Add support for INT4 (32-bit integer) data type to provide storage optimization and PostgreSQL compatibility while maintaining backward compatibility. Features Added: - New INT4 and INT4[] data types for schema definitions - Support for 'int4' and 'smallint' type aliases in DDL - Efficient 4-byte serialization fo...
diff --git a/core/types/data_types.go b/core/types/data_types.go index 228ded96e..49f7ad833 100644 --- a/core/types/data_types.go +++ b/core/types/data_types.go @@ -136,6 +136,8 @@ func (c *DataType) PGScalar() (string, error) { switch strings.ToLower(c.Name) { case intStr: scalar = "INT8" + case int4Str: + sca...
23
19
3
[{"id": "G0", "claim": "Duplicate OID registration: intType.ExtraOIDs includes Int4OID while the new int4Type's primary OID is also Int4OID, which makes OidTypesMap panic on duplicate OIDs (flaky, since map iteration order is non-deterministic).", "category": "correctness", "verdict": "supported", "priority": "P0", "sc...
null
trufnetwork__kwil-db__1585
trufnetwork/kwil-db
1,585
defect
30b5d2ee1bcd823eb73326a86c27959ddc9c0b45
7334bea1e296b08f78cacb57ea36765e8c4da53d
feat: use @leader contextual variable
feat: use @leader contextual variable Implements @leader contextual variable for secure leader-only authorization. Uses BlockContext.Proposer for deterministic leader identification, ensuring consistency with other contextual variable like @height. Technical Implementation: - Add @leader case to contextual varia...
diff --git a/common/common.go b/common/common.go index 69cba1f6a..9b75ee01f 100644 --- a/common/common.go +++ b/common/common.go @@ -224,4 +224,7 @@ type Validators interface { // longer be considered a validator. It will return an error if a // negative power is given. SetValidatorPower(ctx context.Context, tx s...
14
7
3
[{"id": "G0", "claim": "The \"Contextual Variables\" section appears to be duplicated in core/client/README.md and the redundant copy should be removed.", "category": "documentation", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Consensus tests assert raw hex while interpreter ...
null
trufnetwork__kwil-db__1596
trufnetwork/kwil-db
1,596
defect
799cf48f758e5e20616a55e665e0f988f635b6c1
9aff69a01973da9e2e80fe4e024864c21e1f6eb7
chore: implement comparable leader variable
## Description <!--- Describe your changes in detail --> - implement `leader_sender` to make it easily comparable to `signer` ctx variable - add more ways to define the testnet private key schemas ## Related Issue <!--- If this pull requests links to an issue, please link to it here: --> - fix #1595 ...
diff --git a/app/setup/testnet.go b/app/setup/testnet.go index be5cc105d..995ee9684 100644 --- a/app/setup/testnet.go +++ b/app/setup/testnet.go @@ -243,7 +243,7 @@ type NodeGenConfig struct { DBPort uint16 // leave zero for default plus any offset IP string NoPEX bool - NodeKey *crypto.Secp25...
10
2
0
[{"id": "G0", "claim": "Guard against a nil opts.PrivateKey in newClient before the signer type switch, failing fast with an error instead of leaving the signer unset for custom callers that skip ensureDefaults.", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", ...
null
trufnetwork__kwil-db__1614
trufnetwork/kwil-db
1,614
defect
140c3688cbd6a76de33b674e9f8ae0707976a50e
ce4036a6426fcc2d398402a88ba4e257c1101184
chore: improve snapshotter & fix protocol
<!--- Provide a general summary of your changes in the Title above --> ## Description <!--- Describe your changes in detail --> This PR introduces several enhancements to the snapshot handling process, focusing on improving type safety and streamlining functionality. Key changes include: - Replaced hardco...
diff --git a/node/block_processor/processor.go b/node/block_processor/processor.go index 90e5108cd..bc0ebe4b1 100644 --- a/node/block_processor/processor.go +++ b/node/block_processor/processor.go @@ -745,8 +745,7 @@ var ( ) func (bp *BlockProcessor) snapshotDB(ctx context.Context, height int64) error { - snapshots...
5
2
1
[{"id": "G0", "claim": "The chunk-writing loop treats any non-io.EOF error from io.CopyN as fatal, so if io.ErrUnexpectedEOF is returned for the final partial chunk every snapshot whose size is not an exact multiple of chunkSize would fail; treat io.ErrUnexpectedEOF as the normal tail condition and keep the partial chu...
null
trufnetwork__kwil-db__1619
trufnetwork/kwil-db
1,619
defect
372c7bcfcb2cd6ed268b74b517e4acc20febf8f6
4cfaf632251cbd5c308d3973b5b9c0bf7efbcc8a
feat: view catch-up indicator to block context
Extensions can now determine if the node is synchronizing with the network by checking the InCatchup field in BlockContext. This enables extensions to defer resource-intensive operations during initial sync or snapshot restoration, preventing system overload and improving node stability. The block processor now popu...
diff --git a/common/context.go b/common/context.go index 6bbdeab39..4c2769cda 100644 --- a/common/context.go +++ b/common/context.go @@ -44,6 +44,11 @@ type BlockContext struct { Timestamp int64 // Proposer gets the proposer public key of the current block. Proposer crypto.PublicKey + // InCatchup indicates wheth...
1
1
1
[{"id": "G0", "claim": "The reviewer is not convinced InCatchup belongs in BlockContext, since BlockContext should hold immutable data inherent to a block (proposer, timestamp, height) rather than node state that changes independently of a block, and suggests something like a Service-level NodeStatusProvider instead.",...
null
trufnetwork__kwil-db__1632
trufnetwork/kwil-db
1,632
defect
71b1f5fb51e35e4f37bf00a32334932592c99015
dc774fcf6442988ad818408003752a012db6f138
chore: resilient startup process with commit intent
<!--- Provide a general summary of your changes in the Title above --> ## Description <!--- Describe your changes in detail --> This PR introduces a new commit intent logging system to enhance the consensus engine's ability to handle block commits. Key changes include: - Added `commitIntentFileName` to st...
diff --git a/config/folders.go b/config/folders.go index 1796ce7b3..f1ea60b3a 100644 --- a/config/folders.go +++ b/config/folders.go @@ -24,6 +24,7 @@ const ( genesisFileName = "genesis.json" leaderUpdatesFileName = "leader-updates.json" + commitIntentFileName = "commit-intent.json" ) // BlockstoreDir r...
5
4
2
[{"id": "G0", "claim": "If the process crashes after commit() returns but before the kernel flushes the Badger writes, the commit intent will already have been cleared, leaving PG ahead of the blockstore with no metadata to repair; BlockStore.Sync() should be invoked (and its error handled) right after persisting the b...
null
trufnetwork__kwil-db__1640
trufnetwork/kwil-db
1,640
defect
6166b34b04132608af800dee96e5e13657e16263
76dd88c72b26f965276748e8e3672671ff71ad88
feat: support batch processing in database actions
Users can now call actions and execute database operations inside FOR loops, enabling batch processing workflows. Previously, nested queries failed with "query already active" errors. - **Row buffering**: Query results fully buffered before iteration, freeing connection for nested operations - **Savepoints**: Postg...
diff --git a/node/engine/interpreter/context.go b/node/engine/interpreter/context.go index 8a39300c5..80715e02d 100644 --- a/node/engine/interpreter/context.go +++ b/node/engine/interpreter/context.go @@ -80,6 +80,16 @@ type executionContext struct { // This is used to prevent nested queries, which can cause // a d...
7
4
0
[{"id": "G0", "claim": "The struct fields `bufferedRows` and `bufferIndex` on `executionContext` are declared but never used, so remove them or refactor to use them.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Errors from ROLLBACK TO SAVEPOIN...
null
trufnetwork__kwil-db__1645
trufnetwork/kwil-db
1,645
defect
876ea64f573e808d2a07b72c480891530da41ff7
a4ef5a49b2a6dc19e40d9e6147139fa229ead284
feat: enable withdrawal proof retrieval via API
resolves: https://github.com/truflation/website/issues/3038 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added a withdrawal-proof retrieval endpoint that returns recipient, amount, status, Merkle proof/root, validator signatures, contract a...
diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index ef596de0f..67b97f270 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -107,6 +107,21 @@ jobs: run: | task test:unit + # withdrawal proof tests (require individual runs with cleanup) + - name...
15
7
5
[{"id": "G0", "claim": "The recipient validation only checks length and prefix and does not verify hexadecimal characters, so invalid addresses like 0xZZZZ... could pass validation; use go-ethereum's IsHexAddress instead.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"i...
null
trufnetwork__kwil-db__1646
trufnetwork/kwil-db
1,646
defect
67938a045c675bcf92727c56a6eb8dae27a69e4b
ab045f67fc1fd5e2736928798a41093203b54367
chore: add withdrawals table for status tracking
resolves: https://github.com/truflation/website/issues/3040 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added multi-chain withdrawal tracking for cross-network withdrawals. * **Database** * Introduced a withdrawals table with status tra...
diff --git a/node/exts/erc20-bridge/erc20/meta_schema.sql b/node/exts/erc20-bridge/erc20/meta_schema.sql index 728d84b22..1218b5aeb 100644 --- a/node/exts/erc20-bridge/erc20/meta_schema.sql +++ b/node/exts/erc20-bridge/erc20/meta_schema.sql @@ -81,4 +81,23 @@ CREATE TABLE epoch_votes ( nonce INT8 NOT NULL, -- safe...
5
1
0
[{"id": "G0", "claim": "The withdrawals table tracks updated_at and claimed_at but lacks a created_at timestamp recording when the withdrawal entry was initially inserted, which makes it hard to audit when a withdrawal was first registered; add the column as suggested.", "category": "design", "verdict": "supported", "p...
null
trufnetwork__kwil-db__1647
trufnetwork/kwil-db
1,647
defect
b345e6048180e4e304e3a367e552ae1f41327f5d
897ea1f45fb5623c263bff332f97eb49909ab9d1
feat: track withdrawal claim status
resolves: https://github.com/truflation/website/issues/3040 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Public withdrawal-proof RPC added including withdrawal status and optional Ethereum tx hash, plus estimated ready time and related fiel...
diff --git a/node/services/jsonrpc/usersvc/README.md b/node/services/jsonrpc/usersvc/README.md index 04ac04bca..2b131ca39 100644 --- a/node/services/jsonrpc/usersvc/README.md +++ b/node/services/jsonrpc/usersvc/README.md @@ -48,7 +48,8 @@ Run each test individually with manual cleanup: ```bash # Cleanup command (run ...
3
2
0
[{"id": "G0", "claim": "The GetWithdrawalProof error branch treats every query execution error as \"no withdrawal tracking record found\" (logged at debug), conflating the expected no-rows/table-missing case with real execution failures such as connection or syntax errors, so real errors are silently defaulted and misr...
null
trufnetwork__kwil-db__1651
trufnetwork/kwil-db
1,651
defect
774007f672eee77d3823e9a7015b0890fd42a14a
ce11b9c1fb4e1deb69e28c9247cbcc253593857d
chore: enable the withdrawal status tracking and testing
resolves: https://github.com/truflation/website/issues/3040 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Withdrawal listener now handles withdrawal logs uniformly across contract versions (removed conditional gating). * **Tests** *...
diff --git a/node/exts/erc20-bridge/erc20/meta_extension.go b/node/exts/erc20-bridge/erc20/meta_extension.go index 7bd66946d..508c9e444 100644 --- a/node/exts/erc20-bridge/erc20/meta_extension.go +++ b/node/exts/erc20-bridge/erc20/meta_extension.go @@ -72,7 +72,7 @@ var ( // so that we know how to decode them logTy...
2
1
0
[{"id": "G0", "claim": "The commit message says the PR enables withdrawal status tracking, but isOldContract() always returns true so the withdrawal listener never starts in production; the commit message or PR description should clarify this is infrastructure preparation rather than enablement, and the TODO comment sh...
null
trufnetwork__kwil-db__1657
trufnetwork/kwil-db
1,657
defect
7c814473863b54c8e49ac397491d650dc33b27ee
9e2c67eb619bb1e926296f51c902aa1bcb083244
chore: sign withdrawal transaction as validator
resolves: https://github.com/truflation/website/issues/3039 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Tests** * Added a comprehensive end-to-end test for the full withdrawal-proof flow and ensured cleanup added to related withdrawal-proof unit tests. * ...
diff --git a/node/services/jsonrpc/usersvc/service_withdrawal_e2e_test.go b/node/services/jsonrpc/usersvc/service_withdrawal_e2e_test.go new file mode 100644 index 000000000..f2e371a9b --- /dev/null +++ b/node/services/jsonrpc/usersvc/service_withdrawal_e2e_test.go @@ -0,0 +1,299 @@ +//go:build kwiltest + +package user...
4
1
0
[{"id": "G0", "claim": "The e2e test ignores the success bool returned by big.Int.SetString; it should assert parsing succeeded even though the hardcoded string is valid.", "category": "testing", "verdict": "uncertain", "priority": "P3", "scope": "introduced"}, {"id": "G3", "claim": "A warning should be logged when Gen...
null
trufnetwork__kwil-db__1658
trufnetwork/kwil-db
1,658
defect
0b7ce2b524b5fe3a2ce42a8a772aac9459dc1205
954e6da667976fdccf82e37d9ec730b2767ffdda
chore: use same signature for signing bridge
resolves: https://github.com/truflation/website/issues/3039 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Shared service now exposes a pluggable validator signer for standardized signing and Ethereum-compatible address derivation. * **Impro...
diff --git a/app/node/build.go b/app/node/build.go index 4960ef3c4..94752400d 100644 --- a/app/node/build.go +++ b/app/node/build.go @@ -450,6 +450,7 @@ func (c *coreDependencies) service(loggerName string, dbPool sql.DelayedReadTxMa GenesisConfig: c.genesisCfg, LocalConfig: c.cfg, Identity: signer.Comp...
3
1
1
[{"id": "G0", "claim": "Exposing the validator private key through Service.PrivateKey (and initializing it in build.go) makes the raw signing key accessible to every extension without access control, which is a critical security risk; a restricted signing interface should be provided instead.", "category": "security", ...
null
trufnetwork__kwil-db__1660
trufnetwork/kwil-db
1,660
defect
20a562fc2641a4cc2d0b2dee6fa0b78c4593d014
517b8e60b0a8f2cf703af5ec002247f2cb858bc7
chore: enable vote on non-custodial
resolves: https://github.com/truflation/website/issues/3039 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Auto-detection of custodial vs non-custodial bridges and escrow-based Safe initialization; validator key auto-detection (JSON or raw ke...
diff --git a/node/exts/erc20-bridge/signersvc/eth.go b/node/exts/erc20-bridge/signersvc/eth.go index e3c6f4dd0..c47dafcef 100644 --- a/node/exts/erc20-bridge/signersvc/eth.go +++ b/node/exts/erc20-bridge/signersvc/eth.go @@ -37,27 +37,36 @@ type Safe struct { eth *ethclient.Client } +// NewSafeFromEscrow attem...
10
9
0
[{"id": "G0", "claim": "The comment in the non-custodial signing branch misleadingly suggests the message is keccak256-hashed before the Ethereum signed-message prefix is applied, when the code signs the raw 64-byte concatenation that EthZeppelinSign prefixes and then hashes; the comment should clarify the order.", "ca...
null
trufnetwork__kwil-db__1661
trufnetwork/kwil-db
1,661
defect
b8af58932e24fc0e401ab14a9286ee7d1644ec15
b1fcfb33a848bd6e75d589450550c69ad507dfe7
feat: receive signature from pending withdrawal
resolves: https://github.com/truflation/website/issues/3039 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Wallet rewards and active epochs queries now include validator signatures in their returned results for each epoch. * **Tests** * Ad...
diff --git a/node/exts/erc20-bridge/erc20/list_wallet_rewards_test.go b/node/exts/erc20-bridge/erc20/list_wallet_rewards_test.go new file mode 100644 index 000000000..6cad32ed5 --- /dev/null +++ b/node/exts/erc20-bridge/erc20/list_wallet_rewards_test.go @@ -0,0 +1,680 @@ +//go:build kwiltest + +package erc20 + +import ...
4
1
1
[{"id": "G0", "claim": "The row callback in getEpochSignatures silently skips rows whose column count is not 1 (returns nil), which could mask data integrity issues; it should log a warning or return an error instead.", "category": "correctness", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": ...
null
trufnetwork__kwil-db__1663
trufnetwork/kwil-db
1,663
defect
0955c8d87ef64303aad5f29eda049d36bb2cf88d
b1fcbf4b790d961292b63840533a4aa77e710d9e
chore: prevent non-determinsm between validators and tests
resolves: https://github.com/trufnetwork/bridge-validator/issues/2 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Tests** * Added extensive ERC20 bridge determinism tests covering cross-node consistency, signature verification, reward aggregation, message-has...
diff --git a/node/exts/erc20-bridge/erc20/cross_node_determinism_test.go b/node/exts/erc20-bridge/erc20/cross_node_determinism_test.go new file mode 100644 index 000000000..8f2f81a8e --- /dev/null +++ b/node/exts/erc20-bridge/erc20/cross_node_determinism_test.go @@ -0,0 +1,589 @@ +//go:build kwiltest + +package erc20 +...
5
4
2
[{"id": "G0", "claim": "The tests compute an already-prefixed hash and pass it to signMessage(), which adds the Ethereum prefix again, so they sign a double-prefixed digest instead of keccak256(prefix + messageHash), making the signatures inconsistent with production behavior.", "category": "correctness", "verdict": "s...
null
trufnetwork__kwil-db__1664
trufnetwork/kwil-db
1,664
defect
a72f8a7d179684936eb8fc8faba88ab74adac011
2ee21420daf81448083c8db879cd0e67fdb55d7e
chore: confirm bridge finalization with beacon
resolves: https://github.com/trufnetwork/bridge-validator/issues/2 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added beacon chain finality checks to end-block processing to gate epoch finalization when configured. * Added chain configura...
diff --git a/node/exts/erc20-bridge/erc20/beacon_client.go b/node/exts/erc20-bridge/erc20/beacon_client.go new file mode 100644 index 000000000..3d1d0f234 --- /dev/null +++ b/node/exts/erc20-bridge/erc20/beacon_client.go @@ -0,0 +1,92 @@ +package erc20 + +import ( + "context" + "encoding/json" + "fmt" + "net/http" + "t...
7
6
2
[{"id": "G0", "claim": "The hardcoded mainnet genesis time and slot duration constants break Sepolia (and other non-mainnet) support, causing incorrect slot calculations and silent finality check failures; the BeaconChainClient needs network-aware genesis time/slot configuration.", "category": "correctness", "verdict":...
null
trufnetwork__kwil-db__1665
trufnetwork/kwil-db
1,665
defect
e97ebc066644cfef07f0bb1494e805b334a253e4
4f26c74d04c330cfbfad067a66b3c53b5a80d9c0
chore: allow different escrow contracts to be used within same chain
resolves: https://github.com/truflation/website/issues/3117 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Prevent duplicate deposit/withdrawal listeners per instance; ensure tracked entries are cleaned up on disable or startup errors and cleanu...
diff --git a/node/exts/erc20-bridge/erc20/duplicate_listener_test.go b/node/exts/erc20-bridge/erc20/duplicate_listener_test.go new file mode 100644 index 000000000..1d328921d --- /dev/null +++ b/node/exts/erc20-bridge/erc20/duplicate_listener_test.go @@ -0,0 +1,204 @@ +//go:build kwiltest + +package erc20 + +import ( +...
2
2
2
[{"id": "G0", "claim": "If startDepositListener() succeeds but startWithdrawalListener() fails, the function returns an error without stopping the already-started deposit listener or cleaning up its tracking entry, leaving the system in an inconsistent state; cleanup of the deposit listener should be added on withdrawa...
null
trufnetwork__kwil-db__1666
trufnetwork/kwil-db
1,666
defect
086d085466431d4a7e484c6975fd814b0feb3b04
86baa089d6e00d36750b1dfd9d8a84b63fcbbbb8
chore: unblock withdrawals and deposits flow
resolves: https://github.com/truflation/website/issues/3159 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Treat 404/empty beacon responses as non-fatal; fall back to epoch-based finality and gracefully degrade on API/network/parse errors so dep...
diff --git a/node/exts/erc20-bridge/erc20/beacon_client.go b/node/exts/erc20-bridge/erc20/beacon_client.go index bb3861ccb..b0ba5472a 100644 --- a/node/exts/erc20-bridge/erc20/beacon_client.go +++ b/node/exts/erc20-bridge/erc20/beacon_client.go @@ -70,6 +70,14 @@ func (b *BeaconChainClient) IsBlockFinalized(ctx context...
5
5
3
[{"id": "G0", "claim": "The added SECURITY comment states deposits are only credited after beacon finality, but the code below is a TODO, which can mislead audits/ops into assuming protection exists; the check should be implemented or the comment softened to match current behavior.", "category": "security", "verdict": ...
null
trufnetwork__kwil-db__1668
trufnetwork/kwil-db
1,668
defect
b5a45e78041c83ff6844ff24330344085ec0a9b7
c5c1b8890ad5dfac911f42a2162fa0a4747a6c85
feat: see deposits in the transaction history
resolves: https://github.com/truflation/website/issues/3305 resolves: https://github.com/truflation/website/issues/3306 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Deposits are now persisted to a transaction history with full block ...
diff --git a/node/exts/erc20-bridge/erc20/meta_extension.go b/node/exts/erc20-bridge/erc20/meta_extension.go index 4d802553d..0da3b661a 100644 --- a/node/exts/erc20-bridge/erc20/meta_extension.go +++ b/node/exts/erc20-bridge/erc20/meta_extension.go @@ -249,7 +249,7 @@ func init() { for _, log := range logs { i...
6
5
0
[{"id": "G0", "claim": "The deposit test's SELECT * with ordinal column indexing breaks silently if the table schema changes; use explicit column names in the SELECT to make the test resilient.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "TestTransact...
null
trufnetwork__kwil-db__1669
trufnetwork/kwil-db
1,669
defect
aa3bb3cb47f12a6b5c2f9a15087d6417e3ceb1e6
0668a0a0afd5af4695c3c41e0165fed12eee8a52
feat: track the lifecycle of their withdrawals
resolves: https://github.com/truflation/website/issues/3307 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * ERC20 bridge withdrawals now record detailed transaction history, include epoch association, and track status transitions from pending ...
diff --git a/.gitignore b/.gitignore index 68dd981ac..686e01020 100644 --- a/.gitignore +++ b/.gitignore @@ -59,4 +59,5 @@ go.work.sum # mergetool artifacts *.orig -CLAUDE.md \ No newline at end of file +CLAUDE.md +GEMINI.md \ No newline at end of file diff --git a/node/exts/erc20-bridge/erc20/meta_extension.go b/n...
9
6
2
[{"id": "G0", "claim": "In TestWithdrawalHistory the ok return of chains.GetChainInfoByID(\"1\") is silently discarded, so if chain \"1\" is not registered the test fails later with a confusing error instead of a clear assertion; it should check ok with require.True.", "category": "testing", "verdict": "supported", "pr...
null
trufnetwork__kwil-db__1670
trufnetwork/kwil-db
1,670
defect
72e171c68bab7330c862161c42faa6dc5d74f003
c0e4edbd8fdd3ba84646ab5a3b1be07402b025ac
feat: view peer-to-peer transfer
resolves: https://github.com/truflation/website/issues/3308 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Enhanced ERC20 bridge transfer history: records completed transfers with transaction hash, block height, timestamp, and accurate from/t...
diff --git a/.gitignore b/.gitignore index 686e01020..39bcd8193 100644 --- a/.gitignore +++ b/.gitignore @@ -60,4 +60,5 @@ go.work.sum *.orig CLAUDE.md -GEMINI.md \ No newline at end of file +GEMINI.md +uncommitted \ No newline at end of file diff --git a/node/exts/erc20-bridge/erc20/meta_extension.go b/node/exts/e...
5
4
1
[{"id": "G0", "claim": "The bare `uncommitted` ignore pattern is too generic and should be made more specific (file extension, trailing slash, or root prefix) to avoid unintentionally ignoring legitimate files.", "category": "maintainability", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1",...
null
trufnetwork__kwil-db__1671
trufnetwork/kwil-db
1,671
defect
7009f54a7c5ca76070496e64ce9b241bc14b5cef
0fe0e10084b2b4c8d902030174d97f767d419392
feat: view unified transaction history
resolves: https://github.com/truflation/website/issues/3309 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added a public, read-only transaction history query with pagination that returns entries including type, amount, from/to addresses, int...
diff --git a/node/exts/erc20-bridge/erc20/meta_extension.go b/node/exts/erc20-bridge/erc20/meta_extension.go index 9309dfe2c..71e03df60 100644 --- a/node/exts/erc20-bridge/erc20/meta_extension.go +++ b/node/exts/erc20-bridge/erc20/meta_extension.go @@ -1549,6 +1549,58 @@ func init() { return nil }, ...
3
3
2
[{"id": "G0", "claim": "Nullable DB columns (from_address, to_address, external_block_height) are mapped into value-typed HistoryRecord fields, so NULLs surface as zero-values (zero address / 0) even though the return schema declares them Nullable; use pointer types or return nil conditionally in the handler.", "catego...
null