@cdxgen/cdxgen 13.5.0 → 13.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (182) hide show
  1. package/README.md +6 -6
  2. package/bin/cdxgen.js +4 -0
  3. package/bin/evinse.js +3 -0
  4. package/bin/validate.js +6 -0
  5. package/data/license-aliases.json +24 -2
  6. package/data/remediations.json +124 -0
  7. package/data/rules/ai-bom.yaml +1 -1
  8. package/data/rules/brotli-decoder.yaml +107 -0
  9. package/data/rules/vscode-extensions.yaml +75 -0
  10. package/data/spdx-license-list.json +121 -7
  11. package/data/spdx-licenses.json +69 -0
  12. package/data/spdx.schema.json +845 -2
  13. package/lib/cli/bomAssembly.js +92 -3
  14. package/lib/cli/index.js +108 -1
  15. package/lib/cli/jsBom.js +153 -64
  16. package/lib/cli/jvmBom.js +237 -46
  17. package/lib/cli/managedBom.js +142 -16
  18. package/lib/cli/nativeBom.js +42 -5
  19. package/lib/core/boundedFile.js +344 -0
  20. package/lib/core/brotliProbe.js +182 -0
  21. package/lib/core/env.js +8 -0
  22. package/lib/core/fs.js +12 -0
  23. package/lib/core/httpClient.js +98 -1
  24. package/lib/core/lockPaths.js +38 -0
  25. package/lib/core/paths.js +24 -1
  26. package/lib/core/processTree.js +5 -0
  27. package/lib/core/toolRegistry.js +170 -0
  28. package/lib/ecosystems/cppEvidence.js +263 -106
  29. package/lib/ecosystems/cppIncludeResolver.js +16 -5
  30. package/lib/ecosystems/ecosystems.js +25 -10
  31. package/lib/ecosystems/gemHostProbe.js +301 -0
  32. package/lib/ecosystems/gradleutils.js +828 -224
  33. package/lib/ecosystems/parsers-bazel.js +107 -6
  34. package/lib/ecosystems/parsers-js.js +505 -22
  35. package/lib/ecosystems/parsers-misc.js +209 -20
  36. package/lib/ecosystems/parsers-python.js +89 -2
  37. package/lib/ecosystems/pythonutils.js +128 -2
  38. package/lib/ecosystems/rubyutils.js +538 -31
  39. package/lib/ecosystems/scalacliutils.js +2 -0
  40. package/lib/ecosystems/scalasem.js +796 -151
  41. package/lib/ecosystems/vendoredCode.js +237 -3
  42. package/lib/ecosystems/venvProbe.js +360 -0
  43. package/lib/evinser/evinser.js +346 -43
  44. package/lib/helpers/agenticToolutils.js +413 -93
  45. package/lib/helpers/vsixutils.js +1574 -315
  46. package/lib/inventory/atomUtils.js +77 -0
  47. package/lib/inventory/brotliDecoder.js +142 -0
  48. package/lib/inventory/buildToolRateLimit.js +1 -1
  49. package/lib/inventory/cbomutils.js +56 -7
  50. package/lib/inventory/deps.js +35 -0
  51. package/lib/inventory/dosai.js +139 -5
  52. package/lib/inventory/dotnetRuntime.js +217 -0
  53. package/lib/inventory/envcontext.js +307 -13
  54. package/lib/inventory/evidenceUtils.js +11 -0
  55. package/lib/inventory/fetchBatch.js +1 -1
  56. package/lib/inventory/formulationParsers.js +31 -3
  57. package/lib/inventory/gtfobins.js +13 -0
  58. package/lib/inventory/hostRuntimeProbe.js +686 -0
  59. package/lib/inventory/jvmLocalRepos.js +9 -2
  60. package/lib/inventory/jvmToolEnv.js +29 -0
  61. package/lib/inventory/licenseEnhancer.js +12 -0
  62. package/lib/inventory/mavenCentralMirror.js +534 -0
  63. package/lib/inventory/nodeBuildInfo.js +218 -0
  64. package/lib/inventory/nodeHostProbe.js +202 -0
  65. package/lib/inventory/osPackageResolver.js +182 -0
  66. package/lib/inventory/phpBuildInfo.js +10 -59
  67. package/lib/inventory/phpHostProbe.js +32 -488
  68. package/lib/inventory/rubyBuildInfo.js +972 -0
  69. package/lib/inventory/rubyHostProbe.js +218 -0
  70. package/lib/inventory/scalaCoords.js +4 -3
  71. package/lib/inventory/scalaDedupe.js +440 -0
  72. package/lib/inventory/source.js +49 -2
  73. package/lib/managers/binary.js +337 -3
  74. package/lib/managers/docker.js +79 -0
  75. package/lib/parsers/largeJson.js +28 -11
  76. package/lib/parsers/vscodeExtensionId.js +183 -0
  77. package/lib/server/server.js +12 -1
  78. package/lib/stages/postgen/ruleEngine.js +13 -5
  79. package/lib/stages/pregen/envAudit.js +1 -0
  80. package/lib/stages/pregen/pregen.js +114 -57
  81. package/lib/validator/bomValidator.js +6 -1
  82. package/lib/validator/generated/validate-1.6.mjs +1 -1
  83. package/lib/validator/generated/validate-1.7.mjs +1 -1
  84. package/lib/validator/generated/validate-2.0.mjs +1 -1
  85. package/lib/validator/index.js +1 -1
  86. package/package.json +3 -2
  87. package/types/lib/cli/bomAssembly.d.ts +13 -1
  88. package/types/lib/cli/bomAssembly.d.ts.map +1 -1
  89. package/types/lib/cli/index.d.ts.map +1 -1
  90. package/types/lib/cli/jsBom.d.ts +1 -17
  91. package/types/lib/cli/jsBom.d.ts.map +1 -1
  92. package/types/lib/cli/jvmBom.d.ts.map +1 -1
  93. package/types/lib/cli/managedBom.d.ts.map +1 -1
  94. package/types/lib/cli/nativeBom.d.ts.map +1 -1
  95. package/types/lib/core/boundedFile.d.ts +70 -0
  96. package/types/lib/core/boundedFile.d.ts.map +1 -0
  97. package/types/lib/core/brotliProbe.d.ts +37 -0
  98. package/types/lib/core/brotliProbe.d.ts.map +1 -0
  99. package/types/lib/core/env.d.ts +4 -0
  100. package/types/lib/core/env.d.ts.map +1 -1
  101. package/types/lib/core/fs.d.ts.map +1 -1
  102. package/types/lib/core/httpClient.d.ts +24 -0
  103. package/types/lib/core/httpClient.d.ts.map +1 -1
  104. package/types/lib/core/lockPaths.d.ts +19 -0
  105. package/types/lib/core/lockPaths.d.ts.map +1 -0
  106. package/types/lib/core/processTree.d.ts +2 -0
  107. package/types/lib/core/processTree.d.ts.map +1 -1
  108. package/types/lib/core/toolRegistry.d.ts +36 -0
  109. package/types/lib/core/toolRegistry.d.ts.map +1 -0
  110. package/types/lib/ecosystems/cppEvidence.d.ts +40 -13
  111. package/types/lib/ecosystems/cppEvidence.d.ts.map +1 -1
  112. package/types/lib/ecosystems/cppIncludeResolver.d.ts +2 -1
  113. package/types/lib/ecosystems/cppIncludeResolver.d.ts.map +1 -1
  114. package/types/lib/ecosystems/ecosystems.d.ts.map +1 -1
  115. package/types/lib/ecosystems/gemHostProbe.d.ts +28 -0
  116. package/types/lib/ecosystems/gemHostProbe.d.ts.map +1 -0
  117. package/types/lib/ecosystems/gradleutils.d.ts +47 -13
  118. package/types/lib/ecosystems/gradleutils.d.ts.map +1 -1
  119. package/types/lib/ecosystems/parsers-bazel.d.ts.map +1 -1
  120. package/types/lib/ecosystems/parsers-js.d.ts +17 -20
  121. package/types/lib/ecosystems/parsers-js.d.ts.map +1 -1
  122. package/types/lib/ecosystems/parsers-misc.d.ts +19 -0
  123. package/types/lib/ecosystems/parsers-misc.d.ts.map +1 -1
  124. package/types/lib/ecosystems/parsers-python.d.ts +10 -0
  125. package/types/lib/ecosystems/parsers-python.d.ts.map +1 -1
  126. package/types/lib/ecosystems/pythonutils.d.ts +20 -2
  127. package/types/lib/ecosystems/pythonutils.d.ts.map +1 -1
  128. package/types/lib/ecosystems/rubyutils.d.ts +144 -12
  129. package/types/lib/ecosystems/rubyutils.d.ts.map +1 -1
  130. package/types/lib/ecosystems/scalacliutils.d.ts.map +1 -1
  131. package/types/lib/ecosystems/vendoredCode.d.ts +26 -0
  132. package/types/lib/ecosystems/vendoredCode.d.ts.map +1 -1
  133. package/types/lib/ecosystems/venvProbe.d.ts +40 -0
  134. package/types/lib/ecosystems/venvProbe.d.ts.map +1 -0
  135. package/types/lib/evinser/evinser.d.ts +63 -8
  136. package/types/lib/evinser/evinser.d.ts.map +1 -1
  137. package/types/lib/inventory/atomUtils.d.ts +19 -0
  138. package/types/lib/inventory/atomUtils.d.ts.map +1 -1
  139. package/types/lib/inventory/brotliDecoder.d.ts +58 -0
  140. package/types/lib/inventory/brotliDecoder.d.ts.map +1 -0
  141. package/types/lib/inventory/cbomutils.d.ts +17 -0
  142. package/types/lib/inventory/cbomutils.d.ts.map +1 -1
  143. package/types/lib/inventory/deps.d.ts.map +1 -1
  144. package/types/lib/inventory/dosai.d.ts +17 -1
  145. package/types/lib/inventory/dosai.d.ts.map +1 -1
  146. package/types/lib/inventory/dotnetRuntime.d.ts +44 -0
  147. package/types/lib/inventory/dotnetRuntime.d.ts.map +1 -0
  148. package/types/lib/inventory/envcontext.d.ts +52 -6
  149. package/types/lib/inventory/envcontext.d.ts.map +1 -1
  150. package/types/lib/inventory/evidenceUtils.d.ts.map +1 -1
  151. package/types/lib/inventory/formulationParsers.d.ts.map +1 -1
  152. package/types/lib/inventory/gtfobins.d.ts.map +1 -1
  153. package/types/lib/inventory/hostRuntimeProbe.d.ts +44 -0
  154. package/types/lib/inventory/hostRuntimeProbe.d.ts.map +1 -0
  155. package/types/lib/inventory/jvmToolEnv.d.ts +12 -0
  156. package/types/lib/inventory/jvmToolEnv.d.ts.map +1 -1
  157. package/types/lib/inventory/licenseEnhancer.d.ts.map +1 -1
  158. package/types/lib/inventory/mavenCentralMirror.d.ts +170 -0
  159. package/types/lib/inventory/mavenCentralMirror.d.ts.map +1 -0
  160. package/types/lib/inventory/nodeBuildInfo.d.ts +95 -0
  161. package/types/lib/inventory/nodeBuildInfo.d.ts.map +1 -0
  162. package/types/lib/inventory/nodeHostProbe.d.ts +15 -0
  163. package/types/lib/inventory/nodeHostProbe.d.ts.map +1 -0
  164. package/types/lib/inventory/osPackageResolver.d.ts +38 -0
  165. package/types/lib/inventory/osPackageResolver.d.ts.map +1 -1
  166. package/types/lib/inventory/phpBuildInfo.d.ts.map +1 -1
  167. package/types/lib/inventory/phpHostProbe.d.ts.map +1 -1
  168. package/types/lib/inventory/rubyBuildInfo.d.ts +271 -0
  169. package/types/lib/inventory/rubyBuildInfo.d.ts.map +1 -0
  170. package/types/lib/inventory/rubyHostProbe.d.ts +47 -0
  171. package/types/lib/inventory/rubyHostProbe.d.ts.map +1 -0
  172. package/types/lib/inventory/source.d.ts +10 -0
  173. package/types/lib/inventory/source.d.ts.map +1 -1
  174. package/types/lib/managers/binary.d.ts.map +1 -1
  175. package/types/lib/managers/docker.d.ts +12 -0
  176. package/types/lib/managers/docker.d.ts.map +1 -1
  177. package/types/lib/parsers/largeJson.d.ts +4 -3
  178. package/types/lib/parsers/largeJson.d.ts.map +1 -1
  179. package/types/lib/server/server.d.ts.map +1 -1
  180. package/types/lib/stages/pregen/envAudit.d.ts.map +1 -1
  181. package/types/lib/stages/pregen/pregen.d.ts +12 -8
  182. package/types/lib/stages/pregen/pregen.d.ts.map +1 -1
@@ -191,6 +191,14 @@ export declare function toGemModuleNames(name: any): string[];
191
191
  * @returns {Array<string>} List of module names
192
192
  */
193
193
  export declare function collectGemModuleNames(rubyCommand: string, bundleCommand: string, gemHome: string, gemName: string, filePath: string): Array<string>;
194
+ /**
195
+ * Whether a gemspec is a default gem, one that ships with Ruby: RubyGems
196
+ * keeps them under `specifications/default/`.
197
+ *
198
+ * @param {string} gemspecFile path of the gemspec, either separator
199
+ * @returns {boolean}
200
+ */
201
+ export declare function isDefaultGemspecPath(gemspecFile: string): boolean;
194
202
  /**
195
203
  * Method to parse Gemspec file contents.
196
204
  *
@@ -310,33 +318,157 @@ export declare function addRubyGemsDistributionUrls(pkgList: any[]): any[];
310
318
  */
311
319
  export declare function rubyRequirementToVers(requirements: string[]): string | null | undefined;
312
320
  /**
313
- * Describe the Ruby runtime the gems require as one external `platform`
321
+ * Read the Ruby a `.ruby-version` file selects, as rbenv, chruby, rvm, asdf
322
+ * and mise read it: `3.3.6`, `ruby-3.3.6`, `3.3`, `jruby-9.4.8.0`,
323
+ * `truffleruby-24.1.0`, `truffleruby+graalvm-24.1.0`. Only the first word
324
+ * counts; comments and blank lines are skipped.
325
+ *
326
+ * @param {string} text file contents
327
+ * @returns {{engine: string, version?: string, requirement?: string, source: string}|undefined}
328
+ */
329
+ export declare function parseRubyVersionFile(text: string): {
330
+ engine: string;
331
+ version?: string;
332
+ requirement?: string;
333
+ source: string;
334
+ } | undefined;
335
+ /**
336
+ * Read the Ruby an asdf `.tool-versions` file selects: the first version on
337
+ * the `ruby` line, e.g. `ruby 3.3.6 3.2.2`.
338
+ *
339
+ * @param {string} text file contents
340
+ * @returns {{engine: string, version?: string, requirement?: string, source: string}|undefined}
341
+ */
342
+ export declare function parseToolVersionsRuby(text: string): {
343
+ engine: string;
344
+ version?: string;
345
+ requirement?: string;
346
+ source: string;
347
+ } | undefined;
348
+ /**
349
+ * Read the Ruby a mise configuration selects from its `[tools]` table:
350
+ * `ruby = "3.3.6"`, `ruby = ["3.3.6", "3.2"]` or `ruby = { version = "3.3.6" }`.
351
+ *
352
+ * @param {string} text mise.toml contents
353
+ * @param {string} [source="mise.toml"] the file name, for the result
354
+ * @returns {{engine: string, version?: string, requirement?: string, source: string}|undefined}
355
+ */
356
+ export declare function parseMiseRuby(text: string, source?: string): {
357
+ engine: string;
358
+ version?: string;
359
+ requirement?: string;
360
+ source: string;
361
+ } | undefined;
362
+ /**
363
+ * Read the `ruby` directive of a Gemfile: `ruby "3.3.6"`, `ruby "~> 3.3"`,
364
+ * `ruby "3.1.4", engine: "jruby", engine_version: "9.4.8.0"`, or
365
+ * `ruby file: ".ruby-version"`. The Gemfile is never evaluated, so a
366
+ * directive built from an expression, such as `ruby RUBY_VERSION`, says
367
+ * nothing.
368
+ *
369
+ * @param {string} text Gemfile contents
370
+ * @returns {{engine: string, version?: string, requirement?: string,
371
+ * file?: string, source: string}|undefined}
372
+ */
373
+ export declare function parseGemfileRubyDirective(text: string): {
374
+ engine: string;
375
+ version?: string;
376
+ requirement?: string;
377
+ file?: string;
378
+ source: string;
379
+ } | undefined;
380
+ /**
381
+ * Read the `RUBY VERSION` section of a Gemfile.lock, which Bundler writes when
382
+ * the Gemfile has a `ruby` directive: `ruby 3.3.6p108`, `ruby 3.4.0p-1` for a
383
+ * pre-release, or `ruby 3.1.4p0 (jruby 9.4.8.0)` for another engine.
384
+ *
385
+ * @param {string} text Gemfile.lock contents
386
+ * @returns {{engine: string, version: string, patchlevel?: string,
387
+ * rubyVersion?: string, source: string}|undefined}
388
+ */
389
+ export declare function parseGemfileLockRubyVersion(text: string): {
390
+ engine: string;
391
+ version: string;
392
+ patchlevel?: string;
393
+ rubyVersion?: string;
394
+ source: string;
395
+ } | undefined;
396
+ /**
397
+ * Collect every Ruby a project directory declares, from the Gemfile.lock
398
+ * `RUBY VERSION` section, `.ruby-version`, `.tool-versions`, mise.toml and the
399
+ * Gemfile `ruby` directive. Each declaration names its source.
400
+ *
401
+ * @param {string} projectPath project directory
402
+ * @param {string} [lockData] Gemfile.lock contents, when already read
403
+ * @returns {Array<{engine: string, version?: string, requirement?: string,
404
+ * patchlevel?: string, source: string, path: string}>}
405
+ */
406
+ export declare function collectProjectRubyDeclarations(projectPath: string, lockData?: string): Array<{
407
+ engine: string;
408
+ version?: string;
409
+ requirement?: string;
410
+ patchlevel?: string;
411
+ source: string;
412
+ path: string;
413
+ }>;
414
+ /**
415
+ * Settle the Ruby a project runs on from its declarations: the exact version
416
+ * of the most authoritative source that has one, and the requirements of the
417
+ * sources that only constrain it.
418
+ *
419
+ * @param {Array<Object>} declarations result of collectProjectRubyDeclarations
420
+ * @returns {{engine: string, version?: string, patchlevel?: string,
421
+ * prerelease?: boolean, rubyVersion?: string, source?: string,
422
+ * requirements: string[], conflicts: string[]}|undefined}
423
+ */
424
+ export declare function resolveProjectRuby(declarations: Array<Object>): {
425
+ engine: string;
426
+ version?: string;
427
+ patchlevel?: string;
428
+ prerelease?: boolean;
429
+ rubyVersion?: string;
430
+ source?: string;
431
+ requirements: string[];
432
+ conflicts: string[];
433
+ } | undefined;
434
+ /**
435
+ * Describe the Ruby runtime of a project as one external `platform`
314
436
  * component, and make the components that declare a `required_ruby_version`
315
437
  * depend on it (discussion 4409).
316
438
  *
317
- * The component stands for the Ruby the bundle as a whole runs on, so its
318
- * `versionRange` is the intersection of every requirement that could be read,
319
- * in the `vers` syntax CycloneDX mandates for the field. Each component's own
320
- * requirement stays in its `cdx:gem:rubyVersionSpecifiers` property. One
321
- * runtime component per distinct requirement would describe the same
322
- * interpreter many times over: a modest bundle spells `>= 2.x` a dozen ways.
439
+ * When the project pins a Ruby (Gemfile.lock `RUBY VERSION`, `.ruby-version`,
440
+ * `.tool-versions`, mise or the Gemfile `ruby` directive), the component names
441
+ * that version, `pkg:generic/ruby@3.3.6`, with the CPE a scanner matches
442
+ * interpreter advisories by. The requirements of the gems then stay in the
443
+ * `cdx:ruby:requiredVersionRange` property, since CycloneDX allows a
444
+ * `versionRange` only on a component without a version.
445
+ *
446
+ * Without a pin, the component stands for the Ruby the bundle as a whole runs
447
+ * on, so its `versionRange` is the intersection of every requirement that
448
+ * could be read, in the `vers` syntax CycloneDX mandates for the field. Each
449
+ * component's own requirement stays in its `cdx:gem:rubyVersionSpecifiers`
450
+ * property. One runtime component per distinct requirement would describe the
451
+ * same interpreter many times over: a modest bundle spells `>= 2.x` a dozen
452
+ * ways.
323
453
  *
324
454
  * The type is `platform`, the CycloneDX type for a runtime environment that
325
455
  * interprets software, and the one cdxgen gives the Ruby it finds in the
326
- * build environment. The purl names no version, since a range is not one.
456
+ * build environment. A range is not a version, so an unpinned purl names none.
327
457
  *
328
- * `isExternal` and `versionRange` are CycloneDX 1.7 fields, and without them
329
- * the component would claim the product bundles its interpreter, so the caller
330
- * decides whether the BOM should carry it at all.
458
+ * `isExternal` and `versionRange` are CycloneDX 1.7 fields. A pinned runtime
459
+ * also carries the `cdx:ruby:isExternal` property, which says the interpreter
460
+ * comes with the deployment environment in a BOM of an older spec; the caller
461
+ * decides whether such a BOM should carry an unpinned runtime at all.
331
462
  *
332
463
  * @param {Array} pkgList Components
333
464
  * @param {object} parentComponent The metadata.component, when the project is
334
465
  * itself a gem
335
466
  * @param {Array} dependencies Dependency edges
467
+ * @param {object} [projectRuby] result of resolveProjectRuby
336
468
  * @returns {{pkgList: Array, dependencies: Array}} Components and edges with
337
469
  * the runtime component added
338
470
  */
339
- export declare function addRubyRuntimeComponent(pkgList: any[], parentComponent: object, dependencies: any[]): {
471
+ export declare function addRubyRuntimeComponent(pkgList: any[], parentComponent: object, dependencies: any[], projectRuby?: object): {
340
472
  pkgList: any[];
341
473
  dependencies: any[];
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AA;CAAC,GAAC,SAAS,CAyD1D;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,OAAA,EACP,eAAe,EATN,MASM,EACf,YAAY,OAAA,EACZ,WAAW,AARV,CACA,EADQ,MAQE,GAPA;IAAC,OAAO,QAAQ;IAAC,YAAY,QAAO;CAAC,CA4HjD"}
@@ -1 +1 @@
1
- {"version":3,"file":"scalacliutils.d.ts","sourceRoot":"","sources":["../../../lib/ecosystems/scalacliutils.js"],"names":[],"mappings":"AAyCA;;;;;;;;GAQG;AACH,wBAAgB,uBAAuB,CAAC,UAAU,EANvC,MAMuC,GALrC;IAAE,YAAY,EAAE,MAAM,GAAC,IAAI,CAAC;IAAC,QAAQ,EAAE,MAAM,GAAC,IAAI,CAAC;IAAC,aAAa,EAAE,MAAM,GAAC,IAAI,CAAC;IAAC,IAAI,EAAE,MAAM,EAAE,CAAA;CAAE,CAyD5G;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,iBAAiB,CAAC,GAAG,EAL1B,MAK0B,EAAE,OAAO,EAJnC,MAImC,EAAE,UAAU,EAH/C,MAG+C,GAF7C,MAAM,GAAC,IAAI,CAuDvB;AAED;;;;;;;;GAQG;AACH,wBAAgB,2BAA2B,CAAC,OAAO,EAHxC,MAGwC,GAFtC;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,GAAC,IAAI,CAkCjE;AAsBD;;;;;;;;;;;;GAYG;AACH,wBAAgB,yBAAyB,CAAC,OAAO,EALtC,MAKsC,EAAE,OAAO,GAJ/C,MAIoD,GAHlD,MAAM,EAAE,CAmGpB"}
1
+ {"version":3,"file":"scalacliutils.d.ts","sourceRoot":"","sources":["../../../lib/ecosystems/scalacliutils.js"],"names":[],"mappings":"AA0CA;;;;;;;;GAQG;AACH,wBAAgB,uBAAuB,CAAC,UAAU,EANvC,MAMuC,GALrC;IAAE,YAAY,EAAE,MAAM,GAAC,IAAI,CAAC;IAAC,QAAQ,EAAE,MAAM,GAAC,IAAI,CAAC;IAAC,aAAa,EAAE,MAAM,GAAC,IAAI,CAAC;IAAC,IAAI,EAAE,MAAM,EAAE,CAAA;CAAE,CAyD5G;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,iBAAiB,CAAC,GAAG,EAL1B,MAK0B,EAAE,OAAO,EAJnC,MAImC,EAAE,UAAU,EAH/C,MAG+C,GAF7C,MAAM,GAAC,IAAI,CAuDvB;AAED;;;;;;;;GAQG;AACH,wBAAgB,2BAA2B,CAAC,OAAO,EAHxC,MAGwC,GAFtC;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,GAAC,IAAI,CAkCjE;AAsBD;;;;;;;;;;;;GAYG;AACH,wBAAgB,yBAAyB,CAAC,OAAO,EALtC,MAKsC,EAAE,OAAO,GAJ/C,MAIoD,GAHlD,MAAM,EAAE,CAoGpB"}
@@ -14,6 +14,32 @@
14
14
  * @returns {boolean}
15
15
  */
16
16
  export declare function isLicenseFileName(name: string): boolean;
17
+ /**
18
+ * Read the version of a vendored directory from the library's own version
19
+ * header, else from its CMake project() call.
20
+ *
21
+ * @param {string} dir Absolute path of the vendored directory
22
+ * @returns {{version?: string, source?: string, cpe?: string, properties: Object[]}|undefined}
23
+ * undefined when nothing is known, and without a version when only the fix
24
+ * marker could be read
25
+ */
26
+ export declare function vendoredVersionOf(dir: string): {
27
+ version?: string;
28
+ source?: string;
29
+ cpe?: string;
30
+ properties: Object[];
31
+ } | undefined;
32
+ /**
33
+ * Whether a file lies under a directory conventionally holding another
34
+ * project's code (`third_party/`, `vendor/`, `external/`) below the scan root.
35
+ * Build files there belong to the copied project: building them runs that
36
+ * project's build, and their dependencies are its build tooling.
37
+ *
38
+ * @param {string} root Project scan root
39
+ * @param {string} file File path
40
+ * @returns {boolean}
41
+ */
42
+ export declare function isInVendoredDir(root: string, file: string): boolean;
17
43
  /**
18
44
  * Find the directories of a project that carry code under a license other
19
45
  * than the project's.
@@ -1 +1 @@
1
- {"version":3,"file":"vendoredCode.d.ts","sourceRoot":"","sources":["../../../lib/ecosystems/vendoredCode.js"],"names":[],"mappings":"AAAA;;;;;;GAMG;AA2BH;;;;;;;GAOG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAH3B,MAG2B,GAFzB,OAAO,CAkBnB;AAkBD;;;;;;;;;;GAUG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAP1B,MAO0B,EAAE,OAAO,GANnC,MAMwC,EAAE,WAAW,AAL7D,CAEA,EAFQ,MAAM,EAKoD,GAHxD;IAAC,UAAU,EAAE,MAAM,EAAE,CAAC;IAAC,IAAI,EAAE,MAAM,EAAE,CAAA;CAAC,CAwElD"}
1
+ {"version":3,"file":"vendoredCode.d.ts","sourceRoot":"","sources":["../../../lib/ecosystems/vendoredCode.js"],"names":[],"mappings":"AAAA;;;;;;GAMG;AA2BH;;;;;;;GAOG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAH3B,MAG2B,GAFzB,OAAO,CAkBnB;AAuJD;;;;;;;;GAQG;AACH,wBAAgB,iBAAiB,CAAC,GAAG,EAL1B,MAK0B,GAJxB;IAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAAC,GAAG,CAAC,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,EAAE,CAAA;CAAC,GAAC,SAAS,CAuC7F;AAcD;;;;;;;;;GASG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAJzB,MAIyB,EAAE,IAAI,EAH/B,MAG+B,GAF7B,OAAO,CAWnB;AAMD;;;;;;;;;;GAUG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAP1B,MAO0B,EAAE,OAAO,GANnC,MAMwC,EAAE,WAAW,AAL7D,CAEA,EAFQ,MAAM,EAKoD,GAHxD;IAAC,UAAU,EAAE,MAAM,EAAE,CAAC;IAAC,IAAI,EAAE,MAAM,EAAE,CAAA;CAAC,CA0FlD"}
@@ -0,0 +1,40 @@
1
+ /**
2
+ * Find the virtual environments and pyenv interpreters under the fixed
3
+ * places of a root.
4
+ *
5
+ * @param {string} rootPath root directory
6
+ * @param {string} platform `linux` or `darwin`
7
+ * @returns {{path: string, kind: string}[]} environments, at most MAX_ENVIRONMENTS
8
+ */
9
+ export declare function findPythonEnvironments(rootPath: string, platform: string): {
10
+ path: string;
11
+ kind: string;
12
+ }[];
13
+ /**
14
+ * Inventory the packages installed in the virtual environments and pyenv
15
+ * interpreters of a host. One component per distinct name and version, with
16
+ * an occurrence for each dist-info directory it was found in, so no host path
17
+ * reaches a purl.
18
+ *
19
+ * @param {Object} [options] options
20
+ * @param {string} [options.rootPath="/"] root directory; tests point it at a built tree
21
+ * @param {string} [options.platform] `linux` or `darwin`
22
+ * @returns {Object[]} pypi components
23
+ */
24
+ export declare function probeHostPythonEnvironments(options?: {
25
+ rootPath?: string;
26
+ platform?: string;
27
+ }): Object[];
28
+ /**
29
+ * Add the packages of the host's Python environments to an OBOM's component
30
+ * list. A package osquery already listed from the interpreter's own
31
+ * site-packages keeps its component; the environment's dist-info becomes one
32
+ * more occurrence of it, and its cdx:python:environment property says where
33
+ * else it is installed.
34
+ *
35
+ * @param {Object[]} components OBOM components
36
+ * @param {Object[]} envPackages result of probeHostPythonEnvironments
37
+ * @returns {Object[]} the components, with the environment packages merged in
38
+ */
39
+ export declare function mergeHostPythonEnvironmentPackages(components: Object[], envPackages: Object[]): Object[];
40
+ //# sourceMappingURL=venvProbe.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"venvProbe.d.ts","sourceRoot":"","sources":["../../../lib/ecosystems/venvProbe.js"],"names":[],"mappings":"AAoHA;;;;;;;GAOG;AACH,wBAAgB,sBAAsB,CAAC,QAAQ,EAJpC,MAIoC,EAAE,QAAQ,EAH9C,MAG8C,GAF5C;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAC,EAAE,CAkD1C;AA8BD;;;;;;;;;;GAUG;AACH,wBAAgB,2BAA2B,CAAC,OAAO,AALhD,CAGA,EAFA;IAAyB,QAAQ,AAAjC,CACA,EADQ,MAAM,CACd;IAAyB,QAAQ,AAAjC,CACA,EADQ,MAAM,CACd;CAEqD,GAF3C,MAAM,EAAE,CAkGpB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,kCAAkC,CAAC,UAAU,EAJlD,MAAM,EAI4C,EAAE,WAAW,EAH/D,MAAM,EAGyD,GAF7D,MAAM,EAAE,CAuCpB"}
@@ -417,14 +417,7 @@ export declare function isFilterableType(language: string, userDefinedTypesMap:
417
417
  * @returns {void}
418
418
  */
419
419
  export declare function detectServicesFromOpenAPI(_language: string, openapiSpecFile: string, servicesMap: Object): void;
420
- /**
421
- * Method to detect services from annotation objects in the usage slice
422
- *
423
- * @param {string} language Application language
424
- * @param {Array} slice Usages array for each objectSlice
425
- * @param {Object} servicesMap Existing service map
426
- */
427
- export declare function detectServicesFromUsages(language: string, slice: any[], servicesMap?: Object): never[] | undefined;
420
+ export declare function detectServicesFromUsages(language: any, slice: any, servicesMap?: {}): never[] | undefined;
428
421
  /**
429
422
  * Method to detect services from user defined types in the usage slice
430
423
  *
@@ -457,6 +450,35 @@ export declare function constructServiceName(_language: string, slice: Object):
457
450
  * @returns {string[]|undefined} Array of endpoint paths or `undefined` when none are found
458
451
  */
459
452
  export declare function extractEndpoints(language: string, code: string): string[] | undefined;
453
+ /**
454
+ * Key naming the package a purl refers to, independent of its version,
455
+ * qualifiers and subpath. Namespace and name are the decoded purl segments,
456
+ * so an encoded scope (`%40angular/common`) keys like a plain one.
457
+ *
458
+ * @param {string} purl Purl string
459
+ * @returns {string|undefined} `type/namespace/name`, or undefined for a non-purl
460
+ */
461
+ export declare function versionlessPurlKey(purl: string): string | undefined;
462
+ /**
463
+ * Index the data-flow frames recorded under versionless flow purls by
464
+ * {@link versionlessPurlKey}. A flow purl without a version attaches to every
465
+ * BOM component of the same package name, whatever its version (maintainer
466
+ * decision, 2026-10-27); chen leaves the version off exactly when it cannot
467
+ * pick one between apps that pin the package differently.
468
+ *
469
+ * @param {Object} dataFlowFrames Frames keyed by flow purl
470
+ * @returns {Object} Frames keyed by versionless purl key
471
+ */
472
+ export declare function indexVersionlessPurls(dataFlowFrames: Object): Object;
473
+ /**
474
+ * Index the crypto generate pools recorded under versionless flow purls by
475
+ * {@link versionlessPurlKey}, the crypto counterpart of
476
+ * {@link indexVersionlessPurls}.
477
+ *
478
+ * @param {Object} cryptoGeneratePurls Algorithm bom-refs keyed by flow purl
479
+ * @returns {Object} Algorithm bom-ref sets keyed by versionless purl key
480
+ */
481
+ export declare function indexVersionlessCrypto(cryptoGeneratePurls: Object): Object;
460
482
  /**
461
483
  * Method to create the SBOM with evidence file called evinse file.
462
484
  *
@@ -526,4 +548,37 @@ export declare function simplifyType(typeFullName: string): string;
526
548
  * @returns {string|undefined} Enclosing class type or `undefined` when it cannot be resolved
527
549
  */
528
550
  export declare function getClassTypeFromSignature(language: string, typeFullName: string): string | undefined;
551
+ /**
552
+ * npm package name of a JavaScript module specifier: `@scope/pkg/sub` -> `@scope/pkg`,
553
+ * `lodash/fp` -> `lodash`. Node.js builtins (`node:fs`, `fs`) are not packages.
554
+ *
555
+ * @param {string} module module specifier
556
+ * @returns {string|undefined} package name
557
+ */
558
+ export declare function jsPackageOfModule(module: string): string | undefined;
559
+ /**
560
+ * Attribute a JavaScript usage's module-qualified entries to the packages providing them.
561
+ *
562
+ * Each call entry with a `module` is a use of that module's package at the call's line. When
563
+ * the slice's object is an import binding (defined by a require/import naming the module),
564
+ * every call the object takes part in is a use of that package too.
565
+ *
566
+ * @param {Object} ausage usage entry of an object slice
567
+ * @param {string} fileName file of the slice
568
+ * @param {Object} purlImportsMap purl -> imported modules and symbols
569
+ * @param {Object} purlLocationMap purl -> Set of `file#line`
570
+ */
571
+ export declare function attributeJsModules(ausage: Object, fileName: string, purlImportsMap: Object, purlLocationMap: Object): void;
572
+ /**
573
+ * Attribute a callsites slice's records to the packages providing their modules.
574
+ *
575
+ * Each record of `{"callsites": [...]}` (atom `callsites` command) is one external use site
576
+ * carrying its own file and line; the record is an occurrence of every purl whose package
577
+ * matches the record's module.
578
+ *
579
+ * @param {Object} callsitesSlice callsites slice with a `callsites` array
580
+ * @param {Object} purlImportsMap purl -> imported modules and symbols
581
+ * @param {Object} purlLocationMap purl -> Set of `file#line`
582
+ */
583
+ export declare function attributeJsCallsites(callsitesSlice: Object, purlImportsMap: Object, purlLocationMap: Object): void;
529
584
  //# sourceMappingURL=evinser.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"evinser.d.ts","sourceRoot":"","sources":["../../../lib/evinser/evinser.js"],"names":[],"mappings":"AA8HA;;;;;;;;;;GAUG;AACH,wBAAgB,+BAA+B,CAC7C,SAAS,EAJA,MAIA,EACT,kBAAkB,GAJT,MAAM,EAIQ,QAkBxB;AAyBD;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,uBAAuB,CAAC,OAAO,EALpC,MAKoC,EAAE,OAAO,AAJrD,CACA,EADQ,MAI6C,EAAE,OAAO,AAH9D,CACA,EADQ,MAG2D,GAFzD,MAAM,GAAC,SAAS,CAyC5B;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAL/B,MAK+B,EAAE,IAAI,EAJrC,MAIqC,EAAE,KAAK,EAH5C,MAG4C,GAF1C,MAAM,CA2ClB;AAED;;;;GAIG;AACH,wBAAsB,SAAS,CAAC,OAAO,EAF5B,MAE4B;;;;;;;eAuDtC;AAED;;;;;;;;GAQG;AACH,wBAAgB,gBAAgB,CAAC,OAAO,EAJ7B,MAI6B,EAAE,OAAO,AAH9C,CACA,EADQ,MAG2C,GAFzC,MAAM,GAAC,SAAS,CAqB5B;AAED;;;;;;;;;;;;;;GAcG;AACH,w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c,EALL,MAKK,EACd,eAAe,EALN,MAKM,QAehB"}
@@ -49,6 +49,13 @@ export declare function splitAtomCommand(command: string): [string, string | und
49
49
  * @returns {Set<string>} Supported keys
50
50
  */
51
51
  export declare function atomFrontendArgKeys(language: string): Set<string>;
52
+ /**
53
+ * The options the installed atom accepts, as `atom --help` lists them. Asked
54
+ * once per atom command. An atom that fails to start accepts none.
55
+ *
56
+ * @returns {Set<string>} Supported options, such as `--bom-file`
57
+ */
58
+ export declare function atomOptions(): Set<string>;
52
59
  /**
53
60
  * The `--frontend-args` atom takes for a C/C++ language: the project's
54
61
  * compilation database, when there is one and the installed atom reads it
@@ -61,6 +68,18 @@ export declare function atomFrontendArgKeys(language: string): Set<string>;
61
68
  * @returns {string[]} Arguments to add to the atom command
62
69
  */
63
70
  export declare function atomCompileCommandsArgs(src: string, language: string, options?: Object): string[];
71
+ /**
72
+ * The `--bom-file` a reachables slice takes package purls from: the BOM evinse
73
+ * annotates. atom would otherwise only find a BOM saved as `bom.json` inside
74
+ * the scanned directory, so a BOM written anywhere else gave every reachable
75
+ * flow no purl. An atom without `--bom-file` is given the arguments it has
76
+ * always been given, and still reads a `bom.json` in the scanned directory.
77
+ *
78
+ * @param {string} sliceType atom slice command
79
+ * @param {Object} options CLI options, for `input`
80
+ * @returns {string[]} Arguments to add to the atom command
81
+ */
82
+ export declare function atomBomFileArgs(sliceType: string, options?: Object): string[];
64
83
  /**
65
84
  * The arguments that stop atom's Java frontend from running the scanned
66
85
  * project's build. In its default delombok mode, atom runs
@@ -1 +1 @@
1
- {"version":3,"file":"atomUtils.d.ts","sourceRoot":"","sources":["../../../lib/inventory/atomUtils.js"],"names":[],"mappings":"AAkEA;;;GAGG;AACH,eAAO,MAAM,oBAAoB,aAM/B,CAAC;AA2CH;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,mBAAmB,CAAC,GAAG,EAJ5B,MAI4B,EAAE,OAAO,GAHrC,MAG0C,GAFxC,MAAM,GAAC,SAAS,CA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C,MAAM,GAAC,SAKyB,EAAE,SAAS,EAJ3C,MAI2C,EAAE,OAAO,AAH5D,CACA,EADQ,MAGiE,GAF/D,MAAM,EAAE,CAIpB;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,eAAe,CAAC,MAAM,EAL3B,MAK2B,EAAE,SAAS,EAJtC,MAIsC,EAAE,aAAa,EAHrD,MAGqD,GAFnD,OAAO,CAiBnB;AAeD;;;;;;;;;;;;GAYG;AACH,wBAAgB,WAAW,CAAC,GAAG,EALpB,MAKoB,EAAE,IAAI,EAJ1B,MAAM,EAIoB,EAAE,SAAS,GAHrC,MAG0C,GAFxC,OAAO,CA0KnB;AAID;;;;;;;;;;;GAWG;AACH,wBAAgB,oBAAoB,CAAC,UAAU,EAHpC,MAGoC,GAFlC,MAAM,EAAE,CAwBpB;AAcD;;;;;GAKG;AACH,wBAAgB,0BAA0B,CAAC,UAAU,EAF1C,MAE0C,QAQpD;AAED;;;;;;;;;GASG;AACH,wBAAgB,cAAc,CAAC,UAAU,EAJ9B,MAI8B,EAAE,SAAS,EAHzC,MAGyC,GAFvC,GAAC,CAcb;AAED;;;;;;;;;GASG;AACH,wBAAgB,oBAAoB,CAAC,UAAU,EAHpC,MAGoC,GAFlC,MAAM,EAAE,GAAC,MAAM,GAAC,SAAS,CAwBrC;AAED;;;;;;;;;GASG;AACH,wBAAgB,cAAc,CAC5B,GAAG,EARM,MAQN,EACH,QAAQ,EARC,MAQD,EACR,WAAW,GARF,MAQa,EACtB,UAAU,GARD,MAQa,EACtB,OAAO,GARE,MAQG,OA8Cb"}
@@ -0,0 +1,58 @@
1
+ import { MAX_BROTLI_PROBE_BYTES, MAX_BROTLI_PROBES, readBrotliDecoder } from "../core/brotliProbe.js";
2
+ export { MAX_BROTLI_PROBE_BYTES, MAX_BROTLI_PROBES, readBrotliDecoder };
3
+ /**
4
+ * The properties a file component carries once it has been probed: the fix
5
+ * state of each decoder found in it, or why it could not be read.
6
+ *
7
+ * @param {Object} decoder result of readBrotliDecoder
8
+ * @returns {{name: string, value: string}[]} properties to append
9
+ */
10
+ export declare function brotliDecoderProperties(decoder: Object): {
11
+ name: string;
12
+ value: string;
13
+ }[];
14
+ /**
15
+ * The library component every embedded decoder links to. It has no version:
16
+ * no build records one, and only the per-file cdx:brotli:*:blockSwitchFix
17
+ * properties say whether a copy is vulnerable. The `vcs_url` qualifier names
18
+ * the project and keeps the identity apart from an unpackaged `brotli`
19
+ * executable, which is `pkg:generic/brotli`. The purl has no namespace: a
20
+ * `pkg:github` purl is typed as an application and `pkg:generic/google` as a
21
+ * framework when the BOM is assembled, and this is neither.
22
+ *
23
+ * @returns {Object} component with `purl` and `bom-ref`
24
+ */
25
+ export declare function createBrotliComponent(): Object;
26
+ /**
27
+ * Start collecting the decoder copies of one scan.
28
+ *
29
+ * @returns {{component: Object|undefined, dependencies: Object[], copies: number, unpatched: number, unknown: number}}
30
+ */
31
+ export declare function createBrotliInventory(): {
32
+ component: Object | undefined;
33
+ dependencies: Object[];
34
+ copies: number;
35
+ unpatched: number;
36
+ unknown: number;
37
+ };
38
+ /**
39
+ * Tag a probed file component and, when it holds a decoder, link it to the
40
+ * shared brotli component, creating that component on first use. Mutates the
41
+ * file component in place.
42
+ *
43
+ * @param {Object} inventory accumulator from createBrotliInventory
44
+ * @param {Object} fileComponent file component with a `properties` array
45
+ * @param {Object} decoder result of readBrotliDecoder
46
+ */
47
+ export declare function attachBrotliDecoder(inventory: Object, fileComponent: Object, decoder: Object): void;
48
+ /**
49
+ * Finish an inventory: record the copy counts on the brotli component.
50
+ *
51
+ * @param {Object} inventory accumulator from createBrotliInventory
52
+ * @returns {{components: Object[], dependencies: Object[]}} what to add to the BOM
53
+ */
54
+ export declare function finishBrotliInventory(inventory: Object): {
55
+ components: Object[];
56
+ dependencies: Object[];
57
+ };
58
+ //# sourceMappingURL=brotliDecoder.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"brotliDecoder.d.ts","sourceRoot":"","sources":["../../../lib/inventory/brotliDecoder.js"],"names":[],"mappings":"AAIA,OAAO,EACL,sBAAsB,EACtB,iBAAiB,EACjB,iBAAiB,EAClB,MAAM,wBAAwB,CAAC;AAGhC,OAAO,EAAE,sBAAsB,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,CAAC;AAExE;;;;;;GAMG;AACH,wBAAgB,uBAAuB,CAAC,OAAO,EAHpC,MAGoC,GAFlC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAC,EAAE,CAoB3C;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,qBAAqB,IAFxB,MAAM,CAiBlB;AAED;;;;GAIG;AACH,wBAAgB,qBAAqB,IAFxB;IAAC,SAAS,EAAE,MAAM,GAAC,SAAS,CAAC;IAAC,YAAY,EAAE,MAAM,EAAE,CAAC;IAAC,MAAM,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAC,CAUrH;AAED;;;;;;;;GAQG;AACH,wBAAgB,mBAAmB,CAAC,SAAS,EAJlC,MAIkC,EAAE,aAAa,EAHjD,MAGiD,EAAE,OAAO,EAF1D,MAE0D,QAyBpE;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,CAAC,SAAS,EAHpC,MAGoC,GAFlC;IAAC,UAAU,EAAE,MAAM,EAAE,CAAC;IAAC,YAAY,EAAE,MAAM,EAAE,CAAA;CAAC,CAkB1D"}
@@ -30,6 +30,23 @@ export declare function collectDosaiCryptoComponents(src: string, options?: obje
30
30
  /**
31
31
  * Find crypto algorithm in the given code snippet
32
32
  *
33
+ * cleanStr fuses the snippet's identifiers into one lowercase string
34
+ * (`prepare_for_save(iv` becomes `prepareforsaveiv`), so a plain substring
35
+ * test reads short algorithm names inside unrelated identifiers (`rsa` in
36
+ * `for_save`). A name therefore matches only where a cleanStr word begins:
37
+ * the snippet's start, right after any character cleanStr strips or keeps as
38
+ * a separator, or at a lowercase-to-uppercase change in the original text
39
+ * (`SHA256withRSA`, `HmacSHA256`, `PBKDF2WithHmacSHA256`,
40
+ * `generateRsaKeyPair`). Boundaries are computed from the original string
41
+ * before it is lowercased, so case changes survive the cleanStr fusion.
42
+ * Letter/digit changes do not start a word: they added no match on any
43
+ * reviewed form or corpus snippet, while splitting every digit-bearing
44
+ * identifier (`md5`, `base64`) into false word starts. Fused forms the names
45
+ * themselves are written in still match: `algorithms.AES(key)` and
46
+ * `AESGCM(key)` yield `aes`, `AES-256-GCM` yields `aes256-GCM`,
47
+ * `createHash("sha256")` yields `sha-256`. All-uppercase fused forms
48
+ * (`HMACSHA256`) still hide every name but the run's first.
49
+ *
33
50
  * @param {string} code Code snippet
34
51
  * @returns {Array} Arary of crypto algorithm objects with oid and description
35
52
  */
@@ -1 +1 @@
1
- {"version":3,"file":"cbomutils.d.ts","sourceRoot":"","sources":["../../../lib/inventory/cbomutils.js"],"names":[],"mappings":"AAqBA;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,OAAO,EAHhC,MAGgC,EAAE,gBAAgB,KAAA,SAiC5D;AAiXD;;;;;;;;GAQG;AACH,wBAAsB,6BAA6B,CAAC,GAAG,EAL5C,MAK4C,EAAE,OAAO,AAJ7D,CAEA,EADA;IAA0B,IAAI,AAA9B,CACA,EADQ,OAAO,CACf;CAEkE,GAFxD,OAAO,CAAC,MAAM,EAAE,CAAC,CAkD7B;AAED;;;;;;;;GAQG;AACH,wBAAsB,4BAA4B,CAAC,GAAG,EAJ3C,MAI2C,EAAE,OAAO,AAH5D,CACA,EADQ,MAGyD,GAFvD,OAAO,CAAC,MAAM,EAAE,CAAC,CAuG7B;AAED;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAHzB,MAGyB,SAanC"}
1
+ {"version":3,"file":"cbomutils.d.ts","sourceRoot":"","sources":["../../../lib/inventory/cbomutils.js"],"names":[],"mappings":"AAqBA;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,OAAO,EAHhC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,OAAO,EAPE,MAOF,EACP,WAAW,EAPF,MAOE,EACX,eAAe,GAPN,MAOgB,GALd,OAAO,CAAC,MAAM,GAAC,SAAS,CAAC,CA4CrC;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAsB,sBAAsB,CAC1C,OAAO,EARE,MAQF,EACP,YAAY,EARH,MAQG,EACZ,EAAE,eAAyB,EAAE,aAA+B,EAAE,AAR7D,CAGA,EAFA;IAAsB,eAAe,AAArC,CACA,EADQ,MAAM,CACd;IAAsB,aAAa,AAAnC,CACA,EADQ,MAAM,CACd;CAKkE,GALxD,OAAO,CAAC,KAAK,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAC,CAAC,CAAC,CAkDxD;AAED;;;;;;GAMG;AACH,wBAAsB,aAAa,CAAC,OAAO,EAJhC,MAIgC,gBAqE1C;AAED;;;;;;;;;GASG;AACH,wBAAgB,WAAW,CAAC,eAAe,EANhC,MAMgC,EAAE,OAAO,EALzC,MAAM,EAKmC,EAAE,cAAc,EAJzD,MAIyD,EAAE,CAAC,EAH5D,MAG4D,GAF1D,IAAI,CAqDhB;AAED;;;;;;;;;GASG;AACH,wBAAgB,eAAe,CAAC,CAAC,EAJtB,MAAM,GAAC,MAIe,EAAE,CAAC,EAHzB,MAAM,GAAC,MAGkB,GAFvB,MAAM,CAWlB"}
@@ -128,24 +128,40 @@ export declare function dosaiReportFileOmittedSections(reportFile: string): stri
128
128
  * @returns {string[]} The ones cdxgen reads
129
129
  */
130
130
  export declare function dosaiSectionsCdxgenReads(omittedSections: string[]): string[];
131
+ /**
132
+ * The largest number of distinct method calls cdxgen keeps from one report.
133
+ *
134
+ * Reports in the millions of calls repeat the same call sites heavily, so the
135
+ * aggregated rows stay far below this; the cap exists so a report whose calls
136
+ * are all distinct degrades the occurrence evidence instead of the process.
137
+ *
138
+ * @returns {number} Cap on distinct kept rows
139
+ */
140
+ export declare function maxDosaiMethodCalls(): number;
131
141
  /**
132
142
  * Read a dosai methods report of any size.
133
143
  *
134
144
  * A report that fits in one JavaScript string is parsed whole. A larger one is
135
145
  * read in bounded runs, keeping the requested sections, the CallGraph nodes and
136
146
  * edges that PackageReachability references, and the MethodCalls accepted by
137
- * `keepMethodCall` (none when it is omitted). Nothing cdxgen reads is lost.
147
+ * `keepMethodCall` (none when it is omitted). A kept MethodCalls row is
148
+ * reduced to the fields cdxgen reads and aggregated by them, so a call site
149
+ * reached many times is held once with a `CallCount`; distinct rows past
150
+ * {@link maxDosaiMethodCalls} are dropped with one warning. Nothing cdxgen
151
+ * reads is lost.
138
152
  *
139
153
  * @param {string} reportFile Path to the dosai methods JSON
140
154
  * @param {Object} [options] Options
141
155
  * @param {string[]} [options.sections] Sections to keep from a large report (default: every section cdxgen reads)
142
156
  * @param {Function} [options.keepMethodCall] Predicate choosing the MethodCalls to keep from a large report
157
+ * @param {number} [options.maxMethodCalls] Cap on distinct kept MethodCalls, for tests
143
158
  * @param {number} [options.maxTextBytes] Largest report parsed whole, for tests
144
159
  * @returns {Object|undefined} Parsed report, or undefined when missing or invalid
145
160
  */
146
161
  export declare function readDosaiMethodsReport(reportFile: string, options?: {
147
162
  sections?: string[];
148
163
  keepMethodCall?: Function;
164
+ maxMethodCalls?: number;
149
165
  maxTextBytes?: number;
150
166
  }): Object | undefined;
151
167
  /**