Developing a #Python application for a #RaspberryPi. Need to write to an #EEPROM to update some state information without human intervention.
Unless there's some way I've missed to make the files for all 1-wire devices (dynamically added at runtime) more open than root:root / rw-r--r--, I'm going to need root access just so I can write this data.
It's made me think about writing some C for the first time in 30 years, just a short #program that only accepts two parameters: the EEPROM id and the data I want to write. That way I can limit additional #root access to suid on a very restricted tool.
Is this just stupid? Obviously, I can add myself with NOPASSWORD to /etc/sudoers and go about my life. The device has nothing insecure on it, so I can't see any harm from doing the sloppy thing. But it still feels wrong.