circle-ir 3.9.8 → 3.11.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/analysis/passes/broad-catch-pass.d.ts +29 -0
- package/dist/analysis/passes/broad-catch-pass.js +79 -0
- package/dist/analysis/passes/broad-catch-pass.js.map +1 -0
- package/dist/analysis/passes/cleanup-verify-pass.d.ts +28 -0
- package/dist/analysis/passes/cleanup-verify-pass.js +130 -0
- package/dist/analysis/passes/cleanup-verify-pass.js.map +1 -0
- package/dist/analysis/passes/double-close-pass.d.ts +33 -0
- package/dist/analysis/passes/double-close-pass.js +109 -0
- package/dist/analysis/passes/double-close-pass.js.map +1 -0
- package/dist/analysis/passes/missing-guard-dom-pass.d.ts +25 -0
- package/dist/analysis/passes/missing-guard-dom-pass.js +99 -0
- package/dist/analysis/passes/missing-guard-dom-pass.js.map +1 -0
- package/dist/analysis/passes/missing-override-pass.d.ts +27 -0
- package/dist/analysis/passes/missing-override-pass.js +110 -0
- package/dist/analysis/passes/missing-override-pass.js.map +1 -0
- package/dist/analysis/passes/sink-filter-pass.js +88 -9
- package/dist/analysis/passes/sink-filter-pass.js.map +1 -1
- package/dist/analysis/passes/swallowed-exception-pass.d.ts +35 -0
- package/dist/analysis/passes/swallowed-exception-pass.js +103 -0
- package/dist/analysis/passes/swallowed-exception-pass.js.map +1 -0
- package/dist/analysis/passes/taint-matcher-pass.js +6 -1
- package/dist/analysis/passes/taint-matcher-pass.js.map +1 -1
- package/dist/analysis/passes/taint-propagation-pass.js +2 -3
- package/dist/analysis/passes/taint-propagation-pass.js.map +1 -1
- package/dist/analysis/passes/unhandled-exception-pass.d.ts +34 -0
- package/dist/analysis/passes/unhandled-exception-pass.js +123 -0
- package/dist/analysis/passes/unhandled-exception-pass.js.map +1 -0
- package/dist/analysis/passes/unused-interface-method-pass.d.ts +27 -0
- package/dist/analysis/passes/unused-interface-method-pass.js +62 -0
- package/dist/analysis/passes/unused-interface-method-pass.js.map +1 -0
- package/dist/analysis/passes/use-after-close-pass.d.ts +30 -0
- package/dist/analysis/passes/use-after-close-pass.js +100 -0
- package/dist/analysis/passes/use-after-close-pass.js.map +1 -0
- package/dist/analysis/taint-matcher.d.ts +2 -1
- package/dist/analysis/taint-matcher.js +10 -5
- package/dist/analysis/taint-matcher.js.map +1 -1
- package/dist/analyzer.d.ts +12 -3
- package/dist/analyzer.js +30 -3
- package/dist/analyzer.js.map +1 -1
- package/dist/browser/circle-ir.js +1523 -18
- package/dist/core/circle-ir-core.cjs +10 -6
- package/dist/core/circle-ir-core.js +10 -6
- package/dist/graph/exception-flow-graph.d.ts +44 -0
- package/dist/graph/exception-flow-graph.js +75 -0
- package/dist/graph/exception-flow-graph.js.map +1 -0
- package/dist/graph/index.d.ts +1 -0
- package/dist/graph/index.js +1 -0
- package/dist/graph/index.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -10365,9 +10365,9 @@ var PYTHON_TAINTED_PATTERNS = [
|
|
|
10365
10365
|
{ pattern: /\brequest\.query_params\b/, sourceType: "http_param" },
|
|
10366
10366
|
{ pattern: /\brequest\.path_params\b/, sourceType: "http_param" }
|
|
10367
10367
|
];
|
|
10368
|
-
function analyzeTaint(calls, types, config = getDefaultConfig()) {
|
|
10368
|
+
function analyzeTaint(calls, types, config = getDefaultConfig(), typeHierarchy) {
|
|
10369
10369
|
const sources = findSources(calls, types, config.sources);
|
|
10370
|
-
const sinks = findSinks(calls, config.sinks);
|
|
10370
|
+
const sinks = findSinks(calls, config.sinks, typeHierarchy);
|
|
10371
10371
|
const sanitizers = findSanitizers(calls, types, config.sanitizers);
|
|
10372
10372
|
return { sources, sinks, sanitizers };
|
|
10373
10373
|
}
|
|
@@ -10573,11 +10573,11 @@ function isParameterizedQueryCall(call, pattern) {
|
|
|
10573
10573
|
}
|
|
10574
10574
|
return false;
|
|
10575
10575
|
}
|
|
10576
|
-
function findSinks(calls, patterns) {
|
|
10576
|
+
function findSinks(calls, patterns, typeHierarchy) {
|
|
10577
10577
|
const sinkMap = /* @__PURE__ */ new Map();
|
|
10578
10578
|
for (const call of calls) {
|
|
10579
10579
|
for (const pattern of patterns) {
|
|
10580
|
-
if (matchesSinkPattern(call, pattern)) {
|
|
10580
|
+
if (matchesSinkPattern(call, pattern, typeHierarchy)) {
|
|
10581
10581
|
if (isParameterizedQueryCall(call, pattern)) {
|
|
10582
10582
|
continue;
|
|
10583
10583
|
}
|
|
@@ -10591,7 +10591,8 @@ function findSinks(calls, patterns) {
|
|
|
10591
10591
|
cwe: pattern.cwe,
|
|
10592
10592
|
location,
|
|
10593
10593
|
line: call.location.line,
|
|
10594
|
-
confidence
|
|
10594
|
+
confidence,
|
|
10595
|
+
method: call.method_name
|
|
10595
10596
|
});
|
|
10596
10597
|
}
|
|
10597
10598
|
}
|
|
@@ -10668,7 +10669,7 @@ function isJavaScriptTaintedArgument(argExpression, sourcePatterns) {
|
|
|
10668
10669
|
}
|
|
10669
10670
|
return { isTainted: false, sourceType: null };
|
|
10670
10671
|
}
|
|
10671
|
-
function matchesSinkPattern(call, pattern) {
|
|
10672
|
+
function matchesSinkPattern(call, pattern, typeHierarchy) {
|
|
10672
10673
|
const callMethodName = call.method_name;
|
|
10673
10674
|
const patternMethod = pattern.method;
|
|
10674
10675
|
let methodMatches = callMethodName === patternMethod;
|
|
@@ -10684,6 +10685,9 @@ function matchesSinkPattern(call, pattern) {
|
|
|
10684
10685
|
return true;
|
|
10685
10686
|
}
|
|
10686
10687
|
if (call.receiver && !receiverMightBeClass(call.receiver, pattern.class)) {
|
|
10688
|
+
if (typeHierarchy && typeHierarchy.couldBeType(call.receiver, pattern.class)) {
|
|
10689
|
+
return true;
|
|
10690
|
+
}
|
|
10687
10691
|
return false;
|
|
10688
10692
|
}
|
|
10689
10693
|
if (!call.receiver) {
|
|
@@ -10300,9 +10300,9 @@ var PYTHON_TAINTED_PATTERNS = [
|
|
|
10300
10300
|
{ pattern: /\brequest\.query_params\b/, sourceType: "http_param" },
|
|
10301
10301
|
{ pattern: /\brequest\.path_params\b/, sourceType: "http_param" }
|
|
10302
10302
|
];
|
|
10303
|
-
function analyzeTaint(calls, types, config = getDefaultConfig()) {
|
|
10303
|
+
function analyzeTaint(calls, types, config = getDefaultConfig(), typeHierarchy) {
|
|
10304
10304
|
const sources = findSources(calls, types, config.sources);
|
|
10305
|
-
const sinks = findSinks(calls, config.sinks);
|
|
10305
|
+
const sinks = findSinks(calls, config.sinks, typeHierarchy);
|
|
10306
10306
|
const sanitizers = findSanitizers(calls, types, config.sanitizers);
|
|
10307
10307
|
return { sources, sinks, sanitizers };
|
|
10308
10308
|
}
|
|
@@ -10508,11 +10508,11 @@ function isParameterizedQueryCall(call, pattern) {
|
|
|
10508
10508
|
}
|
|
10509
10509
|
return false;
|
|
10510
10510
|
}
|
|
10511
|
-
function findSinks(calls, patterns) {
|
|
10511
|
+
function findSinks(calls, patterns, typeHierarchy) {
|
|
10512
10512
|
const sinkMap = /* @__PURE__ */ new Map();
|
|
10513
10513
|
for (const call of calls) {
|
|
10514
10514
|
for (const pattern of patterns) {
|
|
10515
|
-
if (matchesSinkPattern(call, pattern)) {
|
|
10515
|
+
if (matchesSinkPattern(call, pattern, typeHierarchy)) {
|
|
10516
10516
|
if (isParameterizedQueryCall(call, pattern)) {
|
|
10517
10517
|
continue;
|
|
10518
10518
|
}
|
|
@@ -10526,7 +10526,8 @@ function findSinks(calls, patterns) {
|
|
|
10526
10526
|
cwe: pattern.cwe,
|
|
10527
10527
|
location,
|
|
10528
10528
|
line: call.location.line,
|
|
10529
|
-
confidence
|
|
10529
|
+
confidence,
|
|
10530
|
+
method: call.method_name
|
|
10530
10531
|
});
|
|
10531
10532
|
}
|
|
10532
10533
|
}
|
|
@@ -10603,7 +10604,7 @@ function isJavaScriptTaintedArgument(argExpression, sourcePatterns) {
|
|
|
10603
10604
|
}
|
|
10604
10605
|
return { isTainted: false, sourceType: null };
|
|
10605
10606
|
}
|
|
10606
|
-
function matchesSinkPattern(call, pattern) {
|
|
10607
|
+
function matchesSinkPattern(call, pattern, typeHierarchy) {
|
|
10607
10608
|
const callMethodName = call.method_name;
|
|
10608
10609
|
const patternMethod = pattern.method;
|
|
10609
10610
|
let methodMatches = callMethodName === patternMethod;
|
|
@@ -10619,6 +10620,9 @@ function matchesSinkPattern(call, pattern) {
|
|
|
10619
10620
|
return true;
|
|
10620
10621
|
}
|
|
10621
10622
|
if (call.receiver && !receiverMightBeClass(call.receiver, pattern.class)) {
|
|
10623
|
+
if (typeHierarchy && typeHierarchy.couldBeType(call.receiver, pattern.class)) {
|
|
10624
|
+
return true;
|
|
10625
|
+
}
|
|
10622
10626
|
return false;
|
|
10623
10627
|
}
|
|
10624
10628
|
if (!call.receiver) {
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ExceptionFlowGraph — lightweight wrapper over CFG exception edges.
|
|
3
|
+
*
|
|
4
|
+
* The CFG builder emits edges with `type === 'exception'` connecting the
|
|
5
|
+
* first block of a try body (`from`) to the first block of the corresponding
|
|
6
|
+
* catch handler (`to`). This class indexes those edges so exception-aware
|
|
7
|
+
* passes can query try/catch structure without re-scanning the edge list.
|
|
8
|
+
*/
|
|
9
|
+
import type { CFG, CFGBlock } from '../types/index.js';
|
|
10
|
+
export interface TryCatchInfo {
|
|
11
|
+
tryEntryId: number;
|
|
12
|
+
catchEntryId: number;
|
|
13
|
+
/** First block of the try body. */
|
|
14
|
+
tryBlock: CFGBlock;
|
|
15
|
+
/** First block of the catch handler. */
|
|
16
|
+
catchBlock: CFGBlock;
|
|
17
|
+
}
|
|
18
|
+
export declare class ExceptionFlowGraph {
|
|
19
|
+
/** All try/catch pairs found in the CFG. */
|
|
20
|
+
readonly pairs: TryCatchInfo[];
|
|
21
|
+
/** Block IDs that are catch-handler entry blocks. */
|
|
22
|
+
readonly catchEntryIds: Set<number>;
|
|
23
|
+
/** Block IDs that are try-body entry blocks. */
|
|
24
|
+
readonly tryEntryIds: Set<number>;
|
|
25
|
+
private readonly tryCatchMap;
|
|
26
|
+
private readonly catchTryMap;
|
|
27
|
+
constructor(cfg: CFG, blockById: Map<number, CFGBlock>);
|
|
28
|
+
/** True if at least one try/catch pair was found. */
|
|
29
|
+
get hasTryCatch(): boolean;
|
|
30
|
+
/** True if the given block ID is a catch-handler entry block. */
|
|
31
|
+
isCatchEntry(blockId: number): boolean;
|
|
32
|
+
/** True if the given block ID is a try-body entry block. */
|
|
33
|
+
isTryEntry(blockId: number): boolean;
|
|
34
|
+
/**
|
|
35
|
+
* Returns the catch-entry block IDs for the given try-entry block.
|
|
36
|
+
* Multiple values mean multiple catch clauses for the same try.
|
|
37
|
+
*/
|
|
38
|
+
catchBlocksFor(tryEntryId: number): number[];
|
|
39
|
+
/**
|
|
40
|
+
* Returns the try-entry block ID corresponding to a catch-entry block,
|
|
41
|
+
* or `undefined` if the block is not a catch entry.
|
|
42
|
+
*/
|
|
43
|
+
tryBlockFor(catchEntryId: number): number | undefined;
|
|
44
|
+
}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ExceptionFlowGraph — lightweight wrapper over CFG exception edges.
|
|
3
|
+
*
|
|
4
|
+
* The CFG builder emits edges with `type === 'exception'` connecting the
|
|
5
|
+
* first block of a try body (`from`) to the first block of the corresponding
|
|
6
|
+
* catch handler (`to`). This class indexes those edges so exception-aware
|
|
7
|
+
* passes can query try/catch structure without re-scanning the edge list.
|
|
8
|
+
*/
|
|
9
|
+
// ---------------------------------------------------------------------------
|
|
10
|
+
// ExceptionFlowGraph
|
|
11
|
+
// ---------------------------------------------------------------------------
|
|
12
|
+
export class ExceptionFlowGraph {
|
|
13
|
+
/** All try/catch pairs found in the CFG. */
|
|
14
|
+
pairs;
|
|
15
|
+
/** Block IDs that are catch-handler entry blocks. */
|
|
16
|
+
catchEntryIds;
|
|
17
|
+
/** Block IDs that are try-body entry blocks. */
|
|
18
|
+
tryEntryIds;
|
|
19
|
+
tryCatchMap; // tryEntryId → [catchEntryId, …]
|
|
20
|
+
catchTryMap; // catchEntryId → tryEntryId
|
|
21
|
+
constructor(cfg, blockById) {
|
|
22
|
+
this.pairs = [];
|
|
23
|
+
this.catchEntryIds = new Set();
|
|
24
|
+
this.tryEntryIds = new Set();
|
|
25
|
+
this.tryCatchMap = new Map();
|
|
26
|
+
this.catchTryMap = new Map();
|
|
27
|
+
for (const edge of cfg.edges) {
|
|
28
|
+
if (edge.type !== 'exception')
|
|
29
|
+
continue;
|
|
30
|
+
const tryBlock = blockById.get(edge.from);
|
|
31
|
+
const catchBlock = blockById.get(edge.to);
|
|
32
|
+
if (!tryBlock || !catchBlock)
|
|
33
|
+
continue;
|
|
34
|
+
this.tryEntryIds.add(edge.from);
|
|
35
|
+
this.catchEntryIds.add(edge.to);
|
|
36
|
+
const catches = this.tryCatchMap.get(edge.from) ?? [];
|
|
37
|
+
catches.push(edge.to);
|
|
38
|
+
this.tryCatchMap.set(edge.from, catches);
|
|
39
|
+
this.catchTryMap.set(edge.to, edge.from);
|
|
40
|
+
this.pairs.push({
|
|
41
|
+
tryEntryId: edge.from,
|
|
42
|
+
catchEntryId: edge.to,
|
|
43
|
+
tryBlock,
|
|
44
|
+
catchBlock,
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
/** True if at least one try/catch pair was found. */
|
|
49
|
+
get hasTryCatch() {
|
|
50
|
+
return this.pairs.length > 0;
|
|
51
|
+
}
|
|
52
|
+
/** True if the given block ID is a catch-handler entry block. */
|
|
53
|
+
isCatchEntry(blockId) {
|
|
54
|
+
return this.catchEntryIds.has(blockId);
|
|
55
|
+
}
|
|
56
|
+
/** True if the given block ID is a try-body entry block. */
|
|
57
|
+
isTryEntry(blockId) {
|
|
58
|
+
return this.tryEntryIds.has(blockId);
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* Returns the catch-entry block IDs for the given try-entry block.
|
|
62
|
+
* Multiple values mean multiple catch clauses for the same try.
|
|
63
|
+
*/
|
|
64
|
+
catchBlocksFor(tryEntryId) {
|
|
65
|
+
return this.tryCatchMap.get(tryEntryId) ?? [];
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* Returns the try-entry block ID corresponding to a catch-entry block,
|
|
69
|
+
* or `undefined` if the block is not a catch entry.
|
|
70
|
+
*/
|
|
71
|
+
tryBlockFor(catchEntryId) {
|
|
72
|
+
return this.catchTryMap.get(catchEntryId);
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
//# sourceMappingURL=exception-flow-graph.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exception-flow-graph.js","sourceRoot":"","sources":["../../src/graph/exception-flow-graph.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAiBH,8EAA8E;AAC9E,qBAAqB;AACrB,8EAA8E;AAE9E,MAAM,OAAO,kBAAkB;IAC7B,4CAA4C;IACnC,KAAK,CAAiB;IAE/B,qDAAqD;IAC5C,aAAa,CAAc;IAEpC,gDAAgD;IACvC,WAAW,CAAc;IAEjB,WAAW,CAAwB,CAAC,iCAAiC;IACrE,WAAW,CAAsB,CAAG,4BAA4B;IAEjF,YAAY,GAAQ,EAAE,SAAgC;QACpD,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC;QAChB,IAAI,CAAC,aAAa,GAAG,IAAI,GAAG,EAAE,CAAC;QAC/B,IAAI,CAAC,WAAW,GAAG,IAAI,GAAG,EAAE,CAAC;QAC7B,IAAI,CAAC,WAAW,GAAG,IAAI,GAAG,EAAE,CAAC;QAC7B,IAAI,CAAC,WAAW,GAAG,IAAI,GAAG,EAAE,CAAC;QAE7B,KAAK,MAAM,IAAI,IAAI,GAAG,CAAC,KAAK,EAAE,CAAC;YAC7B,IAAI,IAAI,CAAC,IAAI,KAAK,WAAW;gBAAE,SAAS;YAExC,MAAM,QAAQ,GAAG,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;YAC1C,MAAM,UAAU,GAAG,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;YAC1C,IAAI,CAAC,QAAQ,IAAI,CAAC,UAAU;gBAAE,SAAS;YAEvC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;YAChC,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;YAEhC,MAAM,OAAO,GAAG,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC;YACtD,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;YACtB,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;YAEzC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC;YAEzC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC;gBACd,UAAU,EAAE,IAAI,CAAC,IAAI;gBACrB,YAAY,EAAE,IAAI,CAAC,EAAE;gBACrB,QAAQ;gBACR,UAAU;aACX,CAAC,CAAC;QACL,CAAC;IACH,CAAC;IAED,qDAAqD;IACrD,IAAI,WAAW;QACb,OAAO,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC;IAC/B,CAAC;IAED,iEAAiE;IACjE,YAAY,CAAC,OAAe;QAC1B,OAAO,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;IACzC,CAAC;IAED,4DAA4D;IAC5D,UAAU,CAAC,OAAe;QACxB,OAAO,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;IACvC,CAAC;IAED;;;OAGG;IACH,cAAc,CAAC,UAAkB;QAC/B,OAAO,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,UAAU,CAAC,IAAI,EAAE,CAAC;IAChD,CAAC;IAED;;;OAGG;IACH,WAAW,CAAC,YAAoB;QAC9B,OAAO,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,YAAY,CAAC,CAAC;IAC5C,CAAC;CACF"}
|
package/dist/graph/index.d.ts
CHANGED
|
@@ -2,4 +2,5 @@ export { CodeGraph } from './code-graph.js';
|
|
|
2
2
|
export { ProjectGraph } from './project-graph.js';
|
|
3
3
|
export { ImportGraph } from './import-graph.js';
|
|
4
4
|
export { DominatorGraph } from './dominator-graph.js';
|
|
5
|
+
export { ExceptionFlowGraph, type TryCatchInfo } from './exception-flow-graph.js';
|
|
5
6
|
export { AnalysisPipeline, type AnalysisPass, type PassContext, type PipelineRunResult, } from './analysis-pass.js';
|
package/dist/graph/index.js
CHANGED
|
@@ -2,5 +2,6 @@ export { CodeGraph } from './code-graph.js';
|
|
|
2
2
|
export { ProjectGraph } from './project-graph.js';
|
|
3
3
|
export { ImportGraph } from './import-graph.js';
|
|
4
4
|
export { DominatorGraph } from './dominator-graph.js';
|
|
5
|
+
export { ExceptionFlowGraph } from './exception-flow-graph.js';
|
|
5
6
|
export { AnalysisPipeline, } from './analysis-pass.js';
|
|
6
7
|
//# sourceMappingURL=index.js.map
|
package/dist/graph/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/graph/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EACL,gBAAgB,GAIjB,MAAM,oBAAoB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/graph/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,kBAAkB,EAAqB,MAAM,2BAA2B,CAAC;AAClF,OAAO,EACL,gBAAgB,GAIjB,MAAM,oBAAoB,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -11,6 +11,7 @@ export { extractMeta, extractTypes, extractCalls, extractImports, extractExports
|
|
|
11
11
|
export { getDefaultConfig, createTaintConfig, analyzeTaint, detectUnresolved, propagateTaint, generateFindings, analyzeConstantPropagation, ConstantPropagator, isKnown, createUnknown, getNodeLine, DEFAULT_SOURCES, DEFAULT_SINKS, DEFAULT_SANITIZERS, type ConstantValue, type ConstantPropagatorResult, type TaintPropagationResult, type TaintedVariable, type TaintFlow, } from './analysis/index.js';
|
|
12
12
|
export { getRuleInfo, RULE_DEFINITIONS, type RuleInfo, } from './analysis/rules.js';
|
|
13
13
|
export { DominatorGraph } from './graph/dominator-graph.js';
|
|
14
|
+
export { ExceptionFlowGraph, type TryCatchInfo } from './graph/exception-flow-graph.js';
|
|
14
15
|
export { TypeHierarchyResolver, createWithJdkTypes, SymbolTable, buildSymbolTable, CrossFileResolver, buildCrossFileResolver, } from './resolution/index.js';
|
|
15
16
|
export { getLanguageRegistry, registerLanguage, getLanguagePlugin, getLanguageForFile, detectLanguage, isLanguageSupported, registerBuiltinPlugins, JavaPlugin, JavaScriptPlugin, PythonPlugin, RustPlugin, BaseLanguagePlugin, } from './languages/index.js';
|
|
16
17
|
export type { LanguagePlugin, LanguageRegistry, LanguageNodeTypes, ExtractionContext, FrameworkInfo, TaintSourcePattern, TaintSinkPattern, } from './languages/index.js';
|
package/dist/index.js
CHANGED
|
@@ -15,6 +15,7 @@ export { getDefaultConfig, createTaintConfig, analyzeTaint, detectUnresolved, pr
|
|
|
15
15
|
export { getRuleInfo, RULE_DEFINITIONS, } from './analysis/rules.js';
|
|
16
16
|
// Graph utilities
|
|
17
17
|
export { DominatorGraph } from './graph/dominator-graph.js';
|
|
18
|
+
export { ExceptionFlowGraph } from './graph/exception-flow-graph.js';
|
|
18
19
|
// Resolution utilities
|
|
19
20
|
export { TypeHierarchyResolver, createWithJdkTypes, SymbolTable, buildSymbolTable, CrossFileResolver, buildCrossFileResolver, } from './resolution/index.js';
|
|
20
21
|
// Language plugins
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,gBAAgB;AAChB,OAAO,EACL,YAAY,EACZ,OAAO,EACP,aAAa,EACb,cAAc,EACd,qBAAqB,EACrB,aAAa,GAEd,MAAM,eAAe,CAAC;AAuEvB,sCAAsC;AACtC,OAAO,EACL,UAAU,EACV,KAAK,EACL,QAAQ,EACR,SAAS,EACT,YAAY,EACZ,WAAW,EACX,eAAe,GAMhB,MAAM,iBAAiB,CAAC;AAEzB,kBAAkB;AAClB,OAAO,EACL,WAAW,EACX,YAAY,EACZ,YAAY,EACZ,cAAc,EACd,cAAc,EACd,QAAQ,EACR,QAAQ,GACT,MAAM,iBAAiB,CAAC;AAEzB,qBAAqB;AACrB,OAAO,EACL,gBAAgB,EAChB,iBAAiB,EACjB,YAAY,EACZ,gBAAgB,EAChB,cAAc,EACd,gBAAgB,EAChB,0BAA0B,EAC1B,kBAAkB,EAClB,OAAO,EACP,aAAa,EACb,WAAW,EACX,eAAe,EACf,aAAa,EACb,kBAAkB,GAMnB,MAAM,qBAAqB,CAAC;AAE7B,mBAAmB;AACnB,OAAO,EACL,WAAW,EACX,gBAAgB,GAEjB,MAAM,qBAAqB,CAAC;AAE7B,kBAAkB;AAClB,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,gBAAgB;AAChB,OAAO,EACL,YAAY,EACZ,OAAO,EACP,aAAa,EACb,cAAc,EACd,qBAAqB,EACrB,aAAa,GAEd,MAAM,eAAe,CAAC;AAuEvB,sCAAsC;AACtC,OAAO,EACL,UAAU,EACV,KAAK,EACL,QAAQ,EACR,SAAS,EACT,YAAY,EACZ,WAAW,EACX,eAAe,GAMhB,MAAM,iBAAiB,CAAC;AAEzB,kBAAkB;AAClB,OAAO,EACL,WAAW,EACX,YAAY,EACZ,YAAY,EACZ,cAAc,EACd,cAAc,EACd,QAAQ,EACR,QAAQ,GACT,MAAM,iBAAiB,CAAC;AAEzB,qBAAqB;AACrB,OAAO,EACL,gBAAgB,EAChB,iBAAiB,EACjB,YAAY,EACZ,gBAAgB,EAChB,cAAc,EACd,gBAAgB,EAChB,0BAA0B,EAC1B,kBAAkB,EAClB,OAAO,EACP,aAAa,EACb,WAAW,EACX,eAAe,EACf,aAAa,EACb,kBAAkB,GAMnB,MAAM,qBAAqB,CAAC;AAE7B,mBAAmB;AACnB,OAAO,EACL,WAAW,EACX,gBAAgB,GAEjB,MAAM,qBAAqB,CAAC;AAE7B,kBAAkB;AAClB,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAC5D,OAAO,EAAE,kBAAkB,EAAqB,MAAM,iCAAiC,CAAC;AAExF,uBAAuB;AACvB,OAAO,EACL,qBAAqB,EACrB,kBAAkB,EAClB,WAAW,EACX,gBAAgB,EAChB,iBAAiB,EACjB,sBAAsB,GACvB,MAAM,uBAAuB,CAAC;AAE/B,mBAAmB;AACnB,OAAO,EACL,mBAAmB,EACnB,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,cAAc,EACd,mBAAmB,EACnB,sBAAsB,EACtB,UAAU,EACV,gBAAgB,EAChB,YAAY,EACZ,UAAU,EACV,kBAAkB,GACnB,MAAM,sBAAsB,CAAC;AAY9B,gCAAgC;AAChC,OAAO,EACL,MAAM,EACN,SAAS,EACT,eAAe,EACf,WAAW,EACX,WAAW,GAIZ,MAAM,mBAAmB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "circle-ir",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.11.0",
|
|
4
4
|
"description": "High-performance Static Application Security Testing (SAST) library for detecting security vulnerabilities through taint analysis",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.js",
|