{"$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":"D8","name":"Code Coverage","shortDescription":{"text":"Code Coverage"},"helpUri":"https://codehealth.canine.dev/dimensions/D8"},{"id":"D12","name":"Dependency Hygiene","shortDescription":{"text":"Dependency Hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/D12"},{"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":"D16","name":"Bus Factor","shortDescription":{"text":"Bus Factor"},"helpUri":"https://codehealth.canine.dev/dimensions/D16"},{"id":"D19","name":"Documentation Quality","shortDescription":{"text":"Documentation Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D19"},{"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":"D30","name":"Dependency Vulnerabilities","shortDescription":{"text":"Dependency Vulnerabilities"},"helpUri":"https://codehealth.canine.dev/dimensions/D30","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"]}},{"id":"D34","name":"Knowledge Freshness","shortDescription":{"text":"Knowledge Freshness"},"helpUri":"https://codehealth.canine.dev/dimensions/D34"},{"id":"D35","name":"Change Coupling","shortDescription":{"text":"Change Coupling"},"helpUri":"https://codehealth.canine.dev/dimensions/D35"}]}},"results":[{"ruleId":"D1","level":"warning","message":{"text":"LiteDatabase.liteDatabaseUsage (cyclomatic 76): LiteDatabase.liteDatabaseUsage has cyclomatic complexity 76 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"LiteDB.FSharp.Tests/Tests.LiteDatabase.fs"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3b9d3fcd0feca8a4b04714c74d3db119ce2daf722953fdc8838a9855014196a"}},{"ruleId":"D1","level":"warning","message":{"text":"Experimental.genPicklerAux (cyclomatic 41): Experimental.genPicklerAux has cyclomatic complexity 41 (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":"LiteDB.FSharp/TypeShapeMapper.fs"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"719ec6eac6571ac4c769dec7adfb188da568ecbd085fcacbeb0d8a92088d5077"}},{"ruleId":"D1","level":"warning","message":{"text":"FSharpJsonConverter.ReadJson (cyclomatic 35): FSharpJsonConverter.ReadJson has cyclomatic complexity 35 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"LiteDB.FSharp/Json.fs"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"647e2bc6d3cf672cfce136a2bd733e3df0ae6896b174f74b4e03258c22259791"}},{"ruleId":"D1","level":"warning","message":{"text":"FSharpJsonConverter.WriteJson (cyclomatic 22): FSharpJsonConverter.WriteJson has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"LiteDB.FSharp/Json.fs"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ad1cfd9bc9fbe8aaa11325456e630d553f9386351ca91c910727b431fba8036"}},{"ruleId":"D1","level":"warning","message":{"text":"Bson.deserializeByType (cyclomatic 19): Bson.deserializeByType has cyclomatic complexity 19 (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":"LiteDB.FSharp/Bson.fs"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"45136e4a5fea8c5124d77d05a9dea5cb86a072298a9f6fe848278b9dc98169fb"}},{"ruleId":"D1","level":"warning","message":{"text":"FSharpJsonConverter.CanConvert (cyclomatic 18): FSharpJsonConverter.CanConvert has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"LiteDB.FSharp/Json.fs"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b1ba4c4eec2a484221a6762af1dfb76d495367338799e34e742277d7c6c1676"}},{"ruleId":"D2","level":"warning","message":{"text":"LiteDatabase.liteDatabaseUsage (cognitive 75): LiteDatabase.liteDatabaseUsage has cognitive complexity 75 (threshold 15). Drivers by points: match/switch 65, boolean chains 10 (nesting depth added 8). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"LiteDB.FSharp.Tests/Tests.LiteDatabase.fs"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"684ab07bca4f1745cfb328accc7fe226e9d6adf050cb28213c380b29b5842568"}},{"ruleId":"D2","level":"warning","message":{"text":"Experimental.genPicklerAux (cognitive 68): Experimental.genPicklerAux has cognitive complexity 68 (threshold 15). Drivers by points: if/else 50, loops 13, match/switch 5 (nesting depth added 35). 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":"LiteDB.FSharp/TypeShapeMapper.fs"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7558bd19f66112d91c7725b3f0b92b34b957e8bff72240c6b2b321a13a7c8f7"}},{"ruleId":"D2","level":"warning","message":{"text":"FSharpJsonConverter.ReadJson (cognitive 40): FSharpJsonConverter.ReadJson has cognitive complexity 40 (threshold 15). Drivers by points: match/switch 23, if/else 17 (nesting depth added 21). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"LiteDB.FSharp/Json.fs"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"43f51f33492ba6ca4caa9de2902ab6048226bad64d66135d4ff57f5d938c5e46"}},{"ruleId":"D2","level":"warning","message":{"text":"Bson.deserializeByType (cognitive 38): Bson.deserializeByType has cognitive complexity 38 (threshold 15). Drivers by points: if/else 24, loops 8, match/switch 5, boolean chains 1 (nesting depth added 21). 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":"LiteDB.FSharp/Bson.fs"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd3576883dc9a5a1e50c50db4ad804a9e522798a866fb8786542e6be474d68d3"}},{"ruleId":"D2","level":"warning","message":{"text":"FSharpJsonConverter.WriteJson (cognitive 23): FSharpJsonConverter.WriteJson has cognitive complexity 23 (threshold 15). Drivers by points: if/else 11, match/switch 9, loops 3 (nesting depth added 13). 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":"LiteDB.FSharp/Json.fs"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4a7aa2f1090a6396e127f2fd33b89982f658df0ea4565d45d5757834375193c"}},{"ruleId":"D2","level":"warning","message":{"text":"FSharpJsonConverter.CanConvert (cognitive 17): FSharpJsonConverter.CanConvert has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, boolean chains 3, match/switch 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"LiteDB.FSharp/Json.fs"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"132965e0b2b5c17e8cdf3be385dc1dc410161b0a9025831acd55eb3a913a6aaa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): LiteDB.FSharp/Extensions.fs:46-51 | LiteDB.FSharp/Extensions.fs:64-69 \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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"LiteDB.FSharp/Extensions.fs"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"719f04147b857ea521bc2e0151c3b14ff5abd05df665cedf5c20e7da4ce9e014"}},{"ruleId":"D8","level":"warning","message":{"text":"Coverage not measured: The test suite couldn\u0027t be built/run in-image and no coverage report is committed, so line coverage was not measured \u2014 and it is EXCLUDED from the score rather than scored on a LoC-ratio proxy. No coverage collector was found in your CI either, so there is no existing report to hand us: add a coverage collector to your test run and commit (or publish) its Cobertura/OpenCover/lcov output anywhere in the repo, or make the suite runnable in-image, and real coverage will be measured."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"62e63e619c28f057e129f2997c965d32a457366a9ce18ca019ffb6bdfba85c99"}},{"ruleId":"D12","level":"error","message":{"text":"Vulnerable: LiteDB: LiteDB 5.0.0) \u2014 4.1.4 severity. Critical"},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"3afc1fa9af4df31816e4423734dc03bcabd3e2e46d619d42d16ce16ad7752001"}},{"ruleId":"D16","level":"warning","message":{"text":"dormant codebase \u2014 no living knowledge left to concentrate: All 4 significant source file(s) were last meaningfully changed so long ago that no living knowledge remains \u2014 nothing since has been substantial enough to re-establish ownership (a broad, mechanical sweep that touches many files shallowly does not count, and neither does no activity at all). There is no concentration to measure, so the bus factor is not scored. This is not a clean bill: nobody currently holds working knowledge of this code (see D34 Knowledge Freshness)."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"569d55ea5cb0330f13c125b289d07e5abdfcceac947a2c2645277937942e7d5f"}},{"ruleId":"D30","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":"55b60efb7a65191db7a800999575b87fc734d3dde460aa92a2f20a3b7686c8f5"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"LiteDB.FSharp/Json.fs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"574d5423b81539e374bb57f05abb9c8bea2146cd5a9e9af967bc8877fa9e061b"}},{"ruleId":"D34","level":"note","message":{"text":"Further orphaned files (smaller): 5 smaller file(s) also have no living knowledge \u2014 folded into the freshness score and metrics rather than listed individually (6 orphaned of 6 analysed files in total, counted over production source files of roughly 100 lines or more, excluding tests, vendored, generated and example/demo trees, largest first)."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"ce861fd78f6935114d3a342cb90ad25870f984e1042954fcbbe27c0e23be3658"}}],"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-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":1,"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."]}]}