{"$schema":"https://json.schemastore.org/sarif-2.1.0.json","version":"2.1.0","runs":[{"tool":{"driver":{"name":"codehealth","informationUri":"https://codehealth.canine.dev","rules":[{"id":"D1","name":"Cyclomatic Complexity","shortDescription":{"text":"Cyclomatic Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D1"},{"id":"D2","name":"Cognitive Complexity","shortDescription":{"text":"Cognitive Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D2"},{"id":"D3","name":"God Classes","shortDescription":{"text":"God Classes"},"helpUri":"https://codehealth.canine.dev/dimensions/D3"},{"id":"D4","name":"Code Duplication","shortDescription":{"text":"Code Duplication"},"helpUri":"https://codehealth.canine.dev/dimensions/D4"},{"id":"D13","name":"Secret Scanning","shortDescription":{"text":"Secret Scanning"},"helpUri":"https://codehealth.canine.dev/dimensions/D13","relationships":[{"target":{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-798","CWE-259"]}},{"id":"D15","name":"Churn \u00D7 Complexity Hotspots","shortDescription":{"text":"Churn \u00D7 Complexity Hotspots"},"helpUri":"https://codehealth.canine.dev/dimensions/D15"},{"id":"D21","name":"Naming Consistency","shortDescription":{"text":"Naming Consistency"},"helpUri":"https://codehealth.canine.dev/dimensions/D21"},{"id":"D28","name":"Secrets (history)","shortDescription":{"text":"Secrets (history)"},"helpUri":"https://codehealth.canine.dev/dimensions/D28","relationships":[{"target":{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-798","CWE-259"]}},{"id":"D29","name":"Static Analysis (SAST)","shortDescription":{"text":"Static Analysis (SAST)"},"helpUri":"https://codehealth.canine.dev/dimensions/D29","relationships":[{"target":{"id":"CWE-79","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-78","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-94","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-77","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-79","CWE-89","CWE-78","CWE-94","CWE-77"]}},{"id":"D35","name":"Change Coupling","shortDescription":{"text":"Change Coupling"},"helpUri":"https://codehealth.canine.dev/dimensions/D35"},{"id":"D38","name":"OSV Dependency Vulnerabilities","shortDescription":{"text":"OSV Dependency Vulnerabilities"},"helpUri":"https://codehealth.canine.dev/dimensions/D38","relationships":[{"target":{"id":"CWE-1395","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-937","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1395","CWE-937"]}}]}},"results":[{"ruleId":"D1","level":"warning","message":{"text":"AsyncSequentialSubscriber.processLoop (cyclomatic 29): AsyncSequentialSubscriber.processLoop has cyclomatic complexity 29 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":475}}}],"partialFingerprints":{"codehealthFindingId/v1":"eed4f0f5ee6720963c28e7b8d68efaf5b211597099dab65d4b808cc5a0ed3398"}},{"ruleId":"D1","level":"warning","message":{"text":"AsyncSequentialSubscriber.processBatchedAcks (cyclomatic 27): AsyncSequentialSubscriber.processBatchedAcks has cyclomatic complexity 27 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":796}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3ff34f18f6201941376a83c287ba3c6ae70ecd9b5e621afb15ef25ccb0922eb"}},{"ruleId":"D1","level":"warning","message":{"text":"AsyncSequentialSubscriber.Start (cyclomatic 21): AsyncSequentialSubscriber.Start has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d1a51db2bc4f7259dbb7dc1b5ed6a4c47c97ead062df82ae930ae5cc0833221"}},{"ruleId":"D1","level":"warning","message":{"text":"AsyncSequentialSubscriber.ackLoop (cyclomatic 18): AsyncSequentialSubscriber.ackLoop has cyclomatic complexity 18 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 8 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":638}}}],"partialFingerprints":{"codehealthFindingId/v1":"395f364c9c223554884a93377ac75ab025a2b85105e2e598842b206fc7dd78d9"}},{"ruleId":"D2","level":"warning","message":{"text":"AsyncSequentialSubscriber.processLoop (cognitive 72): AsyncSequentialSubscriber.processLoop has cognitive complexity 72 (threshold 15). Drivers by points: if/else 58, loops 8, boolean chains 4, match/switch 2 (nesting depth added 45). Of this number, 69 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":475}}}],"partialFingerprints":{"codehealthFindingId/v1":"54ab62672b474ca0d38b2b322102e7cef0ebbf03cf4988b5f8148449fe15d41f"}},{"ruleId":"D2","level":"warning","message":{"text":"AsyncSequentialSubscriber.Start (cognitive 63): AsyncSequentialSubscriber.Start has cognitive complexity 63 (threshold 15). Drivers by points: if/else 57, loops 4, match/switch 2 (nesting depth added 44). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cb8265f67b961c499be9d7d300ae791e82e02214cf1fb4ad7e13fbbf558238d"}},{"ruleId":"D2","level":"warning","message":{"text":"AsyncSequentialSubscriber.processBatchedAcks (cognitive 62): AsyncSequentialSubscriber.processBatchedAcks has cognitive complexity 62 (threshold 15). Drivers by points: if/else 48, loops 12, boolean chains 2 (nesting depth added 36). Of this number, 60 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":796}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f660cb000f762c8444e9909b124bae58f443d0bdc5c2dff32e07ceb9d001298"}},{"ruleId":"D2","level":"warning","message":{"text":"AsyncSequentialSubscriber.ackLoop (cognitive 30): AsyncSequentialSubscriber.ackLoop has cognitive complexity 30 (threshold 15). Drivers by points: if/else 21, loops 4, match/switch 4, boolean chains 1 (nesting depth added 14). Of this number, 18 points are the body\u0027s own statements and 12 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":638}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3bc06fb139263e81b9c9bfbd4ca2c18b9522ffc7b20c3b3dda65a14b7a58d07"}},{"ruleId":"D2","level":"warning","message":{"text":"AsyncSequentialSubscriber.ackEvent (cognitive 28): AsyncSequentialSubscriber.ackEvent has cognitive complexity 28 (threshold 15). Drivers by points: if/else 26, boolean chains 1, loops 1 (nesting depth added 16). Of this number, 26 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":726}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8b9b7677fa8f9e726b1913dedd880884849c33caef6754d7c6ccfa586c76368"}},{"ruleId":"D2","level":"warning","message":{"text":"FIFOSubscriber.Start (cognitive 16): FIFOSubscriber.Start has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, loops 1 (nesting depth added 7). Most of this is not in the body itself: 3 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 64). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.fifo.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"985e744a3624b0fc858029a33c9aca9a906fc50d675146afb9a371f936cd604a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: eventconsumer/subscriber.asyncseq.go: FileTooLong \u2014 637 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0ae351e893e03e95560996d55de89fb3fd02742207cd03c5b1b8407be9e9260"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): pgeventstore/storage.go:102-114 | pgeventstore/storage.go:139-151 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060pgeventstore/storage.go:102\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pgeventstore/storage.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"d633baad00035bab14ebd158fbda158c1cc2d373c6d297d65183e955d66f0862"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): eventconsumer/subscriber.asyncseq.go:738-748 | eventconsumer/subscriber.asyncseq.go:827-838 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060eventconsumer/subscriber.asyncseq.go:738\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":738}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3eac863b87576279ec4dd610fbb279a0cd4c13b1c96e0a81f7def130c3b7592"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): eventconsumer/subscriber.asyncseq.go:727-735 | eventconsumer/subscriber.asyncseq.go:801-810 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060eventconsumer/subscriber.asyncseq.go:727\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":727}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e3ff12cb7cdf867b2484ce7bd091d40fae5e51594d953843eaa1591de5f4811"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): eventconsumer/subscriber.asyncseq.go:757-765 | eventconsumer/subscriber.asyncseq.go:892-900 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060eventconsumer/subscriber.asyncseq.go:757\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"eventconsumer/subscriber.asyncseq.go"},"region":{"startLine":757}}}],"partialFingerprints":{"codehealthFindingId/v1":"798786945142d5573a8702b28c430d03bc41cd3f326cc90c04e2ea74b5bd0c99"}},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c350d203d6e39d957d17551d1992c3a21d8e93341968ceaa921b38d7f745dca2"},"taxa":[{"id":"CWE-338","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D38","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"a78119f7a7f882722bfb0a280c7e72efd0dc937ade37237b8c759133cdbe61c9"}},{"ruleId":"D38","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1029701d547daf02d2b3d833d7f1aa6f16c8fe8e05a219bb639de3bcc8682a5e"}},{"ruleId":"D38","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"a1c588a767644909cb909e3780c7ec5981286503cab740ff80dc7697b1221593"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"be217444638ac33aa1bd5044cfc99a2e92b284c1cc1654e8220d2ef2ef47944d"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"9d8f4da93d93156f97ceb651382c175065ad24c552538ff2b779b549bddea902"}}],"taxonomies":[{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d","organization":"MITRE","informationUri":"https://cwe.mitre.org/","isComprehensive":false,"shortDescription":{"text":"The MITRE Common Weakness Enumeration (CWE)."},"taxa":[{"id":"CWE-1395","guid":"800e09e7-c11a-8654-9fa6-86f398995fed","name":"Dependency on Vulnerable Third-Party Component","shortDescription":{"text":"Dependency on Vulnerable Third-Party Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1395.html"},{"id":"CWE-259","guid":"ae9ad959-fbb6-9d5e-892d-3dca66da0b69","name":"Use of Hard-coded Password","shortDescription":{"text":"Use of Hard-coded Password"},"helpUri":"https://cwe.mitre.org/data/definitions/259.html"},{"id":"CWE-338","guid":"e89b7604-c3f7-8b53-bc8c-4d4718c28617","name":"CWE-338","shortDescription":{"text":"CWE-338"},"helpUri":"https://cwe.mitre.org/data/definitions/338.html"},{"id":"CWE-77","guid":"332c8ade-6612-9f56-a06b-d8d90b1a8750","name":"Command Injection","shortDescription":{"text":"Command Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/77.html"},{"id":"CWE-78","guid":"2e31ceaf-c7ae-2e5e-9661-cfb1362789cf","name":"OS Command Injection","shortDescription":{"text":"OS Command Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/78.html"},{"id":"CWE-79","guid":"fd45580b-e8c4-fc5e-8c2f-aa8fab0b4dbf","name":"Cross-site Scripting (XSS)","shortDescription":{"text":"Cross-site Scripting (XSS)"},"helpUri":"https://cwe.mitre.org/data/definitions/79.html"},{"id":"CWE-798","guid":"5e8f057d-fee3-995a-a0cb-9fc5b0d174d1","name":"Use of Hard-coded Credentials","shortDescription":{"text":"Use of Hard-coded Credentials"},"helpUri":"https://cwe.mitre.org/data/definitions/798.html"},{"id":"CWE-89","guid":"6d08fdad-37eb-c150-bbf0-d7d946863407","name":"SQL Injection","shortDescription":{"text":"SQL Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/89.html"},{"id":"CWE-937","guid":"16f316ae-415c-b354-a59b-1f7905f756e9","name":"Using Components with Known Vulnerabilities","shortDescription":{"text":"Using Components with Known Vulnerabilities"},"helpUri":"https://cwe.mitre.org/data/definitions/937.html"},{"id":"CWE-94","guid":"75e7f50c-6c2f-dd52-bf40-bf6c52b861fd","name":"Code Injection","shortDescription":{"text":"Code Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/94.html"}]}],"properties":{"codehealthPublication":{"public":true,"notice":"This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings \u2014 which rule fired, in which file, on which line, and how to fix it \u2014 are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.","securityFindingsRedacted":6,"secretScannerRunsExcluded":0}},"redactionTokens":["A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."]}]}