As for `/etc/network/interfaces`, when you install `wpa-supplicant`, a script hook is installed in: - `/etc/network/if-down.d` - `/etc/network/if-post-down.d` - `/etc/network/if-pre-up.d` - `/etc/network/if-up.d`, The hook is called `wpasupplicant` and is a symlink to `/etc/wpa-supplicant/ifupdown.sh`. This hook will be invoked by `ifup` / `ifdown`, and the script the symlink points too tests wether the interface is wireless or not. If that is the case, the command will be passed on to `wpa-supplicant`. For acting on the commands, passing them to `/sbin/wpa-supplicant`, it seems the script `/sbin/wpa_action` and the binary `/sbin/wpa_cli` are used.