Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main' into reduce-cases-page-l…
Browse files Browse the repository at this point in the history
…oad-bundle-size
  • Loading branch information
adcoelho committed Jun 9, 2023
2 parents 8568762 + 352d7c9 commit 4faf9aa
Show file tree
Hide file tree
Showing 34 changed files with 413 additions and 674 deletions.
6 changes: 5 additions & 1 deletion config/serverless.security.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,11 @@ xpack.uptime.enabled: false

## Enable the Serverless Security plugin
xpack.serverless.security.enabled: true
xpack.serverless.security.productTypes: [{ product_line: 'security', product_tier: 'complete' }]
xpack.serverless.security.productTypes:
[
{ product_line: 'security', product_tier: 'complete' },
{ product_line: 'endpoint', product_tier: 'complete' },
]

## Set the home route
uiSettings.overrides.defaultRoute: /app/security/get_started
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,7 @@ export interface Connector {
index_name: string;
is_native: boolean;
language: string | null;
last_access_control_sync_error: string | null;
last_access_control_sync_scheduled_at: string | null;
last_access_control_sync_status: SyncStatus | null;
last_incremental_sync_scheduled_at: string | null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ export const indices: ElasticsearchIndexWithIngestion[] = [
index_name: 'connector',
is_native: false,
language: 'en',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: SyncStatus.COMPLETED,
last_incremental_sync_scheduled_at: null,
Expand Down Expand Up @@ -233,6 +234,7 @@ export const indices: ElasticsearchIndexWithIngestion[] = [
index_name: 'crawler',
is_native: true,
language: 'en',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: SyncStatus.COMPLETED,
last_incremental_sync_scheduled_at: null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ export const connectorIndex: ConnectorViewIndex = {
index_name: 'connector',
is_native: false,
language: 'en',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: SyncStatus.COMPLETED,
last_incremental_sync_scheduled_at: null,
Expand Down Expand Up @@ -247,6 +248,7 @@ export const crawlerIndex: CrawlerViewIndex = {
index_name: 'crawler',
is_native: true,
language: 'en',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: SyncStatus.COMPLETED,
last_incremental_sync_scheduled_at: null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ describe('Setup Indices', () => {
index_name: { type: 'keyword' },
is_native: { type: 'boolean' },
language: { type: 'keyword' },
last_access_control_sync_error: { type: 'keyword' },
last_access_control_sync_scheduled_at: { type: 'date' },
last_access_control_sync_status: { type: 'keyword' },
last_deleted_document_count: { type: 'long' },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ const connectorMappingsProperties: Record<string, MappingProperty> = {
index_name: { type: 'keyword' },
is_native: { type: 'boolean' },
language: { type: 'keyword' },
last_access_control_sync_error: { type: 'keyword' },
last_access_control_sync_scheduled_at: { type: 'date' },
last_access_control_sync_status: { type: 'keyword' },
last_deleted_document_count: { type: 'long' },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ describe('addConnector lib function', () => {
index_name: 'index_name',
is_native: false,
language: 'fr',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,
Expand Down Expand Up @@ -330,6 +331,7 @@ describe('addConnector lib function', () => {
index_name: 'index_name',
is_native: true,
language: null,
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,
Expand Down Expand Up @@ -441,6 +443,7 @@ describe('addConnector lib function', () => {
index_name: 'search-index_name',
is_native: false,
language: 'en',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ describe('startSync lib function', () => {
error: null,
index_name: 'index_name',
language: null,
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_seen: null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ describe('addConnector lib function', () => {
custom_scheduling: {},
error: null,
index_name: 'index_name',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_seen: null,
Expand Down Expand Up @@ -68,6 +69,7 @@ describe('addConnector lib function', () => {
custom_scheduling: {},
error: null,
index_name: 'index_name',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_seen: null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ describe('recreateConnectorDocument lib function', () => {
index_name: 'indexName',
is_native: false,
language: '',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ describe('createConnectorDocument', () => {
index_name: 'indexName',
is_native: false,
language: 'fr',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,
Expand Down Expand Up @@ -181,6 +182,7 @@ describe('createConnectorDocument', () => {
index_name: 'search-indexName',
is_native: false,
language: 'fr',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ export function createConnectorDocument({
index_name: indexName,
is_native: isNative,
language,
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,
Expand Down
18 changes: 18 additions & 0 deletions x-pack/plugins/fleet/common/constants/authz.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,18 @@ export const ENDPOINT_PRIVILEGES: Record<string, PrivilegeMapObject> = deepFreez
privilegeType: 'api',
privilegeName: 'readHostIsolationExceptions',
},
accessHostIsolationExceptions: {
appId: DEFAULT_APP_CATEGORIES.security.id,
privilegeSplit: '-',
privilegeType: 'api',
privilegeName: 'accessHostIsolationExceptions',
},
deleteHostIsolationExceptions: {
appId: DEFAULT_APP_CATEGORIES.security.id,
privilegeSplit: '-',
privilegeType: 'api',
privilegeName: 'deleteHostIsolationExceptions',
},
writeBlocklist: {
appId: DEFAULT_APP_CATEGORIES.security.id,
privilegeSplit: '-',
Expand Down Expand Up @@ -126,6 +138,12 @@ export const ENDPOINT_PRIVILEGES: Record<string, PrivilegeMapObject> = deepFreez
privilegeType: 'api',
privilegeName: 'writeHostIsolation',
},
writeHostIsolationRelease: {
appId: DEFAULT_APP_CATEGORIES.security.id,
privilegeSplit: '-',
privilegeType: 'api',
privilegeName: 'writeHostIsolationRelease',
},
writeProcessOperations: {
appId: DEFAULT_APP_CATEGORIES.security.id,
privilegeSplit: '-',
Expand Down
Loading

0 comments on commit 4faf9aa

Please sign in to comment.