This may become a warning rather than an action later, but for now
let's make sure older installations that had incorrect permissions
are taken care of.
This is a stop-gap CSRF protection mechanism from unsophisticated attacks. It's to be considered a temporary solution until a more complete one can be implemented, but it should be sufficient in most cases for the time being.
See https://github.com/tonarino/innernet/issues/38 for further discussion.
It was dropping the last character in the name, and I modified it to
instead just error on any &str that has a '\0' in it. The strictness
feels acceptable and simplifies the code a bit.
wgctrl-rs will now look for the WG_USERSPACE_IMPLEMENTATION or
WG_QUICK_USERSPACE_IMPLEMENTATION environment variables to
override the default wireguard-go userspace implementation choice.
Closes#34
Introduces `--hosts-path [PATH]` and `--no-write-hosts` options in `innernet`.
This could be further improved to have a persistent setting in a config file i.e. /etc/innernet.conf (which doesn't currently exist).
Fixes#6