Commit Graph

15 Commits

Author SHA1 Message Date
Karl Persson 2fd7031102
Access Control: Add fine-grained access control to explore (#35883)
* add fixed role for datasource read operations

* Add action for datasource explore

* add authorize middleware to explore index route

* add fgac support for explore navlink

* update hasAccessToExplore to check if accesscontrol is enable and evalute action if it is

* add getExploreRoles to evalute roles based onaccesscontrol, viewersCanEdit and default

* create function to evaluate permissions or using fallback if accesscontrol is disabled

* change hasAccess to prop and derive the value in mapStateToProps

* add test case to ensure buttons is not rendered when user does not have access

* Only hide return with changes button

* remove internal links if user does not have access to explorer

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2021-07-02 14:43:12 +02:00
Gabriel MABILLE d42d874240
AccessControl: Fix docs link to localhost (#36233)
* AccessControl Correct link to localhost

* Removed extra parenthesis in relref definition
2021-06-28 21:11:09 +02:00
Karl Persson 395b942134
Access Control: Add fine-grained access control to GET stats and settings handlers (#35622)
* add accesscontrol action for stats read

* use accesscontrol middleware for stats route

* add fixed role with permissions to read sever stats

* add accesscontrol action for settings read

* use accesscontrol middleware for settings route

* add fixed role with permissions to read settings

* add accesscontrol tests for AdminGetSettings and AdminGetStats

* add ability to scope settings

* add tests for AdminGetSettings
2021-06-14 17:36:48 +02:00
Karl Persson 36c997a625
Access Control: Add fine-grained access control to ldap handlers (#35525)
* Add new accesscontrol action for ldap config reload

* Update ldapAdminEditRole with new ldap config reload permission

* wrap /ldap/reload with accesscontrol authorize middleware

* document new action and update fixed:ldap:admin:edit with said action

* add fake accesscontrol implementation for tests

* Add accesscontrol tests for ldap handlers

Co-authored-by: Ursula Kallio <73951760+osg-grafana@users.noreply.github.com>
2021-06-11 15:58:18 +02:00
Gabriel MABILLE e75c6a748b
Access-Control: Document changes to the provisioner (#35548) 2021-06-11 13:57:49 +02:00
Karl Persson 92adf2e4ff
Access control: Update docs with new settings permission (#35413)
* Update docs with new action and scopes for settings

Co-authored-by: Ursula Kallio <73951760+osg-grafana@users.noreply.github.com>
2021-06-10 13:20:28 +02:00
Emil Tullstedt dc7a641978
Docs: Fix code sample for access control provisioning (#35406) 2021-06-09 13:47:21 +02:00
Gabriel MABILLE 2bbf4fa405
AccessControl: Update permissions and scopes in docs (#35263)
* Saving the current changes made with @osg-grafana @donomii

* Update remaining descriptions

* Update docs/sources/enterprise/access-control/permissions.md

Co-authored-by: Vardan Torosyan <vardants@gmail.com>

* Cleanup grammar

Co-authored-by: Jeremy Price <Jeremy.price@grafana.com>
Co-authored-by: Vardan Torosyan <vardants@gmail.com>
2021-06-04 18:10:49 +02:00
Gabriel MABILLE 134dba5101
Provisioning: Update accesscontrol sample file 2021-06-02 17:22:34 +02:00
Ursula Kallio 99839ee060
Change weight of reference, so they display last. (#35112) 2021-06-02 16:49:32 +02:00
Jeremy Price 2c85bbb738
Access Control: Provisioning docs cleanup (#34982) 2021-06-02 11:55:37 +02:00
Ursula Kallio e0a3f669e5
Add fine-grained-access-control-references.md file. (#35043)
* Add fine-grained-access-control-references.md file.

* Fix syntax error in relref.

* Fix another syntax error.

* Fix broken link:

see introduction of alert rules at PR
https://github.com/grafana/grafana/pull/34839.
2021-06-01 16:35:38 +02:00
Karl Persson 73b8afe724
Document global role and assignment for provisioning (#34739) 2021-06-01 15:52:46 +02:00
Emil Tullstedt 96da84ca49
Access control: Rename predefined roles to fixed roles (docs) (#34472) 2021-05-26 14:59:24 +02:00
Vardan Torosyan 676ddac088
Docs: Document fine-grained access control (#33563) 2021-05-20 09:53:34 -07:00