[tor-bugs] #26766 [Core Tor/Stem]: Cell unused content is ignored while packing

Tor Bug Tracker & Wiki blackhole at torproject.org
Thu Jul 12 03:53:01 UTC 2018


#26766: Cell unused content is ignored while packing
-------------------------------+----------------------
     Reporter:  dmr            |      Owner:  dmr
         Type:  defect         |     Status:  assigned
     Priority:  Medium         |  Milestone:
    Component:  Core Tor/Stem  |    Version:
     Severity:  Normal         |   Keywords:  client
Actual Points:                 |  Parent ID:
       Points:                 |   Reviewer:  atagar
      Sponsor:                 |
-------------------------------+----------------------
 The Cell `unused` attribute is populated when unpacking content, with any
 content that wasn't assigned to another attribute per the cell structure.

 However, it currently isn't used for anything else^^*. It would make the
 most sense to allow such a Cell to be repacked to binary identicality,
 changing `_pack()` to allow this.

 IRC log of discussion with atagar:
 {{{
 18:52 < dmr> atagar: (2) should `unused` be used in `_pack()`, prior to
 additional payload padding? I think it should, to allow repacking into
 something with the same binary value.
 [...]
 18:55 <+atagar> (2) agreed, it should
 18:56 <+atagar> [...] Would you mind sending a patch for (2)?
 [...]
 19:08 <+atagar> dmr: Oh btw, if you could send a unit test along with (2)
 I'd appreciate it. Our tests should check that re-packing cells produces
 the same bytes we read.
 [...]
 19:27 < dmr> atagar: sounds good, and for (2) I was planning that very
 test set!
 }}}

 This ticket tracks the implementation change and the test changes. **I've
 got a pull request coming soon! **

 ^^* 'twas not intended, but I got quite a kick out of that. It's almost...
 well... unused. (Sigh.)

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/26766>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list