-
Notifications
You must be signed in to change notification settings - Fork 155
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Log and config file generation as 0640 root:adm #1182
Conversation
dbungert
commented
Feb 10, 2022
- Implement file mode 0640, owner root:adm for log files and config files that will be copied to the target system and may contain sensitive information.
- Centralize on subiquity-specific write_file & helper funtions rather than a mix of curtin / cloud-init / subiquity versions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't have much context to lean on. But I think we want to keep more restrictive permissions for /autoinstall.yaml
8443b75
to
fe67168
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a couple of comments. Sorry for the slow review!
Create open_perms context manager for custom or multiple writes. Create generate_config for a small removal of redundancy. 0640 root:adm the resulting files.
The two usages of generate_config were both for yaml, so make that simpler.
omode used to be in use, but has been standardized to 'w'. copy_mode was unused. Remove both.
fe67168
to
42db747
Compare