cognium-dev 3.213.0 → 3.214.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 (2) hide show
  1. package/dist/cli.js +28 -26
  2. package/package.json +2 -2
package/dist/cli.js CHANGED
@@ -12752,31 +12752,33 @@ function findSources(calls, types, patterns, sourceLines, language) {
12752
12752
  }
12753
12753
  }
12754
12754
  const RUST_EXTRACTOR_KIND = /(?:^|::)(Json|Form|Query|Path|Extension|Multipart|Body|Bytes)(?:<|$)/;
12755
- for (const type of types) {
12756
- for (const method of type.methods) {
12757
- for (const param of method.parameters) {
12758
- if (!param.type)
12759
- continue;
12760
- const kindMatch = RUST_EXTRACTOR_KIND.exec(param.type);
12761
- if (!kindMatch)
12762
- continue;
12763
- const kind = kindMatch[1];
12764
- if (kind === "Extension")
12765
- continue;
12766
- const sourceType = kind === "Form" || kind === "Query" || kind === "Path" ? "http_param" : "http_body";
12767
- const paramLine = param.line ?? method.start_line;
12768
- const alreadyExists = sources.some((s) => s.line === paramLine && s.variable === param.name);
12769
- if (alreadyExists)
12770
- continue;
12771
- sources.push({
12772
- type: sourceType,
12773
- location: `${param.type} ${param.name} in ${method.name}`,
12774
- severity: "high",
12775
- line: paramLine,
12776
- confidence: 1,
12777
- variable: param.name,
12778
- in_method: method.name
12779
- });
12755
+ if (language === "rust") {
12756
+ for (const type of types) {
12757
+ for (const method of type.methods) {
12758
+ for (const param of method.parameters) {
12759
+ if (!param.type)
12760
+ continue;
12761
+ const kindMatch = RUST_EXTRACTOR_KIND.exec(param.type);
12762
+ if (!kindMatch)
12763
+ continue;
12764
+ const kind = kindMatch[1];
12765
+ if (kind === "Extension")
12766
+ continue;
12767
+ const sourceType = kind === "Form" || kind === "Query" || kind === "Path" ? "http_param" : "http_body";
12768
+ const paramLine = param.line ?? method.start_line;
12769
+ const alreadyExists = sources.some((s) => s.line === paramLine && s.variable === param.name);
12770
+ if (alreadyExists)
12771
+ continue;
12772
+ sources.push({
12773
+ type: sourceType,
12774
+ location: `${param.type} ${param.name} in ${method.name}`,
12775
+ severity: "high",
12776
+ line: paramLine,
12777
+ confidence: 1,
12778
+ variable: param.name,
12779
+ in_method: method.name
12780
+ });
12781
+ }
12780
12782
  }
12781
12783
  }
12782
12784
  }
@@ -47136,7 +47138,7 @@ var colors = {
47136
47138
  };
47137
47139
 
47138
47140
  // src/version.ts
47139
- var version = "3.213.0";
47141
+ var version = "3.214.0";
47140
47142
 
47141
47143
  // src/formatters.ts
47142
47144
  var LIBRARY_API_SURFACE_TAG2 = "library-api-surface:caller-responsibility";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cognium-dev",
3
- "version": "3.213.0",
3
+ "version": "3.214.0",
4
4
  "description": "Static Application Security Testing CLI for detecting security vulnerabilities via taint tracking",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -66,7 +66,7 @@
66
66
  },
67
67
  "dependencies": {
68
68
  "@cognium/project-profile-detect": "^1.1.0",
69
- "circle-ir": "^3.213.0"
69
+ "circle-ir": "^3.214.0"
70
70
  },
71
71
  "devDependencies": {
72
72
  "@types/node": "^25.5.0",