Add support for deprecated roles#57209
Conversation
f32c39c to
e5141b7
Compare
e5141b7 to
58a25fa
Compare
|
Pinging @elastic/kibana-security (Team:Security) |
| */ | ||
| export function isReadOnlyRole(role: Partial<Role>): boolean { | ||
| return isReservedRole(role) || (role._transform_error?.length ?? 0) > 0; | ||
| export function isRoleReadOnly(role: Partial<Role>): boolean { |
There was a problem hiding this comment.
note Just a rename to be more consistent with the other functions in this module
|
|
||
| interface Props { | ||
| authc: AuthenticationServiceSetup; | ||
| apiClient: PublicMethodsOf<UserAPIClient>; |
There was a problem hiding this comment.
note: just a rename to make the client instance clearer, since this component now requires two API clients
| }, | ||
| management: { | ||
| kibanaSearchSettings: `${ELASTIC_WEBSITE_URL}guide/en/kibana/${DOC_LINK_VERSION}/advanced-options.html#kibana-search-settings`, | ||
| dashboardSettings: `${ELASTIC_WEBSITE_URL}guide/en/kibana/${DOC_LINK_VERSION}/advanced-options.html#kibana-dashboard-settings`, |
There was a problem hiding this comment.
Added to support the Deprecated badge for the xpackDashboardMode:roles Advanced Setting added in:
| defaultMessage="Enable mapping" | ||
| /> | ||
| } | ||
| label={i18n.translate( |
There was a problem hiding this comment.
note This just resolves an EUI warning where EuiSwitch's label must be a string when showLabel={false}.
pgayvallet
left a comment
There was a problem hiding this comment.
LGTM for platform changes
|
@elastic/kibana-security this is ready for review |
|
ACK: reviewing |
x-pack/plugins/security/public/management/role_combo_box/role_combo_box.tsx
Show resolved
Hide resolved
...s/security/public/management/role_mappings/edit_role_mapping/role_selector/role_selector.tsx
Show resolved
Hide resolved
...security/public/management/role_mappings/role_mappings_grid/role_mappings_grid_page.test.tsx
Show resolved
Hide resolved
x-pack/plugins/security/public/management/roles/roles_grid/roles_grid_page.tsx
Show resolved
Hide resolved
x-pack/plugins/security/public/management/users/edit_user/edit_user_page.tsx
Show resolved
Hide resolved
x-pack/plugins/security/public/management/users/users_grid/users_grid_page.tsx
Show resolved
Hide resolved
x-pack/plugins/security/public/management/users/users_grid/users_grid_page.tsx
Show resolved
Hide resolved
|
@elasticmachine merge upstream |
|
@elasticmachine merge upstream |
|
@elasticmachine merge upstream |
|
@elasticmachine merge upstream |
|
@kobelb this is ready for another pass. Flaky test result appears unrelated to any changes here. |
…ort-deprecated-roles
|
Here are some suggestions to tighten up the text a bit: Tooltip Roles Feature privileges Mapping |
…ort-deprecated-roles
|
Thanks @gchaps! I'd like to make the copy for the "Tooltip" and "Feature privileges" suggestions match, as they're currently generated using a shared mechanism. Would you be ok replacing
with
More generically, the message looks like this:
Where |
…o/kibana into security/support-deprecated-roles
|
@legrego good idea to make the text match. I edited the tooltip to match our marketing guidelines--we prefer to use Dashboard without "feature" or "app". Also, it makes the text shorter. The kibana_dashboard_only_user role is deprecated. Configure a custom role to grant access to Dashboard. |
…ort-deprecated-roles
💚 Build SucceededHistory
To update your PR or re-run it, just comment with: |
* Add support for deprecated roles * address PR feedback * remove unused import * copy edits * fix snapshots Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
|
Opened corresponding Elasticsearch PR to update deprecation reasons: elastic/elasticsearch#53074 |
* Add support for deprecated roles * address PR feedback * remove unused import * copy edits * fix snapshots Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com> Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Summary
Updates the User, Role, and Role Mappings management pages to warn about the use of deprecated roles.
Resolves #25722
Dashboard Only Mode Roles
Deprecates the advanced setting:

User Grid Page
Edit User Page
Role Grid Page
View Deprecated Role
Role Mappings Grid Page
Edit Role Mapping Page