
Product
Rust Support in Socket Is Now Generally Available
Socket’s Rust and Cargo support is now generally available, providing dependency analysis and supply chain visibility for Rust projects.
dat-replication-protocol
Advanced tools
Streaming implementation of the dat replication protocol
npm install dat-replication-protocol
var protocol = require('dat-replication-protocol')
var p = protocol(function(type, stream) {
if (type === protocol.CHANGES) {
// receiving the changes stream
stream.on('data', function(change) {
console.log('change:', change)
})
}
if (type === protocol.BLOB) {
// receiving a blob stream
stream.pipe(process.stdout)
}
})
var changes = p.createChangesStream()
// write changes data to this stream
changes.write({
key: 'some-row-key',
change: 0,
from: 0,
to: 1,
value: new Buffer('some binary value')
})
var blob = p.createBlobStream(12) // 12 is the length of the blob
blob.write('hello ')
blob.write('world\n')
blob.end()
// for testing lets just pipe it to ourselves
p.pipe(p)
This works similarly to the multiplex module except this uses length prefixed streams for the blobs streams
Basically all changes and blobs are sent as multibuffers (varint prefixed).
--------------------------------------------------
| varint length | single byte id | payload |
--------------------------------------------------
Since blobs can be large they are treated as streams.
MIT
FAQs
streaming implementation of the dat replication protocol
The npm package dat-replication-protocol receives a total of 5 weekly downloads. As such, dat-replication-protocol popularity was classified as not popular.
We found that dat-replication-protocol 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.

Product
Socket’s Rust and Cargo support is now generally available, providing dependency analysis and supply chain visibility for Rust projects.

Security News
Chrome 144 introduces the Temporal API, a modern approach to date and time handling designed to fix long-standing issues with JavaScript’s Date object.

Research
Five coordinated Chrome extensions enable session hijacking and block security controls across enterprise HR and ERP platforms.