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.
[APM] agent keys management improvements (elastic#120765)
* Add userCurrentUser hook * Use EuiFieldText instead of input element * Display error messages in the UI when creating agent keys * Remove default agent key name * Prefix createAgentKeyRoute with /api * Fix issue where you cannot invalidate API keys when you only have manage_own_api_key privilege Co-authored-by: Casper Hübertz <casper@formgeist.com>
- Loading branch information
1 parent
d9aed2a
commit 87cfd9d
Showing
10 changed files
with
178 additions
and
145 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/* | ||
* 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 * as t from 'io-ts'; | ||
|
||
export const enum PrivilegeType { | ||
SOURCEMAP = 'sourcemap:write', | ||
EVENT = 'event:write', | ||
AGENT_CONFIG = 'config_agent:read', | ||
} | ||
|
||
export const privilegesTypeRt = t.array( | ||
t.union([ | ||
t.literal(PrivilegeType.SOURCEMAP), | ||
t.literal(PrivilegeType.EVENT), | ||
t.literal(PrivilegeType.AGENT_CONFIG), | ||
]) | ||
); |
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.