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

policy.kontain.me #40

Open
imjasonh opened this issue Aug 6, 2021 · 0 comments
Open

policy.kontain.me #40

imjasonh opened this issue Aug 6, 2021 · 0 comments

Comments

@imjasonh
Copy link
Owner

imjasonh commented Aug 6, 2021

Some system to let people specify policies that images must adhere to before being able to be pushed or pulled, using some policy language like OPA's Rego, CEL, something along those lines.

E.g., to be able to push to policy.kontain.me/org/app/image the following policy might be put in place:

  • must be based on some approved base image (alpine:latest, not alpine:vulnerable)
  • must not contain a file matching some regex (/etc/bad.exe)
  • must be signed by cosign (signature policies can also apply)
    • because signatures will probably get pushed after the image, this might mean "delete unsigned images after N seconds"

To be able to pull the image, a policy might be:

  • only allow pull by digest
  • must have no unresolved/unacked vulnerabilities (in case new vulns were reported after it was pushed)
  • rate limiting?

Policies, in whatever language, could be bundled into images themselves, at some standard location (policy.kontain.me/org:policy), and apply to pushes/pulls for all images in the hierarchy. Only superusers would be allowed to push to org:policy, and define the policy for users who can push to app:policy or app/image:policy.

Defining policies in a registry means they're content-addressed and portable across registries. It probably makes sense to also track tag history somewhere, so you can audit and rollback.

Accepting pushes requires auth(n,z), which kontain.me hasn't played with yet.

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

1 participant