[CalendarServer-dev] [CalendarServer] #274: caldavd does not properly quote parameters

CalendarServer trac at macosforge.org
Thu May 22 18:41:48 PDT 2008

#274: caldavd does not properly quote parameters
 Reporter:  kmdurbrow at gmail.com  |        Owner:  wsanchez at apple.com
     Type:  Defect               |       Status:  new               
 Priority:  3: Important         |    Milestone:  2.x               
Component:  Calendar Server      |      Version:                    
 Severity:  Other                |   Resolution:                    
 Keywords:                       |  
Changes (by wsanchez at apple.com):

  * priority:  5: Not set => 3: Important
  * milestone:  => 2.x


 This is tricky. `"${configfile}"` is either `""` or `"-f some_file"`. (In
 your case, I'm assuming it's actually `"-f some file"`, with a space.)  So
 quoting it outright makes it into one token, which isn't what we want; we
 want zero or two tokens.

 I think what actually wants to change is something like

 configfile="-f ${OPTARG}"


 configfile="-f \"${OPTARG}\""

 But then the exec line at the bottom still tokenized on the space in the
 filename...  Don't know what the right way to fix that is, offhand, other
 than to rewrite the script in a language (Python) that doesn't have this
 goofy tokenization stuff all over the place.

Ticket URL: <https://trac.calendarserver.org/ticket/274#comment:1>
CalendarServer </>

More information about the calendarserver-dev mailing list