
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
stream-reader-async
Advanced tools
Wraps a readable stream with a bunch of helper buffer-like methods that can be used asynchronously with async/await.
This results in an interesting blend between streams, buffers and promises that's very useful when parsing binary data.
The reader position is updated along with how many bytes you read.
Constructs a new stream reader from a stream.
Returns whether the stream has finished reading. This property may be removed in a future release.
Returns a new buffer of size byteCount and advances the stream position that same amount.
Returns the next byte and advances the stream position by one. Equal to calling read(1)[0]
Reads the next byte and returns whether it's not equal to 0.
Reads a 7-bit encoded integer. This is not the same as a varint, as the order is not reversed before the final binary is added.
A byte is read, if its most significant bit is a 1, there is another byte to be consumed. The other 7 bits are added to the number.
1111111 11100010 11111011 01110101
111111 1100010 1111011 1110101
111111110001011110111110101 // 133742069
Reads a string of strlen. Both parameters are optional. The default encoding is utf8.
If you omit strlen, a first 7-bit integer wil be read, and it will be used as the string length to return.
These methods behave exactly how Node Buffers would, except they return a promise, and don't require an offset as it will always be zero.
FAQs
Provides an async interface for consuming readable streams
The npm package stream-reader-async receives a total of 15 weekly downloads. As such, stream-reader-async popularity was classified as not popular.
We found that stream-reader-async demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.