Re: Per-SSID lease file?
Roy Marples
Mon Feb 09 17:33:48 2015
On 09/02/2015 16:36, Roy Marples wrote:
> Hi
>
> On 09/02/2015 15:55, Pierre-Hugues Husson wrote:
>> I'm happy to see that.
>>
>> I still have one concern, what to do with SSID:
>> In my understanding, your print_string returns an error if the SSID has
>> "wrong" characters, imho it should only drop wrong characters.
>> Also, it's not dropping / or . symbols, and I'm not confident in saying
>> it can't be used as a security flaw
>
> ESCSTRING dictates that no characters are dropped, just escaped
> so a NUL character is translated to a 4 character string of \000
>
> But you are correct about / and .
> I will add some more tests to escape special file paths.
http://roy.marples.name/projects/dhcpcd/ci/10116fb1f19f32205e8ab2769f3c604c9c635563?sbs=0
Escaping / should be sufficient as . only has meaning when preceded by /
Happy with this now?
Roy
Archive administrator: postmaster@marples.name