Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

entityanalytics_okta: split user and device data into their own data streams #12798

Merged
merged 7 commits into from
Mar 3, 2025

Conversation

efd6
Copy link
Contributor

@efd6 efd6 commented Feb 17, 2025

Proposed commit message

entityanalytics_okta: split user and device data into their own data streams

The entityanalytics integrations obtain entity data from a variety of
reasonably consistent data sources relating to system entities. These include
users and devices, and their associated attributes. Initially the
implementations of these integration only reported and indexed user data, but
device data collection was added to the integrations whose data sources made
that data available. In the case of the entra_id integration the user and
device documents were separated into separated data streams, enabling a more
refined approach to entity-based risk assessment. In this integration this
was not done, resulting in user and device data being placed in a data stream
labelled as user data. This can lead to confusing results being presented to
analysts.

So this change separates user data from device data and presents them in
separate data streams, leaving any non-user, non-device data in the
generalised entity data stream. The change does not alter the behaviour of
the user data stream beyond ensuring that device data does not get included
and so is not a breaking change. However, the upgrade path is not transparent
so this is marked as a v2 and an upgrade note is added to the documentation.

Checklist

  • I have reviewed tips for building integrations and this pull request is aligned with them.
  • I have verified that all data streams collect metrics or logs.
  • I have added an entry to my package's changelog.yml file.
  • I have verified that Kibana version constraints are current according to guidelines.
  • I have verified that any added dashboard complies with Kibana's Dashboard good practices

Author's Checklist

  • [ ]

How to test this PR locally

Related issues

Screenshots

…ta streams

This retains user data behaviour, routing non-user data in to the new entity data
stream. This allows device data to be routed to a to-be-added device data stream.
@efd6 efd6 added enhancement New feature or request Team:Security-Service Integrations Security Service Integrations Team [elastic/security-service-integrations] Integration:entityanalytics_okta Okta Entity Analytics labels Feb 17, 2025
@efd6 efd6 self-assigned this Feb 17, 2025
@efd6 efd6 force-pushed the 12657-entityanalytics_okta branch from 1467f40 to 9328a62 Compare February 17, 2025 04:53
@elastic-vault-github-plugin-prod

🚀 Benchmarks report

To see the full report comment with /test benchmark fullreport

@efd6 efd6 marked this pull request as ready for review February 17, 2025 05:28
@efd6 efd6 requested a review from a team as a code owner February 17, 2025 05:28
@elasticmachine
Copy link

Pinging @elastic/security-service-integrations (Team:Security-Service Integrations)

@efd6 efd6 marked this pull request as draft February 23, 2025 23:42
@efd6 efd6 force-pushed the 12657-entityanalytics_okta branch from 5691c6e to 1f6024d Compare February 23, 2025 23:51
@efd6 efd6 force-pushed the 12657-entityanalytics_okta branch from 1f6024d to d746cda Compare February 23, 2025 23:56
@efd6 efd6 marked this pull request as ready for review February 24, 2025 01:03
@efd6
Copy link
Contributor Author

efd6 commented Feb 27, 2025

Upgrade path is bumpy. Investigating.

@efd6 efd6 marked this pull request as draft February 27, 2025 04:52
Comment on lines 47 to 50
inputs:
- type: entity-analytics
title: Collect device identities
description: Collecting device identities from Okta.
Copy link
Member

Choose a reason for hiding this comment

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

On the Add Integration page, I see three separate inputs. I think that in this file we should only have one instance of the entity-analytics input on the entity data stream.

Suggested change
inputs:
- type: entity-analytics
title: Collect device identities
description: Collecting device identities from Okta.

@efd6 efd6 requested review from kcreddy and andrewkroh February 28, 2025 06:56
@@ -6,6 +6,12 @@ This [Okta Entity Analytics](https://www.okta.com/) integration allows users to

This module has been tested against the Core Okta API version **v1**.

## Upgrading to v2 from v1
Copy link
Contributor

Choose a reason for hiding this comment

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

Just a thought:
Should we rename v1 and v2 to 1.x and 2.x, or users infer them anyway?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm finding it hard to get my brain into a state where v1 is not 1.x and v2 is not 2.x, though I do see that v1 is used immediately above referring to the API, so I will add, "of the integration" to the end of the sentence.


In v2 of the integration the user and device data was split into separate data streams. The data ingested into your index will be the same but you may need to update device searches if you were using them.

**NOTE**: When you upgrade from v1 you will need to reconfigure the integration and enable it due to internal changes in the package.
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The issue is not that fields fail to match, it's that the configuration is no longer visible since the name of the policy that holds it has changed, but I will add that link.

@efd6 efd6 force-pushed the 12657-entityanalytics_okta branch from a9d3d70 to 1c587ac Compare March 2, 2025 20:32
@elasticmachine
Copy link

💚 Build Succeeded

History

cc @efd6

Copy link

Quality Gate failed Quality Gate failed

Failed conditions
75.1% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube

@efd6 efd6 marked this pull request as ready for review March 2, 2025 22:38
@efd6 efd6 merged commit 0978854 into elastic:main Mar 3, 2025
6 of 7 checks passed
@elastic-vault-github-plugin-prod

Package entityanalytics_okta - 2.0.0 containing this change is available at https://epr.elastic.co/package/entityanalytics_okta/2.0.0/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Integration:entityanalytics_okta Okta Entity Analytics Team:Security-Service Integrations Security Service Integrations Team [elastic/security-service-integrations]
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[entityanalytics_okta]: device assets mixed up with user assets
4 participants