[zeromq-dev] authentication failure and zmq_msg_send blocking

Pieter Hintjens ph at imatix.com
Mon May 26 17:08:43 CEST 2014

Sorry for the slow reply. I assume you've passed this glitch, with the
latest master and have everything you need now?

On Mon, May 19, 2014 at 3:19 PM, Goswin von Brederlow <goswin-v-b at web.de> wrote:
> Hi,
> I just tried building latest git and now 3 tests block:
> * test_security_null
> * test_security_plain
> * test_security_curve
> I only looked at the first so far but I believe all will be the same
> cause.
> test_security_null uses a DEALER socket and tests what happens when
> the authenication fails using expect_bounce_fail(). The expectation is
> that the send message is never recieved and gives a timeout since the
> client can't authenticate.
> But now the test blocks in zmq_send(), which doesn't have a timeout. I
> blieve this is a side effect of the recently merged work by hutonm
> concerning handing auth errors and reporting them to the client. My
> guess is this causes the DEALER socket to remain in the state where it
> has no available peers, which means zmq_send() blocks till there is
> one (which obviously never happens).
> This behaviour seems rather suboptimal to me. Wouldn't it make more
> sense for zmq_send() to return an error like EAUTH or ENOPEER when all
> peers of the socket have connected but got an error back? The
> connections will not be retried and wouldn't work the second time
> around (usualy) anyway. So zmq_send can never succeed and waiting
> seems pointless.
> Secondly how is the client supposed to detect authentication failures
> at all?
> MfG
>         Goswin
> _______________________________________________
> zeromq-dev mailing list
> zeromq-dev at lists.zeromq.org
> http://lists.zeromq.org/mailman/listinfo/zeromq-dev

More information about the zeromq-dev mailing list