Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-12-15 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
-+-
 Reporter:  catalyst |  Owner:
 |  catalyst
 Type:  defect   | Status:  closed
 Priority:  Medium   |  Milestone:  Tor:
 |  0.4.3.x-final
Component:  Core Tor/Tor |Version:
 Severity:  Normal   | Resolution:  fixed
 Keywords:  042-deferred-20190918, early-review  |  Actual Points:  8
Parent ID:  #29210   | Points:  5
 Reviewer:  teor |Sponsor:
 |  Sponsor31-can
-+-
Changes (by teor):

 * status:  merge_ready => closed
 * resolution:   => fixed


Comment:

 Merged to master.

 Merged with #32629.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-12-09 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
-+-
 Reporter:  catalyst |  Owner:
 |  catalyst
 Type:  defect   | Status:
 |  merge_ready
 Priority:  Medium   |  Milestone:  Tor:
 |  0.4.3.x-final
Component:  Core Tor/Tor |Version:
 Severity:  Normal   | Resolution:
 Keywords:  042-deferred-20190918, early-review  |  Actual Points:  8
Parent ID:  #29210   | Points:  5
 Reviewer:  teor |Sponsor:
 |  Sponsor31-can
-+-
Changes (by catalyst):

 * actualpoints:   => 8


Comment:

 Replying to [comment:15 teor]:
 > Looks good to me, but we can't merge until after the pending releases.
 >
 > Also, please remember to fill in actual points!
 Thanks! I fixed the whitespace issue you commented on in the pull request.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-12-08 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
-+-
 Reporter:  catalyst |  Owner:
 |  catalyst
 Type:  defect   | Status:
 |  merge_ready
 Priority:  Medium   |  Milestone:  Tor:
 |  0.4.3.x-final
Component:  Core Tor/Tor |Version:
 Severity:  Normal   | Resolution:
 Keywords:  042-deferred-20190918, early-review  |  Actual Points:
Parent ID:  #29210   | Points:  5
 Reviewer:  teor |Sponsor:
 |  Sponsor31-can
-+-
Changes (by teor):

 * status:  needs_review => merge_ready


Comment:

 Looks good to me, but we can't merge until after the pending releases.

 Also, please remember to fill in actual points!

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-12-08 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
-+-
 Reporter:  catalyst |  Owner:
 |  catalyst
 Type:  defect   | Status:
 |  needs_review
 Priority:  Medium   |  Milestone:  Tor:
 |  0.4.3.x-final
Component:  Core Tor/Tor |Version:
 Severity:  Normal   | Resolution:
 Keywords:  042-deferred-20190918, early-review  |  Actual Points:
Parent ID:  #29210   | Points:  5
 Reviewer:  teor |Sponsor:
 |  Sponsor31-can
-+-
Changes (by catalyst):

 * status:  accepted => needs_review


Comment:

 Replying to [comment:13 teor]:
 > Looks fine to me as a design, I suggested a few tweaks.
 > Are there any specific things you would like me to look at?
 Thanks! I've addressed your comments, and improved the Doxygen formatting
 a little as well.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-11-05 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
-+-
 Reporter:  catalyst |  Owner:
 |  catalyst
 Type:  defect   | Status:
 |  accepted
 Priority:  Medium   |  Milestone:  Tor:
 |  0.4.3.x-final
Component:  Core Tor/Tor |Version:
 Severity:  Normal   | Resolution:
 Keywords:  042-deferred-20190918, early-review  |  Actual Points:
Parent ID:  #29210   | Points:  5
 Reviewer:  teor |Sponsor:
 |  Sponsor31-can
-+-

Comment (by teor):

 Looks fine to me as a design, I suggested a few tweaks.
 Are there any specific things you would like me to look at?

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-11-05 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
-+-
 Reporter:  catalyst |  Owner:
 |  catalyst
 Type:  defect   | Status:
 |  accepted
 Priority:  Medium   |  Milestone:  Tor:
 |  0.4.3.x-final
Component:  Core Tor/Tor |Version:
 Severity:  Normal   | Resolution:
 Keywords:  042-deferred-20190918, early-review  |  Actual Points:
Parent ID:  #29210   | Points:  5
 Reviewer:  teor |Sponsor:
 |  Sponsor31-can
-+-

Comment (by catalyst):

 Pull request in https://github.com/torproject/tor/pull/1505

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-11-05 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
-+-
 Reporter:  catalyst |  Owner:
 |  catalyst
 Type:  defect   | Status:
 |  accepted
 Priority:  Medium   |  Milestone:  Tor:
 |  0.4.3.x-final
Component:  Core Tor/Tor |Version:
 Severity:  Normal   | Resolution:
 Keywords:  042-deferred-20190918, early-review  |  Actual Points:
Parent ID:  #29210   | Points:  5
 Reviewer:  teor |Sponsor:
 |  Sponsor31-can
-+-
Changes (by catalyst):

 * keywords:  042-deferred-20190918 => 042-deferred-20190918, early-review
 * reviewer:   => teor


--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-09-03 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
--+
 Reporter:  catalyst  |  Owner:  catalyst
 Type:  defect| Status:  accepted
 Priority:  Medium|  Milestone:  Tor: 0.4.2.x-final
Component:  Core Tor/Tor  |Version:
 Severity:  Normal| Resolution:
 Keywords:|  Actual Points:
Parent ID:  #29210| Points:  5
 Reviewer:|Sponsor:  Sponsor31-can
--+
Changes (by gaba):

 * cc: gaba (added)


--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-07-08 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
--+
 Reporter:  catalyst  |  Owner:  catalyst
 Type:  defect| Status:  accepted
 Priority:  Medium|  Milestone:  Tor: 0.4.2.x-final
Component:  Core Tor/Tor  |Version:
 Severity:  Normal| Resolution:
 Keywords:|  Actual Points:
Parent ID:  #29210| Points:  5
 Reviewer:|Sponsor:  Sponsor31-can
--+

Comment (by catalyst):

 WIP branch in my GitHub repository: [https://github.com/tlyu/tor/tree
 /control-refactor control-refactor]; still needs some memory management
 work.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-07-03 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
--+
 Reporter:  catalyst  |  Owner:  catalyst
 Type:  defect| Status:  accepted
 Priority:  Medium|  Milestone:  Tor: 0.4.2.x-final
Component:  Core Tor/Tor  |Version:
 Severity:  Normal| Resolution:
 Keywords:|  Actual Points:
Parent ID:  #29210| Points:  5
 Reviewer:|Sponsor:  Sponsor31-can
--+
Changes (by catalyst):

 * status:  assigned => accepted


Comment:

 Oops should have moved this to "accepted".

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-07-03 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
--+
 Reporter:  catalyst  |  Owner:  catalyst
 Type:  defect| Status:  assigned
 Priority:  Medium|  Milestone:  Tor: 0.4.2.x-final
Component:  Core Tor/Tor  |Version:
 Severity:  Normal| Resolution:
 Keywords:|  Actual Points:
Parent ID:  #29210| Points:  5
 Reviewer:|Sponsor:  Sponsor31-can
--+

Comment (by nickm):

 Thanks for explaining this to me; it makes a lot more sense to me now.
 Based on what you've said above, I think you should go with whatever
 approach seems best to you based on your analysis.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-07-03 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
--+
 Reporter:  catalyst  |  Owner:  catalyst
 Type:  defect| Status:  assigned
 Priority:  Medium|  Milestone:  Tor: 0.4.2.x-final
Component:  Core Tor/Tor  |Version:
 Severity:  Normal| Resolution:
 Keywords:|  Actual Points:
Parent ID:  #29210| Points:  5
 Reviewer:|Sponsor:  Sponsor31-can
--+

Comment (by catalyst):

 Replying to [comment:4 nickm]:
 > I'm not sure that wrapping config_line_t and putting the results in a
 smartlist_t is the route I would recommend here: config_line_t expects to
 be in a linked list.
 I was thinking that each smartlist element would be a length-one linked
 list of `config_line_t`, under most circumstances. Exceptions would be
 reply lines with multiple machine-parsable key-value elements, like many
 of the async event control replies. For these, it would be nice to use
 `kvline_encode()`.

 There are three main categories of reply lines that I see (ignoring the
 difference between a `MidReplyLine` and `EndReplyLine` for now -- part of
 the goal of this is to automatically figure out which to generate):
 * Entire line after the numeric code and separator is meant to be human
 readable, and not generally machine-parsed
 * Entire line after the numeric code and separator is a single `key=value`
 pair
 * Line is a `DataReplyLine`, followed by multi-line `CmdData`
 * After numeric code and separator, a list of machine-parsable keywords or
 `key=value` pairs. These are mostly async control events, but there are
 some synchronous replies that are like this, including `PROTOCOLINFO`.
 These are the reply formats that would benefit most from
 `kvline_encode()`.

 Or maybe I should start by making a new structure for control replies,
 starting with reply code numbers and flat strings? Then stuff that could
 benefit by building up `key=value` argument lists could still use
 `kvline_encode()` explicitly, at least at first. Some of the existing
 control replies like `GETINFO` and `GETCONF` don't quote things the way
 `kvline_encode()` would like to.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-07-03 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
--+
 Reporter:  catalyst  |  Owner:  catalyst
 Type:  defect| Status:  assigned
 Priority:  Medium|  Milestone:  Tor: 0.4.2.x-final
Component:  Core Tor/Tor  |Version:
 Severity:  Normal| Resolution:
 Keywords:|  Actual Points:
Parent ID:  #29210| Points:  5
 Reviewer:|Sponsor:  Sponsor31-can
--+

Comment (by nickm):

 I'm not sure that wrapping config_line_t and putting the results in a
 smartlist_t is the route I would recommend here: config_line_t expects to
 be in a linked list.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-07-02 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
--+
 Reporter:  catalyst  |  Owner:  catalyst
 Type:  defect| Status:  assigned
 Priority:  Medium|  Milestone:  Tor: 0.4.2.x-final
Component:  Core Tor/Tor  |Version:
 Severity:  Normal| Resolution:
 Keywords:|  Actual Points:
Parent ID:  #29210| Points:  5
 Reviewer:|Sponsor:  Sponsor31-can
--+

Comment (by catalyst):

 Sketch so far:

 * New struct `control_reply_line_t` wraps `config_line_t` with additional
 fields for control protocol numeric reply codes and for control event
 async event type numbers (these are different)
 * Make smartlists of `control_reply_line_t` hold entire multiline control
 replies

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-06-25 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
--+
 Reporter:  catalyst  |  Owner:  catalyst
 Type:  defect| Status:  assigned
 Priority:  Medium|  Milestone:  Tor: 0.4.2.x-final
Component:  Core Tor/Tor  |Version:
 Severity:  Normal| Resolution:
 Keywords:|  Actual Points:
Parent ID:  #29210| Points:  5
 Reviewer:|Sponsor:  Sponsor31-can
--+

Comment (by catalyst):

 Replying to [comment:1 nickm]:
 > Could we reuse config_line_t, or is there a mismatch?
 I think it would need to be extended or wrapped to add the numeric result
 code on each line. Some commands like `MAPADDRESS` can have multiple
 result codes in a single response. (This doesn't conform with `control-
 spec.txt` currently, but that's a different problem.) Also some replies
 are one key-value pair per line (e.g., `250-key=value` from `GETCONF`),
 but some contain multiple key-value pairs (e.g., the `ORCONN` async
 reply).

 Also for async events, there's a separate numeric event type code that's
 distinct from the `650` reply code.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-06-25 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
--+
 Reporter:  catalyst  |  Owner:  catalyst
 Type:  defect| Status:  assigned
 Priority:  Medium|  Milestone:  Tor: 0.4.2.x-final
Component:  Core Tor/Tor  |Version:
 Severity:  Normal| Resolution:
 Keywords:|  Actual Points:
Parent ID:  #29210| Points:  5
 Reviewer:|Sponsor:  Sponsor31-can
--+

Comment (by nickm):

 Could we reuse config_line_t, or is there a mismatch?

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

[tor-bugs] #30984 [Core Tor/Tor]: Make a key-value line abstraction to output control replies

2019-06-25 Thread Tor Bug Tracker & Wiki
#30984: Make a key-value line abstraction to output control replies
---+
 Reporter:  catalyst   |  Owner:  catalyst
 Type:  defect | Status:  assigned
 Priority:  Medium |  Milestone:  Tor: 0.4.2.x-final
Component:  Core Tor/Tor   |Version:
 Severity:  Normal |   Keywords:
Actual Points: |  Parent ID:  #29210
   Points:  5  |   Reviewer:
  Sponsor:  Sponsor31-can  |
---+
 A few controller commands still use `connection_buf_add()` or similar low-
 level functions after constructing a list of reply lines. Almost all of
 these are key-value pairs. Create a new abstraction to output these,
 including by automatically including the correct separator character
 between the numeric code and the rest of the line.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs