@oneuptime/common 16.0.0 → 17.0.0

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.
Files changed (572) hide show
  1. package/Models/AnalyticsModels/RumProductAnalyticsEvent.js +15 -6
  2. package/Models/AnalyticsModels/RumProductAnalyticsSession.js +27 -10
  3. package/Models/AnalyticsModels/RumProductAnalyticsUser.js +16 -4
  4. package/Models/AnalyticsModels/RumSession.js +12 -0
  5. package/Models/DatabaseModels/AlertSeverity.js +12 -3
  6. package/Models/DatabaseModels/DataAsset.d.mts +1 -0
  7. package/Models/DatabaseModels/DataAsset.d.ts +1 -0
  8. package/Models/DatabaseModels/DataAsset.js +23 -0
  9. package/Models/DatabaseModels/DataBiConnection.d.mts +2 -1
  10. package/Models/DatabaseModels/DataBiConnection.d.ts +2 -1
  11. package/Models/DatabaseModels/DataBiConnection.js +15 -0
  12. package/Models/DatabaseModels/DataCheck.d.mts +3 -0
  13. package/Models/DatabaseModels/DataCheck.d.ts +3 -0
  14. package/Models/DatabaseModels/DataCheck.js +49 -0
  15. package/Models/DatabaseModels/DataDashboard.d.mts +1 -0
  16. package/Models/DatabaseModels/DataDashboard.d.ts +1 -0
  17. package/Models/DatabaseModels/DataDashboard.js +15 -0
  18. package/Models/DatabaseModels/DataPipeline.d.mts +1 -0
  19. package/Models/DatabaseModels/DataPipeline.d.ts +1 -0
  20. package/Models/DatabaseModels/DataPipeline.js +25 -0
  21. package/Models/DatabaseModels/DataPipelineOwnerTeam.d.mts +19 -0
  22. package/Models/DatabaseModels/DataPipelineOwnerTeam.d.ts +19 -0
  23. package/Models/DatabaseModels/DataPipelineOwnerTeam.js +477 -0
  24. package/Models/DatabaseModels/DataPipelineOwnerTeam.mjs +2 -0
  25. package/Models/DatabaseModels/DataPipelineOwnerUser.d.mts +18 -0
  26. package/Models/DatabaseModels/DataPipelineOwnerUser.d.ts +18 -0
  27. package/Models/DatabaseModels/DataPipelineOwnerUser.js +476 -0
  28. package/Models/DatabaseModels/DataPipelineOwnerUser.mjs +2 -0
  29. package/Models/DatabaseModels/DataStore.d.mts +1 -0
  30. package/Models/DatabaseModels/DataStore.d.ts +1 -0
  31. package/Models/DatabaseModels/DataStore.js +23 -0
  32. package/Models/DatabaseModels/DataStoreFinding.d.mts +2 -0
  33. package/Models/DatabaseModels/DataStoreFinding.d.ts +2 -0
  34. package/Models/DatabaseModels/DataStoreFinding.js +21 -0
  35. package/Models/DatabaseModels/EmailLog.d.mts +1 -0
  36. package/Models/DatabaseModels/EmailLog.d.ts +1 -0
  37. package/Models/DatabaseModels/EmailLog.js +35 -0
  38. package/Models/DatabaseModels/GlobalConfig.d.mts +5 -0
  39. package/Models/DatabaseModels/GlobalConfig.d.ts +5 -0
  40. package/Models/DatabaseModels/GlobalConfig.js +128 -0
  41. package/Models/DatabaseModels/GlobalOidc.d.mts +1 -0
  42. package/Models/DatabaseModels/GlobalOidc.d.ts +1 -0
  43. package/Models/DatabaseModels/GlobalOidc.js +29 -0
  44. package/Models/DatabaseModels/IncidentSeverity.js +12 -3
  45. package/Models/DatabaseModels/Index.js +6 -0
  46. package/Models/DatabaseModels/Monitor.js +18 -0
  47. package/Models/DatabaseModels/NetworkDevice.d.mts +1 -0
  48. package/Models/DatabaseModels/NetworkDevice.d.ts +1 -0
  49. package/Models/DatabaseModels/NetworkDevice.js +49 -0
  50. package/Models/DatabaseModels/NetworkDeviceAutoImportRule.js +2 -2
  51. package/Models/DatabaseModels/OnCallDutyPolicyEscalationRule.js +1 -1
  52. package/Models/DatabaseModels/OnCallDutyPolicyExecutionLog.d.mts +6 -0
  53. package/Models/DatabaseModels/OnCallDutyPolicyExecutionLog.d.ts +6 -0
  54. package/Models/DatabaseModels/OnCallDutyPolicyExecutionLog.js +156 -1
  55. package/Models/DatabaseModels/OnCallDutyPolicyScheduleLayer.js +1 -1
  56. package/Models/DatabaseModels/OnCallDutyPolicyScheduleLayerUser.js +1 -1
  57. package/Models/DatabaseModels/Probe.d.mts +4 -0
  58. package/Models/DatabaseModels/Probe.d.ts +4 -0
  59. package/Models/DatabaseModels/Probe.js +100 -0
  60. package/Models/DatabaseModels/ProductFeedback.d.mts +2 -1
  61. package/Models/DatabaseModels/ProductFeedback.d.ts +2 -1
  62. package/Models/DatabaseModels/ProductFeedback.js +34 -2
  63. package/Models/DatabaseModels/Project.d.mts +4 -1
  64. package/Models/DatabaseModels/Project.d.ts +4 -1
  65. package/Models/DatabaseModels/Project.js +147 -7
  66. package/Models/DatabaseModels/ProjectCallSMSConfig.js +8 -2
  67. package/Models/DatabaseModels/ProjectOidc.d.mts +1 -0
  68. package/Models/DatabaseModels/ProjectOidc.d.ts +1 -0
  69. package/Models/DatabaseModels/ProjectOidc.js +46 -0
  70. package/Models/DatabaseModels/Reseller.js +8 -2
  71. package/Models/DatabaseModels/ResellerPlan.js +12 -3
  72. package/Models/DatabaseModels/RumApplication.d.mts +1 -0
  73. package/Models/DatabaseModels/RumApplication.d.ts +1 -0
  74. package/Models/DatabaseModels/RumApplication.js +58 -0
  75. package/Models/DatabaseModels/RumSessionErasureRequest.d.mts +1 -0
  76. package/Models/DatabaseModels/RumSessionErasureRequest.d.ts +1 -0
  77. package/Models/DatabaseModels/RumSessionErasureRequest.js +40 -0
  78. package/Models/DatabaseModels/SecurityCaseTask.d.mts +1 -0
  79. package/Models/DatabaseModels/SecurityCaseTask.d.ts +1 -0
  80. package/Models/DatabaseModels/SecurityCaseTask.js +27 -0
  81. package/Models/DatabaseModels/ServerEmailLog.d.mts +12 -0
  82. package/Models/DatabaseModels/ServerEmailLog.d.ts +12 -0
  83. package/Models/DatabaseModels/ServerEmailLog.js +206 -0
  84. package/Models/DatabaseModels/ServerEmailLog.mjs +2 -0
  85. package/Models/DatabaseModels/StatusPageGroup.js +1 -1
  86. package/Models/DatabaseModels/StatusPageResource.js +1 -1
  87. package/Models/DatabaseModels/TelemetryException.js +15 -2
  88. package/Models/DatabaseModels/TelemetryIngestionKey.js +10 -0
  89. package/Models/DatabaseModels/User.d.mts +3 -0
  90. package/Models/DatabaseModels/User.d.ts +3 -0
  91. package/Models/DatabaseModels/User.js +66 -0
  92. package/Models/DatabaseModels/UserSession.d.mts +1 -0
  93. package/Models/DatabaseModels/UserSession.d.ts +1 -0
  94. package/Models/DatabaseModels/UserSession.js +32 -0
  95. package/Models/DatabaseModels/WorkspaceLiveMessage.js +21 -15
  96. package/Models/DatabaseModels/WorkspaceNotificationLog.js +17 -9
  97. package/Models/DatabaseModels/WorkspaceNotificationRule.js +8 -2
  98. package/Models/DatabaseModels/WorkspaceNotificationSummary.js +1 -1
  99. package/Server/Services/DatabaseService.d.mts +6 -0
  100. package/Server/Services/DatabaseService.d.ts +6 -0
  101. package/Server/Utils/Workspace/WorkspaceBase.d.mts +1 -0
  102. package/Server/Utils/Workspace/WorkspaceBase.d.ts +1 -0
  103. package/Types/AI/AIActionWords.js +1 -0
  104. package/Types/AI/AIChatPageContext.d.mts +1 -0
  105. package/Types/AI/AIChatPageContext.d.ts +1 -0
  106. package/Types/AI/AIChatPageContext.js +6 -0
  107. package/Types/AI/AIRunProducts.d.mts +14 -0
  108. package/Types/AI/AIRunProducts.d.ts +14 -0
  109. package/Types/AI/AIRunProducts.js +40 -0
  110. package/Types/AI/AIRunProducts.mjs +2 -0
  111. package/Types/AI/AskAiRatings.d.mts +31 -0
  112. package/Types/AI/AskAiRatings.d.ts +31 -0
  113. package/Types/AI/AskAiRatings.js +173 -0
  114. package/Types/AI/AskAiRatings.mjs +13 -0
  115. package/Types/Accounts/SignUpInvitation.d.mts +12 -0
  116. package/Types/Accounts/SignUpInvitation.d.ts +12 -0
  117. package/Types/Accounts/SignUpInvitation.js +84 -0
  118. package/Types/Accounts/SignUpInvitation.mjs +5 -0
  119. package/Types/Analytics/ActivationMilestone.d.mts +2 -1
  120. package/Types/Analytics/ActivationMilestone.d.ts +2 -1
  121. package/Types/Analytics/ActivationMilestone.js +11 -0
  122. package/Types/Analytics/ProductEvent.d.mts +11 -0
  123. package/Types/Analytics/ProductEvent.d.ts +11 -0
  124. package/Types/Analytics/ProductEvent.js +166 -13
  125. package/Types/Analytics/ProductEvent.mjs +3 -0
  126. package/Types/Backup/BackupScriptRun.d.mts +17 -0
  127. package/Types/Backup/BackupScriptRun.d.ts +17 -0
  128. package/Types/Backup/BackupScriptRun.js +96 -0
  129. package/Types/Backup/BackupScriptRun.mjs +6 -0
  130. package/Types/BaseDatabase/DatabaseCommonInteractionProps.d.mts +2 -0
  131. package/Types/BaseDatabase/DatabaseCommonInteractionProps.d.ts +2 -0
  132. package/Types/BaseDatabase/ReadAudience.d.mts +9 -0
  133. package/Types/BaseDatabase/ReadAudience.d.ts +9 -0
  134. package/Types/BaseDatabase/ReadAudience.js +2 -0
  135. package/Types/BaseDatabase/ReadAudience.mjs +1 -0
  136. package/Types/Cloud/CloudKeyMetricGroup.d.mts +17 -0
  137. package/Types/Cloud/CloudKeyMetricGroup.d.ts +17 -0
  138. package/Types/Cloud/CloudKeyMetricGroup.js +84 -0
  139. package/Types/Cloud/CloudKeyMetricGroup.mjs +5 -0
  140. package/Types/Cloud/CloudKeyMetrics.d.mts +28 -1
  141. package/Types/Cloud/CloudKeyMetrics.d.ts +28 -1
  142. package/Types/Cloud/CloudKeyMetrics.js +1209 -206
  143. package/Types/Cloud/CloudKeyMetrics.mjs +6 -0
  144. package/Types/Cloud/CloudResourceCatalog.js +43 -12
  145. package/Types/CloudConnection/CloudConnectionSetupCommands.d.mts +1 -0
  146. package/Types/CloudConnection/CloudConnectionSetupCommands.d.ts +1 -0
  147. package/Types/CloudConnection/CloudConnectionSetupCommands.js +49 -6
  148. package/Types/CloudConnection/CloudConnectionSetupCommands.mjs +1 -0
  149. package/Types/CloudConnection/CloudStreamTemplate.js +6 -2
  150. package/Types/CreateFormAddress.d.mts +3 -0
  151. package/Types/CreateFormAddress.d.ts +3 -0
  152. package/Types/CreateFormAddress.js +17 -0
  153. package/Types/CreateFormAddress.mjs +4 -0
  154. package/Types/DataObservability/DataAssetFreshness.d.mts +5 -0
  155. package/Types/DataObservability/DataAssetFreshness.d.ts +5 -0
  156. package/Types/DataObservability/DataAssetFreshness.js +28 -5
  157. package/Types/DataObservability/DataAssetFreshness.mjs +1 -0
  158. package/Types/DataObservability/DataBiLineage.d.mts +69 -0
  159. package/Types/DataObservability/DataBiLineage.d.ts +69 -0
  160. package/Types/DataObservability/DataBiLineage.js +198 -0
  161. package/Types/DataObservability/DataBiLineage.mjs +13 -0
  162. package/Types/DataObservability/DataLineageColumnTrail.d.mts +2 -1
  163. package/Types/DataObservability/DataLineageColumnTrail.d.ts +2 -1
  164. package/Types/DataObservability/DataLineageColumnTrail.js +41 -3
  165. package/Types/DataObservability/DataLineageColumnTrail.mjs +1 -0
  166. package/Types/DataObservability/DataLineageMap.d.mts +67 -1
  167. package/Types/DataObservability/DataLineageMap.d.ts +67 -1
  168. package/Types/DataObservability/DataLineageMap.js +335 -3
  169. package/Types/DataObservability/DataLineageMap.mjs +14 -0
  170. package/Types/DataObservability/DataObservabilityApiTypes.d.mts +42 -2
  171. package/Types/DataObservability/DataObservabilityApiTypes.d.ts +42 -2
  172. package/Types/DataObservability/DataObservabilityApiTypes.js +21 -1
  173. package/Types/DataObservability/DataObservabilityApiTypes.mjs +4 -0
  174. package/Types/DataObservability/DataObservabilityAttention.d.mts +5 -0
  175. package/Types/DataObservability/DataObservabilityAttention.d.ts +5 -0
  176. package/Types/DataObservability/DataObservabilityAttention.js +48 -1
  177. package/Types/DataObservability/DataObservabilityAttention.mjs +5 -0
  178. package/Types/DataObservability/DataPipelineSchedule.d.mts +4 -0
  179. package/Types/DataObservability/DataPipelineSchedule.d.ts +4 -0
  180. package/Types/DataObservability/DataPipelineSchedule.js +26 -6
  181. package/Types/DataObservability/DataPipelineSchedule.mjs +1 -0
  182. package/Types/DataObservability/DataTableLineage.d.mts +6 -0
  183. package/Types/DataObservability/DataTableLineage.d.ts +6 -0
  184. package/Types/DataSecurity/DataSecurityApiTypes.d.mts +24 -0
  185. package/Types/DataSecurity/DataSecurityApiTypes.d.ts +24 -0
  186. package/Types/DataSecurity/DataSecurityApiTypes.js +21 -1
  187. package/Types/DataSecurity/DataSecurityApiTypes.mjs +2 -0
  188. package/Types/DataSecurity/FindingSampleRecord.d.mts +16 -0
  189. package/Types/DataSecurity/FindingSampleRecord.d.ts +16 -0
  190. package/Types/DataSecurity/FindingSampleRecord.js +112 -0
  191. package/Types/DataSecurity/FindingSampleRecord.mjs +6 -0
  192. package/Types/Database/AccessControl/PermissionScopeNarrowing.js +6 -0
  193. package/Types/Database/MoveInList.d.mts +41 -0
  194. package/Types/Database/MoveInList.d.ts +41 -0
  195. package/Types/Database/MoveInList.js +177 -0
  196. package/Types/Database/MoveInList.mjs +4 -0
  197. package/Types/Email/ServerEmailLog.d.mts +41 -0
  198. package/Types/Email/ServerEmailLog.d.ts +41 -0
  199. package/Types/Email/ServerEmailLog.js +136 -0
  200. package/Types/Email/ServerEmailLog.mjs +11 -0
  201. package/Types/Exception/ProductSwitchedOffException.d.mts +12 -0
  202. package/Types/Exception/ProductSwitchedOffException.d.ts +12 -0
  203. package/Types/Exception/ProductSwitchedOffException.js +38 -0
  204. package/Types/Exception/ProductSwitchedOffException.mjs +2 -0
  205. package/Types/Exception/UnexplainedError.d.mts +7 -0
  206. package/Types/Exception/UnexplainedError.d.ts +7 -0
  207. package/Types/Exception/UnexplainedError.js +36 -1
  208. package/Types/Exception/UnexplainedError.mjs +2 -0
  209. package/Types/InstallationHealth/InstallationHealth.d.mts +39 -0
  210. package/Types/InstallationHealth/InstallationHealth.d.ts +39 -0
  211. package/Types/InstallationHealth/InstallationHealth.js +163 -0
  212. package/Types/Kubernetes/KubernetesHealth.d.mts +16 -0
  213. package/Types/Kubernetes/KubernetesHealth.d.ts +16 -0
  214. package/Types/Kubernetes/KubernetesHealth.js +128 -6
  215. package/Types/Kubernetes/KubernetesHealth.mjs +2 -0
  216. package/Types/Monitor/CloudAppAlertTemplates.d.mts +3 -13
  217. package/Types/Monitor/CloudAppAlertTemplates.d.ts +3 -13
  218. package/Types/Monitor/CloudAppAlertTemplates.js +13 -199
  219. package/Types/Monitor/CriteriaFilter.d.mts +2 -1
  220. package/Types/Monitor/CriteriaFilter.d.ts +2 -1
  221. package/Types/Monitor/CriteriaFilter.js +9 -1
  222. package/Types/Monitor/CriteriaFilterTerms.js +1 -0
  223. package/Types/Monitor/MessageQueueAlertTemplates.d.mts +6 -0
  224. package/Types/Monitor/MessageQueueAlertTemplates.d.ts +6 -0
  225. package/Types/Monitor/MessageQueueAlertTemplates.js +32 -0
  226. package/Types/Monitor/MessageQueueAlertTemplates.mjs +2 -0
  227. package/Types/Monitor/MonitorCriteriaInstance.d.mts +2 -0
  228. package/Types/Monitor/MonitorCriteriaInstance.d.ts +2 -0
  229. package/Types/Monitor/MonitorCriteriaInstance.js +52 -0
  230. package/Types/Monitor/MonitorMetricType.d.mts +2 -1
  231. package/Types/Monitor/MonitorMetricType.d.ts +2 -1
  232. package/Types/Monitor/MonitorMetricType.js +1 -0
  233. package/Types/Monitor/MonitorStepLimit.d.mts +8 -0
  234. package/Types/Monitor/MonitorStepLimit.d.ts +8 -0
  235. package/Types/Monitor/MonitorStepLimit.js +62 -0
  236. package/Types/Monitor/MonitorStepLimit.mjs +3 -0
  237. package/Types/Monitor/MonitorSteps.js +5 -0
  238. package/Types/Monitor/MonitorType.js +2 -1
  239. package/Types/Monitor/ProbeStatusMonitor/ProbeStatusMonitorResponse.d.mts +5 -0
  240. package/Types/Monitor/ProbeStatusMonitor/ProbeStatusMonitorResponse.d.ts +5 -0
  241. package/Types/Monitor/Recommendation/MonitorRecommendationCatalog.d.mts +1 -1
  242. package/Types/Monitor/Recommendation/MonitorRecommendationCatalog.d.ts +1 -1
  243. package/Types/Monitor/Recommendation/MonitorRecommendationCatalog.js +111 -1
  244. package/Types/Monitor/Recommendation/MonitorRecommendationTypes.d.mts +7 -1
  245. package/Types/Monitor/Recommendation/MonitorRecommendationTypes.d.ts +7 -1
  246. package/Types/Monitor/Recommendation/MonitorRecommendationTypes.js +15 -0
  247. package/Types/Monitor/RequestHealthAlertTemplates.d.mts +66 -0
  248. package/Types/Monitor/RequestHealthAlertTemplates.d.ts +66 -0
  249. package/Types/Monitor/RequestHealthAlertTemplates.js +227 -0
  250. package/Types/Monitor/RequestHealthAlertTemplates.mjs +4 -0
  251. package/Types/Monitor/ServerlessAlertTemplates.d.mts +23 -0
  252. package/Types/Monitor/ServerlessAlertTemplates.d.ts +23 -0
  253. package/Types/Monitor/ServerlessAlertTemplates.js +111 -0
  254. package/Types/Monitor/ServerlessAlertTemplates.mjs +7 -0
  255. package/Types/Monitor/ServiceAlertTemplates.d.mts +3 -0
  256. package/Types/Monitor/ServiceAlertTemplates.d.ts +3 -0
  257. package/Types/Monitor/ServiceAlertTemplates.js +61 -0
  258. package/Types/Monitor/ServiceAlertTemplates.mjs +2 -0
  259. package/Types/Monitor/TelemetryRulePreview.js +18 -6
  260. package/Types/Monitor/WhoIsTold.d.mts +71 -0
  261. package/Types/Monitor/WhoIsTold.d.ts +71 -0
  262. package/Types/Monitor/WhoIsTold.js +348 -121
  263. package/Types/Monitor/WhoIsTold.mjs +7 -0
  264. package/Types/NetworkAutomation/RuleRunResult.js +9 -5
  265. package/Types/NetworkDevice/DiscoveredDevice.d.mts +40 -0
  266. package/Types/NetworkDevice/DiscoveredDevice.d.ts +40 -0
  267. package/Types/NetworkDevice/DiscoveredDevice.js +205 -1
  268. package/Types/NetworkDevice/DiscoveredDevice.mjs +9 -0
  269. package/Types/NetworkDevice/DiscoveryImport.js +8 -3
  270. package/Types/NetworkDevice/NetworkDeviceDiscoveredDetails.d.mts +26 -3
  271. package/Types/NetworkDevice/NetworkDeviceDiscoveredDetails.d.ts +26 -3
  272. package/Types/NetworkDevice/NetworkDeviceDiscoveredDetails.js +75 -3
  273. package/Types/NetworkDevice/NetworkDeviceDiscoveredDetails.mjs +2 -0
  274. package/Types/Notification/WhoWasTold.d.mts +190 -0
  275. package/Types/Notification/WhoWasTold.d.ts +190 -0
  276. package/Types/Notification/WhoWasTold.js +662 -0
  277. package/Types/Notification/WhoWasTold.mjs +16 -0
  278. package/Types/NotificationRule/PagingLadderDefault.d.mts +75 -0
  279. package/Types/NotificationRule/PagingLadderDefault.d.ts +75 -0
  280. package/Types/NotificationRule/PagingLadderDefault.js +529 -0
  281. package/Types/NotificationRule/PagingLadderDefault.mjs +24 -0
  282. package/Types/OnCallDutyPolicy/EveryNewEventRules.d.mts +7 -0
  283. package/Types/OnCallDutyPolicy/EveryNewEventRules.d.ts +7 -0
  284. package/Types/OnCallDutyPolicy/EveryNewEventRules.js +53 -2
  285. package/Types/OnCallDutyPolicy/EveryNewEventRules.mjs +3 -0
  286. package/Types/OnCallDutyPolicy/NotificationSetupToFinish.d.mts +6 -0
  287. package/Types/OnCallDutyPolicy/NotificationSetupToFinish.d.ts +6 -0
  288. package/Types/OnCallDutyPolicy/NotificationSetupToFinish.js +27 -0
  289. package/Types/OnCallDutyPolicy/NotificationSetupToFinish.mjs +3 -0
  290. package/Types/OnCallDutyPolicy/OnCallFireDrill.d.mts +83 -0
  291. package/Types/OnCallDutyPolicy/OnCallFireDrill.d.ts +83 -0
  292. package/Types/OnCallDutyPolicy/OnCallFireDrill.js +105 -0
  293. package/Types/OnCallDutyPolicy/OnCallFireDrill.mjs +9 -0
  294. package/Types/OnCallDutyPolicy/OnCallPagePassOn.js +12 -4
  295. package/Types/OnCallDutyPolicy/OnCallRunLevel.d.mts +12 -0
  296. package/Types/OnCallDutyPolicy/OnCallRunLevel.d.ts +12 -0
  297. package/Types/OnCallDutyPolicy/OnCallRunLevel.js +69 -8
  298. package/Types/OnCallDutyPolicy/OnCallRunLevel.mjs +3 -0
  299. package/Types/OnCallDutyPolicy/OnCallTestPage.d.mts +4 -0
  300. package/Types/OnCallDutyPolicy/OnCallTestPage.d.ts +4 -0
  301. package/Types/OnCallDutyPolicy/OnCallTestPage.js +20 -7
  302. package/Types/OnCallDutyPolicy/OnCallTestPage.mjs +2 -0
  303. package/Types/OnCallDutyPolicy/ScheduleLayersSave.d.mts +2 -0
  304. package/Types/OnCallDutyPolicy/ScheduleLayersSave.d.ts +2 -0
  305. package/Types/OnCallDutyPolicy/ScheduleLayersSave.js +14 -1
  306. package/Types/OnCallDutyPolicy/ScheduleLayersSave.mjs +2 -0
  307. package/Types/OnCallDutyPolicy/UserOverrideEdit.d.mts +7 -0
  308. package/Types/OnCallDutyPolicy/UserOverrideEdit.d.ts +7 -0
  309. package/Types/OnCallDutyPolicy/UserOverrideEdit.js +63 -1
  310. package/Types/OnCallDutyPolicy/UserOverrideEdit.mjs +4 -0
  311. package/Types/OnCallDutyPolicy/UserOverrideOverlap.d.mts +21 -1
  312. package/Types/OnCallDutyPolicy/UserOverrideOverlap.d.ts +21 -1
  313. package/Types/OnCallDutyPolicy/UserOverrideOverlap.js +46 -2
  314. package/Types/Permission.d.mts +8 -0
  315. package/Types/Permission.d.ts +8 -0
  316. package/Types/Permission.js +84 -0
  317. package/Types/Probe/ProbeBehind.d.mts +48 -0
  318. package/Types/Probe/ProbeBehind.d.ts +48 -0
  319. package/Types/Probe/ProbeBehind.js +196 -0
  320. package/Types/Probe/ProbeBehind.mjs +6 -0
  321. package/Types/Product/ProductRecordTables.d.mts +8 -0
  322. package/Types/Product/ProductRecordTables.d.ts +8 -0
  323. package/Types/Product/ProductRecordTables.js +847 -0
  324. package/Types/Product/ProductRecordTables.mjs +5 -0
  325. package/Types/Product/ProductUsage.d.mts +2 -0
  326. package/Types/Product/ProductUsage.d.ts +2 -0
  327. package/Types/Product/ProductUsage.js +41 -6
  328. package/Types/Product/ProductUsage.mjs +2 -0
  329. package/Types/Product/ServerProductOffReason.d.mts +4 -0
  330. package/Types/Product/ServerProductOffReason.d.ts +4 -0
  331. package/Types/Product/ServerProductOffReason.js +19 -0
  332. package/Types/Product/ServerProductOffReason.mjs +2 -0
  333. package/Types/Product/ServerProducts.d.mts +2 -4
  334. package/Types/Product/ServerProducts.d.ts +2 -4
  335. package/Types/Product/ServerProducts.js +19 -17
  336. package/Types/ProductFeedback/ProductFeedback.d.mts +45 -1
  337. package/Types/ProductFeedback/ProductFeedback.d.ts +45 -1
  338. package/Types/ProductFeedback/ProductFeedback.js +185 -5
  339. package/Types/ProductFeedback/ProductFeedback.mjs +11 -0
  340. package/Types/PushNotification/PushNotificationCategory.d.mts +1 -0
  341. package/Types/PushNotification/PushNotificationCategory.d.ts +1 -0
  342. package/Types/PushNotification/PushNotificationCategory.js +17 -6
  343. package/Types/PushNotification/PushNotificationCategory.mjs +1 -0
  344. package/Types/Rules/RuleCriteriaFieldRegistry.d.mts +18 -0
  345. package/Types/Rules/RuleCriteriaFieldRegistry.d.ts +18 -0
  346. package/Types/Rules/RuleCriteriaFieldRegistry.js +34 -1
  347. package/Types/Rules/RuleCriteriaFieldRegistry.mjs +4 -0
  348. package/Types/Rum/ProductAnalytics.d.mts +9 -0
  349. package/Types/Rum/ProductAnalytics.d.ts +9 -0
  350. package/Types/Rum/ProductAnalytics.js +56 -8
  351. package/Types/Rum/ProductAnalytics.mjs +6 -0
  352. package/Types/Rum/ProductAnalyticsEvents.js +2 -1
  353. package/Types/Rum/SessionReplay.d.mts +3 -0
  354. package/Types/Rum/SessionReplay.d.ts +3 -0
  355. package/Types/Rum/SessionReplay.js +35 -1
  356. package/Types/Rum/SessionReplay.mjs +2 -0
  357. package/Types/Runbook/RunbookTriggerType.d.mts +1 -0
  358. package/Types/Runbook/RunbookTriggerType.d.ts +1 -0
  359. package/Types/Runbook/RunbookTriggerType.js +19 -1
  360. package/Types/Runbook/RunbookTriggerType.mjs +1 -0
  361. package/Types/SSO/IdentityProviderSignOut.d.mts +24 -0
  362. package/Types/SSO/IdentityProviderSignOut.d.ts +24 -0
  363. package/Types/SSO/IdentityProviderSignOut.js +124 -0
  364. package/Types/SSO/IdentityProviderSignOut.mjs +10 -0
  365. package/Types/SecurityCase/SecurityCaseEventEvidence.d.mts +4 -0
  366. package/Types/SecurityCase/SecurityCaseEventEvidence.d.ts +4 -0
  367. package/Types/SecurityCase/SecurityCaseEventEvidence.js +12 -0
  368. package/Types/SecurityCase/SecurityCaseMatches.d.mts +78 -0
  369. package/Types/SecurityCase/SecurityCaseMatches.d.ts +78 -0
  370. package/Types/SecurityCase/SecurityCaseMatches.js +252 -0
  371. package/Types/SecurityCase/SecurityCaseMatches.mjs +17 -0
  372. package/Types/ServerSending/ProjectCanSend.d.mts +10 -0
  373. package/Types/ServerSending/ProjectCanSend.d.ts +10 -0
  374. package/Types/ServerSending/ProjectCanSend.js +49 -0
  375. package/Types/ServerSending/ProjectCanSend.mjs +4 -0
  376. package/Types/ServerSending/ServerAlerts.d.mts +78 -0
  377. package/Types/ServerSending/ServerAlerts.d.ts +78 -0
  378. package/Types/ServerSending/ServerAlerts.js +393 -0
  379. package/Types/ServerSending/ServerAlerts.mjs +8 -0
  380. package/Types/ServerSending/ServerSendingStatus.d.mts +6 -0
  381. package/Types/ServerSending/ServerSendingStatus.d.ts +6 -0
  382. package/Types/ServerSending/ServerSendingStatus.js +23 -0
  383. package/Types/ServerSending/ServerSetUpProblem.d.mts +46 -0
  384. package/Types/ServerSending/ServerSetUpProblem.d.ts +46 -0
  385. package/Types/ServerSending/ServerSetUpProblem.js +164 -0
  386. package/Types/ServerSending/ServerSetUpProblem.mjs +6 -0
  387. package/Types/ServerSetup/ServerSetupChecklist.d.mts +35 -1
  388. package/Types/ServerSetup/ServerSetupChecklist.d.ts +35 -1
  389. package/Types/ServerSetup/ServerSetupChecklist.js +270 -33
  390. package/Types/ServerSetup/ServerSetupChecklist.mjs +5 -0
  391. package/Types/ServerSetup/ServerTestSend.d.mts +11 -0
  392. package/Types/ServerSetup/ServerTestSend.d.ts +11 -0
  393. package/Types/ServerSetup/ServerTestSend.js +60 -3
  394. package/Types/ServerSetup/ServerTestSend.mjs +2 -0
  395. package/Types/ServiceLevelObjective/SloStatus.d.mts +3 -0
  396. package/Types/ServiceLevelObjective/SloStatus.d.ts +3 -0
  397. package/Types/ServiceLevelObjective/SloStatus.js +38 -0
  398. package/Types/ServiceLevelObjective/SloStatus.mjs +2 -0
  399. package/Types/ServiceLevelObjective/SloStatusChange.d.mts +10 -0
  400. package/Types/ServiceLevelObjective/SloStatusChange.d.ts +10 -0
  401. package/Types/ServiceLevelObjective/SloStatusChange.js +71 -0
  402. package/Types/ServiceLevelObjective/SloStatusChange.mjs +5 -0
  403. package/Types/SetupHealth/SetupHealth.d.mts +31 -3
  404. package/Types/SetupHealth/SetupHealth.d.ts +31 -3
  405. package/Types/SetupHealth/SetupHealth.js +333 -4
  406. package/Types/SetupHealth/SetupHealth.mjs +5 -0
  407. package/Types/StatusPage/NewIncidentSubscriberNotificationDefault.js +8 -5
  408. package/Types/StatusPage/StatusPagePublicName.d.mts +6 -0
  409. package/Types/StatusPage/StatusPagePublicName.d.ts +6 -0
  410. package/Types/StatusPage/StatusPagePublicName.js +32 -0
  411. package/Types/StatusPage/StatusPagePublicName.mjs +3 -0
  412. package/Types/Team/InvitationEmailsNotSent.d.mts +28 -0
  413. package/Types/Team/InvitationEmailsNotSent.d.ts +28 -0
  414. package/Types/Team/InvitationEmailsNotSent.js +261 -0
  415. package/Types/Team/InvitationEmailsNotSent.mjs +13 -0
  416. package/Types/Team/ProjectMemberSearch.d.mts +15 -0
  417. package/Types/Team/ProjectMemberSearch.d.ts +15 -0
  418. package/Types/Team/ProjectMemberSearch.js +180 -0
  419. package/Types/Team/ProjectMemberSearch.mjs +10 -0
  420. package/Types/Team/ProjectRemovalReach.d.mts +15 -0
  421. package/Types/Team/ProjectRemovalReach.d.ts +15 -0
  422. package/Types/Team/ProjectRemovalReach.js +154 -0
  423. package/Types/Team/ProjectRemovalReach.mjs +8 -0
  424. package/Types/Team/ResendInvitation.d.mts +27 -0
  425. package/Types/Team/ResendInvitation.d.ts +27 -0
  426. package/Types/Team/ResendInvitation.js +123 -0
  427. package/Types/Team/ResendInvitation.mjs +12 -0
  428. package/Types/UsedBy/UsedBy.d.mts +1 -0
  429. package/Types/UsedBy/UsedBy.d.ts +1 -0
  430. package/Types/UsedBy/UsedBy.js +2 -0
  431. package/Types/UsedBy/UsedByServerProducts.js +1 -0
  432. package/Types/WelcomeChecklist/WelcomeChecklist.d.mts +27 -4
  433. package/Types/WelcomeChecklist/WelcomeChecklist.d.ts +27 -4
  434. package/Types/WelcomeChecklist/WelcomeChecklist.js +166 -42
  435. package/Types/WelcomeChecklist/WelcomeChecklist.mjs +8 -0
  436. package/Types/WelcomeChecklist/WelcomeChecklistAnswer.d.mts +4 -1
  437. package/Types/WelcomeChecklist/WelcomeChecklistAnswer.d.ts +4 -1
  438. package/Types/WelcomeChecklist/WelcomeChecklistAnswer.js +175 -33
  439. package/Types/WelcomeChecklist/WelcomeChecklistAnswer.mjs +1 -0
  440. package/Types/WelcomeChecklist/WelcomeChecklistState.d.mts +1 -0
  441. package/Types/WelcomeChecklist/WelcomeChecklistState.d.ts +1 -0
  442. package/Types/WelcomeChecklist/WelcomeChecklistState.js +30 -1
  443. package/Types/WelcomeChecklist/WelcomeChecklistState.mjs +1 -0
  444. package/Types/Workflow/Component.d.mts +0 -1
  445. package/Types/Workflow/Component.d.ts +0 -1
  446. package/Types/Workspace/NotificationRules/BaseNotificationRule.d.mts +1 -1
  447. package/Types/Workspace/NotificationRules/BaseNotificationRule.d.ts +1 -1
  448. package/Types/Workspace/NotificationRules/NotificationRuleCondition.d.mts +23 -0
  449. package/Types/Workspace/NotificationRules/NotificationRuleCondition.d.ts +23 -0
  450. package/Types/Workspace/NotificationRules/NotificationRuleUpdates.d.mts +12 -0
  451. package/Types/Workspace/NotificationRules/NotificationRuleUpdates.d.ts +12 -0
  452. package/Types/Workspace/NotificationRules/NotificationRuleUpdates.js +106 -4
  453. package/Types/Workspace/WorkspaceMessagePayload.d.mts +2 -0
  454. package/Types/Workspace/WorkspaceMessagePayload.d.ts +2 -0
  455. package/Types/Workspace/WorkspaceMessagePayload.js +6 -1
  456. package/Types/Workspace/WorkspaceMessagePayload.mjs +1 -0
  457. package/UI/Components/Dropdown/Dropdown.d.mts +2 -0
  458. package/UI/Components/Dropdown/Dropdown.d.ts +2 -0
  459. package/Utils/Dashboard/Components/DashboardProductAnalyticsFunnelComponent.js +6 -1
  460. package/Utils/Dashboard/Components/DashboardProductAnalyticsRetentionComponent.js +6 -1
  461. package/Utils/Dashboard/MonitorListWidgetFormat.d.mts +4 -1
  462. package/Utils/Dashboard/MonitorListWidgetFormat.d.ts +4 -1
  463. package/Utils/Dashboard/MonitorListWidgetFormat.js +9 -4
  464. package/Utils/DataSecurity/CustomDataTypeDetector.js +3 -1
  465. package/Utils/DataSecurity/DetectorPrefilter.d.mts +9 -0
  466. package/Utils/DataSecurity/DetectorPrefilter.d.ts +9 -0
  467. package/Utils/DataSecurity/DetectorPrefilter.js +471 -0
  468. package/Utils/DataSecurity/DetectorPrefilter.mjs +6 -0
  469. package/Utils/DataSecurity/FieldClassifier.d.mts +2 -0
  470. package/Utils/DataSecurity/FieldClassifier.d.ts +2 -0
  471. package/Utils/DataSecurity/FieldClassifier.js +38 -8
  472. package/Utils/DataSecurity/OccurrenceExcerpt.d.mts +22 -0
  473. package/Utils/DataSecurity/OccurrenceExcerpt.d.ts +22 -0
  474. package/Utils/DataSecurity/OccurrenceExcerpt.js +270 -0
  475. package/Utils/DataSecurity/OccurrenceExcerpt.mjs +5 -0
  476. package/Utils/DataSecurity/TextScanner.d.mts +4 -0
  477. package/Utils/DataSecurity/TextScanner.d.ts +4 -0
  478. package/Utils/Monitor/DeviceMonitorDuplicates.d.mts +34 -0
  479. package/Utils/Monitor/DeviceMonitorDuplicates.d.ts +34 -0
  480. package/Utils/Monitor/DeviceMonitorDuplicates.js +134 -0
  481. package/Utils/Monitor/DeviceMonitorDuplicates.mjs +7 -0
  482. package/Utils/Monitor/DeviceMonitorTemplateUtil.d.mts +4 -0
  483. package/Utils/Monitor/DeviceMonitorTemplateUtil.d.ts +4 -0
  484. package/Utils/Monitor/DeviceMonitorTemplateUtil.js +33 -6
  485. package/Utils/Monitor/MonitorMetricType.js +11 -1
  486. package/Utils/Monitor/MonitorOverviewPresentationUtil.js +21 -3
  487. package/Utils/Monitor/ProbeFailureCauses.js +4 -1
  488. package/Utils/Monitor/ProbeStatusMonitorUtil.d.mts +5 -1
  489. package/Utils/Monitor/ProbeStatusMonitorUtil.d.ts +5 -1
  490. package/Utils/Monitor/ProbeStatusMonitorUtil.js +106 -0
  491. package/Utils/NetworkDevice/NetworkDeviceAssetFacts.d.mts +3 -0
  492. package/Utils/NetworkDevice/NetworkDeviceAssetFacts.d.ts +3 -0
  493. package/Utils/NetworkDevice/NetworkDeviceAssetFacts.js +33 -4
  494. package/Utils/NetworkDevice/NetworkDeviceAssetFacts.mjs +1 -0
  495. package/Utils/NetworkDevice/NetworkDeviceStoredManufacturer.d.mts +33 -0
  496. package/Utils/NetworkDevice/NetworkDeviceStoredManufacturer.d.ts +33 -0
  497. package/Utils/NetworkDevice/NetworkDeviceStoredManufacturer.js +105 -0
  498. package/Utils/NetworkDevice/NetworkDeviceStoredManufacturer.mjs +8 -0
  499. package/Utils/NetworkDevice/SnmpCredentialUtil.d.mts +5 -0
  500. package/Utils/NetworkDevice/SnmpCredentialUtil.d.ts +5 -0
  501. package/Utils/NetworkDevice/SnmpCredentialUtil.js +28 -3
  502. package/Utils/NetworkDevice/SnmpCredentialUtil.mjs +3 -0
  503. package/Utils/NetworkDiscovery/DiscoveredEndpointDeviceBuilder.d.mts +1 -0
  504. package/Utils/NetworkDiscovery/DiscoveredEndpointDeviceBuilder.d.ts +1 -0
  505. package/Utils/NetworkDiscovery/DiscoveredEndpointDeviceBuilder.js +20 -1
  506. package/Utils/Rules/RuleCriteriaMatcher.d.mts +1 -0
  507. package/Utils/Rules/RuleCriteriaMatcher.d.ts +1 -0
  508. package/Utils/Rules/RuleCriteriaMatcher.js +6 -0
  509. package/Utils/Rules/RuleCriteriaOwnerMatch.d.mts +10 -0
  510. package/Utils/Rules/RuleCriteriaOwnerMatch.d.ts +10 -0
  511. package/Utils/Rules/RuleCriteriaOwnerMatch.js +83 -0
  512. package/Utils/Rules/RuleCriteriaOwnerMatch.mjs +4 -0
  513. package/Utils/SecurityCase/SecurityCaseMatchRules.d.mts +27 -0
  514. package/Utils/SecurityCase/SecurityCaseMatchRules.d.ts +27 -0
  515. package/Utils/SecurityCase/SecurityCaseMatchRules.js +377 -0
  516. package/Utils/SecurityCase/SecurityCaseMatchRules.mjs +9 -0
  517. package/Utils/Slo/SloBulkRecommendedPolicy.d.mts +35 -0
  518. package/Utils/Slo/SloBulkRecommendedPolicy.d.ts +35 -0
  519. package/Utils/Slo/SloBulkRecommendedPolicy.js +168 -0
  520. package/Utils/Slo/SloBulkRecommendedPolicy.mjs +6 -0
  521. package/Utils/Slo/SloBurnRateRuleState.js +3 -6
  522. package/Utils/Slo/SloErrorBudgetPolicy.d.mts +17 -0
  523. package/Utils/Slo/SloErrorBudgetPolicy.d.ts +17 -0
  524. package/Utils/Slo/SloErrorBudgetPolicy.js +72 -1
  525. package/Utils/Slo/SloErrorBudgetPolicy.mjs +4 -0
  526. package/Utils/Slo/SloFeedMarkdown.d.mts +5 -2
  527. package/Utils/Slo/SloFeedMarkdown.d.ts +5 -2
  528. package/Utils/Slo/SloFeedMarkdown.js +19 -7
  529. package/Utils/Slo/SloFeedMarkdown.mjs +1 -0
  530. package/Utils/Slo/SloHealth.d.mts +5 -0
  531. package/Utils/Slo/SloHealth.d.ts +5 -0
  532. package/Utils/Slo/SloHealth.js +27 -0
  533. package/Utils/Slo/SloListWidgetFormat.js +5 -3
  534. package/Utils/Slo/SloMetricType.js +6 -5
  535. package/Utils/Slo/SloMonitorsFirstCheck.d.mts +13 -0
  536. package/Utils/Slo/SloMonitorsFirstCheck.d.ts +13 -0
  537. package/Utils/Slo/SloMonitorsFirstCheck.js +78 -0
  538. package/Utils/Slo/SloMonitorsFirstCheck.mjs +3 -0
  539. package/Utils/Slo/SloOverviewText.js +7 -0
  540. package/Utils/Slo/SloStatusColor.d.mts +3 -0
  541. package/Utils/Slo/SloStatusColor.d.ts +3 -0
  542. package/Utils/Slo/SloStatusColor.js +3 -0
  543. package/Utils/Slo/SloStatusPosts.d.mts +18 -0
  544. package/Utils/Slo/SloStatusPosts.d.ts +18 -0
  545. package/Utils/Slo/SloStatusPosts.js +95 -0
  546. package/Utils/Slo/SloStatusPosts.mjs +3 -0
  547. package/Utils/StatusPage/GridAxisValues.d.mts +2 -0
  548. package/Utils/StatusPage/GridAxisValues.d.ts +2 -0
  549. package/Utils/StatusPage/GridAxisValues.js +33 -0
  550. package/Utils/StatusPage/GridAxisValues.mjs +3 -0
  551. package/Utils/StatusPage/GroupHierarchyView.d.mts +2 -2
  552. package/Utils/StatusPage/GroupHierarchyView.d.ts +2 -2
  553. package/Utils/StatusPage/GroupHierarchyView.js +13 -12
  554. package/Utils/StatusPage/GroupNestingLayout.d.mts +1 -0
  555. package/Utils/StatusPage/GroupNestingLayout.d.ts +1 -0
  556. package/Utils/StatusPage/GroupNestingLayout.js +25 -5
  557. package/Utils/StatusPage/ResourceExplorer.d.mts +2 -2
  558. package/Utils/StatusPage/ResourceExplorer.d.ts +2 -2
  559. package/Utils/StatusPage/ResourceExplorer.js +15 -21
  560. package/Utils/StatusPage/StatusColorsOnDark.d.mts +5 -3
  561. package/Utils/StatusPage/StatusColorsOnDark.d.ts +5 -3
  562. package/Utils/StatusPage/StatusColorsOnDark.js +18 -6
  563. package/Utils/StatusPage/StatusColorsOnDark.mjs +1 -0
  564. package/Utils/Telemetry/MobileAppFaults.d.mts +8 -0
  565. package/Utils/Telemetry/MobileAppFaults.d.ts +8 -0
  566. package/Utils/Telemetry/MobileAppFaults.js +69 -0
  567. package/Utils/Telemetry/MobileAppFaults.mjs +6 -0
  568. package/Utils/Workspace/WorkspaceRefusal.d.mts +108 -0
  569. package/Utils/Workspace/WorkspaceRefusal.d.ts +108 -0
  570. package/Utils/Workspace/WorkspaceRefusal.js +769 -0
  571. package/Utils/Workspace/WorkspaceRefusal.mjs +50 -0
  572. package/package.json +4 -1
@@ -8,5 +8,6 @@ export declare function buildNetworkDeviceFromDiscoveredDevice(data: {
8
8
  facts: DiscoveredDeviceImportFacts;
9
9
  settings: DiscoveryImportSettings;
10
10
  name?: string | undefined;
11
+ readAt?: Date | undefined;
11
12
  }): NetworkDevice;
12
13
  export declare function buildDiscoveredDeviceFallbackName(name: string, ipAddress: string): string;
@@ -7,6 +7,7 @@ exports.buildNetworkDeviceFromDiscoveredDevice = buildNetworkDeviceFromDiscovere
7
7
  exports.buildDiscoveredDeviceFallbackName = buildDiscoveredDeviceFallbackName;
8
8
  const NetworkDevice_1 = __importDefault(require("../../Models/DatabaseModels/NetworkDevice"));
9
9
  const DeviceNameSource_1 = require("../../Types/NetworkDevice/DeviceNameSource");
10
+ const NetworkDeviceDiscoveredDetails_1 = require("../../Types/NetworkDevice/NetworkDeviceDiscoveredDetails");
10
11
  const NetworkDeviceMonitoringMethod_1 = __importDefault(require("../../Types/NetworkDevice/NetworkDeviceMonitoringMethod"));
11
12
  const ObjectID_1 = __importDefault(require("../../Types/ObjectID"));
12
13
  const DiscoveredDeviceBuilder_1 = require("./DiscoveredDeviceBuilder");
@@ -30,7 +31,13 @@ const DiscoveredDeviceBuilder_1 = require("./DiscoveredDeviceBuilder");
30
31
  * with credentials is walked with the site's (read at each poll), and
31
32
  * one in no such site is checked by ping;
32
33
  * - polled as often as the person chose, and given its vendor's health
33
- * template when it answers SNMP and they asked for that.
34
+ * template when it answers SNMP and they asked for that;
35
+ * - knowing what the list knew about it (issue #9305): the maker its MAC
36
+ * names and the name its controller gives it, in its discovered details
37
+ * with the list's row as their source - so its Vendor / Model and its
38
+ * inventory are not empty. A later change on the list follows it there
39
+ * (DiscoveredDeviceInventorySync); nothing a person saves on the device
40
+ * is ever replaced by them.
34
41
  *
35
42
  * Its name is the name the list showed (the classification a person gave
36
43
  * it, the name its controller or DHCP gave it, else its address). A device
@@ -54,6 +61,18 @@ function buildNetworkDeviceFromDiscoveredDevice(data) {
54
61
  device.macAddress = data.facts.macAddress;
55
62
  device.isMacAddressLearned = true;
56
63
  }
64
+ const listEntries = (0, NetworkDeviceDiscoveredDetails_1.buildDiscoveredListEntries)({
65
+ reading: {
66
+ endpointId: data.facts.endpointId,
67
+ name: data.facts.name || address,
68
+ vendor: data.facts.vendor,
69
+ clientName: data.facts.hostname,
70
+ },
71
+ readAt: data.readAt || new Date(),
72
+ });
73
+ if (Object.keys(listEntries).length > 0) {
74
+ device.discoveredDetails = listEntries;
75
+ }
57
76
  if (data.facts.siteId) {
58
77
  device.siteId = new ObjectID_1.default(data.facts.siteId);
59
78
  }
@@ -21,6 +21,7 @@ export interface MatchesWithLegacyOptions<RuleType extends RuleCriteriaCarrier,
21
21
  emptyResult: boolean;
22
22
  matchesLegacyRule: (rule: RuleType) => Promise<boolean> | boolean;
23
23
  correlation?: LegacyFilterCorrelation<RuleType, CorrelationCandidateType>;
24
+ recordFields?: Readonly<Record<string, (filter: RuleCriteriaFilter) => Promise<boolean> | boolean>> | undefined;
24
25
  }
25
26
  export interface LegacyFilterCorrelation<RuleType extends RuleCriteriaCarrier, CorrelationCandidateType> {
26
27
  fields: ReadonlyArray<Extract<keyof RuleType, string>>;
@@ -21,6 +21,7 @@ export interface MatchesWithLegacyOptions<RuleType extends RuleCriteriaCarrier,
21
21
  emptyResult: boolean;
22
22
  matchesLegacyRule: (rule: RuleType) => Promise<boolean> | boolean;
23
23
  correlation?: LegacyFilterCorrelation<RuleType, CorrelationCandidateType>;
24
+ recordFields?: Readonly<Record<string, (filter: RuleCriteriaFilter) => Promise<boolean> | boolean>> | undefined;
24
25
  }
25
26
  export interface LegacyFilterCorrelation<RuleType extends RuleCriteriaCarrier, CorrelationCandidateType> {
26
27
  fields: ReadonlyArray<Extract<keyof RuleType, string>>;
@@ -371,6 +371,12 @@ class RuleCriteriaMatcher {
371
371
  }
372
372
  static async matchesLegacyFilter(options) {
373
373
  try {
374
+ const matchesRecordField = Object.prototype.hasOwnProperty.call(options.recordFields || {}, options.filter.field)
375
+ ? options.recordFields[options.filter.field]
376
+ : undefined;
377
+ if (matchesRecordField) {
378
+ return await matchesRecordField(options.filter);
379
+ }
374
380
  if (!RuleCriteriaMatcher.isAllowedLegacyField(options)) {
375
381
  return false;
376
382
  }
@@ -0,0 +1,10 @@
1
+ import { RuleCriteriaFilter } from "../../Types/Rules/RuleCriteria.mjs";
2
+ export declare function matchesRuleCriteriaOwnerFilter(data: {
3
+ filter: RuleCriteriaFilter;
4
+ ownerIds: ReadonlyArray<string>;
5
+ }): boolean;
6
+ export declare function getOwnersMeetingRuleCriteriaOwnerFilter(data: {
7
+ filter: RuleCriteriaFilter;
8
+ ownerIds: ReadonlyArray<string>;
9
+ }): Array<string>;
10
+ export default matchesRuleCriteriaOwnerFilter;
@@ -0,0 +1,10 @@
1
+ import { RuleCriteriaFilter } from "../../Types/Rules/RuleCriteria";
2
+ export declare function matchesRuleCriteriaOwnerFilter(data: {
3
+ filter: RuleCriteriaFilter;
4
+ ownerIds: ReadonlyArray<string>;
5
+ }): boolean;
6
+ export declare function getOwnersMeetingRuleCriteriaOwnerFilter(data: {
7
+ filter: RuleCriteriaFilter;
8
+ ownerIds: ReadonlyArray<string>;
9
+ }): Array<string>;
10
+ export default matchesRuleCriteriaOwnerFilter;
@@ -0,0 +1,83 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.matchesRuleCriteriaOwnerFilter = matchesRuleCriteriaOwnerFilter;
4
+ exports.getOwnersMeetingRuleCriteriaOwnerFilter = getOwnersMeetingRuleCriteriaOwnerFilter;
5
+ const RuleCriteria_1 = require("../../Types/Rules/RuleCriteria");
6
+ /*
7
+ * WHETHER A RECORD'S OWNERS MEET AN OWNER CONDITION (#9353).
8
+ *
9
+ * "Alert Owner has any of Platform, Jane" holds when one of the people and
10
+ * teams picked is among the record's owners, "has none of" when none is.
11
+ * The owners are the ids on the record's lists of owner users and owner
12
+ * teams, as they are recorded: a member of an owning team is not an owner
13
+ * by being in it, so picking Jane matches what Jane owns herself, and
14
+ * picking Platform matches what the team owns. A workspace rule's owner
15
+ * condition matches the same way (#7583).
16
+ *
17
+ * Ids are compared as the database writes them, whatever case the rule or
18
+ * the owner rows used. A record with no owners has none of the picks.
19
+ */
20
+ function matchesRuleCriteriaOwnerFilter(data) {
21
+ const picked = getPickedOwnerIds(data.filter);
22
+ if (picked.length === 0) {
23
+ return false;
24
+ }
25
+ const owners = toOwnerSet(data.ownerIds);
26
+ const isOwner = (id) => {
27
+ return owners.has(id);
28
+ };
29
+ switch (data.filter.operator) {
30
+ case RuleCriteria_1.RuleCriteriaOperator.HasAnyOf:
31
+ return picked.some(isOwner);
32
+ case RuleCriteria_1.RuleCriteriaOperator.HasNoneOf:
33
+ return !picked.some(isOwner);
34
+ case RuleCriteria_1.RuleCriteriaOperator.HasAllOf:
35
+ return picked.every(isOwner);
36
+ default:
37
+ // No other operator compares owners: such a condition never holds.
38
+ return false;
39
+ }
40
+ }
41
+ /*
42
+ * THE OWNERS THAT MEET AN OWNER CONDITION (#9407): of the people and teams
43
+ * "has any of" (or "has all of") picks, the ones among the record's owners -
44
+ * in the order the condition picks them, as the condition wrote them. What
45
+ * "When this goes down" names as having made an on-call rule match. "Has
46
+ * none of" holds because no pick is an owner, so it names nobody, and so
47
+ * does a condition the owners do not meet.
48
+ */
49
+ function getOwnersMeetingRuleCriteriaOwnerFilter(data) {
50
+ if (data.filter.operator !== RuleCriteria_1.RuleCriteriaOperator.HasAnyOf &&
51
+ data.filter.operator !== RuleCriteria_1.RuleCriteriaOperator.HasAllOf) {
52
+ return [];
53
+ }
54
+ if (!matchesRuleCriteriaOwnerFilter(data)) {
55
+ return [];
56
+ }
57
+ const owners = toOwnerSet(data.ownerIds);
58
+ const met = [];
59
+ for (const id of getPickedOwnerIds(data.filter)) {
60
+ if (owners.has(id) && !met.includes(id)) {
61
+ met.push(id);
62
+ }
63
+ }
64
+ return met;
65
+ }
66
+ // The ids a condition picks, as the database writes them; empty ones left out.
67
+ function getPickedOwnerIds(filter) {
68
+ return (Array.isArray(filter.value) ? filter.value : [filter.value])
69
+ .map((value) => {
70
+ return String(value !== null && value !== void 0 ? value : "")
71
+ .trim()
72
+ .toLowerCase();
73
+ })
74
+ .filter((value) => {
75
+ return value.length > 0;
76
+ });
77
+ }
78
+ function toOwnerSet(ownerIds) {
79
+ return new Set(ownerIds.map((id) => {
80
+ return id.trim().toLowerCase();
81
+ }));
82
+ }
83
+ exports.default = matchesRuleCriteriaOwnerFilter;
@@ -0,0 +1,4 @@
1
+ import commonJsModule from "./RuleCriteriaOwnerMatch.js";
2
+ export default commonJsModule.default;
3
+ export const getOwnersMeetingRuleCriteriaOwnerFilter = commonJsModule.getOwnersMeetingRuleCriteriaOwnerFilter;
4
+ export const matchesRuleCriteriaOwnerFilter = commonJsModule.matchesRuleCriteriaOwnerFilter;
@@ -0,0 +1,27 @@
1
+ import { SecurityCaseMatchLookForJson } from "../../Types/SecurityCase/SecurityCaseMatches.mjs";
2
+ import SigmaRule from "../../Types/SecurityEvent/SigmaRule.mjs";
3
+ export declare const KEYWORD_FIELD: string;
4
+ export declare function getPositiveSelectionNames(rule: SigmaRule): Set<string>;
5
+ export declare function getSigmaLiteralFragments(value: string): Array<string>;
6
+ export declare function getSigmaRuleLookFor(rules: ReadonlyArray<SigmaRule>): Array<SecurityCaseMatchLookForJson>;
7
+ export interface SigmaRuleGuidance {
8
+ falsePositives: Array<string>;
9
+ references: Array<string>;
10
+ }
11
+ export declare function readSigmaRuleGuidance(ruleYaml: string): SigmaRuleGuidance;
12
+ export interface TextMatchPart {
13
+ text: string;
14
+ isMatch: boolean;
15
+ }
16
+ export declare function splitTextByLookFor(text: string, values: ReadonlyArray<string>): Array<TextMatchPart>;
17
+ export declare function getLookForValues(lookFor: ReadonlyArray<SecurityCaseMatchLookForJson>): Array<string>;
18
+ export interface SecurityCaseMatchWindow {
19
+ start: Date;
20
+ end: Date;
21
+ }
22
+ export declare function getDetectionMatchWindow(data: {
23
+ firstSeenAt: Date | string | null | undefined;
24
+ lastSeenAt: Date | string | null | undefined;
25
+ lookBackInMinutes?: number | undefined;
26
+ now: Date;
27
+ }): SecurityCaseMatchWindow | null;
@@ -0,0 +1,27 @@
1
+ import { SecurityCaseMatchLookForJson } from "../../Types/SecurityCase/SecurityCaseMatches";
2
+ import SigmaRule from "../../Types/SecurityEvent/SigmaRule";
3
+ export declare const KEYWORD_FIELD: string;
4
+ export declare function getPositiveSelectionNames(rule: SigmaRule): Set<string>;
5
+ export declare function getSigmaLiteralFragments(value: string): Array<string>;
6
+ export declare function getSigmaRuleLookFor(rules: ReadonlyArray<SigmaRule>): Array<SecurityCaseMatchLookForJson>;
7
+ export interface SigmaRuleGuidance {
8
+ falsePositives: Array<string>;
9
+ references: Array<string>;
10
+ }
11
+ export declare function readSigmaRuleGuidance(ruleYaml: string): SigmaRuleGuidance;
12
+ export interface TextMatchPart {
13
+ text: string;
14
+ isMatch: boolean;
15
+ }
16
+ export declare function splitTextByLookFor(text: string, values: ReadonlyArray<string>): Array<TextMatchPart>;
17
+ export declare function getLookForValues(lookFor: ReadonlyArray<SecurityCaseMatchLookForJson>): Array<string>;
18
+ export interface SecurityCaseMatchWindow {
19
+ start: Date;
20
+ end: Date;
21
+ }
22
+ export declare function getDetectionMatchWindow(data: {
23
+ firstSeenAt: Date | string | null | undefined;
24
+ lastSeenAt: Date | string | null | undefined;
25
+ lookBackInMinutes?: number | undefined;
26
+ now: Date;
27
+ }): SecurityCaseMatchWindow | null;
@@ -0,0 +1,377 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.KEYWORD_FIELD = void 0;
7
+ exports.getPositiveSelectionNames = getPositiveSelectionNames;
8
+ exports.getSigmaLiteralFragments = getSigmaLiteralFragments;
9
+ exports.getSigmaRuleLookFor = getSigmaRuleLookFor;
10
+ exports.readSigmaRuleGuidance = readSigmaRuleGuidance;
11
+ exports.splitTextByLookFor = splitTextByLookFor;
12
+ exports.getLookForValues = getLookForValues;
13
+ exports.getDetectionMatchWindow = getDetectionMatchWindow;
14
+ const js_yaml_1 = __importDefault(require("js-yaml"));
15
+ const SecurityCaseMatches_1 = require("../../Types/SecurityCase/SecurityCaseMatches");
16
+ /*
17
+ * WHAT A DETECTION MATCHED, the pure half of SecurityCaseMatches
18
+ * (Server/Utils/SecurityCase/Context/SecurityCaseMatches.ts): what a rule's
19
+ * condition looks for, so the case can mark it in each event it matched;
20
+ * the guidance a rule's own Sigma YAML gives (when it is known to fire on
21
+ * something harmless, and where to read more); and the time a detection's
22
+ * events are read over.
23
+ *
24
+ * Free of anything server-only and of React, so the server, the Dashboard
25
+ * and a plain test agree on every rule of it.
26
+ */
27
+ /*
28
+ * The modifiers whose values are text a matching field holds as written:
29
+ * contains, startswith, endswith and an equality, with all, cased and
30
+ * windash only changing how. A value read through any other modifier - a
31
+ * regular expression, a network range, a comparison, a watchlist, exists -
32
+ * is no text to find in the event.
33
+ */
34
+ const TEXT_MODIFIERS = new Set([
35
+ "contains",
36
+ "startswith",
37
+ "endswith",
38
+ "all",
39
+ "cased",
40
+ "windash",
41
+ ]);
42
+ /*
43
+ * Columns that hold a category, not text a person reads: a rule's
44
+ * "className: Authentication" says what kind of event it reads, and finding
45
+ * "Authentication" in the event's message tells nobody anything.
46
+ */
47
+ const CATEGORY_FIELDS = new Set([
48
+ "classname",
49
+ "classuid",
50
+ "categoryname",
51
+ "categoryuid",
52
+ "activityname",
53
+ "severityname",
54
+ "severityid",
55
+ "statusname",
56
+ "vendorname",
57
+ "productname",
58
+ "requestoutcome",
59
+ ]);
60
+ // The field keyword selections are matched against.
61
+ exports.KEYWORD_FIELD = "message";
62
+ // A fragment shorter than this marks too much of an event to say anything.
63
+ const MIN_FRAGMENT_LENGTH = 2;
64
+ /*
65
+ * The selections a condition needs to match, never the ones it needs not
66
+ * to: under an even number of "not"s. "selection and not filter" looks for
67
+ * the selection's values, never the filter's.
68
+ */
69
+ function getPositiveSelectionNames(rule) {
70
+ const names = new Set();
71
+ const allNames = rule.selections.map((selection) => {
72
+ return selection.name;
73
+ });
74
+ const namesFor = (pattern) => {
75
+ if (pattern === "them") {
76
+ return allNames;
77
+ }
78
+ if (pattern.endsWith("*")) {
79
+ const prefix = pattern.slice(0, -1);
80
+ return allNames.filter((name) => {
81
+ return name.startsWith(prefix);
82
+ });
83
+ }
84
+ return allNames.filter((name) => {
85
+ return name === pattern;
86
+ });
87
+ };
88
+ const walk = (node, isNegated) => {
89
+ switch (node.kind) {
90
+ case "selection":
91
+ if (!isNegated) {
92
+ names.add(node.name);
93
+ }
94
+ return;
95
+ case "not":
96
+ walk(node.child, !isNegated);
97
+ return;
98
+ case "and":
99
+ case "or":
100
+ for (const child of node.children) {
101
+ walk(child, isNegated);
102
+ }
103
+ return;
104
+ case "of":
105
+ if (!isNegated) {
106
+ for (const name of namesFor(node.pattern)) {
107
+ names.add(name);
108
+ }
109
+ }
110
+ return;
111
+ }
112
+ };
113
+ walk(rule.condition, false);
114
+ return names;
115
+ }
116
+ /*
117
+ * The literal text in a Sigma value: the runs between its wildcards (`*`
118
+ * any text, `?` one character), with an escaped character (a backslash
119
+ * before it) kept as the character. "cmd*.exe /c" is "cmd" and ".exe /c";
120
+ * "/etc/passwd" with a wildcard either side is "/etc/passwd".
121
+ */
122
+ function getSigmaLiteralFragments(value) {
123
+ const fragments = [];
124
+ let current = "";
125
+ let index = 0;
126
+ const flush = () => {
127
+ if (current.trim().length >= MIN_FRAGMENT_LENGTH) {
128
+ fragments.push(current);
129
+ }
130
+ current = "";
131
+ };
132
+ while (index < value.length) {
133
+ const character = value[index];
134
+ if (character === "\\" && index + 1 < value.length) {
135
+ current += value[index + 1];
136
+ index += 2;
137
+ continue;
138
+ }
139
+ if (character === "*" || character === "?") {
140
+ flush();
141
+ }
142
+ else {
143
+ current += character;
144
+ }
145
+ index++;
146
+ }
147
+ flush();
148
+ return fragments;
149
+ }
150
+ function readRequirementValues(requirement) {
151
+ const isText = requirement.modifiers.every((modifier) => {
152
+ return TEXT_MODIFIERS.has(modifier);
153
+ });
154
+ if (!isText || CATEGORY_FIELDS.has(requirement.field.toLowerCase())) {
155
+ return [];
156
+ }
157
+ return requirement.values.flatMap((value) => {
158
+ return typeof value === "string" ? getSigmaLiteralFragments(value) : [];
159
+ });
160
+ }
161
+ /*
162
+ * What a detection's rules look for, field by field: the literal text of
163
+ * every value their conditions need to match - the selections a "not" does
164
+ * not take away, through a modifier that matches text as written. A
165
+ * correlation's rules are read alike. At most
166
+ * SECURITY_CASE_MATCHES_MAX_LOOK_FOR values, each once (whatever its
167
+ * case) and at most SECURITY_CASE_MATCHES_LOOK_FOR_MAX_LENGTH long.
168
+ */
169
+ function getSigmaRuleLookFor(rules) {
170
+ const byField = new Map();
171
+ const seen = new Set();
172
+ let total = 0;
173
+ const add = (field, value) => {
174
+ const text = value.length > SecurityCaseMatches_1.SECURITY_CASE_MATCHES_LOOK_FOR_MAX_LENGTH
175
+ ? value.slice(0, SecurityCaseMatches_1.SECURITY_CASE_MATCHES_LOOK_FOR_MAX_LENGTH)
176
+ : value;
177
+ const key = text.toLowerCase();
178
+ if (seen.has(key) || total >= SecurityCaseMatches_1.SECURITY_CASE_MATCHES_MAX_LOOK_FOR) {
179
+ return;
180
+ }
181
+ seen.add(key);
182
+ total++;
183
+ byField.set(field, [...(byField.get(field) || []), text]);
184
+ };
185
+ for (const rule of rules) {
186
+ const positive = getPositiveSelectionNames(rule);
187
+ for (const selection of rule.selections) {
188
+ if (!positive.has(selection.name)) {
189
+ continue;
190
+ }
191
+ for (const keyword of selection.keywords) {
192
+ for (const fragment of getSigmaLiteralFragments(keyword)) {
193
+ add(exports.KEYWORD_FIELD, fragment);
194
+ }
195
+ }
196
+ for (const fieldMap of selection.fieldMaps) {
197
+ for (const requirement of fieldMap) {
198
+ for (const value of readRequirementValues(requirement)) {
199
+ add(requirement.field, value);
200
+ }
201
+ }
202
+ }
203
+ }
204
+ }
205
+ return Array.from(byField.entries()).map((entry) => {
206
+ return { field: entry[0], values: entry[1] };
207
+ });
208
+ }
209
+ // What a Sigma rule writes when it knows of no false positive.
210
+ const NO_FALSE_POSITIVE_WORDS = new Set([
211
+ "unknown",
212
+ "none",
213
+ "n/a",
214
+ "na",
215
+ "-",
216
+ ]);
217
+ function readLines(value) {
218
+ const items = Array.isArray(value) ? value : [value];
219
+ const lines = [];
220
+ for (const item of items) {
221
+ if (typeof item !== "string") {
222
+ continue;
223
+ }
224
+ const text = item.trim();
225
+ if (text) {
226
+ lines.push(text.length > SecurityCaseMatches_1.SECURITY_CASE_MATCHES_GUIDANCE_MAX_LENGTH
227
+ ? `${text.slice(0, SecurityCaseMatches_1.SECURITY_CASE_MATCHES_GUIDANCE_MAX_LENGTH - 1)}…`
228
+ : text);
229
+ }
230
+ }
231
+ return lines;
232
+ }
233
+ function addOnce(list, value) {
234
+ if (list.length < SecurityCaseMatches_1.SECURITY_CASE_MATCHES_MAX_GUIDANCE_LINES &&
235
+ !list.some((item) => {
236
+ return item.toLowerCase() === value.toLowerCase();
237
+ })) {
238
+ list.push(value);
239
+ }
240
+ }
241
+ function isWebLink(value) {
242
+ try {
243
+ const url = new globalThis.URL(value);
244
+ return url.protocol === "https:" || url.protocol === "http:";
245
+ }
246
+ catch (_a) {
247
+ return false;
248
+ }
249
+ }
250
+ /*
251
+ * The guidance a rule's own YAML gives: its `falsepositives` - each once,
252
+ * leaving out the "Unknown" Sigma writes when it knows of none - and its
253
+ * `references` that are web links. Every document of the file is read, so a
254
+ * correlation's rules give theirs too. A file that does not read gives
255
+ * none: guidance is never a reason to fail.
256
+ */
257
+ function readSigmaRuleGuidance(ruleYaml) {
258
+ const guidance = { falsePositives: [], references: [] };
259
+ if (!ruleYaml || !ruleYaml.trim()) {
260
+ return guidance;
261
+ }
262
+ let documents = [];
263
+ try {
264
+ documents = js_yaml_1.default.loadAll(ruleYaml);
265
+ }
266
+ catch (_a) {
267
+ return guidance;
268
+ }
269
+ for (const document of documents) {
270
+ if (!document || typeof document !== "object" || Array.isArray(document)) {
271
+ continue;
272
+ }
273
+ const record = document;
274
+ for (const line of readLines(record["falsepositives"])) {
275
+ if (!NO_FALSE_POSITIVE_WORDS.has(line.toLowerCase())) {
276
+ addOnce(guidance.falsePositives, line);
277
+ }
278
+ }
279
+ for (const line of readLines(record["references"])) {
280
+ if (isWebLink(line)) {
281
+ addOnce(guidance.references, line);
282
+ }
283
+ }
284
+ }
285
+ return guidance;
286
+ }
287
+ /*
288
+ * A text in parts, each occurrence of a value the rule looks for marked -
289
+ * found whatever its case, the longest first where two overlap - so the
290
+ * case draws "../../" in "/get_log_file/../../proc/self/environ" apart.
291
+ */
292
+ function splitTextByLookFor(text, values) {
293
+ if (!text) {
294
+ return [];
295
+ }
296
+ const lowered = text.toLowerCase();
297
+ const marked = new Array(text.length).fill(false);
298
+ const needles = values
299
+ .map((value) => {
300
+ return value.toLowerCase();
301
+ })
302
+ .filter((value) => {
303
+ return value.trim().length >= MIN_FRAGMENT_LENGTH;
304
+ })
305
+ .sort((a, b) => {
306
+ return b.length - a.length;
307
+ });
308
+ for (const needle of needles) {
309
+ let from = 0;
310
+ while (from <= lowered.length - needle.length) {
311
+ const at = lowered.indexOf(needle, from);
312
+ if (at === -1) {
313
+ break;
314
+ }
315
+ for (let index = at; index < at + needle.length; index++) {
316
+ marked[index] = true;
317
+ }
318
+ from = at + needle.length;
319
+ }
320
+ }
321
+ const parts = [];
322
+ for (let index = 0; index < text.length; index++) {
323
+ const isMatch = marked[index] === true;
324
+ const last = parts[parts.length - 1];
325
+ if (last && last.isMatch === isMatch) {
326
+ last.text += text[index];
327
+ }
328
+ else {
329
+ parts.push({ text: text[index], isMatch });
330
+ }
331
+ }
332
+ return parts;
333
+ }
334
+ // Every value a detection's rules look for, whatever the field.
335
+ function getLookForValues(lookFor) {
336
+ return lookFor.flatMap((entry) => {
337
+ return entry.values;
338
+ });
339
+ }
340
+ function readDate(value) {
341
+ if (!value) {
342
+ return null;
343
+ }
344
+ const date = new Date(value);
345
+ return Number.isNaN(date.getTime()) ? null : date;
346
+ }
347
+ /*
348
+ * The time a detection's events are read over: from a window before it
349
+ * first fired to just after it last fired - a rule counts its matches in
350
+ * windows of its interval, each window's firing stamped at the window's
351
+ * end - at most SECURITY_CASE_MATCHES_MAX_WINDOW_IN_HOURS from its start
352
+ * (what opened the case is at the start), and never past now.
353
+ * `lookBackInMinutes` is how long a window the source counts in; a source
354
+ * that does not say is read a few minutes either side of its firings. Null
355
+ * for a detection with no time at all.
356
+ */
357
+ function getDetectionMatchWindow(data) {
358
+ const first = readDate(data.firstSeenAt);
359
+ const last = readDate(data.lastSeenAt) || first;
360
+ if (!first || !last) {
361
+ return null;
362
+ }
363
+ const minute = 60 * 1000;
364
+ const padding = SecurityCaseMatches_1.SECURITY_CASE_MATCHES_PADDING_IN_MINUTES * minute;
365
+ const countsInWindows = Boolean(data.lookBackInMinutes && data.lookBackInMinutes > 0);
366
+ // A minute of slack either side of a window, for the seconds a run takes.
367
+ const lookBack = countsInWindows
368
+ ? data.lookBackInMinutes * minute + minute
369
+ : padding;
370
+ const lookAhead = countsInWindows ? minute : padding;
371
+ const start = Math.min(first.getTime(), last.getTime()) - lookBack;
372
+ const end = Math.min(Math.max(first.getTime(), last.getTime()) + lookAhead, start + SecurityCaseMatches_1.SECURITY_CASE_MATCHES_MAX_WINDOW_IN_HOURS * 60 * minute, data.now.getTime());
373
+ return {
374
+ start: new Date(start),
375
+ end: new Date(Math.max(start, end)),
376
+ };
377
+ }
@@ -0,0 +1,9 @@
1
+ import commonJsModule from "./SecurityCaseMatchRules.js";
2
+ export const KEYWORD_FIELD = commonJsModule.KEYWORD_FIELD;
3
+ export const getDetectionMatchWindow = commonJsModule.getDetectionMatchWindow;
4
+ export const getLookForValues = commonJsModule.getLookForValues;
5
+ export const getPositiveSelectionNames = commonJsModule.getPositiveSelectionNames;
6
+ export const getSigmaLiteralFragments = commonJsModule.getSigmaLiteralFragments;
7
+ export const getSigmaRuleLookFor = commonJsModule.getSigmaRuleLookFor;
8
+ export const readSigmaRuleGuidance = commonJsModule.readSigmaRuleGuidance;
9
+ export const splitTextByLookFor = commonJsModule.splitTextByLookFor;
@@ -0,0 +1,35 @@
1
+ import { JSONObject, JSONValue } from "../../Types/JSON.mjs";
2
+ import { SloRecommendedPolicyTier, SloRecommendedPolicyTierToAdd } from "./SloErrorBudgetPolicy.mjs";
3
+ export declare const SLO_BULK_POLICY_ADD_FAILED_MESSAGE: string;
4
+ export declare enum SloBulkRecommendedPolicyStatus {
5
+ Missing = "Missing",
6
+ Added = "Added",
7
+ NothingMissing = "NothingMissing",
8
+ OwnPolicy = "OwnPolicy",
9
+ Refused = "Refused",
10
+ Failed = "Failed"
11
+ }
12
+ export interface SloBulkRecommendedPolicyResult {
13
+ serviceLevelObjectiveId: string;
14
+ status: SloBulkRecommendedPolicyStatus;
15
+ tiers: Array<SloRecommendedPolicyTierToAdd>;
16
+ message: string | null;
17
+ }
18
+ export type SloBulkRecommendedPolicyResultToJSONFunction = (result: SloBulkRecommendedPolicyResult) => JSONObject;
19
+ export declare const sloBulkRecommendedPolicyResultToJSON: SloBulkRecommendedPolicyResultToJSONFunction;
20
+ export type ParseSloBulkRecommendedPolicyResultsFunction = (value: JSONValue | undefined) => Array<SloBulkRecommendedPolicyResult>;
21
+ export declare const parseSloBulkRecommendedPolicyResults: ParseSloBulkRecommendedPolicyResultsFunction;
22
+ export interface SloRecommendedPolicyTierCount {
23
+ tier: SloRecommendedPolicyTier;
24
+ sloCount: number;
25
+ }
26
+ export interface SloBulkRecommendedPolicySummary {
27
+ withTiersSloCount: number;
28
+ nothingMissingSloCount: number;
29
+ ownPolicySloCount: number;
30
+ refusedSloCount: number;
31
+ failedSloCount: number;
32
+ tiers: Array<SloRecommendedPolicyTierCount>;
33
+ }
34
+ export type SummarizeSloBulkRecommendedPolicyFunction = (results: ReadonlyArray<SloBulkRecommendedPolicyResult>) => SloBulkRecommendedPolicySummary;
35
+ export declare const summarizeSloBulkRecommendedPolicy: SummarizeSloBulkRecommendedPolicyFunction;