[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #3291 [Pluggable transport]: obfs2 should wait before closing connection on wrong magic/plength
#3291: obfs2 should wait before closing connection on wrong magic/plength
---------------------------------+------------------------------------------
Reporter: asn | Owner: asn
Type: defect | Status: needs_review
Priority: normal | Milestone:
Component: Pluggable transport | Version:
Keywords: | Parent:
Points: | Actualpoints:
---------------------------------+------------------------------------------
Comment(by nickm):
As noted, RECV_OBFS2_PENDING should probably be called RECV_SEND_PENDING
or something. It's something that other protocols can return too, right?
C tip: the cast here is redundant:
{{{
+ if (evbuffer_add_buffer(dest,source)<0)
+ return (enum recv_ret) RECV_BAD;
+ else
+ return (enum recv_ret) RECV_GOOD;
}}}
RECV_BAD and RECV_GOOD are already of the type you need, and adding extra
casts makes it look like you're doing something dangerous when really it's
all good.
The comment on obfs2_recv is now wrong.
The RECV_BAD_WAIT patch makes no sense to me. What is it for? Why can't
we just close the connection?
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/3291#comment:5>
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