Add connector permissions to fleet server service account#112556
Merged
seanstory merged 10 commits intoelastic:mainfrom Sep 17, 2024
Merged
Add connector permissions to fleet server service account#112556seanstory merged 10 commits intoelastic:mainfrom
seanstory merged 10 commits intoelastic:mainfrom
Conversation
Contributor
Author
|
@elasticmachine merge upstream |
Collaborator
|
Pinging @elastic/es-security (Team:Security) |
Collaborator
|
Pinging @elastic/ingestion-team (Team:Search - Extract & Transform) |
Collaborator
|
Pinging @elastic/ent-search-eng (Team:SearchOrg) |
…zb/elasticsearch into add-connector-permissions-to-fleet
1 task
seanstory
approved these changes
Sep 11, 2024
Member
seanstory
left a comment
There was a problem hiding this comment.
LGTM from the Search team side.
@jakelandis pointed out that we don't need connector secrets, which is the only difference between these too. We don't have a pretty name for the narrower permissions, but we don't need one here. Co-authored-by: Artem Shelkovnikov <lavatroublebubble@gmail.com>
Member
|
buildkite test this |
seanstory
added a commit
to elastic/kibana
that referenced
this pull request
Sep 17, 2024
## Summary Defines custom permissions for connector package. Note: Wait with merging until elastic/elasticsearch#112556 is merged ### Checklist Delete any items that are not applicable to this PR. - [x] [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 + tested e2e with local ES, fleet server and connectors package --------- Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com> Co-authored-by: Sean Story <sean.j.story@gmail.com> Co-authored-by: Artem Shelkovnikov <lavatroublebubble@gmail.com> Co-authored-by: Artem Shelkovnikov <artem.shelkovnikov@elastic.co>
Member
|
@elasticmachine merge upstream |
Member
|
Bump @elastic/fleet , would love to get a cursory review from one of y'all before we merge this. |
javanna
pushed a commit
to javanna/elasticsearch
that referenced
this pull request
Sep 18, 2024
…2556) * Add connector permissions to fleet server service account * [Security] Add permissions to manage connectors for fleet-server service account * Fix tests * Fix tests * Fix typ again (tm) * switch to connector/* vs manage_connectors @jakelandis pointed out that we don't need connector secrets, which is the only difference between these too. We don't have a pretty name for the narrower permissions, but we don't need one here. Co-authored-by: Artem Shelkovnikov <lavatroublebubble@gmail.com> --------- Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com> Co-authored-by: Sean Story <sean.j.story@gmail.com> Co-authored-by: Artem Shelkovnikov <lavatroublebubble@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Add permissions to
fleet-serverservice account to enable running elastic/connectors as an integration.Fleet service service account owns and generates api keys that are used by integrations (components) enrolled in fleet. Connectors are (soon) an integrations that can be deployed in agentless to offer Elastic-managed ingestion story.
There is a corresponding PR in kibana that would grant custom permissions to the
elastic_connectorspackage: elastic/kibana#192081Explanation of added permission
manage_connectorrolecluster:admin/xpack/connector/*- connector service needs to be able to read and write from internal connector indices, there is an ongoing effort to move to this role for connector APIs (see this PR for reference).elastic-connectors*- this is how we currently manage access to internal connector indices, we need read, write and manage access (for refresh operation), this maps to how this is set up in enterprise-search-server service accountcontent-*, user can decide on the index name. This corresponds to search- prefix from enterprise-search-server.search-acl-filter-*- this is a required (and hardcoded in few places) prefix for index storing data related to document-level security logic. If connector index name is e.g.content-google-drive, its corresponding ACL index will be:.search-acl-filter-content-google-drivein
enterprise-search-serverwe defined index-level permissions to beread,write,manage, we can be more granual with"read", "write","monitor","create_index","auto_configure","maintenance"(this would at least prevent deletion of the index)