Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@contrast/reporter

Package Overview
Dependencies
Maintainers
9
Versions
62
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@contrast/reporter - npm Package Compare versions

Comparing version 1.23.2 to 1.24.0

5

lib/index.d.ts

@@ -6,5 +6,8 @@ import BaseReporter, { Core } from './reporters/base';

}
export interface ReporterOptions {
reporters: string[];
}
export default function init(core: Core & {
reporter: ReporterBus;
}): ReporterBus;
}, options?: ReporterOptions): ReporterBus;
//# sourceMappingURL=index.d.ts.map

11

lib/index.js

@@ -23,3 +23,6 @@ "use strict";

const security_logger_1 = __importDefault(require("./reporters/security-logger"));
function init(core) {
const DEFAULT_OPTIONS = {
reporters: ['sec', 'ui', 'file'],
};
function init(core, options = DEFAULT_OPTIONS) {
const { logger } = core;

@@ -35,11 +38,11 @@ const reporters = [];

};
if (core.config.agent.reporters.file) {
if (core.config.agent.reporters.file && options.reporters.includes('file')) {
logger.trace('enabling file reporter');
reporters.push(new file_1.default(core));
}
if (core.config.api.enable) {
if (core.config.api.enable && options.reporters.includes('ui')) {
logger.trace('enabling Contrast UI reporter');
reporters.push(new contrast_ui_1.default(core));
}
if (core.config.protect.enable) {
if (core.config.protect.enable && options.reporters.includes('sec')) {
logger.trace('enabling security logger');

@@ -46,0 +49,0 @@ reporters.push(new security_logger_1.default(core));

{
"name": "@contrast/reporter",
"version": "1.23.2",
"version": "1.24.0",
"description": "Subscribes to agent messages and reports them",

@@ -21,3 +21,3 @@ "license": "SEE LICENSE IN LICENSE",

"dependencies": {
"@contrast/common": "1.17.0",
"@contrast/common": "1.18.0",
"axios": "^1.6.5",

@@ -24,0 +24,0 @@ "crc-32": "^1.2.2",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc