cognium-dev 3.118.0 → 3.119.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.
- package/dist/cli.js +74 -7
- package/package.json +2 -2
package/dist/cli.js
CHANGED
|
@@ -20668,6 +20668,71 @@ class HtmlPlugin extends BaseLanguagePlugin {
|
|
|
20668
20668
|
}
|
|
20669
20669
|
}
|
|
20670
20670
|
|
|
20671
|
+
// ../circle-ir/dist/languages/plugins/vue.js
|
|
20672
|
+
class VuePlugin extends BaseLanguagePlugin {
|
|
20673
|
+
id = "vue";
|
|
20674
|
+
name = "Vue";
|
|
20675
|
+
extensions = [".vue"];
|
|
20676
|
+
wasmPath = "tree-sitter-html.wasm";
|
|
20677
|
+
nodeTypes = {
|
|
20678
|
+
classDeclaration: [],
|
|
20679
|
+
interfaceDeclaration: [],
|
|
20680
|
+
enumDeclaration: [],
|
|
20681
|
+
functionDeclaration: [],
|
|
20682
|
+
methodDeclaration: [],
|
|
20683
|
+
methodCall: [],
|
|
20684
|
+
functionCall: [],
|
|
20685
|
+
assignment: [],
|
|
20686
|
+
variableDeclaration: [],
|
|
20687
|
+
parameter: [],
|
|
20688
|
+
argument: [],
|
|
20689
|
+
annotation: [],
|
|
20690
|
+
decorator: [],
|
|
20691
|
+
importStatement: [],
|
|
20692
|
+
ifStatement: [],
|
|
20693
|
+
forStatement: [],
|
|
20694
|
+
whileStatement: [],
|
|
20695
|
+
tryStatement: [],
|
|
20696
|
+
returnStatement: []
|
|
20697
|
+
};
|
|
20698
|
+
detectFramework(_context) {
|
|
20699
|
+
return;
|
|
20700
|
+
}
|
|
20701
|
+
getBuiltinSources() {
|
|
20702
|
+
return [];
|
|
20703
|
+
}
|
|
20704
|
+
getBuiltinSinks() {
|
|
20705
|
+
return [];
|
|
20706
|
+
}
|
|
20707
|
+
getReceiverType(_node, _context) {
|
|
20708
|
+
return;
|
|
20709
|
+
}
|
|
20710
|
+
isStringLiteral(node) {
|
|
20711
|
+
return node.type === "attribute_value" || node.type === "quoted_attribute_value";
|
|
20712
|
+
}
|
|
20713
|
+
getStringValue(node) {
|
|
20714
|
+
if (!this.isStringLiteral(node))
|
|
20715
|
+
return;
|
|
20716
|
+
const text = node.text;
|
|
20717
|
+
if (text.startsWith('"') && text.endsWith('"') || text.startsWith("'") && text.endsWith("'")) {
|
|
20718
|
+
return text.slice(1, -1);
|
|
20719
|
+
}
|
|
20720
|
+
return text;
|
|
20721
|
+
}
|
|
20722
|
+
extractTypes(_context) {
|
|
20723
|
+
return [];
|
|
20724
|
+
}
|
|
20725
|
+
extractCalls(_context) {
|
|
20726
|
+
return [];
|
|
20727
|
+
}
|
|
20728
|
+
extractImports(_context) {
|
|
20729
|
+
return [];
|
|
20730
|
+
}
|
|
20731
|
+
extractPackage(_context) {
|
|
20732
|
+
return;
|
|
20733
|
+
}
|
|
20734
|
+
}
|
|
20735
|
+
|
|
20671
20736
|
// ../circle-ir/dist/languages/plugins/go.js
|
|
20672
20737
|
class GoPlugin extends BaseLanguagePlugin {
|
|
20673
20738
|
id = "go";
|
|
@@ -21333,6 +21398,7 @@ function registerBuiltinPlugins() {
|
|
|
21333
21398
|
registerLanguage(new RustPlugin);
|
|
21334
21399
|
registerLanguage(new BashPlugin);
|
|
21335
21400
|
registerLanguage(new HtmlPlugin);
|
|
21401
|
+
registerLanguage(new VuePlugin);
|
|
21336
21402
|
registerLanguage(new GoPlugin);
|
|
21337
21403
|
}
|
|
21338
21404
|
// ../circle-ir/dist/analysis/passes/cross-file-pass.js
|
|
@@ -35811,6 +35877,7 @@ function getNodeTypesForLanguage(language) {
|
|
|
35811
35877
|
"while_statement"
|
|
35812
35878
|
]);
|
|
35813
35879
|
case "html":
|
|
35880
|
+
case "vue":
|
|
35814
35881
|
return new Set([
|
|
35815
35882
|
"element",
|
|
35816
35883
|
"script_element",
|
|
@@ -35865,8 +35932,8 @@ async function analyze(code, filePath, language, options = {}) {
|
|
|
35865
35932
|
if (!initialized) {
|
|
35866
35933
|
await initAnalyzer(options);
|
|
35867
35934
|
}
|
|
35868
|
-
if (language === "html") {
|
|
35869
|
-
return
|
|
35935
|
+
if (language === "html" || language === "vue") {
|
|
35936
|
+
return analyzeMarkupFile(code, filePath, options, language);
|
|
35870
35937
|
}
|
|
35871
35938
|
let parseGrammar = language;
|
|
35872
35939
|
if (language === "javascript" || language === "typescript") {
|
|
@@ -36089,16 +36156,16 @@ async function analyze(code, filePath, language, options = {}) {
|
|
|
36089
36156
|
disposeTree(tree);
|
|
36090
36157
|
}
|
|
36091
36158
|
}
|
|
36092
|
-
async function
|
|
36093
|
-
logger.debug("Analyzing
|
|
36159
|
+
async function analyzeMarkupFile(code, filePath, options, language) {
|
|
36160
|
+
logger.debug("Analyzing markup file", { filePath, language, codeLength: code.length });
|
|
36094
36161
|
const tree = await parse(code, "html");
|
|
36095
36162
|
try {
|
|
36096
|
-
const meta = extractMeta(code, tree, filePath,
|
|
36163
|
+
const meta = extractMeta(code, tree, filePath, language);
|
|
36097
36164
|
const htmlParseStatus = extractParseStatus(tree);
|
|
36098
36165
|
if (htmlParseStatus.has_errors) {
|
|
36099
36166
|
logger.warn("Partial parse — IR may be incomplete", {
|
|
36100
36167
|
filePath,
|
|
36101
|
-
language
|
|
36168
|
+
language,
|
|
36102
36169
|
errorCount: htmlParseStatus.error_count,
|
|
36103
36170
|
firstErrorLine: htmlParseStatus.error_locations[0]?.line
|
|
36104
36171
|
});
|
|
@@ -36837,7 +36904,7 @@ var colors = {
|
|
|
36837
36904
|
};
|
|
36838
36905
|
|
|
36839
36906
|
// src/version.ts
|
|
36840
|
-
var version = "3.
|
|
36907
|
+
var version = "3.119.0";
|
|
36841
36908
|
|
|
36842
36909
|
// src/formatters.ts
|
|
36843
36910
|
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.
|
|
3
|
+
"version": "3.119.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.
|
|
69
|
+
"circle-ir": "^3.119.0"
|
|
70
70
|
},
|
|
71
71
|
"devDependencies": {
|
|
72
72
|
"@types/node": "^25.5.0",
|