From bc3f94246ccddee85f7a16c3300e87d191085287 Mon Sep 17 00:00:00 2001 From: Joanne Wang Date: Mon, 30 Sep 2024 11:33:49 -0400 Subject: [PATCH 1/5] fix spacing for threat intel Signed-off-by: Joanne Wang --- .../ThreatIntelSourcesList/ThreatIntelSourcesList.tsx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/public/pages/ThreatIntel/components/ThreatIntelSourcesList/ThreatIntelSourcesList.tsx b/public/pages/ThreatIntel/components/ThreatIntelSourcesList/ThreatIntelSourcesList.tsx index 1c794786..86631ad7 100644 --- a/public/pages/ThreatIntel/components/ThreatIntelSourcesList/ThreatIntelSourcesList.tsx +++ b/public/pages/ThreatIntel/components/ThreatIntelSourcesList/ThreatIntelSourcesList.tsx @@ -34,7 +34,6 @@ export const ThreatIntelSourcesList: React.FC = ({ }) => { return ( - @@ -97,7 +96,11 @@ export const ThreatIntelSourcesList: React.FC = ({ {threatIntelSources.length === 0 && (

No threat intel source present

} + title={ + +

No threat intel source present

+
+ } actions={[ Date: Mon, 30 Sep 2024 18:19:19 -0400 Subject: [PATCH 2/5] fix alienvault source details page crash Signed-off-by: Joanne Wang --- .../ThreatIntelSourceDetails.tsx | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/public/pages/ThreatIntel/components/ThreatIntelSourceDetails/ThreatIntelSourceDetails.tsx b/public/pages/ThreatIntel/components/ThreatIntelSourceDetails/ThreatIntelSourceDetails.tsx index d38f5994..2462d3d2 100644 --- a/public/pages/ThreatIntel/components/ThreatIntelSourceDetails/ThreatIntelSourceDetails.tsx +++ b/public/pages/ThreatIntel/components/ThreatIntelSourceDetails/ThreatIntelSourceDetails.tsx @@ -333,12 +333,12 @@ export const ThreatIntelSourceDetails: React.FC = )} {type === 'URL_DOWNLOAD' && ( - - + - + )} <> @@ -374,7 +374,12 @@ export const ThreatIntelSourceDetails: React.FC = Discard - + Save From 956ea1bfc606479f99556ca7fe2624630b009616 Mon Sep 17 00:00:00 2001 From: Joanne Wang Date: Mon, 30 Sep 2024 18:19:52 -0400 Subject: [PATCH 3/5] fix threat intel findings widget view view all url crash Signed-off-by: Joanne Wang --- .../RecentThreatIntelFindingsWidget.tsx | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/public/pages/Overview/components/Widgets/RecentThreatIntelFindingsWidget.tsx b/public/pages/Overview/components/Widgets/RecentThreatIntelFindingsWidget.tsx index c4e48b66..f11dff12 100644 --- a/public/pages/Overview/components/Widgets/RecentThreatIntelFindingsWidget.tsx +++ b/public/pages/Overview/components/Widgets/RecentThreatIntelFindingsWidget.tsx @@ -16,7 +16,7 @@ import { TableWidget } from './TableWidget'; import { WidgetContainer } from './WidgetContainer'; import { renderTime } from '../../../../utils/helpers'; import { ThreatIntelFinding } from '../../../../../types'; -import { getApplication } from '../../../../services/utils/constants'; +import { getApplication, getUseUpdatedUx } from '../../../../services/utils/constants'; import { IocLabel, ThreatIntelIocType } from '../../../../../common/constants'; const columns: EuiBasicTableColumn[] = [ @@ -78,17 +78,16 @@ export const RecentThreatIntelFindingsWidget: React.FC [ - getApplication().navigateToUrl(threatIntelFindingsUrl)}> + const actions = React.useMemo(() => { + const baseUrl = getUseUpdatedUx() ? getApplication().getUrlForApp(FINDINGS_NAV_ID) : ''; + return [ + View all , - ], - [] - ); + ]; + }, []); return ( From c6c339cfe7cbcadfe560dfe5a7b29d9783dacaf9 Mon Sep 17 00:00:00 2001 From: Joanne Wang Date: Mon, 30 Sep 2024 18:20:23 -0400 Subject: [PATCH 4/5] fix security analtyics breadcrumbs link path crash Signed-off-by: Joanne Wang --- public/utils/constants.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/utils/constants.ts b/public/utils/constants.ts index c3355678..1817d667 100644 --- a/public/utils/constants.ts +++ b/public/utils/constants.ts @@ -79,7 +79,7 @@ export const getNotificationDetailsHref = (channelId: string) => `notifications-dashboards#/channels-details/${channelId}`; export const BREADCRUMBS = Object.freeze({ - SECURITY_ANALYTICS: { text: 'Security Analytics', href: '#/' }, + SECURITY_ANALYTICS: { text: 'Security Analytics', href: `#${ROUTES.OVERVIEW}` }, OVERVIEW: { text: 'Overview', href: `#${ROUTES.OVERVIEW}` }, GETTING_STARTED: { text: 'Getting started', href: `#${ROUTES.GETTING_STARTED}` }, FINDINGS: { text: 'Findings', href: `#${ROUTES.FINDINGS}` }, From c8354bcf4ce117d932ea9e4b07a1484f1cafbccf Mon Sep 17 00:00:00 2001 From: Joanne Wang Date: Tue, 1 Oct 2024 14:18:49 -0700 Subject: [PATCH 5/5] fix duplicate findings Signed-off-by: Joanne Wang --- public/store/FindingsStore.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/public/store/FindingsStore.ts b/public/store/FindingsStore.ts index 65422527..ef080023 100644 --- a/public/store/FindingsStore.ts +++ b/public/store/FindingsStore.ts @@ -132,6 +132,10 @@ export class FindingsStore implements IFindingsStore { const firstGetFindingsRes = await this.service.getFindings(getFindingsQueryParams); + if (signal.aborted) { + return allFindings; + } + if (firstGetFindingsRes.ok) { const extendedFindings = this.extendFindings(firstGetFindingsRes.response.findings, detector); onPartialFindingsFetched?.(extendedFindings);