[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #5454 [Stem]: ExitPolicy Class for stem



#5454: ExitPolicy Class for stem
-------------------------+--------------------------------------------------
 Reporter:  gsathya      |          Owner:  atagar           
     Type:  enhancement  |         Status:  needs_information
 Priority:  normal       |      Milestone:                   
Component:  Stem         |        Version:                   
 Keywords:               |         Parent:                   
   Points:               |   Actualpoints:                   
-------------------------+--------------------------------------------------

Comment(by atagar):

 > Okay, let me do that. Also do you want me to check the exit policy
 string with a regexp for errors? I'm guessing this would take a while if
 we have to match _every_ other pattern _and_ check for correctness(like
 octets should be less than 256 etc)?

 Yes and no. We should be validating the ExitPolicy string, much as we do
 with everything else, and giving an error if any of it is invalid
 (malformed ips, invalid port numbers, etc). However, we shouldn't be doing
 this via a regex.

 You can find some helper functions for checking validity in the connection
 util...
 https://gitweb.torproject.org/stem.git/blob/HEAD:/stem/util/connection.py#l15

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/5454#comment:16>
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