circle-ir 4.9.26 → 4.9.28
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/config-loader.d.ts.map +1 -1
- package/dist/analysis/config-loader.js +23 -3
- package/dist/analysis/config-loader.js.map +1 -1
- package/dist/analysis/findings.d.ts.map +1 -1
- package/dist/analysis/findings.js +154 -0
- package/dist/analysis/findings.js.map +1 -1
- package/dist/analysis/interprocedural.d.ts.map +1 -1
- package/dist/analysis/interprocedural.js +63 -0
- package/dist/analysis/interprocedural.js.map +1 -1
- package/dist/analysis/passes/language-sources-pass.d.ts.map +1 -1
- package/dist/analysis/passes/language-sources-pass.js +156 -4
- package/dist/analysis/passes/language-sources-pass.js.map +1 -1
- package/dist/analysis/passes/taint-propagation-pass.d.ts.map +1 -1
- package/dist/analysis/passes/taint-propagation-pass.js +97 -4
- package/dist/analysis/passes/taint-propagation-pass.js.map +1 -1
- package/dist/analysis/passes/variable-shadowing-pass.d.ts.map +1 -1
- package/dist/analysis/passes/variable-shadowing-pass.js +15 -0
- package/dist/analysis/passes/variable-shadowing-pass.js.map +1 -1
- package/dist/analysis/taint-matcher.d.ts.map +1 -1
- package/dist/analysis/taint-matcher.js +21 -1
- package/dist/analysis/taint-matcher.js.map +1 -1
- package/dist/analyzer.d.ts +36 -0
- package/dist/analyzer.d.ts.map +1 -1
- package/dist/analyzer.js +30 -0
- package/dist/analyzer.js.map +1 -1
- package/dist/browser/circle-ir.js +360 -13
- package/dist/core/circle-ir-core.cjs +94 -5
- package/dist/core/circle-ir-core.js +94 -5
- package/dist/core/extractors/calls.js +127 -1
- package/dist/core/extractors/calls.js.map +1 -1
- package/dist/types/index.d.ts +17 -0
- package/dist/types/index.d.ts.map +1 -1
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-loader.d.ts","sourceRoot":"","sources":["../../src/analysis/config-loader.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EACV,YAAY,EACZ,UAAU,EACV,mBAAmB,EACnB,kBAAkB,EAClB,WAAW,EACX,aAAa,EACb,WAAW,EACX,gBAAgB,EAChB,UAAU,EACX,MAAM,oBAAoB,CAAC;AAE5B;;;GAGG;AACH,wBAAgB,WAAW,CAAC,CAAC,EAAE,OAAO,EAAE,MAAM,GAAG,CAAC,CAEjD;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,YAAY,EAAE,GAAG,aAAa,EAAE,CAiB1E;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,OAAO,EAAE,UAAU,EAAE,GAAG;IACtD,KAAK,EAAE,WAAW,EAAE,CAAC;IACrB,UAAU,EAAE,gBAAgB,EAAE,CAAC;CAChC,CAcA;AAED;;;;;GAKG;AACH,wBAAgB,wBAAwB,CACtC,OAAO,EAAE,mBAAmB,EAAE,GAC7B,kBAAkB,EAAE,CAQtB;AAED;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAC/B,cAAc,EAAE,MAAM,EAAE,EACxB,YAAY,EAAE,MAAM,EAAE,EACtB,qBAAqB,GAAE,MAAM,EAAO,GACnC,WAAW,CAYb;AAED;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAE,aAAa,EAwzB1C,CAAC;AA+KF,eAAO,MAAM,aAAa,EAAE,WAAW,
|
|
1
|
+
{"version":3,"file":"config-loader.d.ts","sourceRoot":"","sources":["../../src/analysis/config-loader.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EACV,YAAY,EACZ,UAAU,EACV,mBAAmB,EACnB,kBAAkB,EAClB,WAAW,EACX,aAAa,EACb,WAAW,EACX,gBAAgB,EAChB,UAAU,EACX,MAAM,oBAAoB,CAAC;AAE5B;;;GAGG;AACH,wBAAgB,WAAW,CAAC,CAAC,EAAE,OAAO,EAAE,MAAM,GAAG,CAAC,CAEjD;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,YAAY,EAAE,GAAG,aAAa,EAAE,CAiB1E;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,OAAO,EAAE,UAAU,EAAE,GAAG;IACtD,KAAK,EAAE,WAAW,EAAE,CAAC;IACrB,UAAU,EAAE,gBAAgB,EAAE,CAAC;CAChC,CAcA;AAED;;;;;GAKG;AACH,wBAAgB,wBAAwB,CACtC,OAAO,EAAE,mBAAmB,EAAE,GAC7B,kBAAkB,EAAE,CAQtB;AAED;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAC/B,cAAc,EAAE,MAAM,EAAE,EACxB,YAAY,EAAE,MAAM,EAAE,EACtB,qBAAqB,GAAE,MAAM,EAAO,GACnC,WAAW,CAYb;AAED;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAE,aAAa,EAwzB1C,CAAC;AA+KF,eAAO,MAAM,aAAa,EAAE,WAAW,EA8nEtC,CAAC;AAEF,eAAO,MAAM,kBAAkB,EAAE,gBAAgB,EAgjBhD,CAAC;AAEF;;;;;;;;;GASG;AACH,eAAO,MAAM,sBAAsB,EAAE,kBAAkB,EAiDtD,CAAC;AAEF;;GAEG;AACH,wBAAgB,gBAAgB,IAAI,WAAW,CAO9C;AAMD;;;;;;;;GAQG;AACH,eAAO,MAAM,oBAAoB,EAAE,UAAU,EA8F5C,CAAC"}
|
|
@@ -2422,9 +2422,14 @@ export const DEFAULT_SINKS = [
|
|
|
2422
2422
|
{ method: 'deserialize', class: 'bincode', type: 'deserialization', cwe: 'CWE-502', severity: 'critical', arg_positions: [0] },
|
|
2423
2423
|
{ method: 'from_str', class: 'toml', type: 'deserialization', cwe: 'CWE-502', severity: 'high', arg_positions: [0] },
|
|
2424
2424
|
{ method: 'from_str', class: 'ron', type: 'deserialization', cwe: 'CWE-502', severity: 'high', arg_positions: [0] },
|
|
2425
|
-
//
|
|
2426
|
-
|
|
2427
|
-
|
|
2425
|
+
// #294/#484: no classless `from_str` / `from_slice` deserialization sink.
|
|
2426
|
+
// Those rows matched EVERY `T::from_str` / `from_slice` — `u32::from_str`,
|
|
2427
|
+
// `Url::from_str`, `PublicKey::from_slice` — i.e. ordinary `FromStr` / byte
|
|
2428
|
+
// parsing, which cannot instantiate an attacker-chosen type. Removing them
|
|
2429
|
+
// was previously blocked because the class-scoped rows below could not match
|
|
2430
|
+
// the IMPORTED call form (`use serde_json::from_str; from_str(&body)`); the
|
|
2431
|
+
// `::` path-separator fix in taint-matcher.ts makes them match, so the
|
|
2432
|
+
// classless rows are no longer load-bearing.
|
|
2428
2433
|
// Rust XSS (actix-web, rocket, axum response body)
|
|
2429
2434
|
{ method: 'body', class: 'HttpResponseBuilder', type: 'xss', cwe: 'CWE-79', severity: 'high', arg_positions: [0] },
|
|
2430
2435
|
{ method: 'body', class: 'HttpResponse', type: 'xss', cwe: 'CWE-79', severity: 'high', arg_positions: [0] },
|
|
@@ -2820,10 +2825,19 @@ export const DEFAULT_SINKS = [
|
|
|
2820
2825
|
// C# XSS — raw HTML output (CWE-79).
|
|
2821
2826
|
{ method: 'Raw', class: 'Html', type: 'xss', cwe: 'CWE-79', severity: 'high', arg_positions: [0], languages: ['csharp'] },
|
|
2822
2827
|
{ method: 'Write', class: 'Response', type: 'xss', cwe: 'CWE-79', severity: 'high', arg_positions: [0], languages: ['csharp'] },
|
|
2828
|
+
// ASP.NET Core writes the response body through the `HttpResponseWritingExtensions`
|
|
2829
|
+
// extension methods rather than `Response.Write`, so the System.Web row above does
|
|
2830
|
+
// not cover it. Receiver-scoped to `Response` so the many unrelated `WriteAsync`
|
|
2831
|
+
// overloads (Stream, StreamWriter, TextWriter, PipeWriter) are untouched. (#503)
|
|
2832
|
+
{ method: 'WriteAsync', class: 'Response', type: 'xss', cwe: 'CWE-79', severity: 'high', arg_positions: [0], languages: ['csharp'] },
|
|
2823
2833
|
{ method: 'HtmlString', type: 'xss', cwe: 'CWE-79', severity: 'high', arg_positions: [0], languages: ['csharp'] },
|
|
2824
2834
|
// Blazor `new MarkupString(x)` renders its argument as raw HTML (the framework's
|
|
2825
2835
|
// documented "trusted markup" escape hatch) — attacker-controlled input is XSS. (ca#275)
|
|
2826
2836
|
{ method: 'MarkupString', class: 'constructor', type: 'xss', cwe: 'CWE-79', severity: 'high', arg_positions: [0], languages: ['csharp'] },
|
|
2837
|
+
// #503 (part 1): `Response.StatusDescription = "Bad " + data` writes
|
|
2838
|
+
// attacker text into the HTTP status line (CWE-81). Surfaced by the
|
|
2839
|
+
// property-assignment synthesiser in the C# extractor, receiver-gated there.
|
|
2840
|
+
{ method: 'StatusDescription', class: 'Response', type: 'xss', cwe: 'CWE-81', severity: 'medium', arg_positions: [0], languages: ['csharp'] },
|
|
2827
2841
|
// `return Content(html, "text/html")` on a controller writes arg 0 to the
|
|
2828
2842
|
// response body unescaped (cognium-dev#275). Taint-gated on arg 0; the common
|
|
2829
2843
|
// `Content(constantString)` and the JSON/plain-text content types are
|
|
@@ -2838,6 +2852,12 @@ export const DEFAULT_SINKS = [
|
|
|
2838
2852
|
// filter is the constructor argument.
|
|
2839
2853
|
{ method: 'DirectorySearcher', type: 'ldap_injection', cwe: 'CWE-90', severity: 'high', arg_positions: [0], languages: ['csharp'] },
|
|
2840
2854
|
{ method: 'DirectoryEntry', type: 'ldap_injection', cwe: 'CWE-90', severity: 'high', arg_positions: [0], languages: ['csharp'] },
|
|
2855
|
+
// #336: a tainted `HttpClient.BaseAddress` gives the attacker the scheme,
|
|
2856
|
+
// host and port of every RELATIVE request made on that client, so the
|
|
2857
|
+
// request arguments can all be constant and the destination still be
|
|
2858
|
+
// attacker-chosen. Surfaced by the property-assignment synthesiser, which
|
|
2859
|
+
// class-gates it to a resolved `HttpClient`.
|
|
2860
|
+
{ method: 'BaseAddress', class: 'HttpClient', type: 'ssrf', cwe: 'CWE-918', severity: 'high', arg_positions: [0], languages: ['csharp'] },
|
|
2841
2861
|
// C# open redirect — ASP.NET MVC / Minimal API redirect helpers (CWE-601,
|
|
2842
2862
|
// cognium-dev#273/#275). Classless: `return Redirect(url)` on a controller is
|
|
2843
2863
|
// an implicit-`this` call (no receiver), and `Results.Redirect(url)` /
|