• Scott Kuhl's avatar
    Only write /etc/hosts when necessary. · e1106a33
    Scott Kuhl authored
    Without this patch, sshuttle 'restores' /etc/hosts even if it didn't
    make any modifications to it. This can be confirmed by running without
    --auto-hosts and confirming that the modification time of /etc/hosts
    is unchanged while sshuttle is running, but is updated when sshuttle
    exits (and a debug2() message is printed indicating the file is
    written).
    
    I'm not aware of the previous behavior causing problems. However,
    writing an important file unnecessarily as root should be avoided.
    e1106a33
Name
Last commit
Last update
.github/workflows Loading commit data...
bin Loading commit data...
docs Loading commit data...
sshuttle Loading commit data...
tests Loading commit data...
.gitignore Loading commit data...
.prospector.yml Loading commit data...
CHANGES.rst Loading commit data...
LICENSE Loading commit data...
MANIFEST.in Loading commit data...
README.rst Loading commit data...
bandit.yml Loading commit data...
requirements-tests.txt Loading commit data...
requirements.txt Loading commit data...
run Loading commit data...
setup.cfg Loading commit data...
setup.py Loading commit data...
tox.ini Loading commit data...