Skip to content
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

File Permissions being Overridden in Docker Deployment #98

Open
hreineck opened this issue Jun 1, 2022 · 1 comment
Open

File Permissions being Overridden in Docker Deployment #98

hreineck opened this issue Jun 1, 2022 · 1 comment
Labels
bug Something isn't working

Comments

@hreineck
Copy link
Contributor

hreineck commented Jun 1, 2022

When using the OSCAL Editor in the all-in-one Docker environment, saving any changes causes the file permissions to change to -rw-r--r--, making it so that the user within Docker is the only user with write permissions.

Implementation Notes

I'm assuming that this is an issue with the "save" feature of the REST service itself, but it could very well be an issue with Docker configuration.

@hreineck hreineck added the bug Something isn't working label Jun 1, 2022
@laurelmay
Copy link
Contributor

I think it's both -- So

Files.move(tempFile.toPath(), oscalFile.toPath(), StandardCopyOption.REPLACE_EXISTING);
is definitely a cause. We probably also want COPY_ATTRIBUTES and maybe even ATOMIC_MOVE.

But as far as the owning user changing, that's 100% expected behavior as far as I'm concerned. The container is running "rootless" (in a user namespace) and the user is a non-zero UID. So when that user performs a write operation, it should in fact perform the write as that user.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants