[tor-bugs] #3679 [Torctl]: TorCtl Event Parsing Rewrite

Tor Bug Tracker & Wiki torproject-admin at torproject.org
Sat Oct 8 22:46:15 UTC 2011


#3679: TorCtl Event Parsing Rewrite
-------------------------+--------------------------------------------------
 Reporter:  atagar       |          Owner:              
     Type:  enhancement  |         Status:  needs_review
 Priority:  normal       |      Milestone:              
Component:  Torctl       |        Version:              
 Keywords:               |         Parent:              
   Points:               |   Actualpoints:              
-------------------------+--------------------------------------------------

Comment(by atagar):

 For CIRC events the path is a positional argument. For instance...
 650 CIRC 9 EXTENDED
 $59A3237FA7EB42CAD215FB6EA638ABF7F245873E~zzz,$E5E3E9A472EAF7BE9682B86E92305DB4C71048EF~Amunet2
 PURPOSE=GENERAL

 Which is parsed from the _decodeFields function:
 {{{
 1494     for entry in body.split():
 1495       m = KW_ARG.match(entry)
 1496
 1497       if m:
 1498         k, v = m.groups()
 1499         keywords[k] = v
 1500       else:
 1501         positional.append(entry)
 }}}

 Due to the split there shouldn't be any extra whitespace around the
 positional entries.

 Are you sure that this is a bug? Are you able to reproduce any use case
 where the strip is needed?

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


More information about the tor-bugs mailing list