0
Fork 0
mirror of https://github.com/project-zot/zot.git synced 2024-12-30 22:34:13 -05:00
zot/pkg/api
Alex Stan 49e8167dbe graphql: Apply authorization on /_search endpoint
- AccessControlContext now resides in a separate package from where it can be imported,
along with the contextKey that will be used to set and retrieve this context value.

- AccessControlContext has a new field called Username, that will be of use for future
implementations in graphQL resolvers.

- GlobalSearch resolver now uses this context to filter repos available to the logged user.

- moved logic for uploading images in tests so that it can be used in every package

- tests were added for multiple request scenarios, when zot-server requires authz
on specific repos

- added tests with injected errors for extended coverage

- added tests for status code error injection utilities

Closes https://github.com/project-zot/zot/issues/615

Signed-off-by: Alex Stan <alexandrustan96@yahoo.ro>
2022-08-26 21:31:26 +03:00
..
config Remove AllowReadOnly and ReadOnly 2022-08-10 14:27:21 -07:00
constants routes: strip query parameter from request URL 2022-06-08 22:50:37 -07:00
authn.go Remove AllowReadOnly and ReadOnly 2022-08-10 14:27:21 -07:00
authz.go graphql: Apply authorization on /_search endpoint 2022-08-26 21:31:26 +03:00
controller.go Added content-type to Access-Control-Allow-Headers needed for playground preflight 2022-08-16 22:47:24 +03:00
controller_test.go graphql: Apply authorization on /_search endpoint 2022-08-26 21:31:26 +03:00
errors.go Leave zot repositories in a consistent state after zot hits fd limit closes #359 2022-03-31 13:25:15 -07:00
errors_test.go move references to zotregistry.io and project-zot 2021-12-05 10:52:27 -08:00
ldap.go lint: upgrade golangci-lint 2021-12-20 17:20:35 -08:00
regexp.go lint: upgrade golangci-lint 2021-12-20 17:20:35 -08:00
routes.go graphql: Apply authorization on /_search endpoint 2022-08-26 21:31:26 +03:00
routes_test.go Fix file handlers not being closed after calls to ImageStore.GetBlob 2022-08-19 09:22:13 -07:00
session.go controller: support rate-limiting incoming requests 2022-01-24 12:48:13 -08:00