Socket
Socket
Sign inDemoInstall

@appland/scanner

Package Overview
Dependencies
237
Maintainers
4
Versions
119
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.63.0 to 1.64.0

2

built/check.js

@@ -12,3 +12,3 @@ "use strict";

this.options = options || makeOptions();
this.scope = rule.scope || 'root';
this.scope = rule.scope || 'command';
this.includeScope = [];

@@ -15,0 +15,0 @@ this.excludeScope = [];

@@ -38,10 +38,3 @@ "use strict";

return __awaiter(this, void 0, void 0, function* () {
const numScopesChecked = yield this.checkScope(appMapFile, appMapIndex, check, check.scope, findings);
if (numScopesChecked === 0 && check.scope === 'command') {
yield this.checkScope(appMapFile, appMapIndex, check, 'root', findings);
}
});
}
checkScope(appMapFile, appMapIndex, check, scope, findings) {
return __awaiter(this, void 0, void 0, function* () {
const scope = check.scope;
if ((0, util_1.verbose)()) {

@@ -60,5 +53,3 @@ console.warn(`Checking AppMap ${appMapIndex.appMap.name} with scope ${scope}`);

};
let numScopes = 0;
for (const scope of scopeIterator.scopes(callEvents())) {
numScopes += 1;
if ((0, util_1.verbose)()) {

@@ -80,3 +71,2 @@ console.warn(`Scope ${scope.scope}`);

}
return numScopes;
});

@@ -83,0 +73,0 @@ }

@@ -104,2 +104,3 @@ "use strict";

labels: [Secret, Log],
scope: 'root',
impactDomain: 'Security',

@@ -106,0 +107,0 @@ enumerateScope: true,

@@ -33,3 +33,2 @@ "use strict";

title: 'Slow function call',
scope: 'root',
impactDomain: 'Performance',

@@ -36,0 +35,0 @@ enumerateScope: true,

@@ -24,3 +24,8 @@ "use strict";

*scopes(events) {
let found = false;
const roots = [];
for (const event of events) {
if (event.isCall() && !event.parent) {
roots.push(event);
}
if (event.isCall() &&

@@ -30,2 +35,3 @@ (event.codeObject.labels.has(Command) ||

event.httpServerRequest)) {
found = true;
yield new ScopeImpl(event);

@@ -35,4 +41,11 @@ this.advanceToReturnEvent(event, events);

}
// If no true command is found, yield all root events.
if (!found) {
for (let index = 0; index < roots.length; index++) {
const event = roots[index];
yield new ScopeImpl(event);
}
}
}
}
exports.default = CommandScope;

@@ -0,1 +1,8 @@

# [@appland/scanner-v1.64.0](https://github.com/applandinc/appmap-js/compare/@appland/scanner-v1.63.0...@appland/scanner-v1.64.0) (2022-08-04)
### Features
* Command scope falls back on root events ([3823a1f](https://github.com/applandinc/appmap-js/commit/3823a1f686212db49b87f2995baa2103a4e007d1))
# [@appland/scanner-v1.63.0](https://github.com/applandinc/appmap-js/compare/@appland/scanner-v1.62.2...@appland/scanner-v1.63.0) (2022-07-28)

@@ -2,0 +9,0 @@

@@ -11,2 +11,3 @@ ---

- log
scope: root
---

@@ -13,0 +14,0 @@

@@ -6,3 +6,2 @@ ---

impactDomain: Performance
scope: root
---

@@ -9,0 +8,0 @@

{
"name": "@appland/scanner",
"version": "1.63.0",
"version": "1.64.0",
"description": "",

@@ -64,3 +64,2 @@ "bin": "built/cli.js",

"ajv": "^8.8.2",
"ansi-escapes": "^5.0.0",
"applicationinsights": "^2.1.4",

@@ -90,12 +89,16 @@ "async": "^3.2.3",

"targets": [
"node14-linux-x64",
"node14-win-x64",
"node14-macos-x64"
"node16-linux-x64",
"node16-win-x64",
"node16-macos-x64",
"node16-macos-arm64"
],
"scripts": [
"built/scanner/*.js"
"built/scanner/*.js",
"built/rules/**/*.js"
],
"assets": [
"built/sampleConfig/*.yml",
"built/**/*.json"
"built/**/*.json",
"package.json",
"doc/**/*.md"
],

@@ -102,0 +105,0 @@ "outputPath": "dist"

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc