nMustaki / debinterface

A simple Python library for dealing with the /etc/network/interfaces file in most Debian based distributions.
BSD 3-Clause "New" or "Revised" License
10 stars 16 forks source link

Interface file permissions are written as rw------- #14

Closed mchubby closed 7 years ago

mchubby commented 8 years ago

debinterface relies on tempfile.NamedTemporaryFile to create the file. Debian does not set such permissions at install time.

The 0600 permissions are hardwired in NamedTemporaryFile by design.

nMustaki commented 8 years ago

Good catch ! We should chmod to 0644. Again, do you want to submit a PR ?

-- / "What do you despise? By this you are truly known." from Manual of Muad'Dib by the Princess Irulan. /

On Fri, Dec 9, 2016 at 10:56 AM, mchubby notifications@github.com wrote:

debinterface relies on tempfile.NamedTemporaryFile to create the file. Debian does not set such permissions at install time.

The 0600 permissions are hardwired in NamedTemporaryFile by design http://stackoverflow.com/questions/10541760/can-i-set-the-umask-for-tempfile-namedtemporaryfile-in-python .

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/nMustaki/debinterface/issues/14, or mute the thread https://github.com/notifications/unsubscribe-auth/AA-fUTBoUFeZIFOsCSVK7TWSX0qeJQwUks5rGSXCgaJpZM4LIwol .