-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[TIP] Enables TI plugin with kibana.yml feature flag #137838
Changes from 2 commits
e6ca139
5bfd9bc
346e397
815f876
0b2e554
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,9 @@ | |
* 2.0. | ||
*/ | ||
import type { CoreStart } from '@kbn/core/public'; | ||
import type { AppLinkItems } from './types'; | ||
import { links as threatIntelligenceLinks } from '../../threat_intelligence/links'; | ||
import type { ExperimentalFeatures } from '../../../common/experimental_features'; | ||
import type { AppLinkItems, LinkItem } from './types'; | ||
import { links as detectionLinks } from '../../detections/links'; | ||
import { links as timelinesLinks } from '../../timelines/links'; | ||
import { getCasesLinkItems } from '../../cases/links'; | ||
|
@@ -30,17 +32,27 @@ export const links = Object.freeze([ | |
|
||
export const getFilteredLinks = async ( | ||
core: CoreStart, | ||
plugins: StartPlugins | ||
plugins: StartPlugins, | ||
experimentalFeatures: Readonly<ExperimentalFeatures> | ||
): Promise<AppLinkItems> => { | ||
const managementFilteredLinks = await getManagementFilteredLinks(core, plugins); | ||
|
||
const threatHuntingFilteredLinks = { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I hesitated to go the opposite way (adding the threatIntelligence entry to the threatHuntingLandingLinks.link property) but going this current route meant modifying one less file. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. no need to do this, links have support for experimentalFeatures, you can add the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. haha I had took a note of this There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yeah that worked, I don't know what I did... must have forgotten to update my kibana.yml... 🤦♂️ |
||
...threatHuntingLandingLinks, | ||
links: !experimentalFeatures.threatIntelligenceEnabled | ||
? threatHuntingLandingLinks.links?.filter( | ||
(p: LinkItem) => p.id !== threatIntelligenceLinks.id | ||
) | ||
: threatHuntingLandingLinks.links, | ||
}; | ||
|
||
return Object.freeze([ | ||
dashboardsLandingLinks, | ||
detectionLinks, | ||
cloudSecurityPostureRootLinks, | ||
timelinesLinks, | ||
casesLinks, | ||
threatHuntingLandingLinks, | ||
threatHuntingFilteredLinks, | ||
gettingStartedLinks, | ||
managementFilteredLinks, | ||
]); | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -52,6 +52,7 @@ export default async function ({ readConfigFile }: FtrConfigProviderContext) { | |
'riskyHostsEnabled', | ||
'riskyUsersEnabled', | ||
'insightsRelatedAlertsByProcessAncestry', | ||
'threatIntelligenceEnabled', | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is there any plan of adding specific TI plugin tests on Security Solution Cypress tests? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @MadameSheema we have some e2e Cypress tests in our plugin directly and this PR updates some e2e Cypress tests within the Security Solution plugin. I wasn't thinking about adding any other tests, especially because this feature flag is temporary and should be very short lived. We're planning on releasing everything in 8.5 (plans could change though). Did you have anything specify in mind you wanted me/us to add? |
||
])}`, | ||
`--home.disableWelcomeScreen=true`, | ||
], | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure I was allowed to use this object but it seemed to make sense, as the Threat Intelligence plugin is loaded within the Security Solution plugin