rockymeza / wifi

[unmaintained] WiFi tools for linux
http://pypi.python.org/pypi/wifi
BSD 2-Clause "Simplified" License
305 stars 151 forks source link

schema with colons brakes the library #106

Open albertogeniola opened 8 years ago

albertogeniola commented 8 years ago

Hi all,

I want to report that a schema is saved without any attention to "special chars", things get broken. I discovered it by saving schema names with the associated BSSID. The library does not complain when saving the schema, so colons are reported in /etc/network/interfaces. However, any further invocation of schema.find() will throw an exception: "need more than 1 value to unpack".

This happens because interface file is parsed without any special handling for colons.

My quick workaround at this time is to replace colons with underscores.