
Research
/Security News
Critical Vulnerability in NestJS Devtools: Localhost RCE via Sandbox Escape
A flawed sandbox in @nestjs/devtools-integration lets attackers run code on your machine via CSRF, leading to full Remote Code Execution (RCE).
@stdlib/assert-is-node-stream-like
Advanced tools
Test if a value is Node stream-like.
npm install @stdlib/assert-is-node-stream-like
var isNodeStreamLike = require( '@stdlib/assert-is-node-stream-like' );
Tests if a value
is Node stream-like.
var transformStream = require( '@stdlib/streams-node-transform' );
var bool = isNodeStreamLike( transformStream() );
// returns true
var stream = require( 'stream' );
var transformStream = require( '@stdlib/streams-node-transform' );
var isNodeStreamLike = require( '@stdlib/assert-is-node-stream-like' );
var bool = isNodeStreamLike( new stream.Stream() );
// returns true
bool = isNodeStreamLike( new stream.Readable() );
// returns true
bool = isNodeStreamLike( new stream.Writable() );
// returns true
bool = isNodeStreamLike( new stream.Duplex() );
// returns true
bool = isNodeStreamLike( new stream.Transform() );
// returns true
bool = isNodeStreamLike( transformStream() );
// returns true
bool = isNodeStreamLike( {} );
// returns false
bool = isNodeStreamLike( [] );
// returns false
bool = isNodeStreamLike( null );
// returns false
function Stream() {
return this;
}
bool = isNodeStreamLike( Stream );
// returns false
bool = isNodeStreamLike( new Stream() );
// returns false
This package is part of stdlib, a standard library for JavaScript and Node.js, with an emphasis on numerical and scientific computing. The library provides a collection of robust, high performance libraries for mathematics, statistics, streams, utilities, and more.
For more information on the project, filing bug reports and feature requests, and guidance on how to develop stdlib, see the main project repository.
See LICENSE.
Copyright © 2016-2021. The Stdlib Authors.
0.0.6 (2021-07-09)
No changes reported for this release.
</section> <!-- /.release --> <section class="release" id="v0.0.5">FAQs
Test if a value is Node stream-like.
The npm package @stdlib/assert-is-node-stream-like receives a total of 2,073 weekly downloads. As such, @stdlib/assert-is-node-stream-like popularity was classified as popular.
We found that @stdlib/assert-is-node-stream-like demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 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
A flawed sandbox in @nestjs/devtools-integration lets attackers run code on your machine via CSRF, leading to full Remote Code Execution (RCE).
Product
Customize license detection with Socket’s new license overlays: gain control, reduce noise, and handle edge cases with precision.
Product
Socket now supports Rust and Cargo, offering package search for all users and experimental SBOM generation for enterprise projects.