erosolar-cli 1.5.2 → 1.5.4

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 (346) hide show
  1. package/config/security-deployment.json +54 -0
  2. package/dist/bin/adapters/node/index.js +33 -0
  3. package/dist/bin/adapters/types.js +1 -0
  4. package/dist/bin/alpha-zero/agentWrapper.js +165 -0
  5. package/dist/bin/alpha-zero/codeEvaluator.js +272 -0
  6. package/dist/bin/alpha-zero/competitiveRunner.js +219 -0
  7. package/dist/bin/alpha-zero/index.js +98 -0
  8. package/dist/bin/alpha-zero/introspection.js +298 -0
  9. package/dist/bin/alpha-zero/metricsTracker.js +207 -0
  10. package/dist/bin/alpha-zero/security/core.js +269 -0
  11. package/dist/bin/alpha-zero/security/google.js +308 -0
  12. package/dist/bin/alpha-zero/security/googleLoader.js +40 -0
  13. package/dist/bin/alpha-zero/security/index.js +31 -0
  14. package/dist/bin/alpha-zero/security/simulation.js +274 -0
  15. package/dist/bin/alpha-zero/selfModification.js +231 -0
  16. package/dist/bin/alpha-zero/types.js +30 -0
  17. package/dist/bin/bin/erosolar-optimized.js +205 -0
  18. package/dist/bin/capabilities/agentSpawningCapability.js +116 -0
  19. package/dist/bin/capabilities/bashCapability.js +22 -0
  20. package/dist/bin/capabilities/cloudCapability.js +36 -0
  21. package/dist/bin/capabilities/codeAnalysisCapability.js +22 -0
  22. package/dist/bin/capabilities/codeQualityCapability.js +23 -0
  23. package/dist/bin/capabilities/dependencySecurityCapability.js +22 -0
  24. package/dist/bin/capabilities/devCapability.js +22 -0
  25. package/dist/bin/capabilities/editCapability.js +28 -0
  26. package/dist/bin/capabilities/emailCapability.js +20 -0
  27. package/dist/bin/capabilities/enhancedGitCapability.js +221 -0
  28. package/dist/bin/capabilities/filesystemCapability.js +22 -0
  29. package/dist/bin/capabilities/globCapability.js +28 -0
  30. package/dist/bin/capabilities/interactionCapability.js +20 -0
  31. package/dist/bin/capabilities/learnCapability.js +22 -0
  32. package/dist/bin/capabilities/mcpCapability.js +20 -0
  33. package/dist/bin/capabilities/notebookCapability.js +28 -0
  34. package/dist/bin/capabilities/planningCapability.js +27 -0
  35. package/dist/bin/capabilities/refactoringCapability.js +23 -0
  36. package/dist/bin/capabilities/repoChecksCapability.js +22 -0
  37. package/dist/bin/capabilities/searchCapability.js +22 -0
  38. package/dist/bin/capabilities/skillCapability.js +76 -0
  39. package/dist/bin/capabilities/taskManagementCapability.js +20 -0
  40. package/dist/bin/capabilities/testingCapability.js +23 -0
  41. package/dist/bin/capabilities/toolManifest.js +159 -0
  42. package/dist/bin/capabilities/toolRegistry.js +114 -0
  43. package/dist/bin/capabilities/webCapability.js +20 -0
  44. package/dist/bin/config.js +139 -0
  45. package/dist/bin/contracts/v1/agent.js +7 -0
  46. package/dist/bin/contracts/v1/agentProfileManifest.js +8 -0
  47. package/dist/bin/contracts/v1/agentRules.js +9 -0
  48. package/dist/bin/contracts/v1/toolAccess.js +8 -0
  49. package/dist/bin/core/agent.js +362 -0
  50. package/dist/bin/core/agentProfileManifest.js +187 -0
  51. package/dist/bin/core/agentProfiles.js +34 -0
  52. package/dist/bin/core/agentRulebook.js +135 -0
  53. package/dist/bin/core/agentSchemaLoader.js +233 -0
  54. package/dist/bin/core/contextManager.js +412 -0
  55. package/dist/bin/core/contextWindow.js +122 -0
  56. package/dist/bin/core/customCommands.js +80 -0
  57. package/dist/bin/core/errors/apiKeyErrors.js +114 -0
  58. package/dist/bin/core/errors/errorTypes.js +340 -0
  59. package/dist/bin/core/errors/safetyValidator.js +304 -0
  60. package/dist/bin/core/errors.js +32 -0
  61. package/dist/bin/core/modelDiscovery.js +755 -0
  62. package/dist/bin/core/preferences.js +224 -0
  63. package/dist/bin/core/schemaValidator.js +92 -0
  64. package/dist/bin/core/secretStore.js +199 -0
  65. package/dist/bin/core/sessionStore.js +187 -0
  66. package/dist/bin/core/toolRuntime.js +290 -0
  67. package/dist/bin/core/types.js +1 -0
  68. package/dist/bin/erosolar-optimized.d.ts +12 -0
  69. package/dist/bin/erosolar-optimized.d.ts.map +1 -0
  70. package/dist/bin/erosolar-optimized.js +239 -0
  71. package/dist/bin/erosolar-optimized.js.map +1 -0
  72. package/dist/bin/erosolar.js +14 -0
  73. package/dist/bin/erosolar.js.map +1 -1
  74. package/dist/bin/headless/headlessApp.js +172 -0
  75. package/dist/bin/mcp/config.js +202 -0
  76. package/dist/bin/mcp/stdioClient.js +172 -0
  77. package/dist/bin/mcp/toolBridge.js +104 -0
  78. package/dist/bin/mcp/types.js +1 -0
  79. package/dist/bin/plugins/index.js +113 -0
  80. package/dist/bin/plugins/providers/anthropic/index.js +25 -0
  81. package/dist/bin/plugins/providers/deepseek/index.js +24 -0
  82. package/dist/bin/plugins/providers/google/index.js +26 -0
  83. package/dist/bin/plugins/providers/index.js +19 -0
  84. package/dist/bin/plugins/providers/ollama/index.js +59 -0
  85. package/dist/bin/plugins/providers/openai/index.js +26 -0
  86. package/dist/bin/plugins/providers/xai/index.js +24 -0
  87. package/dist/bin/plugins/tools/agentSpawning/agentSpawningPlugin.js +8 -0
  88. package/dist/bin/plugins/tools/bash/localBashPlugin.js +13 -0
  89. package/dist/bin/plugins/tools/checks/localRepoChecksPlugin.js +13 -0
  90. package/dist/bin/plugins/tools/cloud/cloudPlugin.js +13 -0
  91. package/dist/bin/plugins/tools/codeAnalysis/codeAnalysisPlugin.js +13 -0
  92. package/dist/bin/plugins/tools/codeQuality/codeQualityPlugin.js +13 -0
  93. package/dist/bin/plugins/tools/dependency/dependencyPlugin.js +11 -0
  94. package/dist/bin/plugins/tools/development/devPlugin.js +13 -0
  95. package/dist/bin/plugins/tools/edit/editPlugin.js +14 -0
  96. package/dist/bin/plugins/tools/email/emailPlugin.js +11 -0
  97. package/dist/bin/plugins/tools/enhancedGit/enhancedGitPlugin.js +8 -0
  98. package/dist/bin/plugins/tools/filesystem/localFilesystemPlugin.js +13 -0
  99. package/dist/bin/plugins/tools/glob/globPlugin.js +14 -0
  100. package/dist/bin/plugins/tools/index.js +2 -0
  101. package/dist/bin/plugins/tools/interaction/interactionPlugin.js +11 -0
  102. package/dist/bin/plugins/tools/learn/learnPlugin.js +13 -0
  103. package/dist/bin/plugins/tools/mcp/mcpPlugin.js +8 -0
  104. package/dist/bin/plugins/tools/nodeDefaults.js +56 -0
  105. package/dist/bin/plugins/tools/notebook/notebookPlugin.js +14 -0
  106. package/dist/bin/plugins/tools/planning/planningPlugin.js +14 -0
  107. package/dist/bin/plugins/tools/refactoring/refactoringPlugin.js +11 -0
  108. package/dist/bin/plugins/tools/registry.js +57 -0
  109. package/dist/bin/plugins/tools/search/localSearchPlugin.js +13 -0
  110. package/dist/bin/plugins/tools/skills/skillPlugin.js +8 -0
  111. package/dist/bin/plugins/tools/taskManagement/taskManagementPlugin.js +11 -0
  112. package/dist/bin/plugins/tools/testing/testingPlugin.js +11 -0
  113. package/dist/bin/plugins/tools/web/webPlugin.js +11 -0
  114. package/dist/bin/providers/anthropicProvider.js +329 -0
  115. package/dist/bin/providers/googleProvider.js +203 -0
  116. package/dist/bin/providers/openaiChatCompletionsProvider.js +208 -0
  117. package/dist/bin/providers/openaiResponsesProvider.js +249 -0
  118. package/dist/bin/providers/providerFactory.js +24 -0
  119. package/dist/bin/runtime/agentController.js +321 -0
  120. package/dist/bin/runtime/agentHost.js +153 -0
  121. package/dist/bin/runtime/agentSession.js +195 -0
  122. package/dist/bin/runtime/node.js +10 -0
  123. package/dist/bin/runtime/universal.js +28 -0
  124. package/dist/bin/shell/bracketedPasteManager.js +350 -0
  125. package/dist/bin/shell/fileChangeTracker.js +65 -0
  126. package/dist/bin/shell/interactiveShell.js +2908 -0
  127. package/dist/bin/shell/liveStatus.js +78 -0
  128. package/dist/bin/shell/shellApp.js +290 -0
  129. package/dist/bin/shell/systemPrompt.js +60 -0
  130. package/dist/bin/shell/updateManager.js +108 -0
  131. package/dist/bin/skills/skillRepository.js +236 -0
  132. package/dist/bin/skills/types.js +1 -0
  133. package/dist/bin/subagents/taskRunner.js +269 -0
  134. package/dist/bin/tools/backgroundBashTools.js +211 -0
  135. package/dist/bin/tools/bashTools.js +159 -0
  136. package/dist/bin/tools/cloudTools.js +864 -0
  137. package/dist/bin/tools/codeAnalysisTools.js +641 -0
  138. package/dist/bin/tools/codeQualityTools.js +294 -0
  139. package/dist/bin/tools/dependencyTools.js +282 -0
  140. package/dist/bin/tools/devTools.js +238 -0
  141. package/dist/bin/tools/diffUtils.js +137 -0
  142. package/dist/bin/tools/editTools.js +134 -0
  143. package/dist/bin/tools/emailTools.js +448 -0
  144. package/dist/bin/tools/fileTools.js +282 -0
  145. package/dist/bin/tools/globTools.js +173 -0
  146. package/dist/bin/tools/grepTools.js +332 -0
  147. package/dist/bin/tools/interactionTools.js +170 -0
  148. package/dist/bin/tools/learnTools.js +1818 -0
  149. package/dist/bin/tools/notebookEditTools.js +196 -0
  150. package/dist/bin/tools/planningTools.js +46 -0
  151. package/dist/bin/tools/refactoringTools.js +293 -0
  152. package/dist/bin/tools/repoChecksTools.js +160 -0
  153. package/dist/bin/tools/searchTools.js +206 -0
  154. package/dist/bin/tools/skillTools.js +177 -0
  155. package/dist/bin/tools/taskManagementTools.js +156 -0
  156. package/dist/bin/tools/testingTools.js +232 -0
  157. package/dist/bin/tools/webTools.js +480 -0
  158. package/dist/bin/ui/ShellUIAdapter.js +459 -0
  159. package/dist/bin/ui/UnifiedUIController.js +183 -0
  160. package/dist/bin/ui/animation/AnimationScheduler.js +430 -0
  161. package/dist/bin/ui/codeHighlighter.js +854 -0
  162. package/dist/bin/ui/designSystem.js +121 -0
  163. package/dist/bin/ui/display.js +1222 -0
  164. package/dist/bin/ui/interrupts/InterruptManager.js +437 -0
  165. package/dist/bin/ui/layout.js +139 -0
  166. package/dist/bin/ui/orchestration/StatusOrchestrator.js +403 -0
  167. package/dist/bin/ui/outputMode.js +38 -0
  168. package/dist/bin/ui/persistentPrompt.js +183 -0
  169. package/dist/bin/ui/richText.js +338 -0
  170. package/dist/bin/ui/shortcutsHelp.js +87 -0
  171. package/dist/bin/ui/telemetry/UITelemetry.js +443 -0
  172. package/dist/bin/ui/textHighlighter.js +210 -0
  173. package/dist/bin/ui/theme.js +116 -0
  174. package/dist/bin/ui/toolDisplay.js +423 -0
  175. package/dist/bin/ui/toolDisplayAdapter.js +357 -0
  176. package/dist/bin/workspace.js +106 -0
  177. package/dist/bin/workspace.validator.js +213 -0
  178. package/dist/capabilities/cloudCapability.d.ts +13 -0
  179. package/dist/capabilities/cloudCapability.d.ts.map +1 -0
  180. package/dist/capabilities/cloudCapability.js +38 -0
  181. package/dist/capabilities/cloudCapability.js.map +1 -0
  182. package/dist/capabilities/index.d.ts +1 -0
  183. package/dist/capabilities/index.d.ts.map +1 -1
  184. package/dist/capabilities/index.js +1 -0
  185. package/dist/capabilities/index.js.map +1 -1
  186. package/dist/capabilities/offensiveSecurityCapability.d.ts +26 -0
  187. package/dist/capabilities/offensiveSecurityCapability.d.ts.map +1 -0
  188. package/dist/capabilities/offensiveSecurityCapability.js +58 -0
  189. package/dist/capabilities/offensiveSecurityCapability.js.map +1 -0
  190. package/dist/capabilities/realSecurityCapability.d.ts +26 -0
  191. package/dist/capabilities/realSecurityCapability.d.ts.map +1 -0
  192. package/dist/capabilities/realSecurityCapability.js +53 -0
  193. package/dist/capabilities/realSecurityCapability.js.map +1 -0
  194. package/dist/capabilities/securityCapability.d.ts +32 -0
  195. package/dist/capabilities/securityCapability.d.ts.map +1 -0
  196. package/dist/capabilities/securityCapability.js +57 -0
  197. package/dist/capabilities/securityCapability.js.map +1 -0
  198. package/dist/capabilities/ultimateSecurityCapability.d.ts +42 -0
  199. package/dist/capabilities/ultimateSecurityCapability.d.ts.map +1 -0
  200. package/dist/capabilities/ultimateSecurityCapability.js +96 -0
  201. package/dist/capabilities/ultimateSecurityCapability.js.map +1 -0
  202. package/dist/core/LazyLoader.d.ts +129 -0
  203. package/dist/core/LazyLoader.d.ts.map +1 -0
  204. package/dist/core/LazyLoader.js +240 -0
  205. package/dist/core/LazyLoader.js.map +1 -0
  206. package/dist/core/intelligenceTools.d.ts +19 -0
  207. package/dist/core/intelligenceTools.d.ts.map +1 -0
  208. package/dist/core/intelligenceTools.js +453 -0
  209. package/dist/core/intelligenceTools.js.map +1 -0
  210. package/dist/core/operationalTools.d.ts +19 -0
  211. package/dist/core/operationalTools.d.ts.map +1 -0
  212. package/dist/core/operationalTools.js +467 -0
  213. package/dist/core/operationalTools.js.map +1 -0
  214. package/dist/offensive/core/offensive-engine.d.ts +171 -0
  215. package/dist/offensive/core/offensive-engine.d.ts.map +1 -0
  216. package/dist/offensive/core/offensive-engine.js +345 -0
  217. package/dist/offensive/core/offensive-engine.js.map +1 -0
  218. package/dist/offensive/core/offensive-integration.d.ts +129 -0
  219. package/dist/offensive/core/offensive-integration.d.ts.map +1 -0
  220. package/dist/offensive/core/offensive-integration.js +364 -0
  221. package/dist/offensive/core/offensive-integration.js.map +1 -0
  222. package/dist/offensive/core/offensive-tools.d.ts +55 -0
  223. package/dist/offensive/core/offensive-tools.d.ts.map +1 -0
  224. package/dist/offensive/core/offensive-tools.js +438 -0
  225. package/dist/offensive/core/offensive-tools.js.map +1 -0
  226. package/dist/offensive/offensive-cli.d.ts +48 -0
  227. package/dist/offensive/offensive-cli.d.ts.map +1 -0
  228. package/dist/offensive/offensive-cli.js +233 -0
  229. package/dist/offensive/offensive-cli.js.map +1 -0
  230. package/dist/plugins/index.d.ts +1 -1
  231. package/dist/plugins/index.d.ts.map +1 -1
  232. package/dist/plugins/index.js +2 -0
  233. package/dist/plugins/index.js.map +1 -1
  234. package/dist/plugins/tools/cloud/cloudPlugin.d.ts +3 -0
  235. package/dist/plugins/tools/cloud/cloudPlugin.d.ts.map +1 -0
  236. package/dist/plugins/tools/cloud/cloudPlugin.js +14 -0
  237. package/dist/plugins/tools/cloud/cloudPlugin.js.map +1 -0
  238. package/dist/plugins/tools/nodeDefaults.d.ts.map +1 -1
  239. package/dist/plugins/tools/nodeDefaults.js +2 -0
  240. package/dist/plugins/tools/nodeDefaults.js.map +1 -1
  241. package/dist/security/advanced-persistence-research.d.ts +92 -0
  242. package/dist/security/advanced-persistence-research.d.ts.map +1 -0
  243. package/dist/security/advanced-persistence-research.js +195 -0
  244. package/dist/security/advanced-persistence-research.js.map +1 -0
  245. package/dist/security/apt-simulation-cli.d.ts +57 -0
  246. package/dist/security/apt-simulation-cli.d.ts.map +1 -0
  247. package/dist/security/apt-simulation-cli.js +278 -0
  248. package/dist/security/apt-simulation-cli.js.map +1 -0
  249. package/dist/security/apt-simulation-engine-complete.d.ts +97 -0
  250. package/dist/security/apt-simulation-engine-complete.d.ts.map +1 -0
  251. package/dist/security/apt-simulation-engine-complete.js +441 -0
  252. package/dist/security/apt-simulation-engine-complete.js.map +1 -0
  253. package/dist/security/apt-simulation-engine.d.ts +97 -0
  254. package/dist/security/apt-simulation-engine.d.ts.map +1 -0
  255. package/dist/security/apt-simulation-engine.js +441 -0
  256. package/dist/security/apt-simulation-engine.js.map +1 -0
  257. package/dist/security/assessment/vulnerabilityAssessment.d.ts +104 -0
  258. package/dist/security/assessment/vulnerabilityAssessment.d.ts.map +1 -0
  259. package/dist/security/assessment/vulnerabilityAssessment.js +315 -0
  260. package/dist/security/assessment/vulnerabilityAssessment.js.map +1 -0
  261. package/dist/security/authorization/securityAuthorization.d.ts +88 -0
  262. package/dist/security/authorization/securityAuthorization.d.ts.map +1 -0
  263. package/dist/security/authorization/securityAuthorization.js +172 -0
  264. package/dist/security/authorization/securityAuthorization.js.map +1 -0
  265. package/dist/security/authorization.d.ts +45 -0
  266. package/dist/security/authorization.d.ts.map +1 -0
  267. package/dist/security/authorization.js +128 -0
  268. package/dist/security/authorization.js.map +1 -0
  269. package/dist/security/comprehensive-security-research.d.ts +84 -0
  270. package/dist/security/comprehensive-security-research.d.ts.map +1 -0
  271. package/dist/security/comprehensive-security-research.js +211 -0
  272. package/dist/security/comprehensive-security-research.js.map +1 -0
  273. package/dist/security/offensive/exploitationEngine.d.ts +54 -0
  274. package/dist/security/offensive/exploitationEngine.d.ts.map +1 -0
  275. package/dist/security/offensive/exploitationEngine.js +263 -0
  276. package/dist/security/offensive/exploitationEngine.js.map +1 -0
  277. package/dist/security/persistence-analyzer.d.ts +56 -0
  278. package/dist/security/persistence-analyzer.d.ts.map +1 -0
  279. package/dist/security/persistence-analyzer.js +187 -0
  280. package/dist/security/persistence-analyzer.js.map +1 -0
  281. package/dist/security/persistence-cli.d.ts +36 -0
  282. package/dist/security/persistence-cli.d.ts.map +1 -0
  283. package/dist/security/persistence-cli.js +160 -0
  284. package/dist/security/persistence-cli.js.map +1 -0
  285. package/dist/security/persistence-research.d.ts +100 -0
  286. package/dist/security/persistence-research.d.ts.map +1 -0
  287. package/dist/security/persistence-research.js +372 -0
  288. package/dist/security/persistence-research.js.map +1 -0
  289. package/dist/security/real/networkExploitation.d.ts +92 -0
  290. package/dist/security/real/networkExploitation.d.ts.map +1 -0
  291. package/dist/security/real/networkExploitation.js +316 -0
  292. package/dist/security/real/networkExploitation.js.map +1 -0
  293. package/dist/security/real/persistenceImplementation.d.ts +62 -0
  294. package/dist/security/real/persistenceImplementation.d.ts.map +1 -0
  295. package/dist/security/real/persistenceImplementation.js +323 -0
  296. package/dist/security/real/persistenceImplementation.js.map +1 -0
  297. package/dist/security/real/vulnerabilityScanner.d.ts +73 -0
  298. package/dist/security/real/vulnerabilityScanner.d.ts.map +1 -0
  299. package/dist/security/real/vulnerabilityScanner.js +341 -0
  300. package/dist/security/real/vulnerabilityScanner.js.map +1 -0
  301. package/dist/security/research/persistenceResearch.d.ts +97 -0
  302. package/dist/security/research/persistenceResearch.d.ts.map +1 -0
  303. package/dist/security/research/persistenceResearch.js +282 -0
  304. package/dist/security/research/persistenceResearch.js.map +1 -0
  305. package/dist/security/security-testing-framework.d.ts +120 -0
  306. package/dist/security/security-testing-framework.d.ts.map +1 -0
  307. package/dist/security/security-testing-framework.js +372 -0
  308. package/dist/security/security-testing-framework.js.map +1 -0
  309. package/dist/security/simulation/attackSimulation.d.ts +93 -0
  310. package/dist/security/simulation/attackSimulation.d.ts.map +1 -0
  311. package/dist/security/simulation/attackSimulation.js +341 -0
  312. package/dist/security/simulation/attackSimulation.js.map +1 -0
  313. package/dist/shell/bracketedPasteManager.d.ts +76 -0
  314. package/dist/shell/bracketedPasteManager.d.ts.map +1 -1
  315. package/dist/shell/bracketedPasteManager.js +267 -9
  316. package/dist/shell/bracketedPasteManager.js.map +1 -1
  317. package/dist/shell/interactiveShell.d.ts +34 -1
  318. package/dist/shell/interactiveShell.d.ts.map +1 -1
  319. package/dist/shell/interactiveShell.js +304 -24
  320. package/dist/shell/interactiveShell.js.map +1 -1
  321. package/dist/shell/taskCompletionDetector.d.ts +101 -0
  322. package/dist/shell/taskCompletionDetector.d.ts.map +1 -0
  323. package/dist/shell/taskCompletionDetector.js +343 -0
  324. package/dist/shell/taskCompletionDetector.js.map +1 -0
  325. package/dist/tools/cloudTools.d.ts +57 -0
  326. package/dist/tools/cloudTools.d.ts.map +1 -0
  327. package/dist/tools/cloudTools.js +865 -0
  328. package/dist/tools/cloudTools.js.map +1 -0
  329. package/dist/tools/enhancedSecurityTools.d.ts +19 -0
  330. package/dist/tools/enhancedSecurityTools.d.ts.map +1 -0
  331. package/dist/tools/enhancedSecurityTools.js +215 -0
  332. package/dist/tools/enhancedSecurityTools.js.map +1 -0
  333. package/dist/tools/offensiveSecurityTools.d.ts +16 -0
  334. package/dist/tools/offensiveSecurityTools.d.ts.map +1 -0
  335. package/dist/tools/offensiveSecurityTools.js +285 -0
  336. package/dist/tools/offensiveSecurityTools.js.map +1 -0
  337. package/dist/tools/realSecurityTools.d.ts +18 -0
  338. package/dist/tools/realSecurityTools.d.ts.map +1 -0
  339. package/dist/tools/realSecurityTools.js +468 -0
  340. package/dist/tools/realSecurityTools.js.map +1 -0
  341. package/dist/tools/securityTools.d.ts +20 -0
  342. package/dist/tools/securityTools.d.ts.map +1 -0
  343. package/dist/tools/securityTools.js +449 -0
  344. package/dist/tools/securityTools.js.map +1 -0
  345. package/package.json +27 -12
  346. package/scripts/deploy-security-capabilities.js +178 -0
@@ -0,0 +1,92 @@
1
+ /**
2
+ * Real Network Exploitation Engine
3
+ *
4
+ * Actual network reconnaissance, scanning, and exploitation capabilities.
5
+ * Real tools for authorized penetration testing and security assessment.
6
+ *
7
+ * LEGAL NOTICE: For authorized security research and testing only.
8
+ */
9
+ export interface NetworkScan {
10
+ target: string;
11
+ openPorts: PortScanResult[];
12
+ services: ServiceInfo[];
13
+ vulnerabilities: NetworkVulnerability[];
14
+ }
15
+ export interface PortScanResult {
16
+ port: number;
17
+ state: 'open' | 'closed' | 'filtered';
18
+ service: string;
19
+ version?: string;
20
+ }
21
+ export interface ServiceInfo {
22
+ port: number;
23
+ protocol: string;
24
+ service: string;
25
+ banner?: string;
26
+ }
27
+ export interface NetworkVulnerability {
28
+ id: string;
29
+ name: string;
30
+ severity: 'critical' | 'high' | 'medium' | 'low';
31
+ description: string;
32
+ port: number;
33
+ exploitation: string;
34
+ }
35
+ export interface ExploitationAttempt {
36
+ vulnerabilityId: string;
37
+ target: string;
38
+ port: number;
39
+ success: boolean;
40
+ output: string;
41
+ evidence: string;
42
+ }
43
+ /**
44
+ * Real Network Exploitation Engine
45
+ */
46
+ export declare class RealNetworkExploitation {
47
+ /**
48
+ * Perform comprehensive network scan
49
+ */
50
+ scanNetwork(target: string): Promise<NetworkScan>;
51
+ /**
52
+ * Scan specific port
53
+ */
54
+ private scanPort;
55
+ /**
56
+ * Get service information
57
+ */
58
+ private getServiceInfo;
59
+ /**
60
+ * Check for port-specific vulnerabilities
61
+ */
62
+ private checkPortVulnerabilities;
63
+ /**
64
+ * Exploit SSH service
65
+ */
66
+ exploitSSH(target: string, username: string, password: string): Promise<ExploitationAttempt>;
67
+ /**
68
+ * Exploit FTP service
69
+ */
70
+ exploitFTP(target: string): Promise<ExploitationAttempt>;
71
+ /**
72
+ * Enumerate SMB shares
73
+ */
74
+ exploitSMB(target: string): Promise<ExploitationAttempt>;
75
+ /**
76
+ * Get HTTP banner
77
+ */
78
+ private getHttpBanner;
79
+ /**
80
+ * Get SSH banner
81
+ */
82
+ private getSshBanner;
83
+ /**
84
+ * Get service name by port
85
+ */
86
+ private getServiceByPort;
87
+ /**
88
+ * Generate network exploitation report
89
+ */
90
+ generateNetworkReport(scan: NetworkScan, exploits: ExploitationAttempt[]): string;
91
+ }
92
+ //# sourceMappingURL=networkExploitation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"networkExploitation.d.ts","sourceRoot":"","sources":["../../../src/security/real/networkExploitation.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAKH,MAAM,WAAW,WAAW;IAC1B,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,cAAc,EAAE,CAAC;IAC5B,QAAQ,EAAE,WAAW,EAAE,CAAC;IACxB,eAAe,EAAE,oBAAoB,EAAE,CAAC;CACzC;AAED,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,GAAG,QAAQ,GAAG,UAAU,CAAC;IACtC,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,oBAAoB;IACnC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,UAAU,GAAG,MAAM,GAAG,QAAQ,GAAG,KAAK,CAAC;IACjD,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,mBAAmB;IAClC,eAAe,EAAE,MAAM,CAAC;IACxB,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,OAAO,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED;;GAEG;AACH,qBAAa,uBAAuB;IAElC;;OAEG;IACG,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC;IAkCvD;;OAEG;YACW,QAAQ;IAsBtB;;OAEG;YACW,cAAc;IA2B5B;;OAEG;YACW,wBAAwB;IAmDtC;;OAEG;IACG,UAAU,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,mBAAmB,CAAC;IA0BlG;;OAEG;IACG,UAAU,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,mBAAmB,CAAC;IA0B9D;;OAEG;IACG,UAAU,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,mBAAmB,CAAC;IA0B9D;;OAEG;YACW,aAAa;IAU3B;;OAEG;YACW,YAAY;IAS1B;;OAEG;IACH,OAAO,CAAC,gBAAgB;IA2BxB;;OAEG;IACH,qBAAqB,CAAC,IAAI,EAAE,WAAW,EAAE,QAAQ,EAAE,mBAAmB,EAAE,GAAG,MAAM;CAmClF"}
@@ -0,0 +1,316 @@
1
+ /**
2
+ * Real Network Exploitation Engine
3
+ *
4
+ * Actual network reconnaissance, scanning, and exploitation capabilities.
5
+ * Real tools for authorized penetration testing and security assessment.
6
+ *
7
+ * LEGAL NOTICE: For authorized security research and testing only.
8
+ */
9
+ import { execSync } from 'child_process';
10
+ /**
11
+ * Real Network Exploitation Engine
12
+ */
13
+ export class RealNetworkExploitation {
14
+ /**
15
+ * Perform comprehensive network scan
16
+ */
17
+ async scanNetwork(target) {
18
+ const scan = {
19
+ target,
20
+ openPorts: [],
21
+ services: [],
22
+ vulnerabilities: []
23
+ };
24
+ try {
25
+ // Scan common ports
26
+ const commonPorts = [21, 22, 23, 25, 53, 80, 110, 135, 139, 143, 443, 445, 993, 995, 1433, 3306, 3389, 5432, 5900, 6379];
27
+ for (const port of commonPorts) {
28
+ const portResult = await this.scanPort(target, port);
29
+ if (portResult.state === 'open') {
30
+ scan.openPorts.push(portResult);
31
+ // Get service information
32
+ const serviceInfo = await this.getServiceInfo(target, port);
33
+ scan.services.push(serviceInfo);
34
+ // Check for vulnerabilities
35
+ const vulns = await this.checkPortVulnerabilities(target, port, serviceInfo.service);
36
+ scan.vulnerabilities.push(...vulns);
37
+ }
38
+ }
39
+ }
40
+ catch (error) {
41
+ console.error('Network scan error:', error);
42
+ }
43
+ return scan;
44
+ }
45
+ /**
46
+ * Scan specific port
47
+ */
48
+ async scanPort(target, port) {
49
+ try {
50
+ // Use system tools for port scanning
51
+ const command = `timeout 2 bash -c "echo > /dev/tcp/${target}/${port}" 2>/dev/null && echo 'open' || echo 'closed'`;
52
+ const result = execSync(command, { encoding: 'utf8' }).trim();
53
+ const service = this.getServiceByPort(port);
54
+ return {
55
+ port,
56
+ state: result === 'open' ? 'open' : 'closed',
57
+ service
58
+ };
59
+ }
60
+ catch (error) {
61
+ return {
62
+ port,
63
+ state: 'closed',
64
+ service: 'unknown'
65
+ };
66
+ }
67
+ }
68
+ /**
69
+ * Get service information
70
+ */
71
+ async getServiceInfo(target, port) {
72
+ const service = this.getServiceByPort(port);
73
+ try {
74
+ // Attempt to get service banner
75
+ let banner = '';
76
+ if (port === 80 || port === 443) {
77
+ banner = await this.getHttpBanner(target, port);
78
+ }
79
+ else if (port === 22) {
80
+ banner = await this.getSshBanner(target);
81
+ }
82
+ return {
83
+ port,
84
+ protocol: port === 443 ? 'https' : 'tcp',
85
+ service,
86
+ banner
87
+ };
88
+ }
89
+ catch (error) {
90
+ return {
91
+ port,
92
+ protocol: 'tcp',
93
+ service
94
+ };
95
+ }
96
+ }
97
+ /**
98
+ * Check for port-specific vulnerabilities
99
+ */
100
+ async checkPortVulnerabilities(target, port, service) {
101
+ const vulnerabilities = [];
102
+ // Common vulnerability checks
103
+ if (port === 22 && service === 'ssh') {
104
+ vulnerabilities.push({
105
+ id: 'ssh-weak-auth',
106
+ name: 'SSH Weak Authentication',
107
+ severity: 'high',
108
+ description: 'SSH service may allow weak authentication methods',
109
+ port,
110
+ exploitation: 'Brute force or weak credential attacks'
111
+ });
112
+ }
113
+ if (port === 21 && service === 'ftp') {
114
+ vulnerabilities.push({
115
+ id: 'ftp-anonymous',
116
+ name: 'FTP Anonymous Access',
117
+ severity: 'medium',
118
+ description: 'FTP service may allow anonymous access',
119
+ port,
120
+ exploitation: 'Anonymous login and file access'
121
+ });
122
+ }
123
+ if (port === 445 && service === 'smb') {
124
+ vulnerabilities.push({
125
+ id: 'smb-share',
126
+ name: 'SMB Share Discovery',
127
+ severity: 'medium',
128
+ description: 'SMB service may expose network shares',
129
+ port,
130
+ exploitation: 'Share enumeration and access'
131
+ });
132
+ }
133
+ if ((port === 80 || port === 443) && service === 'http') {
134
+ vulnerabilities.push({
135
+ id: 'web-app',
136
+ name: 'Web Application',
137
+ severity: 'medium',
138
+ description: 'Web service detected - potential application vulnerabilities',
139
+ port,
140
+ exploitation: 'Web application testing and exploitation'
141
+ });
142
+ }
143
+ return vulnerabilities;
144
+ }
145
+ /**
146
+ * Exploit SSH service
147
+ */
148
+ async exploitSSH(target, username, password) {
149
+ try {
150
+ // Attempt SSH connection
151
+ const command = `sshpass -p '${password}' ssh -o StrictHostKeyChecking=no ${username}@${target} 'echo "SSH access successful"'`;
152
+ const output = execSync(command, { encoding: 'utf8', stdio: 'pipe' });
153
+ return {
154
+ vulnerabilityId: 'ssh-weak-auth',
155
+ target,
156
+ port: 22,
157
+ success: true,
158
+ output: 'SSH access obtained',
159
+ evidence: output
160
+ };
161
+ }
162
+ catch (error) {
163
+ return {
164
+ vulnerabilityId: 'ssh-weak-auth',
165
+ target,
166
+ port: 22,
167
+ success: false,
168
+ output: `SSH exploitation failed: ${error}`,
169
+ evidence: ''
170
+ };
171
+ }
172
+ }
173
+ /**
174
+ * Exploit FTP service
175
+ */
176
+ async exploitFTP(target) {
177
+ try {
178
+ // Attempt anonymous FTP login
179
+ const command = `curl -s ftp://${target}/ --user anonymous:anonymous`;
180
+ const output = execSync(command, { encoding: 'utf8', stdio: 'pipe' });
181
+ return {
182
+ vulnerabilityId: 'ftp-anonymous',
183
+ target,
184
+ port: 21,
185
+ success: output.length > 0,
186
+ output: output.length > 0 ? 'Anonymous FTP access possible' : 'Anonymous access denied',
187
+ evidence: output
188
+ };
189
+ }
190
+ catch (error) {
191
+ return {
192
+ vulnerabilityId: 'ftp-anonymous',
193
+ target,
194
+ port: 21,
195
+ success: false,
196
+ output: `FTP exploitation failed: ${error}`,
197
+ evidence: ''
198
+ };
199
+ }
200
+ }
201
+ /**
202
+ * Enumerate SMB shares
203
+ */
204
+ async exploitSMB(target) {
205
+ try {
206
+ // Attempt SMB share enumeration
207
+ const command = `smbclient -L //${target} -N`;
208
+ const output = execSync(command, { encoding: 'utf8', stdio: 'pipe' });
209
+ return {
210
+ vulnerabilityId: 'smb-share',
211
+ target,
212
+ port: 445,
213
+ success: output.includes('Sharename'),
214
+ output: output.includes('Sharename') ? 'SMB shares enumerated' : 'No shares found',
215
+ evidence: output
216
+ };
217
+ }
218
+ catch (error) {
219
+ return {
220
+ vulnerabilityId: 'smb-share',
221
+ target,
222
+ port: 445,
223
+ success: false,
224
+ output: `SMB exploitation failed: ${error}`,
225
+ evidence: ''
226
+ };
227
+ }
228
+ }
229
+ /**
230
+ * Get HTTP banner
231
+ */
232
+ async getHttpBanner(target, port) {
233
+ try {
234
+ const protocol = port === 443 ? 'https' : 'http';
235
+ const command = `curl -s -I ${protocol}://${target} | head -n 10`;
236
+ return execSync(command, { encoding: 'utf8' });
237
+ }
238
+ catch (error) {
239
+ return '';
240
+ }
241
+ }
242
+ /**
243
+ * Get SSH banner
244
+ */
245
+ async getSshBanner(target) {
246
+ try {
247
+ const command = `timeout 2 ssh -o StrictHostKeyChecking=no -o ConnectTimeout=2 ${target} 'exit' 2>&1 | head -n 5`;
248
+ return execSync(command, { encoding: 'utf8' });
249
+ }
250
+ catch (error) {
251
+ return '';
252
+ }
253
+ }
254
+ /**
255
+ * Get service name by port
256
+ */
257
+ getServiceByPort(port) {
258
+ const serviceMap = {
259
+ 21: 'ftp',
260
+ 22: 'ssh',
261
+ 23: 'telnet',
262
+ 25: 'smtp',
263
+ 53: 'dns',
264
+ 80: 'http',
265
+ 110: 'pop3',
266
+ 135: 'rpc',
267
+ 139: 'netbios',
268
+ 143: 'imap',
269
+ 443: 'https',
270
+ 445: 'smb',
271
+ 993: 'imaps',
272
+ 995: 'pop3s',
273
+ 1433: 'mssql',
274
+ 3306: 'mysql',
275
+ 3389: 'rdp',
276
+ 5432: 'postgresql',
277
+ 5900: 'vnc',
278
+ 6379: 'redis'
279
+ };
280
+ return serviceMap[port] || 'unknown';
281
+ }
282
+ /**
283
+ * Generate network exploitation report
284
+ */
285
+ generateNetworkReport(scan, exploits) {
286
+ let report = 'NETWORK EXPLOITATION REPORT\n';
287
+ report += '='.repeat(50) + '\n\n';
288
+ report += `Target: ${scan.target}\n`;
289
+ report += `Scan Date: ${new Date().toISOString()}\n\n`;
290
+ report += 'OPEN PORTS:\n';
291
+ report += '-'.repeat(30) + '\n';
292
+ scan.openPorts.forEach(port => {
293
+ report += `${port.port}/tcp ${port.state} ${port.service}\n`;
294
+ });
295
+ report += '\nVULNERABILITIES:\n';
296
+ report += '-'.repeat(30) + '\n';
297
+ scan.vulnerabilities.forEach(vuln => {
298
+ report += `\n${vuln.name} (${vuln.severity.toUpperCase()})\n`;
299
+ report += `Port: ${vuln.port}\n`;
300
+ report += `Description: ${vuln.description}\n`;
301
+ report += `Exploitation: ${vuln.exploitation}\n`;
302
+ });
303
+ report += '\nEXPLOITATION ATTEMPTS:\n';
304
+ report += '-'.repeat(30) + '\n';
305
+ exploits.forEach(exploit => {
306
+ report += `\n${exploit.vulnerabilityId} (Port ${exploit.port})\n`;
307
+ report += `Success: ${exploit.success ? 'YES' : 'NO'}\n`;
308
+ report += `Output: ${exploit.output}\n`;
309
+ if (exploit.evidence) {
310
+ report += `Evidence: ${exploit.evidence.substring(0, 200)}...\n`;
311
+ }
312
+ });
313
+ return report;
314
+ }
315
+ }
316
+ //# sourceMappingURL=networkExploitation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"networkExploitation.js","sourceRoot":"","sources":["../../../src/security/real/networkExploitation.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,QAAQ,EAAS,MAAM,eAAe,CAAC;AA0ChD;;GAEG;AACH,MAAM,OAAO,uBAAuB;IAElC;;OAEG;IACH,KAAK,CAAC,WAAW,CAAC,MAAc;QAC9B,MAAM,IAAI,GAAgB;YACxB,MAAM;YACN,SAAS,EAAE,EAAE;YACb,QAAQ,EAAE,EAAE;YACZ,eAAe,EAAE,EAAE;SACpB,CAAC;QAEF,IAAI,CAAC;YACH,oBAAoB;YACpB,MAAM,WAAW,GAAG,CAAC,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;YAEzH,KAAK,MAAM,IAAI,IAAI,WAAW,EAAE,CAAC;gBAC/B,MAAM,UAAU,GAAG,MAAM,IAAI,CAAC,QAAQ,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;gBACrD,IAAI,UAAU,CAAC,KAAK,KAAK,MAAM,EAAE,CAAC;oBAChC,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;oBAEhC,0BAA0B;oBAC1B,MAAM,WAAW,GAAG,MAAM,IAAI,CAAC,cAAc,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;o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,IAAI,KAAK,IAAI,CAAC,IAAI,KAAK,IAAI,CAAC,QAAQ,CAAC,WAAW,EAAE,KAAK,CAAC;YAC9D,MAAM,IAAI,SAAS,IAAI,CAAC,IAAI,IAAI,CAAC;YACjC,MAAM,IAAI,gBAAgB,IAAI,CAAC,WAAW,IAAI,CAAC;YAC/C,MAAM,IAAI,iBAAiB,IAAI,CAAC,YAAY,IAAI,CAAC;QACnD,CAAC,CAAC,CAAC;QAEH,MAAM,IAAI,4BAA4B,CAAC;QACvC,MAAM,IAAI,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC;QAChC,QAAQ,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE;YACzB,MAAM,IAAI,KAAK,OAAO,CAAC,eAAe,UAAU,OAAO,CAAC,IAAI,KAAK,CAAC;YAClE,MAAM,IAAI,YAAY,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC;YACzD,MAAM,IAAI,WAAW,OAAO,CAAC,MAAM,IAAI,CAAC;YACxC,IAAI,OAAO,CAAC,QAAQ,EAAE,CAAC;gBACrB,MAAM,IAAI,aAAa,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC,EAAE,GAAG,CAAC,OAAO,CAAC;YACnE,CAAC;QACH,CAAC,CAAC,CAAC;QAEH,OAAO,MAAM,CAAC;IAChB,CAAC;CACF"}
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Real Persistence Implementation Engine
3
+ *
4
+ * Actual persistence mechanisms for Windows, Linux, cloud platforms, and containers.
5
+ * These are real techniques used in authorized security testing and red team operations.
6
+ *
7
+ * LEGAL NOTICE: For authorized security research and testing only.
8
+ */
9
+ export interface PersistenceImplementation {
10
+ id: string;
11
+ name: string;
12
+ platform: string;
13
+ implement: () => Promise<{
14
+ success: boolean;
15
+ output: string;
16
+ }>;
17
+ detect: () => Promise<{
18
+ detected: boolean;
19
+ evidence: string;
20
+ }>;
21
+ remove: () => Promise<{
22
+ success: boolean;
23
+ output: string;
24
+ }>;
25
+ }
26
+ /**
27
+ * Real Persistence Implementation Engine
28
+ */
29
+ export declare class RealPersistenceEngine {
30
+ private implementations;
31
+ constructor();
32
+ /**
33
+ * Implement persistence mechanism
34
+ */
35
+ implementPersistence(techniqueId: string): Promise<{
36
+ success: boolean;
37
+ output: string;
38
+ }>;
39
+ /**
40
+ * Detect persistence mechanism
41
+ */
42
+ detectPersistence(techniqueId: string): Promise<{
43
+ detected: boolean;
44
+ evidence: string;
45
+ }>;
46
+ /**
47
+ * Remove persistence mechanism
48
+ */
49
+ removePersistence(techniqueId: string): Promise<{
50
+ success: boolean;
51
+ output: string;
52
+ }>;
53
+ /**
54
+ * Get available implementations for current platform
55
+ */
56
+ getAvailableImplementations(): PersistenceImplementation[];
57
+ /**
58
+ * Initialize real persistence implementations
59
+ */
60
+ private initializeImplementations;
61
+ }
62
+ //# sourceMappingURL=persistenceImplementation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"persistenceImplementation.d.ts","sourceRoot":"","sources":["../../../src/security/real/persistenceImplementation.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAMH,MAAM,WAAW,yBAAyB;IACxC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,OAAO,CAAC;QAAE,OAAO,EAAE,OAAO,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAC/D,MAAM,EAAE,MAAM,OAAO,CAAC;QAAE,QAAQ,EAAE,OAAO,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAC/D,MAAM,EAAE,MAAM,OAAO,CAAC;QAAE,OAAO,EAAE,OAAO,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CAC7D;AAED;;GAEG;AACH,qBAAa,qBAAqB;IAChC,OAAO,CAAC,eAAe,CAAyC;;IAOhE;;OAEG;IACG,oBAAoB,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,OAAO,EAAE,OAAO,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC;IAa9F;;OAEG;IACG,iBAAiB,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,QAAQ,EAAE,OAAO,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAE,CAAC;IAa9F;;OAEG;IACG,iBAAiB,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,OAAO,EAAE,OAAO,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC;IAa3F;;OAEG;IACH,2BAA2B,IAAI,yBAAyB,EAAE;IAO1D;;OAEG;IACH,OAAO,CAAC,yBAAyB;CA+PlC"}