0
Fork 0
mirror of https://github.com/project-zot/zot.git synced 2024-12-16 21:56:37 -05:00
zot/pkg/cli
Lisca Ana-Roberta 336526065f
feat(groups)!: added "groups" mechanism for authZ (#1123)
BREAKING CHANGE: repository paths are now specified under a new config key called "repositories" under "accessControl" section in order to handle "groups" feature. Previously the repository paths were specified directly under "accessControl".

This PR adds the ability to create groups of users which can be used for authZ policies, instead of just users.

{
"http": {
   "accessControl": {
       "groups": {

Just like the users, groups can be part of repository policies/default policies/admin policies. The 'groups' field in accessControl can be missing if there are no groups. The permissions priority is user>group>default>admin policy, verified in this order (in authz.go), and permissions are cumulative. It works with LDAP too, and the group attribute name is configurable. The DN of the group is used as the group name and the functionality is the same. All groups for the given user are added to the context in authn.go. Repository paths are now specified under a new keyword called "repositories" under "accessControl" section in order to handle "groups" feature.

Signed-off-by: Ana-Roberta Lisca <ana.kagome@yahoo.com>
2023-03-08 11:47:15 -08:00
..
cli.go build(tags): remove redundant build tag ui_base (#857) 2022-10-10 15:05:55 +03:00
client.go feat(repodb): Multiarch Image support (#1147) 2023-02-27 11:23:18 -08:00
client_elevated_test.go refactor: Cleanup/simplify testcases in /pkg/cli (#1103) 2023-01-16 21:52:50 -08:00
client_test.go test(refactor): cleanup/simplify testcases (#1124) 2023-01-20 10:01:52 -08:00
client_utils_test.go feat(repodb): Multiarch Image support (#1147) 2023-02-27 11:23:18 -08:00
config_cmd.go chore(lint): gci to separate zot from other imports (#870) 2022-10-20 09:39:20 -07:00
config_cmd_test.go chore(lint): gci to separate zot from other imports (#870) 2022-10-20 09:39:20 -07:00
config_reloader.go chore(lint): gci to separate zot from other imports (#870) 2022-10-20 09:39:20 -07:00
config_reloader_test.go feat(groups)!: added "groups" mechanism for authZ (#1123) 2023-03-08 11:47:15 -08:00
cve_cmd.go fix(cli): do not show signatures and fix tls verification client side (#904) 2022-10-22 23:44:20 -07:00
cve_cmd_test.go refactor(test): update cve tests to stop duplicating test/data if not needed (#1232) 2023-03-02 09:45:23 -08:00
discover.go fix(cli): do not show signatures and fix tls verification client side (#904) 2022-10-22 23:44:20 -07:00
extensions_test.go feat(ui): package zui within zot binary (#1161) 2023-02-10 14:52:54 -08:00
image_cmd.go fix(cli): do not show signatures and fix tls verification client side (#904) 2022-10-22 23:44:20 -07:00
image_cmd_test.go feat(repodb): Multiarch Image support (#1147) 2023-02-27 11:23:18 -08:00
minimal.go build(tags): remove redundant build tag ui_base (#857) 2022-10-10 15:05:55 +03:00
repo_cmd.go chore(lint): gci to separate zot from other imports (#870) 2022-10-20 09:39:20 -07:00
root.go feat(groups)!: added "groups" mechanism for authZ (#1123) 2023-03-08 11:47:15 -08:00
root_test.go feat(groups)!: added "groups" mechanism for authZ (#1123) 2023-03-08 11:47:15 -08:00
searcher.go feat(repodb): Multiarch Image support (#1147) 2023-02-27 11:23:18 -08:00
service.go feat(repodb): Multiarch Image support (#1147) 2023-02-27 11:23:18 -08:00
stress_test.go refactor: Cleanup/simplify testcases in /pkg/cli (#1103) 2023-01-16 21:52:50 -08:00