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

Docker container redis:alpine contains files with unsafe permissions #404

Open
zem opened this issue Jun 21, 2024 · 1 comment
Open

Docker container redis:alpine contains files with unsafe permissions #404

zem opened this issue Jun 21, 2024 · 1 comment

Comments

@zem
Copy link

zem commented Jun 21, 2024

The Docker Image docker.io/library/redis:alpine is containing files with unsafe permissions, in this case ./usr/local/bin/docker-entrypoint.sh is chmod 777 files whith chmod 777 should be found nowhere on a unix system for security reasons, not even in containers as it can be used as backdoor to escalate privileges!

Here you can see the output of my container creation framework (podman-tools), which contains
a container linter to avoid running potential insecure containers:

podman container create  --volume mastodon_redis:/data --restart always --name mastodon_redis --pod mastodon  docker.io/library/redis:alpine 
b401a0b13ade88729e3f66a68caf603f484f11e5664563e7d05517b1cd09507e
WARNING! FOUND FILES WITH UNSAFE PERMISSIONS IN CONTAINER!
path relative to container root
-rwxrwxrwx. 1 root root 661 Jun 20 20:55 ./usr/local/bin/docker-entrypoint.sh
WARNING! FOUND FILES WITH UNSAFE PERMISSIONS IN CONTAINER!
container mastodon_redis lint failed
@zem zem changed the title Docker container redis:alpine contains files with unsafe permissions! Docker container redis:alpine contains files with unsafe permissions Jun 21, 2024
@tianon
Copy link
Contributor

tianon commented Jun 21, 2024

This is another case of moby/buildkit#5066 😞

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants