Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
165 commits
Select commit Hold shift + click to select a range
4d405a0
feat: add trusted devices feature flag and role
szwarckonrad Jul 22, 2025
254e119
feat: add dedicated product feature key for Trusted Devices management
szwarckonrad Jul 22, 2025
f1206c1
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 22, 2025
b4a07ca
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 23, 2025
b187040
Merge branch 'device-control-rbac' of https://github.com/szwarckonrad…
szwarckonrad Jul 23, 2025
168132c
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 23, 2025
298cffc
feat: add USB device protection card with enterprise license check
szwarckonrad Jul 23, 2025
b231c5f
refactor: rename and update Device Control card component
szwarckonrad Jul 23, 2025
fabb491
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 24, 2025
0662df5
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 24, 2025
7c670d2
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 24, 2025
8a42e2c
Merge branch 'refs/heads/main' into device-control-rbac
szwarckonrad Jul 25, 2025
a7a112f
feat: add device control settings to endpoint security policy
szwarckonrad Jul 25, 2025
9420353
feat: add device control settings to endpoint policy configuration
szwarckonrad Jul 25, 2025
a4a8dea
chore: remove legacy locked card upgrade message from translations
szwarckonrad Jul 25, 2025
8885331
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 25, 2025
35cf852
feat: add device control license validation to endpoint policy config
szwarckonrad Jul 25, 2025
d6decda
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 25, 2025
6708c91
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 25, 2025
d0118aa
feat: add device control popup settings and update license checks to …
szwarckonrad Jul 25, 2025
9ac0f77
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 28, 2025
7d0f505
feat: add trusted devices management functionality
szwarckonrad Jul 30, 2025
b94b6ca
Merge branch 'main' into device-control-manage
szwarckonrad Jul 30, 2025
9b21efe
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 30, 2025
9988f8a
feat: add execute only access level to device control and update test…
szwarckonrad Jul 30, 2025
5ba098d
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 30, 2025
c69573d
Merge branch 'main' into device-control-manage
szwarckonrad Jul 30, 2025
e84649a
feat: add endpoint_trusted_devices to detection alert schema and comm…
szwarckonrad Jul 30, 2025
c542419
[CI] Auto-commit changed files from 'yarn openapi:bundle'
kibanamachine Jul 30, 2025
546814d
[CI] Auto-commit changed files from 'make api-docs'
kibanamachine Jul 30, 2025
40946bd
[CI] Auto-commit changed files from 'yarn openapi:generate'
kibanamachine Jul 30, 2025
522fa33
feat: add trusted devices to endpoint artifact list types
szwarckonrad Jul 30, 2025
061df95
Merge branch 'main' into device-control-manage
szwarckonrad Jul 30, 2025
7d0503b
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 30, 2025
03a4d9e
refactor: remove unnecessary comments from device control components
szwarckonrad Jul 30, 2025
6b588cb
Merge branch 'main' into device-control-rbac
szwarckonrad Jul 30, 2025
ff25c0b
fix: remove outdated upgrade messages from security solution endpoint…
szwarckonrad Jul 30, 2025
bc0737b
Merge branch 'device-control-manage' into device-control-combined
szwarckonrad Jul 30, 2025
4b06bf6
feat: add endpoint_trusted_devices to various lists and tests
szwarckonrad Jul 30, 2025
6bf163a
feat: add endpoint_trusted_devices to various lists and tests
szwarckonrad Jul 30, 2025
c05578e
Merge branch 'main' into device-control-combined
szwarckonrad Jul 31, 2025
b1d066f
Merge branch 'main' into device-control-combined
szwarckonrad Jul 31, 2025
867c16d
Trusted devices form component
szwarckonrad Jul 31, 2025
e87577c
Add TrustedDeviceConditionEntryField enum and update translations and…
szwarckonrad Aug 1, 2025
9137c88
Merge branch 'main' into device-control-combined
szwarckonrad Aug 1, 2025
a4c09d3
Merge branch 'main' into device-control-rbac
szwarckonrad Aug 1, 2025
3a797b8
Refactor TrustedDevicesApiClient to utilize separate transforms modul…
szwarckonrad Aug 1, 2025
5f54c99
Merge branch 'device-control-rbac' into device-control-manage
szwarckonrad Aug 1, 2025
5c69395
Merge device-control-rbac into device-control-combined
szwarckonrad Aug 1, 2025
74f2f5c
Add new translation for "Windows and Mac" and update OS selection in …
szwarckonrad Aug 1, 2025
9625f60
refactor: update device control access level labels for clarity
szwarckonrad Aug 1, 2025
14daca5
Merge branch 'main' into device-control-rbac
szwarckonrad Aug 1, 2025
807d7d5
refactor: update access level terminology in DeviceControlProtectionL…
szwarckonrad Aug 1, 2025
ae1b13d
Merge branch 'main' into device-control-rbac
szwarckonrad Aug 1, 2025
ea3b746
Merge branch 'main' into device-control-rbac
szwarckonrad Aug 4, 2025
4dcfe8a
Merge branch 'device-control-rbac' into device-control-manage
szwarckonrad Aug 4, 2025
b3f3e3d
Merge branch 'device-control-rbac' into device-control-combined
szwarckonrad Aug 4, 2025
071ba30
feat: add support for trusted devices with new schemas and artifact m…
szwarckonrad Aug 4, 2025
4b8b59d
cr
szwarckonrad Aug 4, 2025
3abead6
Merge branch 'main' into device-control-rbac
szwarckonrad Aug 4, 2025
b5b26b9
Merge branch 'device-control-rbac' into device-control-manage
szwarckonrad Aug 4, 2025
47915b2
Merge branch 'device-control-rbac' into device-control-combined
szwarckonrad Aug 4, 2025
d7aa239
fix: update experimental feature flag for trusted devices in subfeatu…
szwarckonrad Aug 4, 2025
1751538
Merge branch 'main' into device-control-manage
szwarckonrad Aug 5, 2025
eafc50e
Merge branch 'main' into device-control-manage
szwarckonrad Aug 5, 2025
cc8d208
Merge branch 'device-control-manage' of https://github.com/szwarckonr…
szwarckonrad Aug 5, 2025
e1464aa
Merge branch 'main' into device-control-combined
szwarckonrad Aug 5, 2025
4f4af33
Refactor trusted devices feature flag references to use unified key
szwarckonrad Aug 5, 2025
ad6858c
Merge branch 'main' into device-control-manage
szwarckonrad Aug 5, 2025
5baf52f
Merge branch 'device-control-manage' into device-control-combined
szwarckonrad Aug 5, 2025
a57b304
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 5, 2025
c84c689
Fix TrustedDevicesArtifactCard to use correct artifacts path
szwarckonrad Aug 5, 2025
2629125
Merge branch 'main' into device-control-manage
szwarckonrad Aug 5, 2025
5786b57
Remove unused createEndpointTrustedDevicesList function and its refer…
szwarckonrad Aug 6, 2025
41a7afc
Merge branch 'main' into device-control-manage
szwarckonrad Aug 6, 2025
8cadd91
Merge branch 'device-control-manage' into device-control-combined
szwarckonrad Aug 6, 2025
d37c165
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 6, 2025
fa311fd
Merge branch 'main' into device-control-manage
szwarckonrad Aug 7, 2025
099f6df
Update data-test-subj attribute in TrustedDevicesPolicyCard to "trust…
szwarckonrad Aug 7, 2025
5097bd3
Merge branch 'device-control-rbac' into device-control-combined
szwarckonrad Aug 7, 2025
dc0b1f8
Merge branch 'device-control-manage' into device-control-combined
szwarckonrad Aug 7, 2025
2cb9cc7
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 7, 2025
efb0f1d
Merge branch 'main' into device-control-manage
szwarckonrad Aug 7, 2025
b05c3b9
Merge branch 'device-control-manage' into device-control-combined
szwarckonrad Aug 7, 2025
b6ae545
Merge branch 'main' into device-control-combined
szwarckonrad Aug 8, 2025
29592c6
remove redundant comments
szwarckonrad Aug 8, 2025
11985a1
Merge branch 'main' into device-control-combined
szwarckonrad Aug 8, 2025
816783d
Add tests for Trusted Devices API client, transforms, form, and list …
szwarckonrad Aug 8, 2025
806deff
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 8, 2025
0949a8f
Merge branch 'main' into device-control-combined
szwarckonrad Aug 11, 2025
29fb9bd
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 11, 2025
ae74be9
Unit coverage
szwarckonrad Aug 11, 2025
1cf678a
Merge branch 'main' into device-control-artifacts
szwarckonrad Aug 11, 2025
41ab373
Merge branch 'main' into device-control-combined
szwarckonrad Aug 12, 2025
2991187
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 12, 2025
45fe76d
Merge branch 'main' into device-control-combined
szwarckonrad Aug 13, 2025
3ba08ee
Merge branch 'main' into device-control-artifacts
szwarckonrad Aug 13, 2025
cb75a3f
Merge branch 'main' into device-control-combined
szwarckonrad Aug 14, 2025
fb2be05
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 14, 2025
cb20ec1
CR comments
szwarckonrad Aug 14, 2025
57f5a1e
Add user selection tracking for OS types in TrustedDevicesForm
szwarckonrad Aug 14, 2025
08f8bfc
Merge branch 'main' into device-control-combined
szwarckonrad Aug 14, 2025
5081394
Merge branch 'main' into device-control-validators
szwarckonrad Aug 14, 2025
7ddc578
feat: add trusted device validation
szwarckonrad Aug 14, 2025
afd2719
Merge branch 'main' into device-control-validators
szwarckonrad Aug 14, 2025
d75a630
Merge branch 'main' into device-control-artifacts
szwarckonrad Aug 14, 2025
a945c18
Merge branch 'main' into device-control-combined
szwarckonrad Aug 14, 2025
06a3f15
Merge branch 'main' into device-control-validators
szwarckonrad Aug 14, 2025
253dc5e
feat: enhance trusted device validation with feature flag checks
szwarckonrad Aug 18, 2025
5562369
Merge branch 'main' into device-control-combined
szwarckonrad Aug 18, 2025
115aace
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 18, 2025
00d7154
Merge branch 'device-control-artifacts' into device-control-validators
szwarckonrad Aug 18, 2025
6b672ee
feat: add support for trusted devices in exception list and role mana…
szwarckonrad Aug 18, 2025
6b576f4
[CI] Auto-commit changed files from 'node scripts/lint_ts_projects --…
kibanamachine Aug 18, 2025
2d17172
[CI] Auto-commit changed files from 'yarn openapi:bundle'
kibanamachine Aug 18, 2025
c4dcdd0
[CI] Auto-commit changed files from 'make api-docs'
kibanamachine Aug 18, 2025
9fed67b
feat: add trusted devices feature to endpoint policy manager role
szwarckonrad Aug 18, 2025
bdedfca
Merge branch 'main' into device-control-combined
szwarckonrad Aug 18, 2025
f139fab
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 18, 2025
bec3b4a
Merge branch 'device-control-artifacts' into device-control-validators
szwarckonrad Aug 18, 2025
425f9b2
Merge branch 'device-control-validators' of https://github.com/szwarc…
szwarckonrad Aug 18, 2025
f226a89
cr
szwarckonrad Aug 18, 2025
5fb8ded
Merge branch 'main' into device-control-combined
szwarckonrad Aug 18, 2025
d61c7c2
lint
szwarckonrad Aug 18, 2025
0d2dc30
Merge branch 'main' into device-control-combined
szwarckonrad Aug 18, 2025
b758c66
Merge branch 'main' into device-control-combined
szwarckonrad Aug 19, 2025
5138a55
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 19, 2025
4d570a6
Merge branch 'device-control-artifacts' into device-control-validators
szwarckonrad Aug 19, 2025
ec11fa2
Initial cypress setup for trusted devices
szwarckonrad Aug 19, 2025
8f665d2
Add support for trusted devices in RBAC and navigation tests
szwarckonrad Aug 19, 2025
1c36e39
Add OS_OPTIONS_PLACEHOLDER translation for operating system selection
szwarckonrad Aug 19, 2025
df24319
Merge branch 'main' into device-control-combined
szwarckonrad Aug 19, 2025
8803f79
Merge branch 'device-control-combined' into device-control-artifacts
szwarckonrad Aug 19, 2025
37f4071
Merge branch 'device-control-artifacts' into device-control-validators
szwarckonrad Aug 19, 2025
793263a
Merge branch 'device-control-validators' into device-control-cypress
szwarckonrad Aug 19, 2025
f140dff
Merge branch 'main' into device-control-artifacts
szwarckonrad Aug 20, 2025
8d9d135
Refactor RBAC navigation tests to include SIEM version filtering for …
szwarckonrad Aug 20, 2025
b0f045b
Merge branch 'main' into device-control-artifacts
szwarckonrad Aug 20, 2025
1fb57bd
Merge branch 'device-control-artifacts' of https://github.com/szwarck…
szwarckonrad Aug 20, 2025
682e875
clean up comments
szwarckonrad Aug 20, 2025
d559a5a
Merge branch 'device-control-artifacts' into device-control-validators
szwarckonrad Aug 20, 2025
b55e8d9
Merge branch 'device-control-validators' into device-control-cypress
szwarckonrad Aug 20, 2025
a70302f
align cypress tests
szwarckonrad Aug 20, 2025
1e1a5f9
enable feature in cypress test
szwarckonrad Aug 20, 2025
541ef01
Merge branch 'main' into device-control-artifacts
szwarckonrad Aug 20, 2025
80821a4
Merge branch 'device-control-artifacts' into device-control-validators
szwarckonrad Aug 20, 2025
5b66602
Merge branch 'device-control-validators' into device-control-cypress
szwarckonrad Aug 20, 2025
52365d1
Merge branch 'main' into device-control-artifacts
szwarckonrad Aug 21, 2025
74c3cb1
Merge branch 'device-control-artifacts' into device-control-validators
szwarckonrad Aug 21, 2025
bef97c6
Merge branch 'device-control-validators' into device-control-cypress
szwarckonrad Aug 21, 2025
9348340
Merge branch 'main' into device-control-validators
szwarckonrad Aug 22, 2025
8994133
Merge branch 'device-control-validators' into device-control-cypress
szwarckonrad Aug 22, 2025
5ce5dbd
remove outdated comments
szwarckonrad Aug 22, 2025
d71ecae
Merge branch 'main' into device-control-validators
szwarckonrad Aug 25, 2025
e8ec84d
Merge branch 'main' into device-control-validators
szwarckonrad Aug 26, 2025
17ac822
refactor validation schemas
szwarckonrad Aug 26, 2025
801f034
Merge branch 'device-control-validators' into device-control-cypress
szwarckonrad Aug 26, 2025
ee2db0c
Merge branch 'main' into device-control-cypress
szwarckonrad Aug 26, 2025
c86441d
Merge branch 'main' into device-control-cypress
szwarckonrad Aug 27, 2025
19126ea
cr: keep roles files synced
szwarckonrad Aug 27, 2025
92386bb
cr: sync detections_admin role
szwarckonrad Aug 27, 2025
58eb1f1
Merge branch 'main' into device-control-cypress
szwarckonrad Aug 27, 2025
1fafdc9
cr: sync roles.yml files
szwarckonrad Aug 27, 2025
848bf47
skip trusted devices in mki
szwarckonrad Aug 27, 2025
711de25
Merge branch 'main' into device-control-cypress
szwarckonrad Aug 27, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ editor:
- feature_siemV3.endpoint_list_all
- feature_siemV3.global_artifact_management_all
- feature_siemV3.trusted_applications_all
- feature_siemV3.trusted_devices_all
- feature_siemV3.event_filters_all
- feature_siemV3.host_isolation_exceptions_all
- feature_siemV3.blocklist_all
Expand Down Expand Up @@ -315,6 +316,7 @@ t3_analyst:
- feature_siemV3.endpoint_list_all
- feature_siemV3.global_artifact_management_all
- feature_siemV3.trusted_applications_all
- feature_siemV3.trusted_devices_all
- feature_siemV3.event_filters_all
- feature_siemV3.host_isolation_exceptions_all
- feature_siemV3.blocklist_all
Expand Down Expand Up @@ -464,6 +466,7 @@ rule_author:
- feature_siemV3.endpoint_list_all
- feature_siemV3.global_artifact_management_all
- feature_siemV3.trusted_applications_all
- feature_siemV3.trusted_devices_all
- feature_siemV3.event_filters_all
- feature_siemV3.host_isolation_exceptions_read
- feature_siemV3.blocklist_all # Elastic Defend Policy Management
Expand Down Expand Up @@ -540,6 +543,7 @@ soc_manager:
- feature_siemV3.endpoint_list_all
- feature_siemV3.global_artifact_management_all
- feature_siemV3.trusted_applications_all
- feature_siemV3.trusted_devices_all
- feature_siemV3.event_filters_all
- feature_siemV3.host_isolation_exceptions_all
- feature_siemV3.blocklist_all
Expand Down Expand Up @@ -680,6 +684,7 @@ platform_engineer:
- feature_siemV3.endpoint_list_all
- feature_siemV3.global_artifact_management_all
- feature_siemV3.trusted_applications_all
- feature_siemV3.trusted_devices_all
- feature_siemV3.event_filters_all
- feature_siemV3.host_isolation_exceptions_all
- feature_siemV3.blocklist_all # Elastic Defend Policy Management
Expand Down Expand Up @@ -756,6 +761,7 @@ endpoint_operations_analyst:
- feature_siemV3.endpoint_list_all
- feature_siemV3.global_artifact_management_all
- feature_siemV3.trusted_applications_all
- feature_siemV3.trusted_devices_all
Copy link
Copy Markdown
Member

@pheyos pheyos Aug 27, 2025

Choose a reason for hiding this comment

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

It looks like this change in not present in the elasticsearch-controller (yet?). We usually try to keep the role definitions in sync. Otherwise, any testing that relies on this extra privilege might pass locally but fail in MKI runs. What are your plans around this here?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

This feature targets 9.2 and we will most likely add this privilege before the feature freeze. I'm okay with reverting this change and revisiting once we merged controller. CC @gergoabraham

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@pheyos, as we do not have custom roles for serverless in our test suites at the moment, I think there must be a discrepancy somewhere to be able to use the new privileges in cy/ftr tests. the discrepancy is either between elasticsearch-controller and kibana (as the current PR introduces it), or between (elasticsearch-controller + kibana's kbn-es resource) and (kibana's test resource).

do you think one is better than the other? i think updating elasticsearch-controller later should be fine, as this allows us to locally test the new roles, and have CI tests in place for the new features, while these tests are skipped in MKI. but i guess we can go the other way around as well - keeping the new privileges out of kbn-es resource

Copy link
Copy Markdown
Contributor Author

@szwarckonrad szwarckonrad Aug 27, 2025

Choose a reason for hiding this comment

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

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@gergoabraham @szwarckonrad it's true that we can't always be in perfect sync and there's risk in every version of discrepancy.

CI tests in place for the new features, while these tests are skipped in MKI

In this case, I think it makes sense to go this route. If any FTR tests start failing in MKI due to this role definition change (unlikely unless we explicitly add specific tests for it - the tests seem to be mostly in Cypress), then we would have to skip these tests for MKI runs until the role definition in elasticsearch-controller has caught up. With that, I'm going to approve this PR from the AppEx QA point of view.

- feature_siemV3.event_filters_all
- feature_siemV3.host_isolation_exceptions_all
- feature_siemV3.blocklist_all
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ export const APP_POLICIES_PATH = `${APP_PATH}${POLICIES_PATH}` as const;
export const APP_ENDPOINT_EXCEPTIONS_PATH = `${APP_PATH}${ENDPOINT_EXCEPTIONS_PATH}` as const;
export const APP_MANAGE_PATH = `${APP_PATH}${MANAGE_PATH}` as const;
export const APP_TRUSTED_APPS_PATH = `${APP_PATH}${TRUSTED_APPS_PATH}` as const;
export const APP_TRUSTED_DEVICES_PATH = `${APP_PATH}${TRUSTED_DEVICES_PATH}` as const;
export const APP_EVENT_FILTERS_PATH = `${APP_PATH}${EVENT_FILTERS_PATH}` as const;
export const APP_HOST_ISOLATION_EXCEPTIONS_PATH =
`${APP_PATH}${HOST_ISOLATION_EXCEPTIONS_PATH}` as const;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,159 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/

import { ENDPOINT_ARTIFACT_LISTS } from '@kbn/securitysolution-list-constants';
import {
createArtifactList,
createPerPolicyArtifact,
removeExceptionsList,
trustedDevicesFormSelectors,
} from '../../tasks/artifacts';
import type { IndexedFleetEndpointPolicyResponse } from '../../../../../common/endpoint/data_loaders/index_fleet_endpoint_policy';
import { createAgentPolicyTask, getEndpointIntegrationVersion } from '../../tasks/fleet';
import { login } from '../../tasks/login';

const {
openTrustedDevices,
selectOs,
selectField,
selectOperator,
fillValue,
fillOutTrustedDevicesFlyout,
submitForm,
validateSuccessPopup,
validateRenderedCondition,
deleteTrustedDeviceItem,
} = trustedDevicesFormSelectors;

describe(
'Trusted Devices',
{
tags: ['@ess', '@serverless', '@skipInServerlessMKI'],
env: {
ftrConfig: {
kbnServerArgs: [
`--xpack.securitySolution.enableExperimental=${JSON.stringify(['trustedDevices'])}`,
],
},
},
},
() => {
let indexedPolicy: IndexedFleetEndpointPolicyResponse;

before(() => {
getEndpointIntegrationVersion().then((version) => {
createAgentPolicyTask(version).then((data) => {
indexedPolicy = data;
});
});
});

beforeEach(() => {
login();
});

after(() => {
if (indexedPolicy) {
cy.task('deleteIndexedFleetEndpointPolicies', indexedPolicy);
}
});

const createArtifactBodyRequest = () => ({
list_id: ENDPOINT_ARTIFACT_LISTS.trustedDevices.id,
entries: [
{
field: 'user.name',
operator: 'included',
type: 'match',
value: 'test-user',
},
],
os_types: ['windows', 'macos'],
});

describe('Renders Trusted Devices form fields', () => {
it('Correctly renders trusted devices form for Windows and Mac', () => {
openTrustedDevices({ create: true });

selectOs('Windows and Mac');

selectField('Username');
selectOperator('is');
fillValue('test-user');
});

it('Renders all field options correctly', () => {
openTrustedDevices({ create: true });
selectOs('Windows and Mac');

const fields: Array<'Username' | 'Host' | 'Device ID' | 'Manufacturer' | 'Product ID'> = [
'Username',
'Host',
'Device ID',
'Manufacturer',
'Product ID',
];

fields.forEach((field) => {
selectField(field);
cy.getByTestSubj('trustedDevices-form-fieldSelect').should('contain', field);
});
});
});

describe('Handles CRUD with device fields', () => {
afterEach(() => {
removeExceptionsList(ENDPOINT_ARTIFACT_LISTS.trustedDevices.id);
});

it('Correctly creates a trusted device with a single username field on Windows and Mac', () => {
const expectedCondition = /user\.name\s*IS\s*test-user/i;

openTrustedDevices({ create: true });
fillOutTrustedDevicesFlyout();
selectOs('Windows and Mac');
selectField('Username');
selectOperator('is');
fillValue('test-user');
submitForm();

validateSuccessPopup('create');
validateRenderedCondition(expectedCondition);
});

describe('Correctly updates and deletes trusted device with single username field', () => {
let itemId: string;

beforeEach(() => {
createArtifactList(ENDPOINT_ARTIFACT_LISTS.trustedDevices.id);
createPerPolicyArtifact('Test Trusted Device', createArtifactBodyRequest()).then(
(response) => {
itemId = response.body.item_id;
}
);
});

it('Updates trusted device username field item', () => {
const expectedCondition = /user\.name\s*IS\s*updated-user/i;

openTrustedDevices({ itemId });
fillValue('updated-user');
submitForm();

validateSuccessPopup('update');
validateRenderedCondition(expectedCondition);
});

it('Deletes a trusted device item', () => {
openTrustedDevices();
deleteTrustedDeviceItem();
validateSuccessPopup('delete');
});
});
});
}
);
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/

import { getArtifactsListTestDataForArtifact } from '../../fixtures/artifacts_page';
import { getArtifactMockedDataTests } from '../../support/artifacts_rbac_runner';

describe(
'Trusted devices RBAC',
{
tags: ['@ess', '@serverless', '@skipInServerlessMKI'],
env: {
ftrConfig: {
kbnServerArgs: [
`--xpack.securitySolution.enableExperimental=${JSON.stringify(['trustedDevices'])}`,
],
},
},
},

getArtifactMockedDataTests(getArtifactsListTestDataForArtifact('trustedDevices'), ['siemV3'])
);
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,13 @@ describe(
'When defining a kibana role for Endpoint security access',
{
tags: '@ess',
env: {
ftrConfig: {
kbnServerArgs: [
`--xpack.securitySolution.enableExperimental=${JSON.stringify(['trustedDevices'])}`,
],
},
},
},
() => {
const getAllSubFeatureRows = (): Cypress.Chainable<JQuery<HTMLElement>> => {
Expand Down Expand Up @@ -55,6 +62,7 @@ describe(
'Automatic Troubleshooting Access to the automatic troubleshooting.Automatic Troubleshooting sub-feature privilegeAllReadNone',
'Global Artifact Management Manage global assignment of endpoint artifacts (e.g., Trusted Applications, Event Filters) across all policies. This privilege controls global assignment rights only; privileges for each artifact type are required for full artifact management.Global Artifact Management sub-feature privilegeAllNone',
'Trusted Applications Helps mitigate conflicts with other software, usually other antivirus or endpoint security applications.Trusted Applications sub-feature privilegeAllReadNone',
'Trusted Devices Allows management of trusted USB and external devices that bypass device control protections.Trusted Devices sub-feature privilegeAllReadNone',
'Host Isolation Exceptions Add specific IP addresses that isolated hosts are still allowed to communicate with, even when isolated from the rest of the network.Host Isolation Exceptions sub-feature privilegeAllReadNone',
'Blocklist Extend Elastic Defend’s protection against malicious processes and protect against potentially harmful applications.Blocklist sub-feature privilegeAllReadNone',
'Event Filters Filter out endpoint events that you do not need or want stored in Elasticsearch.Event Filters sub-feature privilegeAllReadNone',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ describe(
kbnServerArgs: [
`--xpack.securitySolution.enableExperimental=${JSON.stringify([
'endpointManagementSpaceAwarenessEnabled',
'trustedDevices',
])}`,
],
},
Expand Down Expand Up @@ -107,6 +108,7 @@ describe(
'Automatic TroubleshootingNone',
'Global Artifact ManagementNone',
'Trusted ApplicationsNone',
'Trusted DevicesNone',
'Host Isolation ExceptionsNone',
'BlocklistNone',
'Event FiltersNone',
Expand Down
Loading