Skip to content

Commit

Permalink
Update Vulnerability type in types
Browse files Browse the repository at this point in the history
  • Loading branch information
ameliav committed Sep 27, 2024
1 parent 19661bc commit e0e6dab
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 46 deletions.
38 changes: 37 additions & 1 deletion frontend/src/types/domain.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { Organization } from './organization';
import { Vulnerability } from './vulnerability';
import { Scan } from './scan';

export interface Product {
Expand Down Expand Up @@ -82,6 +81,43 @@ export interface Webpage {
responseSize: number | null;
}

export interface Vulnerability {
id: string;
domain: Domain;
createdAt: string;
lastSeen: string | null;
title: string;
cve: string | null;
isKev?: string;
cwe: string | null;
cpe: string | null;
description: string;
cvss: number | null;
severity: string | null;
state: string;
source: string;
structuredData: { [x: string]: any };
substate: string;
notes: string;
actions: {
type: 'state-change' | 'comment';
state?: string;
substate?: string;
value?: string;
automatic: boolean;
userId: string | null;
userName: string | null;
date: string;
}[];
references: {
url: string;
name: string;
source: string;
tags: string[];
}[];
service: Service;
}

export interface Domain {
id: string;
name: string;
Expand Down
12 changes: 6 additions & 6 deletions frontend/src/types/index.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
export * from './cpe';
export * from './cve';
export * from './domain';
export * from './vulnerability';
export * from './scan';
export * from './notification';
export * from './organization';
export * from './user';
export * from './org-query';
export * from './query';
export * from './report';
export * from './role';
export * from './scan-task';
export * from './saved-search';
export * from './scan-task';
export * from './scan';
export * from './stats';
export * from './report';
export * from './notification';
export * from './user';
2 changes: 1 addition & 1 deletion frontend/src/types/stats.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Vulnerability } from './vulnerability';
import { Vulnerability } from './domain';

export interface Point {
id: string;
Expand Down
38 changes: 0 additions & 38 deletions frontend/src/types/vulnerability.ts

This file was deleted.

0 comments on commit e0e6dab

Please sign in to comment.