[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #5156 [Obfsproxy]: assertion failure at src/network.c:931: circ
#5156: assertion failure at src/network.c:931: circ
-----------------------+----------------------------------------------------
Reporter: arma | Owner: asn
Type: defect | Status: new
Priority: normal | Milestone:
Component: Obfsproxy | Version:
Keywords: | Parent:
Points: | Actualpoints:
-----------------------+----------------------------------------------------
Comment(by asn):
Replying to [comment:3 nickm]:
> Ah, it looks like there's an ordering bug here.
bufferevent_connect_hostname is allowed to complete immediately while it
is called, but the function calling it assumes that it's okay to set up
the ->circuit pointer after the open_outbound_hostname call returns.
>
> So the right fix here seems to be setting the circuit earlier, I guess?
So I see, I didn't know that bufferevent callbacks are triggered
immediately. I thought they were triggered on the next libevent loop;
seems like this is the behavior of deferred callbacks, though.
So, does `simple_server_listener_cb()` and `simple_client_listener_cb()`
have the same problem? `open_outbound()` seems to do `bufferevent_setcb`
and `bufferevent_socket_connect` before setting up the circuit.
I'm wondering, do we have any more instances of this bug?
I'll do some more research, try to reproduce it, and then try to make a
patch.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/5156#comment:4>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs