Commit Graph

12 Commits

Author SHA1 Message Date
Brian Warner
1219fd08ca subchannel: enforce separation between half-close and full-close API 2019-08-11 22:20:49 -07:00
Brian Warner
1c8c2997c7 subchannel: tolerate multiple pre-open inbound DATA messages 2019-08-11 22:20:49 -07:00
Brian Warner
327e72e6ac update subchannel state machine for half-close
also handle open-but-not-yet-connected subchannels better
2019-08-11 15:24:39 -07:00
Brian Warner
b233763082 subchannel: deliver queued connectionMade before any data
The previous implementation would call the control/receiving Protocol
completely backwards: dataReceived first, then connectionLost, then finally
connectionMade. Which didn't work at all, of course.
2019-08-11 14:20:33 -07:00
Brian Warner
85cb003498 WIP: rewrite w.dilate API to return endpoints synchronously
test_manager still needs rewriting
2019-07-12 00:01:55 -07:00
Brian Warner
75fad02a28 subchannel: queue pending opens with a deque(), not a list
slightly cleaner
2019-07-08 01:15:13 -07:00
Brian Warner
575cf5d789 subchannel: check MAX_FRAME_LENGTH, 2**32 minus headers
Anyone sending 4GB in a single `transport.write()` is in for a surprise, but
at least we'll surprise them with an assertion *before* spending the time and
memory encrypting that monster.
2019-07-07 23:59:54 -07:00
Brian Warner
d1aefa815d fix subchannel open/close, add test
I think I just managed to forget that inbound_close requires we respond with
a close ourselves. Also outbound open means we must add the subchannel to the
inbound table, so we can receive any data on it at all.
2019-07-06 01:50:29 -07:00
Brian Warner
8043e508fa make SubChannel IDs integers, not 4-bytes
I'm sure I had a good reason for avoiding integers, but it makes logging and
testing more difficult, and both sides are using integers to generate them
anyways (so one side can pick the odd ones, and the other can pick the even
ones).
2019-07-06 01:10:34 -07:00
Brian Warner
74c416517f scids are four-byte strings, not integers
be consistent about it
2019-02-10 16:23:20 -08:00
Brian Warner
05900bd08b fix some flake8 complaints 2018-12-23 15:22:57 -05:00
Brian Warner
34686a346a add dilation code
(this compresses several months of false starts and rearchitecting)
2018-12-23 15:21:08 -05:00