erickt / rust-zmq

Rust zeromq bindings.
Apache License 2.0
886 stars 189 forks source link

Curve support zmq::CurveKeyPair::new(); #401

Open glennpierce opened 2 weeks ago

glennpierce commented 2 weeks ago

Hi I am running on debian 12,5

I have a zeromq python client script working fine that includes the line

context = zmq.Context()
public_key, secret_key = zmq.curve_keypair()

this script works fine and i need to translate it to rust but I get errors when doing

// Generate curve keypair
let keypair_result = zmq::CurveKeyPair::new();

I get the error

Err(Operation not supported)

Is the a feature I need to enable. I can see one from the docs

I am using versions

zmq = { version = "0.10", optional = true }
zmq-sys = { version = "0.12.0", optional = true }

Thanks

esemeniuc commented 1 week ago

My pr fixes it: https://github.com/erickt/rust-zmq/pull/400