graphql-engine/server/src-lib/Data
Swann Moreau 8bd34b4a51 server, pro: add support for per-role allowlists
spec: https://github.com/hasura/graphql-engine-mono/pull/2278

Briefly:
- extend metadata so that allowlist entries get a new scope field
- update `add_collection_to_allowlist` to accept this new scope field,
  and adds `update_scope_of_collection_in_allowlist` to change the scope
- scope can be global or role-based; a collection is available for every
  role if it is global, and available to every listed role if it is role-based
- graphql-engine-oss is aware of role-based allowlist metadata; collections
  with non-global scope are treated as if they weren't in the allowlist

To run the tests:
- `cabal run graphql-engine-tests -- unit --match Allowlist`
- py-tests against pro:
  - launch `graphql-engine-pro` with `HASURA_GRAPHQL_ADMIN_SECRET` and `HASURA_GRAPHQL_ENABLE_ALLOWLIST`
  - `pytest test_allowlist_queries.py --hge-urls=... --pg-urls=... --hge-key=... --test-allowlist-queries --pro-tests`

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/2477
Co-authored-by: Anon Ray <616387+ecthiender@users.noreply.github.com>
Co-authored-by: Robert <132113+robx@users.noreply.github.com>
GitOrigin-RevId: 01f8026fbe59d8701e2de30986511a452fce1a99
2022-02-08 16:54:49 +00:00
..
Aeson server: fix JSON path in error when parsing sources in metadata 2021-11-11 15:56:36 +00:00
GADT/Compare server, pro: actually reformat the code-base using ormolu 2021-09-23 22:57:37 +00:00
HashMap/Strict server, pro: add support for per-role allowlists 2022-02-08 16:54:49 +00:00
List server, pro: actually reformat the code-base using ormolu 2021-09-23 22:57:37 +00:00
Parser server: Refresh JWKs maximum once per second 2022-01-28 00:18:56 +00:00
Sequence server, pro: actually reformat the code-base using ormolu 2021-09-23 22:57:37 +00:00
Text server, pro: actually reformat the code-base using ormolu 2021-09-23 22:57:37 +00:00
Time/Clock server, pro: actually reformat the code-base using ormolu 2021-09-23 22:57:37 +00:00
Tuple server, pro: actually reformat the code-base using ormolu 2021-09-23 22:57:37 +00:00
URL server, pro: actually reformat the code-base using ormolu 2021-09-23 22:57:37 +00:00
Environment.hs Allows for mock env vars in test-webhook-transform endpoint 2021-12-09 07:59:46 +00:00
SqlCommenter.hs server, pro: actually reformat the code-base using ormolu 2021-09-23 22:57:37 +00:00
TByteString.hs Feature/webhook response transforms 2022-01-19 04:47:36 +00:00