Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
@timberio/bunyan
Advanced tools
New to Timber? Here's a low-down on logging in Javascript.
@timberio/bunyan
This NPM library provides a Bunyan writable stream that transmits logs to Timber.io via the @timberio/node
logger.
Here's how to get started:
Install the Node.js Timber logger and the Bunyan stream plugin via NPM:
npm i @timberio/node @timberio/bunyan
In ES6/Typescript, import both the Timber
logger class and the Timber Bunyan stream class:
import { Timber } from "@timberio/node";
import { TimberStream } from "@timberio/bunyan";
For CommonJS, require the packages instead:
const { Timber } = require("@timberio/node");
const { TimberStream } = require("@timberio/bunyan");
You can create a client the usual way for @timberio/node
, and then pass it into a new instance of TimberStream
:
// Assuming you've imported the Timber packages above, also import Bunyan...
import bunyan from "bunyan";
// Create a Timber client
const timber = new Timber("timber-organization-key", "timber-source-key");
// Create a Bunyan logger - passing in the Timber stream
const logger = bunyan.createLogger({
name: "Example logger",
level: "debug",
streams: [
{
stream: new TimberStream(timber)
}
]
});
// Log as normal in Bunyan - your logs will sync with Timber.io!
logger.info("Hello from Bunyan");
Timber will log at the debug
level and above. Trace logs or any log level below 20
will be ignored.
The fatal
log level is transformed to error
in the Timber logger.
FAQs
Timber.io - Bunyan writable stream
The npm package @timberio/bunyan receives a total of 0 weekly downloads. As such, @timberio/bunyan popularity was classified as not popular.
We found that @timberio/bunyan demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 5 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.