Skip to content

Conversation

@doakalexi
Copy link
Contributor

@doakalexi doakalexi commented Jan 7, 2025

Summary

This PR is followup to, #203503. This PR adds a test to make sure that sub-feature description remains accurate, and changes to hide the connector edit test tab and create connector button when a user only has read access.

Checklist

To verify

  1. Create a new read only role and disable EDR connectors under the Actions and Connectors privilege
  2. Create a new user and assign that role to user
  3. Create a Sentinel One connector (It doesn't need to work, you can use fake values for the url and token)
  4. Login as the new user and go to the connector page in stack management
  5. Verify that the "Create connector" button is not visible
  6. Click on the connector you created, verify that you can't see the test tab

@doakalexi doakalexi changed the title Connector rbac followup [ResponseOps] Granular Connector RBAC followup Jan 8, 2025
@doakalexi doakalexi changed the title [ResponseOps] Granular Connector RBAC followup [ResponseOps] Granular connector RBAC followup Jan 8, 2025
@doakalexi doakalexi added Team:ResponseOps Platform ResponseOps team (formerly the Cases and Alerting teams) t// release_note:skip Skip the PR/issue when compiling release notes backport:prev-minor v8.18.0 v9.0.0 labels Jan 8, 2025
@doakalexi
Copy link
Contributor Author

/ci

@doakalexi doakalexi marked this pull request as ready for review January 8, 2025 17:51
@doakalexi doakalexi requested a review from a team as a code owner January 8, 2025 17:51
@elasticmachine
Copy link
Contributor

Pinging @elastic/response-ops (Team:ResponseOps)

@doakalexi doakalexi requested review from JiaweiWu and ymao1 January 13, 2025 15:55
@doakalexi doakalexi requested a review from a team as a code owner January 15, 2025 17:17
Copy link
Contributor

@paul-tavares paul-tavares left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the changes. I checked the PR out and ran through the security solution functionality and LGTM 👍

@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
triggersActionsUi 1.7MB 1.7MB +73.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
stackConnectors 61.8KB 61.9KB +90.0B
Unknown metric groups

ESLint disabled line counts

id before after diff
@kbn/test-suites-xpack 742 743 +1

Total ESLint disabled count

id before after diff
@kbn/test-suites-xpack 767 768 +1

History

Copy link
Contributor

@ymao1 ymao1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Works as described.

@doakalexi doakalexi merged commit 12998a8 into elastic:main Jan 21, 2025
8 checks passed
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.x

https://github.com/elastic/kibana/actions/runs/12896296671

kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jan 21, 2025
## Summary

This PR is followup to, elastic#203503.
This PR adds a test to make sure that sub-feature description remains
accurate, and changes to hide the connector edit test tab and create
connector button when a user only has read access.

### Checklist

- [ ] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

### To verify

1. Create a new read only role and disable EDR connectors under the
Actions and Connectors privilege
2. Create a new user and assign that role to user
3. Create a Sentinel One connector (It doesn't need to work, you can use
fake values for the url and token)
4. Login as the new user and go to the connector page in stack
management
5. Verify that the "Create connector" button is not visible
6. Click on the connector you created, verify that you can't see the
test tab

(cherry picked from commit 12998a8)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.x

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Jan 21, 2025
# Backport

This will backport the following commits from `main` to `8.x`:
- [[ResponseOps] Granular connector RBAC followup
(#205818)](#205818)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Alexi
Doak","email":"[email protected]"},"sourceCommit":{"committedDate":"2025-01-21T21:33:54Z","message":"[ResponseOps]
Granular connector RBAC followup (#205818)\n\n## Summary\r\n\r\nThis PR
is followup to, https://github.com/elastic/kibana/pull/203503.\r\nThis
PR adds a test to make sure that sub-feature description
remains\r\naccurate, and changes to hide the connector edit test tab and
create\r\nconnector button when a user only has read access.\r\n\r\n###
Checklist\r\n\r\n- [ ] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common scenarios\r\n\r\n\r\n### To
verify\r\n\r\n1. Create a new read only role and disable EDR connectors
under the\r\nActions and Connectors privilege\r\n2. Create a new user
and assign that role to user\r\n3. Create a Sentinel One connector (It
doesn't need to work, you can use\r\nfake values for the url and
token)\r\n4. Login as the new user and go to the connector page in
stack\r\nmanagement\r\n5. Verify that the \"Create connector\" button is
not visible\r\n6. Click on the connector you created, verify that you
can't see the\r\ntest
tab","sha":"12998a8fe1823c3ba672ad8ff68a1292ccc72d8e","branchLabelMapping":{"^v9.0.0$":"main","^v8.18.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:ResponseOps","v9.0.0","backport:prev-minor","v8.18.0"],"title":"[ResponseOps]
Granular connector RBAC
followup","number":205818,"url":"https://github.com/elastic/kibana/pull/205818","mergeCommit":{"message":"[ResponseOps]
Granular connector RBAC followup (#205818)\n\n## Summary\r\n\r\nThis PR
is followup to, https://github.com/elastic/kibana/pull/203503.\r\nThis
PR adds a test to make sure that sub-feature description
remains\r\naccurate, and changes to hide the connector edit test tab and
create\r\nconnector button when a user only has read access.\r\n\r\n###
Checklist\r\n\r\n- [ ] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common scenarios\r\n\r\n\r\n### To
verify\r\n\r\n1. Create a new read only role and disable EDR connectors
under the\r\nActions and Connectors privilege\r\n2. Create a new user
and assign that role to user\r\n3. Create a Sentinel One connector (It
doesn't need to work, you can use\r\nfake values for the url and
token)\r\n4. Login as the new user and go to the connector page in
stack\r\nmanagement\r\n5. Verify that the \"Create connector\" button is
not visible\r\n6. Click on the connector you created, verify that you
can't see the\r\ntest
tab","sha":"12998a8fe1823c3ba672ad8ff68a1292ccc72d8e"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/205818","number":205818,"mergeCommit":{"message":"[ResponseOps]
Granular connector RBAC followup (#205818)\n\n## Summary\r\n\r\nThis PR
is followup to, https://github.com/elastic/kibana/pull/203503.\r\nThis
PR adds a test to make sure that sub-feature description
remains\r\naccurate, and changes to hide the connector edit test tab and
create\r\nconnector button when a user only has read access.\r\n\r\n###
Checklist\r\n\r\n- [ ] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common scenarios\r\n\r\n\r\n### To
verify\r\n\r\n1. Create a new read only role and disable EDR connectors
under the\r\nActions and Connectors privilege\r\n2. Create a new user
and assign that role to user\r\n3. Create a Sentinel One connector (It
doesn't need to work, you can use\r\nfake values for the url and
token)\r\n4. Login as the new user and go to the connector page in
stack\r\nmanagement\r\n5. Verify that the \"Create connector\" button is
not visible\r\n6. Click on the connector you created, verify that you
can't see the\r\ntest
tab","sha":"12998a8fe1823c3ba672ad8ff68a1292ccc72d8e"}},{"branch":"8.x","label":"v8.18.0","branchLabelMappingKey":"^v8.18.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Alexi Doak <[email protected]>
viduni94 pushed a commit to viduni94/kibana that referenced this pull request Jan 23, 2025
## Summary

This PR is followup to, elastic#203503.
This PR adds a test to make sure that sub-feature description remains
accurate, and changes to hide the connector edit test tab and create
connector button when a user only has read access.

### Checklist

- [ ] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios


### To verify

1. Create a new read only role and disable EDR connectors under the
Actions and Connectors privilege
2. Create a new user and assign that role to user
3. Create a Sentinel One connector (It doesn't need to work, you can use
fake values for the url and token)
4. Login as the new user and go to the connector page in stack
management
5. Verify that the "Create connector" button is not visible
6. Click on the connector you created, verify that you can't see the
test tab
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release_note:skip Skip the PR/issue when compiling release notes Team:ResponseOps Platform ResponseOps team (formerly the Cases and Alerting teams) t// v8.18.0 v9.0.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants