OpenInternet / copilot

An easy to use censorship simulating access point in a box
https://openinternet.github.io/copilot/
GNU Lesser General Public License v3.0
26 stars 2 forks source link

Wireless network interfaces do not choose consistant names #92

Closed seamustuohy closed 8 years ago

seamustuohy commented 8 years ago

As I discovered in https://github.com/OpenInternet/co-pilot/issues/44 network interfaces are not consistently named. We need to have the create_ap script check what the local interface name is before running scripts against it.

Any fix needs to touch both of these hard coded values. https://github.com/OpenInternet/co-pilot/blob/e73dc9d424caa9f02f508140b416532e8b0ead4d/copilot/plugins/create_ap/start#L3 https://github.com/OpenInternet/co-pilot/blob/f876875cfeaaf96450e554a6c77d8cc81c31586c/copilot/plugins/create_ap/config.py#L39

References:

seamustuohy commented 8 years ago

The way I will go about this is to parse the tree of PCI devices in /sys/class/net and look for the one with a wireless file. That way, not matter what the naming is, I will just grab the wireless device.

seamustuohy commented 8 years ago

Addressed in https://github.com/OpenInternet/co-pilot/pull/94