@nice2dev/ui-tools 1.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +36 -0
- package/dist/access-control.d.ts +726 -0
- package/dist/access-control.d.ts.map +1 -0
- package/dist/accessibility-i18n.d.ts +1017 -0
- package/dist/accessibility-i18n.d.ts.map +1 -0
- package/dist/ai-assistant.d.ts +263 -0
- package/dist/ai-assistant.d.ts.map +1 -0
- package/dist/ai-playgrounds.d.ts +842 -0
- package/dist/ai-playgrounds.d.ts.map +1 -0
- package/dist/alerting-incidents.d.ts +558 -0
- package/dist/alerting-incidents.d.ts.map +1 -0
- package/dist/api-designer.d.ts +1568 -0
- package/dist/api-designer.d.ts.map +1 -0
- package/dist/api-testing.d.ts +1146 -0
- package/dist/api-testing.d.ts.map +1 -0
- package/dist/apm-profiling.d.ts +656 -0
- package/dist/apm-profiling.d.ts.map +1 -0
- package/dist/artifacts.d.ts +421 -0
- package/dist/artifacts.d.ts.map +1 -0
- package/dist/audit-compliance.d.ts +752 -0
- package/dist/audit-compliance.d.ts.map +1 -0
- package/dist/certificates.d.ts +256 -0
- package/dist/certificates.d.ts.map +1 -0
- package/dist/chart-builder.d.ts +1404 -0
- package/dist/chart-builder.d.ts.map +1 -0
- package/dist/cloud-instances.d.ts +169 -0
- package/dist/cloud-instances.d.ts.map +1 -0
- package/dist/config-management.d.ts +350 -0
- package/dist/config-management.d.ts.map +1 -0
- package/dist/containers.d.ts +256 -0
- package/dist/containers.d.ts.map +1 -0
- package/dist/dashboard-designer.d.ts +1238 -0
- package/dist/dashboard-designer.d.ts.map +1 -0
- package/dist/data-management.d.ts +496 -0
- package/dist/data-management.d.ts.map +1 -0
- package/dist/data-pipeline.d.ts +1105 -0
- package/dist/data-pipeline.d.ts.map +1 -0
- package/dist/data-warehouse.d.ts +1097 -0
- package/dist/data-warehouse.d.ts.map +1 -0
- package/dist/dataset-management.d.ts +782 -0
- package/dist/dataset-management.d.ts.map +1 -0
- package/dist/db-adapters.d.ts +704 -0
- package/dist/db-adapters.d.ts.map +1 -0
- package/dist/db-admin.d.ts +699 -0
- package/dist/db-admin.d.ts.map +1 -0
- package/dist/db-designer.d.ts +366 -0
- package/dist/db-designer.d.ts.map +1 -0
- package/dist/debugger.d.ts +356 -0
- package/dist/debugger.d.ts.map +1 -0
- package/dist/device-management.d.ts +871 -0
- package/dist/device-management.d.ts.map +1 -0
- package/dist/distributed-tracing.d.ts +427 -0
- package/dist/distributed-tracing.d.ts.map +1 -0
- package/dist/dns-management.d.ts +215 -0
- package/dist/dns-management.d.ts.map +1 -0
- package/dist/download-manager.d.ts +271 -0
- package/dist/download-manager.d.ts.map +1 -0
- package/dist/download-torrent.d.ts +1062 -0
- package/dist/download-torrent.d.ts.map +1 -0
- package/dist/edge-computing.d.ts +720 -0
- package/dist/edge-computing.d.ts.map +1 -0
- package/dist/education.d.ts +1135 -0
- package/dist/education.d.ts.map +1 -0
- package/dist/email-template.d.ts +1141 -0
- package/dist/email-template.d.ts.map +1 -0
- package/dist/erp-enterprise.d.ts +1270 -0
- package/dist/erp-enterprise.d.ts.map +1 -0
- package/dist/form-builder.d.ts +1117 -0
- package/dist/form-builder.d.ts.map +1 -0
- package/dist/game-engine-advanced.d.ts +1049 -0
- package/dist/game-engine-advanced.d.ts.map +1 -0
- package/dist/git.d.ts +415 -0
- package/dist/git.d.ts.map +1 -0
- package/dist/hardware-integration.d.ts +966 -0
- package/dist/hardware-integration.d.ts.map +1 -0
- package/dist/iac.d.ts +318 -0
- package/dist/iac.d.ts.map +1 -0
- package/dist/icon-tools.d.ts +1023 -0
- package/dist/icon-tools.d.ts.map +1 -0
- package/dist/ide.d.ts +322 -0
- package/dist/ide.d.ts.map +1 -0
- package/dist/index.cjs +2 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.ts +176 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.mjs +1887 -0
- package/dist/index.mjs.map +1 -0
- package/dist/integration-platform.d.ts +857 -0
- package/dist/integration-platform.d.ts.map +1 -0
- package/dist/kubernetes.d.ts +278 -0
- package/dist/kubernetes.d.ts.map +1 -0
- package/dist/life-management.d.ts +1132 -0
- package/dist/life-management.d.ts.map +1 -0
- package/dist/log-management.d.ts +473 -0
- package/dist/log-management.d.ts.map +1 -0
- package/dist/mathematics.d.ts +870 -0
- package/dist/mathematics.d.ts.map +1 -0
- package/dist/message-queue.d.ts +1006 -0
- package/dist/message-queue.d.ts.map +1 -0
- package/dist/metrics-dashboard.d.ts +596 -0
- package/dist/metrics-dashboard.d.ts.map +1 -0
- package/dist/mobile-components.d.ts +766 -0
- package/dist/mobile-components.d.ts.map +1 -0
- package/dist/model-deployment.d.ts +787 -0
- package/dist/model-deployment.d.ts.map +1 -0
- package/dist/model-registry.d.ts +740 -0
- package/dist/model-registry.d.ts.map +1 -0
- package/dist/model-training.d.ts +706 -0
- package/dist/model-training.d.ts.map +1 -0
- package/dist/network-config.d.ts +334 -0
- package/dist/network-config.d.ts.map +1 -0
- package/dist/network-monitoring.d.ts +291 -0
- package/dist/network-monitoring.d.ts.map +1 -0
- package/dist/pdf-tools.d.ts +1003 -0
- package/dist/pdf-tools.d.ts.map +1 -0
- package/dist/pipelines.d.ts +250 -0
- package/dist/pipelines.d.ts.map +1 -0
- package/dist/remote-desktop.d.ts +207 -0
- package/dist/remote-desktop.d.ts.map +1 -0
- package/dist/report-designer.d.ts +1153 -0
- package/dist/report-designer.d.ts.map +1 -0
- package/dist/scada-industrial.d.ts +848 -0
- package/dist/scada-industrial.d.ts.map +1 -0
- package/dist/scientific-research.d.ts +1149 -0
- package/dist/scientific-research.d.ts.map +1 -0
- package/dist/secret-management.d.ts +617 -0
- package/dist/secret-management.d.ts.map +1 -0
- package/dist/security-scanning.d.ts +714 -0
- package/dist/security-scanning.d.ts.map +1 -0
- package/dist/self-service-analytics.d.ts +1208 -0
- package/dist/self-service-analytics.d.ts.map +1 -0
- package/dist/sensor-dashboard.d.ts +845 -0
- package/dist/sensor-dashboard.d.ts.map +1 -0
- package/dist/server-management.d.ts +331 -0
- package/dist/server-management.d.ts.map +1 -0
- package/dist/smart-home.d.ts +861 -0
- package/dist/smart-home.d.ts.map +1 -0
- package/dist/spreadsheet.d.ts +1043 -0
- package/dist/spreadsheet.d.ts.map +1 -0
- package/dist/sql-editor.d.ts +402 -0
- package/dist/sql-editor.d.ts.map +1 -0
- package/dist/terminal.d.ts +245 -0
- package/dist/terminal.d.ts.map +1 -0
- package/dist/testing-qa.d.ts +1013 -0
- package/dist/testing-qa.d.ts.map +1 -0
- package/dist/torrent-client.d.ts +298 -0
- package/dist/torrent-client.d.ts.map +1 -0
- package/dist/traceless.d.ts +759 -0
- package/dist/traceless.d.ts.map +1 -0
- package/dist/virtual-machines.d.ts +199 -0
- package/dist/virtual-machines.d.ts.map +1 -0
- package/dist/visual-scripting.d.ts +381 -0
- package/dist/visual-scripting.d.ts.map +1 -0
- package/dist/word-processor.d.ts +1124 -0
- package/dist/word-processor.d.ts.map +1 -0
- package/dist/workspace.d.ts +333 -0
- package/dist/workspace.d.ts.map +1 -0
- package/package.json +62 -0
|
@@ -0,0 +1,714 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file security-scanning.ts
|
|
3
|
+
* @module @nice2dev/ui-tools/security-scanning
|
|
4
|
+
* @description PRO-12.1 — Security Scanning types
|
|
5
|
+
*
|
|
6
|
+
* SAST, DAST, container scanning, dependency scanning,
|
|
7
|
+
* vulnerability dashboard, CVE database, risk scoring.
|
|
8
|
+
*/
|
|
9
|
+
/** Security dashboard */
|
|
10
|
+
export interface SecurityDashboard {
|
|
11
|
+
readonly summary: VulnerabilitySummary;
|
|
12
|
+
readonly scanHistory: readonly ScanHistoryEntry[];
|
|
13
|
+
readonly topVulnerabilities: readonly Vulnerability[];
|
|
14
|
+
readonly riskTrend: readonly RiskTrendPoint[];
|
|
15
|
+
readonly complianceStatus: readonly ComplianceStatusItem[];
|
|
16
|
+
readonly lastUpdated: Date;
|
|
17
|
+
}
|
|
18
|
+
/** Vulnerability summary */
|
|
19
|
+
export interface VulnerabilitySummary {
|
|
20
|
+
readonly critical: number;
|
|
21
|
+
readonly high: number;
|
|
22
|
+
readonly medium: number;
|
|
23
|
+
readonly low: number;
|
|
24
|
+
readonly informational: number;
|
|
25
|
+
readonly total: number;
|
|
26
|
+
readonly fixedLast30Days: number;
|
|
27
|
+
readonly newLast30Days: number;
|
|
28
|
+
readonly meanTimeToRemediate: number;
|
|
29
|
+
}
|
|
30
|
+
/** Scan history entry */
|
|
31
|
+
export interface ScanHistoryEntry {
|
|
32
|
+
readonly scanId: string;
|
|
33
|
+
readonly scanType: SecurityScanType;
|
|
34
|
+
readonly timestamp: Date;
|
|
35
|
+
readonly duration: number;
|
|
36
|
+
readonly status: ScanStatus;
|
|
37
|
+
readonly findingsCount: number;
|
|
38
|
+
readonly newFindings: number;
|
|
39
|
+
readonly fixedFindings: number;
|
|
40
|
+
}
|
|
41
|
+
/** Security scan type */
|
|
42
|
+
export type SecurityScanType = 'sast' | 'dast' | 'sca' | 'container' | 'iac' | 'secret' | 'penetration' | 'compliance';
|
|
43
|
+
/** Scan status */
|
|
44
|
+
export type ScanStatus = 'pending' | 'running' | 'completed' | 'failed' | 'cancelled';
|
|
45
|
+
/** Risk trend point */
|
|
46
|
+
export interface RiskTrendPoint {
|
|
47
|
+
readonly date: Date;
|
|
48
|
+
readonly riskScore: number;
|
|
49
|
+
readonly criticalCount: number;
|
|
50
|
+
readonly highCount: number;
|
|
51
|
+
}
|
|
52
|
+
/** Compliance status item */
|
|
53
|
+
export interface ComplianceStatusItem {
|
|
54
|
+
readonly framework: ComplianceFramework;
|
|
55
|
+
readonly controlsPassed: number;
|
|
56
|
+
readonly controlsFailed: number;
|
|
57
|
+
readonly controlsTotal: number;
|
|
58
|
+
readonly compliancePercent: number;
|
|
59
|
+
readonly lastAssessed: Date;
|
|
60
|
+
}
|
|
61
|
+
/** Compliance framework */
|
|
62
|
+
export type ComplianceFramework = 'soc2' | 'pci_dss' | 'hipaa' | 'gdpr' | 'iso27001' | 'nist_csf' | 'cis_benchmarks' | 'fedramp';
|
|
63
|
+
/** Vulnerability */
|
|
64
|
+
export interface Vulnerability {
|
|
65
|
+
readonly id: string;
|
|
66
|
+
readonly cveId?: string;
|
|
67
|
+
readonly cweId?: string;
|
|
68
|
+
readonly title: string;
|
|
69
|
+
readonly description: string;
|
|
70
|
+
readonly severity: VulnerabilitySeverity;
|
|
71
|
+
readonly cvssScore?: number;
|
|
72
|
+
readonly cvssVector?: string;
|
|
73
|
+
readonly epssScore?: number;
|
|
74
|
+
readonly category: VulnerabilityCategory;
|
|
75
|
+
readonly status: VulnerabilityStatus;
|
|
76
|
+
readonly source: VulnerabilitySource;
|
|
77
|
+
readonly firstDetected: Date;
|
|
78
|
+
readonly lastSeen: Date;
|
|
79
|
+
readonly fixedAt?: Date;
|
|
80
|
+
readonly dueDate?: Date;
|
|
81
|
+
readonly affectedAssets: readonly AffectedAsset[];
|
|
82
|
+
readonly remediation?: RemediationInfo;
|
|
83
|
+
readonly references: readonly VulnerabilityReference[];
|
|
84
|
+
readonly assignee?: string;
|
|
85
|
+
readonly tags: readonly string[];
|
|
86
|
+
}
|
|
87
|
+
/** Vulnerability severity */
|
|
88
|
+
export type VulnerabilitySeverity = 'critical' | 'high' | 'medium' | 'low' | 'informational';
|
|
89
|
+
/** Vulnerability category */
|
|
90
|
+
export type VulnerabilityCategory = 'injection' | 'authentication' | 'authorization' | 'xss' | 'csrf' | 'ssrf' | 'xxe' | 'deserialization' | 'path_traversal' | 'information_disclosure' | 'misconfiguration' | 'cryptographic' | 'dependency' | 'container' | 'infrastructure' | 'secret_exposure' | 'other';
|
|
91
|
+
/** Vulnerability status */
|
|
92
|
+
export type VulnerabilityStatus = 'open' | 'in_progress' | 'fixed' | 'accepted' | 'false_positive' | 'wont_fix' | 'duplicate';
|
|
93
|
+
/** Vulnerability source */
|
|
94
|
+
export interface VulnerabilitySource {
|
|
95
|
+
readonly scanType: SecurityScanType;
|
|
96
|
+
readonly scanner: string;
|
|
97
|
+
readonly scanId: string;
|
|
98
|
+
readonly ruleId?: string;
|
|
99
|
+
}
|
|
100
|
+
/** Affected asset */
|
|
101
|
+
export interface AffectedAsset {
|
|
102
|
+
readonly type: AssetType;
|
|
103
|
+
readonly name: string;
|
|
104
|
+
readonly version?: string;
|
|
105
|
+
readonly path?: string;
|
|
106
|
+
readonly location?: CodeLocation;
|
|
107
|
+
readonly environment?: string;
|
|
108
|
+
}
|
|
109
|
+
/** Asset type */
|
|
110
|
+
export type AssetType = 'source_code' | 'dependency' | 'container_image' | 'infrastructure' | 'api_endpoint' | 'web_application' | 'configuration' | 'secret';
|
|
111
|
+
/** Code location */
|
|
112
|
+
export interface CodeLocation {
|
|
113
|
+
readonly file: string;
|
|
114
|
+
readonly startLine: number;
|
|
115
|
+
readonly endLine?: number;
|
|
116
|
+
readonly startColumn?: number;
|
|
117
|
+
readonly endColumn?: number;
|
|
118
|
+
readonly snippet?: string;
|
|
119
|
+
}
|
|
120
|
+
/** Remediation info */
|
|
121
|
+
export interface RemediationInfo {
|
|
122
|
+
readonly description: string;
|
|
123
|
+
readonly effort: RemediationEffort;
|
|
124
|
+
readonly steps?: readonly string[];
|
|
125
|
+
readonly fixVersion?: string;
|
|
126
|
+
readonly patchAvailable: boolean;
|
|
127
|
+
readonly workaround?: string;
|
|
128
|
+
}
|
|
129
|
+
/** Remediation effort */
|
|
130
|
+
export type RemediationEffort = 'trivial' | 'low' | 'medium' | 'high' | 'complex';
|
|
131
|
+
/** Vulnerability reference */
|
|
132
|
+
export interface VulnerabilityReference {
|
|
133
|
+
readonly type: ReferenceType;
|
|
134
|
+
readonly url: string;
|
|
135
|
+
readonly title?: string;
|
|
136
|
+
}
|
|
137
|
+
/** Reference type */
|
|
138
|
+
export type ReferenceType = 'cve' | 'cwe' | 'nvd' | 'advisory' | 'article' | 'exploit' | 'patch' | 'other';
|
|
139
|
+
/** SAST scan config */
|
|
140
|
+
export interface SastScanConfig {
|
|
141
|
+
readonly id: string;
|
|
142
|
+
readonly name: string;
|
|
143
|
+
readonly enabled: boolean;
|
|
144
|
+
readonly language: SastLanguage;
|
|
145
|
+
readonly rules: readonly SastRuleConfig[];
|
|
146
|
+
readonly excludePaths: readonly string[];
|
|
147
|
+
readonly includePaths: readonly string[];
|
|
148
|
+
readonly severity: readonly VulnerabilitySeverity[];
|
|
149
|
+
readonly failOnSeverity?: VulnerabilitySeverity;
|
|
150
|
+
readonly maxIssues?: number;
|
|
151
|
+
}
|
|
152
|
+
/** SAST language */
|
|
153
|
+
export type SastLanguage = 'javascript' | 'typescript' | 'python' | 'java' | 'csharp' | 'go' | 'ruby' | 'php' | 'kotlin' | 'swift' | 'rust' | 'cpp';
|
|
154
|
+
/** SAST rule config */
|
|
155
|
+
export interface SastRuleConfig {
|
|
156
|
+
readonly ruleId: string;
|
|
157
|
+
readonly enabled: boolean;
|
|
158
|
+
readonly severity?: VulnerabilitySeverity;
|
|
159
|
+
readonly parameters?: Record<string, unknown>;
|
|
160
|
+
}
|
|
161
|
+
/** SAST finding */
|
|
162
|
+
export interface SastFinding {
|
|
163
|
+
readonly id: string;
|
|
164
|
+
readonly ruleId: string;
|
|
165
|
+
readonly ruleName: string;
|
|
166
|
+
readonly category: VulnerabilityCategory;
|
|
167
|
+
readonly severity: VulnerabilitySeverity;
|
|
168
|
+
readonly message: string;
|
|
169
|
+
readonly location: CodeLocation;
|
|
170
|
+
readonly dataFlow?: readonly DataFlowStep[];
|
|
171
|
+
readonly cweId?: string;
|
|
172
|
+
readonly owaspCategory?: string;
|
|
173
|
+
readonly confidence: ConfidenceLevel;
|
|
174
|
+
readonly remediation?: string;
|
|
175
|
+
}
|
|
176
|
+
/** Data flow step */
|
|
177
|
+
export interface DataFlowStep {
|
|
178
|
+
readonly index: number;
|
|
179
|
+
readonly location: CodeLocation;
|
|
180
|
+
readonly description: string;
|
|
181
|
+
readonly type: 'source' | 'propagator' | 'sink';
|
|
182
|
+
}
|
|
183
|
+
/** Confidence level */
|
|
184
|
+
export type ConfidenceLevel = 'high' | 'medium' | 'low';
|
|
185
|
+
/** DAST scan config */
|
|
186
|
+
export interface DastScanConfig {
|
|
187
|
+
readonly id: string;
|
|
188
|
+
readonly name: string;
|
|
189
|
+
readonly enabled: boolean;
|
|
190
|
+
readonly targetUrl: string;
|
|
191
|
+
readonly scanType: DastScanType;
|
|
192
|
+
readonly authentication?: DastAuthentication;
|
|
193
|
+
readonly crawlConfig: CrawlConfig;
|
|
194
|
+
readonly attackPolicies: readonly string[];
|
|
195
|
+
readonly excludeUrls: readonly string[];
|
|
196
|
+
readonly scanSpeed: DastScanSpeed;
|
|
197
|
+
readonly maxDuration?: number;
|
|
198
|
+
}
|
|
199
|
+
/** DAST scan type */
|
|
200
|
+
export type DastScanType = 'passive' | 'active' | 'full' | 'api';
|
|
201
|
+
/** DAST authentication */
|
|
202
|
+
export interface DastAuthentication {
|
|
203
|
+
readonly type: DastAuthType;
|
|
204
|
+
readonly config: Record<string, unknown>;
|
|
205
|
+
}
|
|
206
|
+
/** DAST auth type */
|
|
207
|
+
export type DastAuthType = 'none' | 'http_basic' | 'http_bearer' | 'form_based' | 'session_cookie' | 'oauth2';
|
|
208
|
+
/** Crawl config */
|
|
209
|
+
export interface CrawlConfig {
|
|
210
|
+
readonly maxDepth: number;
|
|
211
|
+
readonly maxUrls: number;
|
|
212
|
+
readonly timeout: number;
|
|
213
|
+
readonly userAgent?: string;
|
|
214
|
+
readonly respectRobotsTxt: boolean;
|
|
215
|
+
readonly includedDomains: readonly string[];
|
|
216
|
+
readonly excludedPatterns: readonly string[];
|
|
217
|
+
}
|
|
218
|
+
/** DAST scan speed */
|
|
219
|
+
export type DastScanSpeed = 'fast' | 'normal' | 'thorough';
|
|
220
|
+
/** DAST finding */
|
|
221
|
+
export interface DastFinding {
|
|
222
|
+
readonly id: string;
|
|
223
|
+
readonly alertId: string;
|
|
224
|
+
readonly name: string;
|
|
225
|
+
readonly description: string;
|
|
226
|
+
readonly severity: VulnerabilitySeverity;
|
|
227
|
+
readonly url: string;
|
|
228
|
+
readonly method: string;
|
|
229
|
+
readonly parameter?: string;
|
|
230
|
+
readonly attack?: string;
|
|
231
|
+
readonly evidence?: string;
|
|
232
|
+
readonly cweId?: string;
|
|
233
|
+
readonly owaspCategory?: string;
|
|
234
|
+
readonly solution?: string;
|
|
235
|
+
readonly references: readonly string[];
|
|
236
|
+
readonly requestResponse?: HttpExchange;
|
|
237
|
+
}
|
|
238
|
+
/** HTTP exchange */
|
|
239
|
+
export interface HttpExchange {
|
|
240
|
+
readonly request: HttpRequest;
|
|
241
|
+
readonly response: HttpResponse;
|
|
242
|
+
}
|
|
243
|
+
/** HTTP request */
|
|
244
|
+
export interface HttpRequest {
|
|
245
|
+
readonly method: string;
|
|
246
|
+
readonly url: string;
|
|
247
|
+
readonly headers: Record<string, string>;
|
|
248
|
+
readonly body?: string;
|
|
249
|
+
}
|
|
250
|
+
/** HTTP response */
|
|
251
|
+
export interface HttpResponse {
|
|
252
|
+
readonly statusCode: number;
|
|
253
|
+
readonly headers: Record<string, string>;
|
|
254
|
+
readonly body?: string;
|
|
255
|
+
}
|
|
256
|
+
/** Container scan config */
|
|
257
|
+
export interface ContainerScanConfig {
|
|
258
|
+
readonly id: string;
|
|
259
|
+
readonly name: string;
|
|
260
|
+
readonly enabled: boolean;
|
|
261
|
+
readonly registries: readonly ContainerRegistry[];
|
|
262
|
+
readonly imagePatterns: readonly string[];
|
|
263
|
+
readonly excludePatterns: readonly string[];
|
|
264
|
+
readonly scanOnPush: boolean;
|
|
265
|
+
readonly scanSchedule?: string;
|
|
266
|
+
readonly severityThreshold?: VulnerabilitySeverity;
|
|
267
|
+
}
|
|
268
|
+
/** Container registry */
|
|
269
|
+
export interface ContainerRegistry {
|
|
270
|
+
readonly type: RegistryType;
|
|
271
|
+
readonly url: string;
|
|
272
|
+
readonly credentialId?: string;
|
|
273
|
+
}
|
|
274
|
+
/** Registry type */
|
|
275
|
+
export type RegistryType = 'docker_hub' | 'ecr' | 'gcr' | 'acr' | 'harbor' | 'artifactory' | 'quay' | 'ghcr';
|
|
276
|
+
/** Container scan result */
|
|
277
|
+
export interface ContainerScanResult {
|
|
278
|
+
readonly imageId: string;
|
|
279
|
+
readonly imageName: string;
|
|
280
|
+
readonly imageTag: string;
|
|
281
|
+
readonly digest: string;
|
|
282
|
+
readonly scannedAt: Date;
|
|
283
|
+
readonly os: OsInfo;
|
|
284
|
+
readonly layers: readonly ImageLayer[];
|
|
285
|
+
readonly vulnerabilities: readonly ContainerVulnerability[];
|
|
286
|
+
readonly baseImage?: string;
|
|
287
|
+
readonly size: number;
|
|
288
|
+
readonly configIssues: readonly ConfigurationIssue[];
|
|
289
|
+
}
|
|
290
|
+
/** OS info */
|
|
291
|
+
export interface OsInfo {
|
|
292
|
+
readonly family: string;
|
|
293
|
+
readonly name: string;
|
|
294
|
+
readonly version?: string;
|
|
295
|
+
}
|
|
296
|
+
/** Image layer */
|
|
297
|
+
export interface ImageLayer {
|
|
298
|
+
readonly digest: string;
|
|
299
|
+
readonly size: number;
|
|
300
|
+
readonly createdBy?: string;
|
|
301
|
+
readonly vulnerabilityCount: number;
|
|
302
|
+
}
|
|
303
|
+
/** Container vulnerability */
|
|
304
|
+
export interface ContainerVulnerability extends Vulnerability {
|
|
305
|
+
readonly packageName: string;
|
|
306
|
+
readonly installedVersion: string;
|
|
307
|
+
readonly fixedVersion?: string;
|
|
308
|
+
readonly layer?: string;
|
|
309
|
+
readonly packageType: PackageType;
|
|
310
|
+
}
|
|
311
|
+
/** Package type */
|
|
312
|
+
export type PackageType = 'apk' | 'apt' | 'rpm' | 'npm' | 'pip' | 'gem' | 'go' | 'cargo' | 'nuget' | 'jar';
|
|
313
|
+
/** Configuration issue */
|
|
314
|
+
export interface ConfigurationIssue {
|
|
315
|
+
readonly id: string;
|
|
316
|
+
readonly title: string;
|
|
317
|
+
readonly description: string;
|
|
318
|
+
readonly severity: VulnerabilitySeverity;
|
|
319
|
+
readonly category: ConfigIssueCategory;
|
|
320
|
+
readonly remediation?: string;
|
|
321
|
+
}
|
|
322
|
+
/** Config issue category */
|
|
323
|
+
export type ConfigIssueCategory = 'root_user' | 'sensitive_data' | 'exposed_port' | 'outdated_base' | 'missing_healthcheck' | 'privileged_mode' | 'writable_filesystem';
|
|
324
|
+
/** Dependency scan config */
|
|
325
|
+
export interface DependencyScanConfig {
|
|
326
|
+
readonly id: string;
|
|
327
|
+
readonly name: string;
|
|
328
|
+
readonly enabled: boolean;
|
|
329
|
+
readonly ecosystems: readonly PackageEcosystem[];
|
|
330
|
+
readonly manifestPatterns: readonly string[];
|
|
331
|
+
readonly lockfilePatterns: readonly string[];
|
|
332
|
+
readonly excludePaths: readonly string[];
|
|
333
|
+
readonly devDependencies: boolean;
|
|
334
|
+
readonly licensePolicy?: LicensePolicy;
|
|
335
|
+
}
|
|
336
|
+
/** Package ecosystem */
|
|
337
|
+
export type PackageEcosystem = 'npm' | 'yarn' | 'pnpm' | 'pip' | 'poetry' | 'pipenv' | 'maven' | 'gradle' | 'nuget' | 'go' | 'cargo' | 'gem' | 'composer' | 'pub';
|
|
338
|
+
/** License policy */
|
|
339
|
+
export interface LicensePolicy {
|
|
340
|
+
readonly allowed: readonly string[];
|
|
341
|
+
readonly denied: readonly string[];
|
|
342
|
+
readonly review: readonly string[];
|
|
343
|
+
}
|
|
344
|
+
/** Dependency */
|
|
345
|
+
export interface Dependency {
|
|
346
|
+
readonly name: string;
|
|
347
|
+
readonly version: string;
|
|
348
|
+
readonly ecosystem: PackageEcosystem;
|
|
349
|
+
readonly scope: DependencyScope;
|
|
350
|
+
readonly direct: boolean;
|
|
351
|
+
readonly licenses: readonly string[];
|
|
352
|
+
readonly vulnerabilities: readonly DependencyVulnerability[];
|
|
353
|
+
readonly dependencyPath: readonly string[];
|
|
354
|
+
readonly latestVersion?: string;
|
|
355
|
+
readonly deprecated?: boolean;
|
|
356
|
+
readonly maintainerCount?: number;
|
|
357
|
+
readonly lastPublished?: Date;
|
|
358
|
+
}
|
|
359
|
+
/** Dependency scope */
|
|
360
|
+
export type DependencyScope = 'runtime' | 'development' | 'optional' | 'peer';
|
|
361
|
+
/** Dependency vulnerability */
|
|
362
|
+
export interface DependencyVulnerability extends Vulnerability {
|
|
363
|
+
readonly vulnerableVersions: string;
|
|
364
|
+
readonly patchedVersions?: string;
|
|
365
|
+
readonly publishedDate: Date;
|
|
366
|
+
readonly advisoryUrl?: string;
|
|
367
|
+
}
|
|
368
|
+
/** Secret scan config */
|
|
369
|
+
export interface SecretScanConfig {
|
|
370
|
+
readonly id: string;
|
|
371
|
+
readonly name: string;
|
|
372
|
+
readonly enabled: boolean;
|
|
373
|
+
readonly patterns: readonly SecretPattern[];
|
|
374
|
+
readonly includePaths: readonly string[];
|
|
375
|
+
readonly excludePaths: readonly string[];
|
|
376
|
+
readonly excludePatterns: readonly string[];
|
|
377
|
+
readonly commitHistory: boolean;
|
|
378
|
+
readonly historicalLimit?: number;
|
|
379
|
+
}
|
|
380
|
+
/** Secret pattern */
|
|
381
|
+
export interface SecretPattern {
|
|
382
|
+
readonly id: string;
|
|
383
|
+
readonly name: string;
|
|
384
|
+
readonly type: SecretType;
|
|
385
|
+
readonly pattern: string;
|
|
386
|
+
readonly keywords?: readonly string[];
|
|
387
|
+
readonly enabled: boolean;
|
|
388
|
+
readonly severity: VulnerabilitySeverity;
|
|
389
|
+
}
|
|
390
|
+
/** Secret type */
|
|
391
|
+
export type SecretType = 'api_key' | 'aws_access_key' | 'azure_key' | 'gcp_key' | 'private_key' | 'certificate' | 'password' | 'token' | 'jwt' | 'oauth_secret' | 'database_url' | 'ssh_key' | 'slack_webhook' | 'stripe_key' | 'twilio_key' | 'sendgrid_key' | 'generic';
|
|
392
|
+
/** Secret finding */
|
|
393
|
+
export interface SecretFinding {
|
|
394
|
+
readonly id: string;
|
|
395
|
+
readonly patternId: string;
|
|
396
|
+
readonly secretType: SecretType;
|
|
397
|
+
readonly severity: VulnerabilitySeverity;
|
|
398
|
+
readonly file: string;
|
|
399
|
+
readonly line: number;
|
|
400
|
+
readonly commit?: string;
|
|
401
|
+
readonly author?: string;
|
|
402
|
+
readonly date?: Date;
|
|
403
|
+
readonly redactedValue: string;
|
|
404
|
+
readonly verified?: boolean;
|
|
405
|
+
readonly status: SecretFindingStatus;
|
|
406
|
+
readonly rotated: boolean;
|
|
407
|
+
readonly rotatedAt?: Date;
|
|
408
|
+
}
|
|
409
|
+
/** Secret finding status */
|
|
410
|
+
export type SecretFindingStatus = 'active' | 'rotated' | 'false_positive' | 'ignored';
|
|
411
|
+
/** IaC scan config */
|
|
412
|
+
export interface IacScanConfig {
|
|
413
|
+
readonly id: string;
|
|
414
|
+
readonly name: string;
|
|
415
|
+
readonly enabled: boolean;
|
|
416
|
+
readonly frameworks: readonly IacFramework[];
|
|
417
|
+
readonly includePaths: readonly string[];
|
|
418
|
+
readonly excludePaths: readonly string[];
|
|
419
|
+
readonly policies: readonly IacPolicy[];
|
|
420
|
+
readonly skipSoftFail: boolean;
|
|
421
|
+
}
|
|
422
|
+
/** IaC framework */
|
|
423
|
+
export type IacFramework = 'terraform' | 'cloudformation' | 'arm' | 'kubernetes' | 'helm' | 'ansible' | 'docker' | 'pulumi';
|
|
424
|
+
/** IaC policy */
|
|
425
|
+
export interface IacPolicy {
|
|
426
|
+
readonly id: string;
|
|
427
|
+
readonly name: string;
|
|
428
|
+
readonly enabled: boolean;
|
|
429
|
+
readonly severity: VulnerabilitySeverity;
|
|
430
|
+
readonly category: IacPolicyCategory;
|
|
431
|
+
readonly check: string;
|
|
432
|
+
}
|
|
433
|
+
/** IaC policy category */
|
|
434
|
+
export type IacPolicyCategory = 'networking' | 'iam' | 'encryption' | 'logging' | 'backup' | 'public_access' | 'compliance' | 'best_practice';
|
|
435
|
+
/** IaC finding */
|
|
436
|
+
export interface IacFinding {
|
|
437
|
+
readonly id: string;
|
|
438
|
+
readonly policyId: string;
|
|
439
|
+
readonly policyName: string;
|
|
440
|
+
readonly severity: VulnerabilitySeverity;
|
|
441
|
+
readonly category: IacPolicyCategory;
|
|
442
|
+
readonly resource: IacResource;
|
|
443
|
+
readonly message: string;
|
|
444
|
+
readonly remediation?: string;
|
|
445
|
+
readonly documentationUrl?: string;
|
|
446
|
+
}
|
|
447
|
+
/** IaC resource */
|
|
448
|
+
export interface IacResource {
|
|
449
|
+
readonly type: string;
|
|
450
|
+
readonly name: string;
|
|
451
|
+
readonly file: string;
|
|
452
|
+
readonly line: number;
|
|
453
|
+
readonly address?: string;
|
|
454
|
+
}
|
|
455
|
+
/** CVE entry */
|
|
456
|
+
export interface CveEntry {
|
|
457
|
+
readonly cveId: string;
|
|
458
|
+
readonly description: string;
|
|
459
|
+
readonly publishedDate: Date;
|
|
460
|
+
readonly modifiedDate: Date;
|
|
461
|
+
readonly status: CveStatus;
|
|
462
|
+
readonly cvss: CvssInfo;
|
|
463
|
+
readonly cwe: readonly string[];
|
|
464
|
+
readonly references: readonly CveReference[];
|
|
465
|
+
readonly affectedProducts: readonly CpeEntry[];
|
|
466
|
+
readonly exploitAvailable: boolean;
|
|
467
|
+
readonly patchAvailable: boolean;
|
|
468
|
+
}
|
|
469
|
+
/** CVE status */
|
|
470
|
+
export type CveStatus = 'analyzed' | 'modified' | 'rejected' | 'reserved';
|
|
471
|
+
/** CVSS info */
|
|
472
|
+
export interface CvssInfo {
|
|
473
|
+
readonly version: '2.0' | '3.0' | '3.1' | '4.0';
|
|
474
|
+
readonly score: number;
|
|
475
|
+
readonly severity: VulnerabilitySeverity;
|
|
476
|
+
readonly vector: string;
|
|
477
|
+
readonly metrics: CvssMetrics;
|
|
478
|
+
}
|
|
479
|
+
/** CVSS metrics */
|
|
480
|
+
export interface CvssMetrics {
|
|
481
|
+
readonly attackVector: 'network' | 'adjacent' | 'local' | 'physical';
|
|
482
|
+
readonly attackComplexity: 'low' | 'high';
|
|
483
|
+
readonly privilegesRequired: 'none' | 'low' | 'high';
|
|
484
|
+
readonly userInteraction: 'none' | 'required';
|
|
485
|
+
readonly scope: 'unchanged' | 'changed';
|
|
486
|
+
readonly confidentialityImpact: 'none' | 'low' | 'high';
|
|
487
|
+
readonly integrityImpact: 'none' | 'low' | 'high';
|
|
488
|
+
readonly availabilityImpact: 'none' | 'low' | 'high';
|
|
489
|
+
readonly exploitCodeMaturity?: string;
|
|
490
|
+
readonly remediationLevel?: string;
|
|
491
|
+
readonly reportConfidence?: string;
|
|
492
|
+
}
|
|
493
|
+
/** CVE reference */
|
|
494
|
+
export interface CveReference {
|
|
495
|
+
readonly url: string;
|
|
496
|
+
readonly source: string;
|
|
497
|
+
readonly tags: readonly string[];
|
|
498
|
+
}
|
|
499
|
+
/** CPE entry */
|
|
500
|
+
export interface CpeEntry {
|
|
501
|
+
readonly cpe: string;
|
|
502
|
+
readonly vendor: string;
|
|
503
|
+
readonly product: string;
|
|
504
|
+
readonly version: string;
|
|
505
|
+
readonly versionEndExcluding?: string;
|
|
506
|
+
readonly versionEndIncluding?: string;
|
|
507
|
+
}
|
|
508
|
+
/** Penetration test report */
|
|
509
|
+
export interface PentestReport {
|
|
510
|
+
readonly id: string;
|
|
511
|
+
readonly title: string;
|
|
512
|
+
readonly type: PentestType;
|
|
513
|
+
readonly scope: PentestScope;
|
|
514
|
+
readonly methodology: string;
|
|
515
|
+
readonly startDate: Date;
|
|
516
|
+
readonly endDate: Date;
|
|
517
|
+
readonly tester: TesterInfo;
|
|
518
|
+
readonly executiveSummary: string;
|
|
519
|
+
readonly findings: readonly PentestFinding[];
|
|
520
|
+
readonly riskRating: RiskRating;
|
|
521
|
+
readonly recommendations: readonly Recommendation[];
|
|
522
|
+
readonly attachments: readonly Attachment[];
|
|
523
|
+
}
|
|
524
|
+
/** Pentest type */
|
|
525
|
+
export type PentestType = 'black_box' | 'gray_box' | 'white_box' | 'red_team' | 'purple_team';
|
|
526
|
+
/** Pentest scope */
|
|
527
|
+
export interface PentestScope {
|
|
528
|
+
readonly inScope: readonly string[];
|
|
529
|
+
readonly outOfScope: readonly string[];
|
|
530
|
+
readonly constraints: readonly string[];
|
|
531
|
+
readonly objectives: readonly string[];
|
|
532
|
+
}
|
|
533
|
+
/** Tester info */
|
|
534
|
+
export interface TesterInfo {
|
|
535
|
+
readonly name: string;
|
|
536
|
+
readonly organization: string;
|
|
537
|
+
readonly certifications: readonly string[];
|
|
538
|
+
readonly contact: string;
|
|
539
|
+
}
|
|
540
|
+
/** Pentest finding */
|
|
541
|
+
export interface PentestFinding {
|
|
542
|
+
readonly id: string;
|
|
543
|
+
readonly title: string;
|
|
544
|
+
readonly severity: VulnerabilitySeverity;
|
|
545
|
+
readonly cvssScore: number;
|
|
546
|
+
readonly description: string;
|
|
547
|
+
readonly impact: string;
|
|
548
|
+
readonly likelihood: LikelihoodLevel;
|
|
549
|
+
readonly affectedAssets: readonly string[];
|
|
550
|
+
readonly proofOfConcept?: string;
|
|
551
|
+
readonly screenshots?: readonly string[];
|
|
552
|
+
readonly remediation: string;
|
|
553
|
+
readonly references: readonly string[];
|
|
554
|
+
readonly status: PentestFindingStatus;
|
|
555
|
+
}
|
|
556
|
+
/** Likelihood level */
|
|
557
|
+
export type LikelihoodLevel = 'high' | 'medium' | 'low';
|
|
558
|
+
/** Pentest finding status */
|
|
559
|
+
export type PentestFindingStatus = 'open' | 'remediated' | 'verified' | 'accepted';
|
|
560
|
+
/** Risk rating */
|
|
561
|
+
export interface RiskRating {
|
|
562
|
+
readonly overall: VulnerabilitySeverity;
|
|
563
|
+
readonly score: number;
|
|
564
|
+
readonly breakdown: Record<VulnerabilitySeverity, number>;
|
|
565
|
+
}
|
|
566
|
+
/** Recommendation */
|
|
567
|
+
export interface Recommendation {
|
|
568
|
+
readonly priority: number;
|
|
569
|
+
readonly title: string;
|
|
570
|
+
readonly description: string;
|
|
571
|
+
readonly effort: RemediationEffort;
|
|
572
|
+
readonly relatedFindings: readonly string[];
|
|
573
|
+
}
|
|
574
|
+
/** Attachment */
|
|
575
|
+
export interface Attachment {
|
|
576
|
+
readonly id: string;
|
|
577
|
+
readonly name: string;
|
|
578
|
+
readonly type: string;
|
|
579
|
+
readonly size: number;
|
|
580
|
+
readonly url: string;
|
|
581
|
+
}
|
|
582
|
+
/** Remediation task */
|
|
583
|
+
export interface RemediationTask {
|
|
584
|
+
readonly id: string;
|
|
585
|
+
readonly title: string;
|
|
586
|
+
readonly description: string;
|
|
587
|
+
readonly vulnerabilityIds: readonly string[];
|
|
588
|
+
readonly status: RemediationStatus;
|
|
589
|
+
readonly priority: TaskPriority;
|
|
590
|
+
readonly assignee?: string;
|
|
591
|
+
readonly team?: string;
|
|
592
|
+
readonly dueDate?: Date;
|
|
593
|
+
readonly createdAt: Date;
|
|
594
|
+
readonly updatedAt: Date;
|
|
595
|
+
readonly completedAt?: Date;
|
|
596
|
+
readonly effort: RemediationEffort;
|
|
597
|
+
readonly comments: readonly TaskComment[];
|
|
598
|
+
readonly linkedIssues: readonly LinkedIssue[];
|
|
599
|
+
}
|
|
600
|
+
/** Remediation status */
|
|
601
|
+
export type RemediationStatus = 'open' | 'in_progress' | 'pending_verification' | 'verified' | 'closed' | 'wont_fix';
|
|
602
|
+
/** Task priority */
|
|
603
|
+
export type TaskPriority = 'urgent' | 'high' | 'medium' | 'low';
|
|
604
|
+
/** Task comment */
|
|
605
|
+
export interface TaskComment {
|
|
606
|
+
readonly id: string;
|
|
607
|
+
readonly author: string;
|
|
608
|
+
readonly content: string;
|
|
609
|
+
readonly createdAt: Date;
|
|
610
|
+
}
|
|
611
|
+
/** Linked issue */
|
|
612
|
+
export interface LinkedIssue {
|
|
613
|
+
readonly system: IssueTracker;
|
|
614
|
+
readonly issueId: string;
|
|
615
|
+
readonly url: string;
|
|
616
|
+
readonly status?: string;
|
|
617
|
+
}
|
|
618
|
+
/** Issue tracker */
|
|
619
|
+
export type IssueTracker = 'jira' | 'github' | 'gitlab' | 'azure_devops' | 'servicenow';
|
|
620
|
+
/** Risk score */
|
|
621
|
+
export interface RiskScore {
|
|
622
|
+
readonly overall: number;
|
|
623
|
+
readonly category: RiskCategory;
|
|
624
|
+
readonly factors: readonly RiskFactor[];
|
|
625
|
+
readonly trend: RiskTrend;
|
|
626
|
+
readonly lastCalculated: Date;
|
|
627
|
+
}
|
|
628
|
+
/** Risk category */
|
|
629
|
+
export type RiskCategory = 'critical' | 'high' | 'medium' | 'low' | 'minimal';
|
|
630
|
+
/** Risk factor */
|
|
631
|
+
export interface RiskFactor {
|
|
632
|
+
readonly name: string;
|
|
633
|
+
readonly weight: number;
|
|
634
|
+
readonly score: number;
|
|
635
|
+
readonly maxScore: number;
|
|
636
|
+
readonly description: string;
|
|
637
|
+
}
|
|
638
|
+
/** Risk trend */
|
|
639
|
+
export interface RiskTrend {
|
|
640
|
+
readonly direction: 'improving' | 'stable' | 'worsening';
|
|
641
|
+
readonly changePercent: number;
|
|
642
|
+
readonly period: string;
|
|
643
|
+
}
|
|
644
|
+
/** Scan schedule */
|
|
645
|
+
export interface ScanSchedule {
|
|
646
|
+
readonly id: string;
|
|
647
|
+
readonly name: string;
|
|
648
|
+
readonly enabled: boolean;
|
|
649
|
+
readonly scanConfigs: readonly string[];
|
|
650
|
+
readonly cronExpression: string;
|
|
651
|
+
readonly timezone: string;
|
|
652
|
+
readonly notifyOnComplete: boolean;
|
|
653
|
+
readonly notifyOnFailure: boolean;
|
|
654
|
+
readonly notificationChannels: readonly string[];
|
|
655
|
+
readonly lastRun?: Date;
|
|
656
|
+
readonly nextRun?: Date;
|
|
657
|
+
}
|
|
658
|
+
/** Security policy */
|
|
659
|
+
export interface SecurityPolicy {
|
|
660
|
+
readonly id: string;
|
|
661
|
+
readonly name: string;
|
|
662
|
+
readonly description: string;
|
|
663
|
+
readonly enabled: boolean;
|
|
664
|
+
readonly rules: readonly PolicyRule[];
|
|
665
|
+
readonly scope: PolicyScope;
|
|
666
|
+
readonly enforcement: PolicyEnforcement;
|
|
667
|
+
readonly createdAt: Date;
|
|
668
|
+
readonly updatedAt: Date;
|
|
669
|
+
}
|
|
670
|
+
/** Policy rule */
|
|
671
|
+
export interface PolicyRule {
|
|
672
|
+
readonly id: string;
|
|
673
|
+
readonly name: string;
|
|
674
|
+
readonly condition: PolicyCondition;
|
|
675
|
+
readonly action: PolicyAction;
|
|
676
|
+
}
|
|
677
|
+
/** Policy condition */
|
|
678
|
+
export interface PolicyCondition {
|
|
679
|
+
readonly field: string;
|
|
680
|
+
readonly operator: PolicyOperator;
|
|
681
|
+
readonly value: unknown;
|
|
682
|
+
readonly and?: readonly PolicyCondition[];
|
|
683
|
+
readonly or?: readonly PolicyCondition[];
|
|
684
|
+
}
|
|
685
|
+
/** Policy operator */
|
|
686
|
+
export type PolicyOperator = 'equals' | 'not_equals' | 'contains' | 'not_contains' | 'greater_than' | 'less_than' | 'in' | 'not_in' | 'matches';
|
|
687
|
+
/** Policy action */
|
|
688
|
+
export interface PolicyAction {
|
|
689
|
+
readonly type: PolicyActionType;
|
|
690
|
+
readonly parameters?: Record<string, unknown>;
|
|
691
|
+
}
|
|
692
|
+
/** Policy action type */
|
|
693
|
+
export type PolicyActionType = 'block' | 'warn' | 'notify' | 'audit' | 'fail_build' | 'require_approval';
|
|
694
|
+
/** Policy scope */
|
|
695
|
+
export interface PolicyScope {
|
|
696
|
+
readonly repositories?: readonly string[];
|
|
697
|
+
readonly environments?: readonly string[];
|
|
698
|
+
readonly teams?: readonly string[];
|
|
699
|
+
}
|
|
700
|
+
/** Policy enforcement */
|
|
701
|
+
export interface PolicyEnforcement {
|
|
702
|
+
readonly mode: 'audit' | 'enforce';
|
|
703
|
+
readonly gracePeriod?: number;
|
|
704
|
+
readonly exceptions: readonly PolicyException[];
|
|
705
|
+
}
|
|
706
|
+
/** Policy exception */
|
|
707
|
+
export interface PolicyException {
|
|
708
|
+
readonly id: string;
|
|
709
|
+
readonly reason: string;
|
|
710
|
+
readonly approvedBy: string;
|
|
711
|
+
readonly expiresAt?: Date;
|
|
712
|
+
readonly scope: PolicyScope;
|
|
713
|
+
}
|
|
714
|
+
//# sourceMappingURL=security-scanning.d.ts.map
|