ZmqSharp.Security.Curve
0.5.2
dotnet add package ZmqSharp.Security.Curve --version 0.5.2
NuGet\Install-Package ZmqSharp.Security.Curve -Version 0.5.2
<PackageReference Include="ZmqSharp.Security.Curve" Version="0.5.2" />
<PackageVersion Include="ZmqSharp.Security.Curve" Version="0.5.2" />
<PackageReference Include="ZmqSharp.Security.Curve" />
paket add ZmqSharp.Security.Curve --version 0.5.2
#r "nuget: ZmqSharp.Security.Curve, 0.5.2"
#:package ZmqSharp.Security.Curve@0.5.2
#addin nuget:?package=ZmqSharp.Security.Curve&version=0.5.2
#tool nuget:?package=ZmqSharp.Security.Curve&version=0.5.2
ZmqSharp
·
· License: Apache-2.0
A fully asynchronous, AOT-compatible .NET implementation of the ZMTP 3.0 protocol (ZeroMQ wire protocol) with libzmq-compatible socket semantics.
- Value-type messages (
ZMessage/ZFrame/ZSegment) with explicit ownership and move semantics — no per-message allocations on the hot path. - All 11 libzmq socket types: PAIR, PUSH, PULL, PUB, SUB, REQ, REP, DEALER, ROUTER, XPUB, XSUB, each verified against the NetMQ (libzmq-compatible) implementation over TCP in both directions.
- TCP and ipc (Unix domain socket) transports with a single string-endpoint facade (
tcp://host:port,ipc://path). libzmq supports ipc on Unix only, and NetMQ'sipc://is a TCP hash rather than a Unix domain socket; ZmqSharp offers trueipc://Unix domain sockets on every platform, including Windows — a concrete differentiator (0015 section 5.3, 0020 section 7/8). - Per-peer bounded queues with configurable full modes (Wait, DropWrite, DropNewest, DropOldest) and mandatory reclamation of dropped messages.
- Copy-on-write peer snapshots: zero-allocation send and receive hot paths in optimized builds.
- Full Native AOT: no runtime reflection or dynamic code generation.
Usage
using ZmqSharp;
// PAIR over TCP.
await using var server = new ZPairSocket();
await using var client = new ZPairSocket();
await server.BindAsync("tcp://127.0.0.1:5555");
await client.ConnectAsync("tcp://127.0.0.1:5555");
await client.SendAsync("hello"u8.ToArray());
var message = await server.Messages.ReadAsync();
// PAIR over ipc (Unix domain socket): an absolute path, a relative one
// resolved against the system temp directory, or - on Linux - an abstract
// namespace name (libzmq's ipc://@name convention) that creates no
// filesystem entry.
await using var ipcServer = new ZPairSocket();
await using var ipcClient = new ZPairSocket();
await ipcServer.BindAsync("ipc:///tmp/zmqsharp.sock");
await ipcClient.ConnectAsync("ipc:///tmp/zmqsharp.sock");
REQ/REP (operation-oriented):
await using var rep = new ZRepSocket();
rep.BindRequestHandler((context, token) =>
rep.SendReplyAsync(context, ZMessage.FromOwned("pong"u8.ToArray()), token));
await using var req = new ZReqSocket();
var reply = await req.RequestAsync(ZMessage.FromOwned("ping"u8.ToArray()));
Design
Design documents live in docs/impl/. The architecture is a transport core (ZSocketBase) composed with per-pattern
cores and bound to a semantic delivery seam (IPatternSink); surfaces are thin composition roots constructed directly
(new ZPairSocket()), with the queue surface as the default receive path (Messages) and BindAsync/ConnectAsync
as the repeatable endpoint surface (0022, 0023).
License
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- BouncyCastle.Cryptography (>= 2.7.0)
- ZmqSharp (>= 0.5.2)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.