3
0
mirror of https://github.com/grafana/grafana.git synced 2025-02-25 18:55:37 -06:00
grafana/pkg/models
Karl Persson a5e4a533fa
Access control: use uid for dashboard and folder scopes ()
* use uid:s for folder and dashboard permissions

* evaluate folder and dashboard permissions based on uids

* add dashboard.uid to accept list

* Check for exact suffix

* Check parent folder on create

* update test

* drop dashboard:create actions with dashboard scope

* fix typo

* AccessControl: test id 0 scope conversion

* AccessControl: store only parent folder UID

* AccessControl: extract general as a constant

* FolderServices: Prevent creation of a folder uid'd general

* FolderServices: Test folder creation prevention

* Update pkg/services/guardian/accesscontrol_guardian.go

* FolderServices: fix mock call expect

* FolderServices: remove uneeded mocks

Co-authored-by: jguer <joao.guerreiro@grafana.com>
2022-03-30 15:14:26 +02:00
..
address.go feat(organization): added update org address to http api and to org details settings view, closes 2015-09-08 14:22:44 +02:00
alert_notifications.go API: Extract OpenAPI specification from source code using go-swagger () 2022-02-08 13:38:43 +01:00
alert_test.go Chore: Rewrite models alert test to standard library () 2021-01-01 13:18:47 +01:00
alert.go Add missing option "OK" for Error state () 2022-03-02 19:07:55 -05:00
apikey.go Separate API key store from SA token store () 2022-02-28 11:30:45 +01:00
context_test.go Chore: replace macaron with web package () 2021-10-11 14:30:59 +02:00
context.go Application: Make error-template title configurable () 2021-10-13 08:35:01 +02:00
dashboard_acl_test.go Chore: Rewrite models dashboard acl test to standard library () 2021-01-01 13:22:48 +01:00
dashboard_acl.go Forbid creation of dashboard permissions with both a user and a team () 2021-10-13 12:16:58 -06:00
dashboard_snapshot.go API: Extract OpenAPI specification from source code using go-swagger () 2022-02-08 13:38:43 +01:00
dashboard_thumbs.go Previews: capability check () 2022-02-16 21:49:50 +04:00
dashboard_version.go Chore: Fix staticcheck issues () 2020-11-05 13:07:06 +01:00
dashboards_test.go Chore: Rewrite models dashboards test to standard library () 2021-01-01 13:29:40 +01:00
dashboards.go ValidatedQueries: start of validated queries API () 2022-03-07 09:33:01 -09:00
datasource.go Data sources: Grant creator edit permissions to data source by default () 2022-03-21 17:16:05 +01:00
folders.go Access control: use uid for dashboard and folder scopes () 2022-03-30 15:14:26 +02:00
health.go feat: added api health endpoint that does not require auth and never creates sessions, returns db status as well. 2017-04-25 17:17:45 +02:00
helpflags.go Chore: Remove unused Go code () 2020-11-17 11:51:31 +01:00
jwt.go Migrate to Wire for dependency injection () 2021-08-25 15:11:22 +02:00
libraryelements.go LibraryElements: Creates usage stats for panels and variables () 2021-05-24 06:11:01 +02:00
licensing.go FeatureFlags: Revert managing feature flags outside of settings.Cfg () 2022-01-24 16:08:05 +01:00
live.go Live: proxy subscribe data for subscribe and runstream plugin calls () 2021-12-14 20:12:00 +03:00
login_attempt.go login: uses epochs for login throtting. 2018-02-16 17:25:46 +01:00
models.go Okta OAuth provider (team sync support) () 2020-04-02 17:35:48 +03:00
notifications.go Email: Allow configuration of content types for email notifications () 2021-07-19 13:31:51 +03:00
org_user.go Service accounts: Split user and service account database () 2022-03-14 18:24:07 +01:00
org.go Chore: Fix staticcheck issues () 2020-11-05 13:07:06 +01:00
playlist.go Chore: Remove unused Go code () 2020-11-17 11:51:31 +01:00
plugin_settings.go Encryption: Refactor securejsondata.SecureJsonData to stop relying on global functions () 2021-10-07 17:33:50 +03:00
preferences.go Navigation: Introduce a preferences table to store Navbar preferences () 2022-03-17 12:07:20 +00:00
quotas.go Alerting: Remove ngalert feature toggle and introduce two new settings for enabling Grafana 8 alerts and disabling them for specific organisations () 2021-09-29 16:16:40 +02:00
search_user_filter.go Create search filters by interface () 2021-10-07 16:06:16 +02:00
search.go remove bus from search and avoid import cycle () 2022-03-21 23:54:30 +08:00
shorturl.go Short URL: Cleanup unvisited/stale short URLs () 2020-11-09 18:08:16 +01:00
star.go Chore: Fix staticcheck issues () 2020-11-05 13:07:06 +01:00
stats.go Usage stats: Count API keys () 2021-12-22 17:37:45 +01:00
tags_test.go Chore: Rewrite models tags test to standard library () 2021-01-05 17:20:41 +01:00
tags.go Create annotations () 2017-10-07 10:31:39 +02:00
team_member.go AccessControl: Implement SQL filters for team members filtering () 2022-02-09 17:46:37 +01:00
team.go Security: Sync security changes on main () 2022-02-09 13:44:38 +01:00
temp_user.go Users: Expire old user invites () 2020-10-13 12:30:09 +02:00
theme.go Dash previews: populate crawler queue from SQL query () 2022-02-09 13:23:32 +04:00
user_auth.go LDAP: Use an interface instead of a bus to get group teams () 2022-02-01 12:03:21 +01:00
user_token.go Migrate to Wire for dependency injection () 2021-08-25 15:11:22 +02:00
user.go ingore permissions in json serialization () 2022-03-07 16:35:57 +01:00
validations.go Plugins: Requests validator () 2021-02-03 20:47:45 +01:00