forked from elastic/kibana
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ResponseOps][Cases] Manual migration of routes without access tags (e…
…lastic#203449) Closes elastic#1322 ## Summary Since most cases routes do not use access tags they need to be migrated to include a `reason` in the security params. [Documentation.](https://docs.elastic.dev/kibana-dev-docs/key-concepts/security-api-authorization#opting-out-of-authorization-for-specific-routes) ## Routes updated in this PR - `Cases` - [x] GET `${CASES_URL}/_find` - [x] DELETE `/api/cases` - [x] PATCH `/api/cases` - [x] POST `/api/cases` - [x] GET `${CASES_URL}/{case_id}` - [x] POST `${CASE_DETAILS_URL}/connector/{connector_id}/_push` - `Alerts` - [x] GET `${CASES_URL}/alerts/{alert_id}` - `Categories` - [x] GET `${CASES_INTERNAL_URL}/categories` - `Reporters` - [x] GET `${CASES_URL}/reporters` - `Tags` - [x] GET `CASE_TAGS_URL` - `Comments` - [x] DELETE `${CASE_DETAILS_URL}/comments` - [x] DELETE `${CASE_DETAILS_URL}/comments/{comment_id}` - [x] GET `${CASE_COMMENTS_URL}/_find` - [x] GET `CASE_DETAILS_ALERT_URL` - [x] GET `CASE_COMMENTS_URL` - [x] GET `CASE_COMMENT_DETAILS_URL` - [x] PATCH `CASE_COMMENTS_URL` - [x] POST `CASE_COMMENTS_URL` - `Configure` - [x] POST `CASE_CONFIGURE_URL` - [x] PATCH `CASE_CONFIGURE_URL` - [x] GET `CASE_CONFIGURE_URL` - `Files` - [x] GET `CASES_FILES_URL` - `Internal` - [x] POST `INTERNAL_BULK_CREATE_ATTACHMENTS_URL` - [x] POST `INTERNAL_DELETE_FILE_ATTACHMENTS_URL` - [x] POST `INTERNAL_BULK_GET_ATTACHMENTS_URL` - [x] POST `INTERNAL_BULK_GET_CASES_URL` - [x] GET `INTERNAL_CASE_METRICS_DETAILS_URL` - [x] GET `INTERNAL_GET_CASE_USER_ACTIONS_STATS_URL` - [x] GET `INTERNAL_CASE_USERS_URL` - [x] GET `INTERNAL_CASE_METRICS_URL` - [x] GET `INTERNAL_CONNECTORS_URL` - [x] PUT `INTERNAL_PUT_CUSTOM_FIELDS_URL` - [x] POST `${CASES_INTERNAL_URL}/_search` - `Stats` - [x] GET `CASE_STATUS_URL` - `User Actions` - [x] GET `CASE_FIND_USER_ACTIONS_URL` - [x] GET `CASE_USER_ACTIONS_URL`
- Loading branch information
1 parent
99a9f0f
commit 28850a8
Showing
40 changed files
with
101 additions
and
1 deletion.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
/* | ||
* 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 type { RouteSecurity } from '@kbn/core-http-server'; | ||
|
||
/** | ||
* This constant is used as the default value for the security object in routes | ||
* where a reason for opting out needs to be provided. | ||
*/ | ||
export const DEFAULT_CASES_ROUTE_SECURITY: RouteSecurity = { | ||
authz: { | ||
enabled: false, | ||
reason: | ||
"This route is opted out from authorization because cases uses it's own authorization model inside the cases client.", | ||
}, | ||
}; |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.