thuban 0.4.10 → 0.4.12

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 (1531) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +437 -437
  3. package/dist/LICENSE +21 -0
  4. package/dist/README.md +437 -0
  5. package/dist/cli.js +2 -0
  6. package/dist/package.json +63 -0
  7. package/dist/packages/crucible/.golden/golden-master.json +414 -0
  8. package/dist/packages/crucible/report-generator.js +1 -0
  9. package/dist/packages/crucible/rules/code-scanner-core.json +303 -0
  10. package/dist/packages/crucible/rules/command-injection.json +411 -0
  11. package/dist/packages/crucible/rules/crypto-misuse.json +35 -0
  12. package/dist/packages/crucible/rules/deserialization.json +152 -0
  13. package/dist/packages/crucible/rules/env-injection.json +46 -0
  14. package/dist/packages/crucible/rules/eval-abuse.json +104 -0
  15. package/dist/packages/crucible/rules/file-upload.json +46 -0
  16. package/dist/packages/crucible/rules/hallucination.json +22 -0
  17. package/dist/packages/crucible/rules/hardcoded-secret.json +397 -0
  18. package/dist/packages/crucible/rules/hardcoded-url.json +13 -0
  19. package/dist/packages/crucible/rules/insecure-crypto.json +302 -0
  20. package/dist/packages/crucible/rules/integer-overflow.json +35 -0
  21. package/dist/packages/crucible/rules/log-injection.json +33 -0
  22. package/dist/packages/crucible/rules/mass-assignment.json +112 -0
  23. package/dist/packages/crucible/rules/open-redirect.json +196 -0
  24. package/dist/packages/crucible/rules/path-traversal.json +422 -0
  25. package/dist/packages/crucible/rules/prototype-pollution.json +22 -0
  26. package/dist/packages/crucible/rules/sql-injection.json +619 -0
  27. package/dist/packages/crucible/rules/ssrf.json +557 -0
  28. package/dist/packages/crucible/rules/timing-attack.json +55 -0
  29. package/dist/packages/crucible/rules/unsafe-block.json +24 -0
  30. package/dist/packages/crucible/rules/xss.json +663 -0
  31. package/dist/packages/crucible/rules/xxe.json +66 -0
  32. package/dist/packages/crucible/rules/yaml-deserialization.json +22 -0
  33. package/dist/packages/crucible/rules/yaml-injection.json +22 -0
  34. package/dist/packages/crucible/seeds/csharp/seed-001.cs +28 -0
  35. package/dist/packages/crucible/seeds/csharp/seed-002.cs +24 -0
  36. package/dist/packages/crucible/seeds/csharp/seed-003.cs +30 -0
  37. package/dist/packages/crucible/seeds/csharp/seed-004.cs +31 -0
  38. package/dist/packages/crucible/seeds/csharp/seed-005.cs +28 -0
  39. package/dist/packages/crucible/seeds/csharp/seed-006.cs +25 -0
  40. package/dist/packages/crucible/seeds/csharp/seed-007.cs +34 -0
  41. package/dist/packages/crucible/seeds/csharp/seed-008.cs +23 -0
  42. package/dist/packages/crucible/seeds/csharp/seed-009.cs +27 -0
  43. package/dist/packages/crucible/seeds/csharp/seed-010.cs +29 -0
  44. package/dist/packages/crucible/seeds/csharp/seed-011.cs +32 -0
  45. package/dist/packages/crucible/seeds/csharp/seed-012.cs +27 -0
  46. package/dist/packages/crucible/seeds/csharp/seed-013.cs +27 -0
  47. package/dist/packages/crucible/seeds/csharp/seed-014.cs +26 -0
  48. package/dist/packages/crucible/seeds/csharp/seed-015.cs +33 -0
  49. package/dist/packages/crucible/seeds/csharp/seed-016.cs +25 -0
  50. package/dist/packages/crucible/seeds/csharp/seed-017.cs +22 -0
  51. package/dist/packages/crucible/seeds/csharp/seed-018.cs +26 -0
  52. package/dist/packages/crucible/seeds/csharp/seed-019.cs +25 -0
  53. package/dist/packages/crucible/seeds/csharp/seed-020.cs +22 -0
  54. package/dist/packages/crucible/seeds/csharp/seed-021.cs +28 -0
  55. package/dist/packages/crucible/seeds/csharp/seed-022.cs +25 -0
  56. package/dist/packages/crucible/seeds/csharp/seed-023.cs +33 -0
  57. package/dist/packages/crucible/seeds/csharp/seed-024.cs +31 -0
  58. package/dist/packages/crucible/seeds/csharp/seed-025.cs +31 -0
  59. package/dist/packages/crucible/seeds/csharp/seed-026.cs +25 -0
  60. package/dist/packages/crucible/seeds/csharp/seed-027.cs +29 -0
  61. package/dist/packages/crucible/seeds/csharp/seed-028.cs +25 -0
  62. package/dist/packages/crucible/seeds/csharp/seed-029.cs +27 -0
  63. package/dist/packages/crucible/seeds/csharp/seed-030.cs +27 -0
  64. package/dist/packages/crucible/seeds/csharp/seed-031.cs +28 -0
  65. package/dist/packages/crucible/seeds/csharp/seed-032.cs +30 -0
  66. package/dist/packages/crucible/seeds/csharp/seed-033.cs +27 -0
  67. package/dist/packages/crucible/seeds/csharp/seed-034.cs +25 -0
  68. package/dist/packages/crucible/seeds/csharp/seed-035.cs +32 -0
  69. package/dist/packages/crucible/seeds/csharp/seed-036.cs +28 -0
  70. package/dist/packages/crucible/seeds/csharp/seed-037.cs +29 -0
  71. package/dist/packages/crucible/seeds/csharp/seed-038.cs +28 -0
  72. package/dist/packages/crucible/seeds/csharp/seed-039.cs +29 -0
  73. package/dist/packages/crucible/seeds/csharp/seed-040.cs +28 -0
  74. package/dist/packages/crucible/seeds/csharp/seed-041.cs +33 -0
  75. package/dist/packages/crucible/seeds/csharp/seed-042.cs +27 -0
  76. package/dist/packages/crucible/seeds/csharp/seed-043.cs +27 -0
  77. package/dist/packages/crucible/seeds/csharp/seed-044.cs +25 -0
  78. package/dist/packages/crucible/seeds/csharp/seed-045.cs +30 -0
  79. package/dist/packages/crucible/seeds/csharp/seed-046.cs +29 -0
  80. package/dist/packages/crucible/seeds/csharp/seed-047.cs +26 -0
  81. package/dist/packages/crucible/seeds/csharp/seed-048.cs +31 -0
  82. package/dist/packages/crucible/seeds/csharp/seed-049.cs +27 -0
  83. package/dist/packages/crucible/seeds/csharp/seed-050.cs +30 -0
  84. package/dist/packages/crucible/seeds/csharp/seed-051.cs +34 -0
  85. package/dist/packages/crucible/seeds/csharp/seed-052.cs +36 -0
  86. package/dist/packages/crucible/seeds/go/seed-001.go +29 -0
  87. package/dist/packages/crucible/seeds/go/seed-002.go +27 -0
  88. package/dist/packages/crucible/seeds/go/seed-003.go +31 -0
  89. package/dist/packages/crucible/seeds/go/seed-004.go +27 -0
  90. package/dist/packages/crucible/seeds/go/seed-005.go +27 -0
  91. package/dist/packages/crucible/seeds/go/seed-006.go +29 -0
  92. package/dist/packages/crucible/seeds/go/seed-007.go +24 -0
  93. package/dist/packages/crucible/seeds/go/seed-008.go +25 -0
  94. package/dist/packages/crucible/seeds/go/seed-009.go +30 -0
  95. package/dist/packages/crucible/seeds/go/seed-010.go +35 -0
  96. package/dist/packages/crucible/seeds/go/seed-011.go +24 -0
  97. package/dist/packages/crucible/seeds/go/seed-012.go +24 -0
  98. package/dist/packages/crucible/seeds/go/seed-013.go +31 -0
  99. package/dist/packages/crucible/seeds/go/seed-014.go +35 -0
  100. package/dist/packages/crucible/seeds/go/seed-015.go +25 -0
  101. package/dist/packages/crucible/seeds/go/seed-016.go +19 -0
  102. package/dist/packages/crucible/seeds/go/seed-017.go +23 -0
  103. package/dist/packages/crucible/seeds/go/seed-018.go +23 -0
  104. package/dist/packages/crucible/seeds/go/seed-019.go +22 -0
  105. package/dist/packages/crucible/seeds/go/seed-020.go +31 -0
  106. package/dist/packages/crucible/seeds/go/seed-021.go +22 -0
  107. package/dist/packages/crucible/seeds/go/seed-022.go +29 -0
  108. package/dist/packages/crucible/seeds/go/seed-023.go +26 -0
  109. package/dist/packages/crucible/seeds/go/seed-024.go +27 -0
  110. package/dist/packages/crucible/seeds/go/seed-025.go +23 -0
  111. package/dist/packages/crucible/seeds/go/seed-026.go +29 -0
  112. package/dist/packages/crucible/seeds/go/seed-027.go +26 -0
  113. package/dist/packages/crucible/seeds/go/seed-028.go +23 -0
  114. package/dist/packages/crucible/seeds/go/seed-029.go +28 -0
  115. package/dist/packages/crucible/seeds/go/seed-030.go +27 -0
  116. package/dist/packages/crucible/seeds/go/seed-031.go +28 -0
  117. package/dist/packages/crucible/seeds/go/seed-032.go +27 -0
  118. package/dist/packages/crucible/seeds/go/seed-033.go +29 -0
  119. package/dist/packages/crucible/seeds/go/seed-034.go +22 -0
  120. package/dist/packages/crucible/seeds/go/seed-035.go +32 -0
  121. package/dist/packages/crucible/seeds/go/seed-036.go +27 -0
  122. package/dist/packages/crucible/seeds/go/seed-037.go +27 -0
  123. package/dist/packages/crucible/seeds/go/seed-038.go +27 -0
  124. package/dist/packages/crucible/seeds/go/seed-039.go +26 -0
  125. package/dist/packages/crucible/seeds/go/seed-040.go +37 -0
  126. package/dist/packages/crucible/seeds/go/seed-041.go +23 -0
  127. package/dist/packages/crucible/seeds/go/seed-042.go +32 -0
  128. package/dist/packages/crucible/seeds/go/seed-043.go +35 -0
  129. package/dist/packages/crucible/seeds/go/seed-044.go +25 -0
  130. package/dist/packages/crucible/seeds/go/seed-045.go +26 -0
  131. package/dist/packages/crucible/seeds/go/seed-046.go +34 -0
  132. package/dist/packages/crucible/seeds/go/seed-047.go +26 -0
  133. package/dist/packages/crucible/seeds/go/seed-048.go +29 -0
  134. package/dist/packages/crucible/seeds/go/seed-049.go +24 -0
  135. package/dist/packages/crucible/seeds/go/seed-050.go +27 -0
  136. package/dist/packages/crucible/seeds/go/seed-051.go +38 -0
  137. package/dist/packages/crucible/seeds/go/seed-052.go +27 -0
  138. package/dist/packages/crucible/seeds/java/seed-001.java +23 -0
  139. package/dist/packages/crucible/seeds/java/seed-002.java +22 -0
  140. package/dist/packages/crucible/seeds/java/seed-003.java +28 -0
  141. package/dist/packages/crucible/seeds/java/seed-004.java +26 -0
  142. package/dist/packages/crucible/seeds/java/seed-005.java +33 -0
  143. package/dist/packages/crucible/seeds/java/seed-006.java +22 -0
  144. package/dist/packages/crucible/seeds/java/seed-007.java +21 -0
  145. package/dist/packages/crucible/seeds/java/seed-008.java +29 -0
  146. package/dist/packages/crucible/seeds/java/seed-009.java +24 -0
  147. package/dist/packages/crucible/seeds/java/seed-010.java +30 -0
  148. package/dist/packages/crucible/seeds/java/seed-011.java +25 -0
  149. package/dist/packages/crucible/seeds/java/seed-012.java +20 -0
  150. package/dist/packages/crucible/seeds/java/seed-013.java +26 -0
  151. package/dist/packages/crucible/seeds/java/seed-014.java +23 -0
  152. package/dist/packages/crucible/seeds/java/seed-015.java +25 -0
  153. package/dist/packages/crucible/seeds/java/seed-016.java +22 -0
  154. package/dist/packages/crucible/seeds/java/seed-017.java +24 -0
  155. package/dist/packages/crucible/seeds/java/seed-018.java +24 -0
  156. package/dist/packages/crucible/seeds/java/seed-019.java +38 -0
  157. package/dist/packages/crucible/seeds/java/seed-020.java +24 -0
  158. package/dist/packages/crucible/seeds/java/seed-021.java +22 -0
  159. package/dist/packages/crucible/seeds/java/seed-022.java +22 -0
  160. package/dist/packages/crucible/seeds/java/seed-023.java +22 -0
  161. package/dist/packages/crucible/seeds/java/seed-024.java +25 -0
  162. package/dist/packages/crucible/seeds/java/seed-025.java +27 -0
  163. package/dist/packages/crucible/seeds/java/seed-026.java +25 -0
  164. package/dist/packages/crucible/seeds/java/seed-027.java +22 -0
  165. package/dist/packages/crucible/seeds/java/seed-028.java +21 -0
  166. package/dist/packages/crucible/seeds/java/seed-029.java +28 -0
  167. package/dist/packages/crucible/seeds/java/seed-030.java +27 -0
  168. package/dist/packages/crucible/seeds/java/seed-031.java +23 -0
  169. package/dist/packages/crucible/seeds/java/seed-032.java +22 -0
  170. package/dist/packages/crucible/seeds/java/seed-033.java +24 -0
  171. package/dist/packages/crucible/seeds/java/seed-034.java +24 -0
  172. package/dist/packages/crucible/seeds/java/seed-035.java +29 -0
  173. package/dist/packages/crucible/seeds/java/seed-036.java +25 -0
  174. package/dist/packages/crucible/seeds/java/seed-037.java +30 -0
  175. package/dist/packages/crucible/seeds/java/seed-038.java +29 -0
  176. package/dist/packages/crucible/seeds/java/seed-039.java +26 -0
  177. package/dist/packages/crucible/seeds/java/seed-040.java +31 -0
  178. package/dist/packages/crucible/seeds/java/seed-041.java +20 -0
  179. package/dist/packages/crucible/seeds/java/seed-042.java +26 -0
  180. package/dist/packages/crucible/seeds/java/seed-043.java +31 -0
  181. package/dist/packages/crucible/seeds/java/seed-044.java +22 -0
  182. package/dist/packages/crucible/seeds/java/seed-045.java +25 -0
  183. package/dist/packages/crucible/seeds/java/seed-046.java +22 -0
  184. package/dist/packages/crucible/seeds/java/seed-047.java +26 -0
  185. package/dist/packages/crucible/seeds/java/seed-048.java +24 -0
  186. package/dist/packages/crucible/seeds/java/seed-049.java +28 -0
  187. package/dist/packages/crucible/seeds/java/seed-050.java +29 -0
  188. package/dist/packages/crucible/seeds/java/seed-051.java +25 -0
  189. package/dist/packages/crucible/seeds/java/seed-052.java +32 -0
  190. package/dist/packages/crucible/seeds/js/seed-001.js +27 -0
  191. package/dist/packages/crucible/seeds/js/seed-002.js +28 -0
  192. package/dist/packages/crucible/seeds/js/seed-003.js +30 -0
  193. package/dist/packages/crucible/seeds/js/seed-004.js +28 -0
  194. package/dist/packages/crucible/seeds/js/seed-005.js +31 -0
  195. package/dist/packages/crucible/seeds/js/seed-006.js +28 -0
  196. package/dist/packages/crucible/seeds/js/seed-007.js +26 -0
  197. package/dist/packages/crucible/seeds/js/seed-008.js +30 -0
  198. package/dist/packages/crucible/seeds/js/seed-009.js +30 -0
  199. package/dist/packages/crucible/seeds/js/seed-010.js +29 -0
  200. package/dist/packages/crucible/seeds/js/seed-011.js +34 -0
  201. package/dist/packages/crucible/seeds/js/seed-012.js +32 -0
  202. package/dist/packages/crucible/seeds/js/seed-013.js +29 -0
  203. package/dist/packages/crucible/seeds/js/seed-014.js +29 -0
  204. package/dist/packages/crucible/seeds/js/seed-015.js +31 -0
  205. package/dist/packages/crucible/seeds/js/seed-016.js +31 -0
  206. package/dist/packages/crucible/seeds/js/seed-017.js +30 -0
  207. package/dist/packages/crucible/seeds/js/seed-018.js +29 -0
  208. package/dist/packages/crucible/seeds/js/seed-019.js +32 -0
  209. package/dist/packages/crucible/seeds/js/seed-020.js +29 -0
  210. package/dist/packages/crucible/seeds/js/seed-021.js +31 -0
  211. package/dist/packages/crucible/seeds/js/seed-022.js +31 -0
  212. package/dist/packages/crucible/seeds/js/seed-023.js +29 -0
  213. package/dist/packages/crucible/seeds/js/seed-024.js +29 -0
  214. package/dist/packages/crucible/seeds/js/seed-025.js +34 -0
  215. package/dist/packages/crucible/seeds/js/seed-026.js +31 -0
  216. package/dist/packages/crucible/seeds/js/seed-027.js +31 -0
  217. package/dist/packages/crucible/seeds/js/seed-028.js +33 -0
  218. package/dist/packages/crucible/seeds/js/seed-029.js +33 -0
  219. package/dist/packages/crucible/seeds/js/seed-030.js +30 -0
  220. package/dist/packages/crucible/seeds/js/seed-031.js +31 -0
  221. package/dist/packages/crucible/seeds/js/seed-032.js +34 -0
  222. package/dist/packages/crucible/seeds/js/seed-033.js +33 -0
  223. package/dist/packages/crucible/seeds/js/seed-034.js +33 -0
  224. package/dist/packages/crucible/seeds/js/seed-035.js +30 -0
  225. package/dist/packages/crucible/seeds/js/seed-036.js +30 -0
  226. package/dist/packages/crucible/seeds/js/seed-037.js +29 -0
  227. package/dist/packages/crucible/seeds/js/seed-038.js +31 -0
  228. package/dist/packages/crucible/seeds/js/seed-039.js +34 -0
  229. package/dist/packages/crucible/seeds/js/seed-040.js +35 -0
  230. package/dist/packages/crucible/seeds/js/seed-041.js +32 -0
  231. package/dist/packages/crucible/seeds/js/seed-042.js +32 -0
  232. package/dist/packages/crucible/seeds/js/seed-043.js +27 -0
  233. package/dist/packages/crucible/seeds/js/seed-044.js +29 -0
  234. package/dist/packages/crucible/seeds/js/seed-045.js +33 -0
  235. package/dist/packages/crucible/seeds/js/seed-046.js +33 -0
  236. package/dist/packages/crucible/seeds/js/seed-047.js +29 -0
  237. package/dist/packages/crucible/seeds/js/seed-048.js +29 -0
  238. package/dist/packages/crucible/seeds/js/seed-049.js +34 -0
  239. package/dist/packages/crucible/seeds/js/seed-050.js +34 -0
  240. package/dist/packages/crucible/seeds/js/seed-051.js +30 -0
  241. package/dist/packages/crucible/seeds/js/seed-052.js +30 -0
  242. package/dist/packages/crucible/seeds/js/seed-053.js +26 -0
  243. package/dist/packages/crucible/seeds/js/seed-054.js +35 -0
  244. package/dist/packages/crucible/seeds/js/seed-055.js +33 -0
  245. package/dist/packages/crucible/seeds/kotlin/seed-001.kt +24 -0
  246. package/dist/packages/crucible/seeds/kotlin/seed-002.kt +27 -0
  247. package/dist/packages/crucible/seeds/kotlin/seed-003.kt +29 -0
  248. package/dist/packages/crucible/seeds/kotlin/seed-004.kt +24 -0
  249. package/dist/packages/crucible/seeds/kotlin/seed-005.kt +29 -0
  250. package/dist/packages/crucible/seeds/kotlin/seed-006.kt +21 -0
  251. package/dist/packages/crucible/seeds/kotlin/seed-007.kt +23 -0
  252. package/dist/packages/crucible/seeds/kotlin/seed-008.kt +25 -0
  253. package/dist/packages/crucible/seeds/kotlin/seed-009.kt +21 -0
  254. package/dist/packages/crucible/seeds/kotlin/seed-010.kt +28 -0
  255. package/dist/packages/crucible/seeds/kotlin/seed-011.kt +22 -0
  256. package/dist/packages/crucible/seeds/kotlin/seed-012.kt +25 -0
  257. package/dist/packages/crucible/seeds/kotlin/seed-013.kt +30 -0
  258. package/dist/packages/crucible/seeds/kotlin/seed-014.kt +27 -0
  259. package/dist/packages/crucible/seeds/kotlin/seed-015.kt +24 -0
  260. package/dist/packages/crucible/seeds/kotlin/seed-016.kt +28 -0
  261. package/dist/packages/crucible/seeds/kotlin/seed-017.kt +33 -0
  262. package/dist/packages/crucible/seeds/kotlin/seed-018.kt +31 -0
  263. package/dist/packages/crucible/seeds/kotlin/seed-019.kt +28 -0
  264. package/dist/packages/crucible/seeds/kotlin/seed-020.kt +31 -0
  265. package/dist/packages/crucible/seeds/kotlin/seed-021.kt +34 -0
  266. package/dist/packages/crucible/seeds/kotlin/seed-022.kt +29 -0
  267. package/dist/packages/crucible/seeds/kotlin/seed-023.kt +20 -0
  268. package/dist/packages/crucible/seeds/kotlin/seed-024.kt +23 -0
  269. package/dist/packages/crucible/seeds/kotlin/seed-025.kt +23 -0
  270. package/dist/packages/crucible/seeds/kotlin/seed-026.kt +26 -0
  271. package/dist/packages/crucible/seeds/kotlin/seed-027.kt +29 -0
  272. package/dist/packages/crucible/seeds/kotlin/seed-028.kt +24 -0
  273. package/dist/packages/crucible/seeds/kotlin/seed-029.kt +27 -0
  274. package/dist/packages/crucible/seeds/kotlin/seed-030.kt +26 -0
  275. package/dist/packages/crucible/seeds/kotlin/seed-031.kt +28 -0
  276. package/dist/packages/crucible/seeds/kotlin/seed-032.kt +29 -0
  277. package/dist/packages/crucible/seeds/kotlin/seed-033.kt +30 -0
  278. package/dist/packages/crucible/seeds/kotlin/seed-034.kt +26 -0
  279. package/dist/packages/crucible/seeds/kotlin/seed-035.kt +33 -0
  280. package/dist/packages/crucible/seeds/kotlin/seed-036.kt +25 -0
  281. package/dist/packages/crucible/seeds/kotlin/seed-037.kt +26 -0
  282. package/dist/packages/crucible/seeds/kotlin/seed-038.kt +25 -0
  283. package/dist/packages/crucible/seeds/kotlin/seed-039.kt +29 -0
  284. package/dist/packages/crucible/seeds/kotlin/seed-040.kt +28 -0
  285. package/dist/packages/crucible/seeds/kotlin/seed-041.kt +31 -0
  286. package/dist/packages/crucible/seeds/kotlin/seed-042.kt +27 -0
  287. package/dist/packages/crucible/seeds/kotlin/seed-043.kt +26 -0
  288. package/dist/packages/crucible/seeds/kotlin/seed-044.kt +27 -0
  289. package/dist/packages/crucible/seeds/kotlin/seed-045.kt +27 -0
  290. package/dist/packages/crucible/seeds/kotlin/seed-046.kt +33 -0
  291. package/dist/packages/crucible/seeds/kotlin/seed-047.kt +32 -0
  292. package/dist/packages/crucible/seeds/kotlin/seed-048.kt +20 -0
  293. package/dist/packages/crucible/seeds/kotlin/seed-049.kt +23 -0
  294. package/dist/packages/crucible/seeds/kotlin/seed-050.kt +19 -0
  295. package/dist/packages/crucible/seeds/php/seed-001.php +23 -0
  296. package/dist/packages/crucible/seeds/php/seed-002.php +18 -0
  297. package/dist/packages/crucible/seeds/php/seed-003.php +25 -0
  298. package/dist/packages/crucible/seeds/php/seed-004.php +21 -0
  299. package/dist/packages/crucible/seeds/php/seed-005.php +21 -0
  300. package/dist/packages/crucible/seeds/php/seed-006.php +21 -0
  301. package/dist/packages/crucible/seeds/php/seed-007.php +18 -0
  302. package/dist/packages/crucible/seeds/php/seed-008.php +19 -0
  303. package/dist/packages/crucible/seeds/php/seed-009.php +24 -0
  304. package/dist/packages/crucible/seeds/php/seed-010.php +24 -0
  305. package/dist/packages/crucible/seeds/php/seed-011.php +18 -0
  306. package/dist/packages/crucible/seeds/php/seed-012.php +24 -0
  307. package/dist/packages/crucible/seeds/php/seed-013.php +23 -0
  308. package/dist/packages/crucible/seeds/php/seed-014.php +20 -0
  309. package/dist/packages/crucible/seeds/php/seed-015.php +18 -0
  310. package/dist/packages/crucible/seeds/php/seed-016.php +18 -0
  311. package/dist/packages/crucible/seeds/php/seed-017.php +18 -0
  312. package/dist/packages/crucible/seeds/php/seed-018.php +17 -0
  313. package/dist/packages/crucible/seeds/php/seed-019.php +24 -0
  314. package/dist/packages/crucible/seeds/php/seed-020.php +19 -0
  315. package/dist/packages/crucible/seeds/php/seed-021.php +22 -0
  316. package/dist/packages/crucible/seeds/php/seed-022.php +15 -0
  317. package/dist/packages/crucible/seeds/php/seed-023.php +24 -0
  318. package/dist/packages/crucible/seeds/php/seed-024.php +22 -0
  319. package/dist/packages/crucible/seeds/php/seed-025.php +20 -0
  320. package/dist/packages/crucible/seeds/php/seed-026.php +22 -0
  321. package/dist/packages/crucible/seeds/php/seed-027.php +15 -0
  322. package/dist/packages/crucible/seeds/php/seed-028.php +15 -0
  323. package/dist/packages/crucible/seeds/php/seed-029.php +21 -0
  324. package/dist/packages/crucible/seeds/php/seed-030.php +21 -0
  325. package/dist/packages/crucible/seeds/php/seed-031.php +23 -0
  326. package/dist/packages/crucible/seeds/php/seed-032.php +18 -0
  327. package/dist/packages/crucible/seeds/php/seed-033.php +18 -0
  328. package/dist/packages/crucible/seeds/php/seed-034.php +24 -0
  329. package/dist/packages/crucible/seeds/php/seed-035.php +22 -0
  330. package/dist/packages/crucible/seeds/php/seed-036.php +17 -0
  331. package/dist/packages/crucible/seeds/php/seed-037.php +19 -0
  332. package/dist/packages/crucible/seeds/php/seed-038.php +20 -0
  333. package/dist/packages/crucible/seeds/php/seed-039.php +15 -0
  334. package/dist/packages/crucible/seeds/php/seed-040.php +21 -0
  335. package/dist/packages/crucible/seeds/php/seed-041.php +20 -0
  336. package/dist/packages/crucible/seeds/php/seed-042.php +21 -0
  337. package/dist/packages/crucible/seeds/php/seed-043.php +21 -0
  338. package/dist/packages/crucible/seeds/php/seed-044.php +25 -0
  339. package/dist/packages/crucible/seeds/php/seed-045.php +25 -0
  340. package/dist/packages/crucible/seeds/php/seed-046.php +20 -0
  341. package/dist/packages/crucible/seeds/php/seed-047.php +21 -0
  342. package/dist/packages/crucible/seeds/php/seed-048.php +19 -0
  343. package/dist/packages/crucible/seeds/php/seed-049.php +18 -0
  344. package/dist/packages/crucible/seeds/php/seed-050.php +20 -0
  345. package/dist/packages/crucible/seeds/python/seed-001.py +33 -0
  346. package/dist/packages/crucible/seeds/python/seed-002.py +39 -0
  347. package/dist/packages/crucible/seeds/python/seed-003.py +31 -0
  348. package/dist/packages/crucible/seeds/python/seed-004.py +33 -0
  349. package/dist/packages/crucible/seeds/python/seed-005.py +33 -0
  350. package/dist/packages/crucible/seeds/python/seed-006.py +34 -0
  351. package/dist/packages/crucible/seeds/python/seed-007.py +33 -0
  352. package/dist/packages/crucible/seeds/python/seed-008.py +38 -0
  353. package/dist/packages/crucible/seeds/python/seed-009.py +38 -0
  354. package/dist/packages/crucible/seeds/python/seed-010.py +42 -0
  355. package/dist/packages/crucible/seeds/python/seed-011.py +30 -0
  356. package/dist/packages/crucible/seeds/python/seed-012.py +35 -0
  357. package/dist/packages/crucible/seeds/python/seed-013.py +33 -0
  358. package/dist/packages/crucible/seeds/python/seed-014.py +40 -0
  359. package/dist/packages/crucible/seeds/python/seed-015.py +33 -0
  360. package/dist/packages/crucible/seeds/python/seed-016.py +34 -0
  361. package/dist/packages/crucible/seeds/python/seed-017.py +34 -0
  362. package/dist/packages/crucible/seeds/python/seed-018.py +30 -0
  363. package/dist/packages/crucible/seeds/python/seed-019.py +33 -0
  364. package/dist/packages/crucible/seeds/python/seed-020.py +37 -0
  365. package/dist/packages/crucible/seeds/python/seed-021 2.py +37 -0
  366. package/dist/packages/crucible/seeds/python/seed-021.py +37 -0
  367. package/dist/packages/crucible/seeds/python/seed-022 2.py +34 -0
  368. package/dist/packages/crucible/seeds/python/seed-022.py +34 -0
  369. package/dist/packages/crucible/seeds/python/seed-023 2.py +37 -0
  370. package/dist/packages/crucible/seeds/python/seed-023.py +37 -0
  371. package/dist/packages/crucible/seeds/python/seed-024 2.py +38 -0
  372. package/dist/packages/crucible/seeds/python/seed-024.py +38 -0
  373. package/dist/packages/crucible/seeds/python/seed-025 2.py +40 -0
  374. package/dist/packages/crucible/seeds/python/seed-025.py +40 -0
  375. package/dist/packages/crucible/seeds/python/seed-026 2.py +35 -0
  376. package/dist/packages/crucible/seeds/python/seed-026.py +35 -0
  377. package/dist/packages/crucible/seeds/python/seed-027 2.py +35 -0
  378. package/dist/packages/crucible/seeds/python/seed-027.py +35 -0
  379. package/dist/packages/crucible/seeds/python/seed-028 2.py +42 -0
  380. package/dist/packages/crucible/seeds/python/seed-028.py +42 -0
  381. package/dist/packages/crucible/seeds/python/seed-029.py +42 -0
  382. package/dist/packages/crucible/seeds/python/seed-030 2.py +37 -0
  383. package/dist/packages/crucible/seeds/python/seed-030.py +37 -0
  384. package/dist/packages/crucible/seeds/python/seed-031 2.py +34 -0
  385. package/dist/packages/crucible/seeds/python/seed-031.py +34 -0
  386. package/dist/packages/crucible/seeds/python/seed-032.py +33 -0
  387. package/dist/packages/crucible/seeds/python/seed-033.py +32 -0
  388. package/dist/packages/crucible/seeds/python/seed-034.py +38 -0
  389. package/dist/packages/crucible/seeds/python/seed-035.py +35 -0
  390. package/dist/packages/crucible/seeds/python/seed-036 2.py +33 -0
  391. package/dist/packages/crucible/seeds/python/seed-036.py +33 -0
  392. package/dist/packages/crucible/seeds/python/seed-037 2.py +41 -0
  393. package/dist/packages/crucible/seeds/python/seed-037.py +41 -0
  394. package/dist/packages/crucible/seeds/python/seed-038 2.py +33 -0
  395. package/dist/packages/crucible/seeds/python/seed-038.py +33 -0
  396. package/dist/packages/crucible/seeds/python/seed-039 2.py +39 -0
  397. package/dist/packages/crucible/seeds/python/seed-039.py +39 -0
  398. package/dist/packages/crucible/seeds/python/seed-040 2.py +39 -0
  399. package/dist/packages/crucible/seeds/python/seed-040.py +39 -0
  400. package/dist/packages/crucible/seeds/python/seed-041 2.py +37 -0
  401. package/dist/packages/crucible/seeds/python/seed-041.py +37 -0
  402. package/dist/packages/crucible/seeds/python/seed-042 2.py +38 -0
  403. package/dist/packages/crucible/seeds/python/seed-042.py +38 -0
  404. package/dist/packages/crucible/seeds/python/seed-043 2.py +32 -0
  405. package/dist/packages/crucible/seeds/python/seed-043.py +32 -0
  406. package/dist/packages/crucible/seeds/python/seed-044 2.py +38 -0
  407. package/dist/packages/crucible/seeds/python/seed-044.py +38 -0
  408. package/dist/packages/crucible/seeds/python/seed-045 2.py +36 -0
  409. package/dist/packages/crucible/seeds/python/seed-045.py +36 -0
  410. package/dist/packages/crucible/seeds/python/seed-046 2.py +33 -0
  411. package/dist/packages/crucible/seeds/python/seed-046.py +33 -0
  412. package/dist/packages/crucible/seeds/python/seed-047 2.py +44 -0
  413. package/dist/packages/crucible/seeds/python/seed-047.py +44 -0
  414. package/dist/packages/crucible/seeds/python/seed-048 2.py +35 -0
  415. package/dist/packages/crucible/seeds/python/seed-048.py +35 -0
  416. package/dist/packages/crucible/seeds/python/seed-049 2.py +39 -0
  417. package/dist/packages/crucible/seeds/python/seed-049.py +39 -0
  418. package/dist/packages/crucible/seeds/python/seed-050 2.py +39 -0
  419. package/dist/packages/crucible/seeds/python/seed-050.py +39 -0
  420. package/dist/packages/crucible/seeds/python/seed-051 2.py +38 -0
  421. package/dist/packages/crucible/seeds/python/seed-051.py +38 -0
  422. package/dist/packages/crucible/seeds/python/seed-052 2.py +41 -0
  423. package/dist/packages/crucible/seeds/python/seed-052.py +41 -0
  424. package/dist/packages/crucible/seeds/ruby/seed-001 2.rb +15 -0
  425. package/dist/packages/crucible/seeds/ruby/seed-001.rb +15 -0
  426. package/dist/packages/crucible/seeds/ruby/seed-002 2.rb +22 -0
  427. package/dist/packages/crucible/seeds/ruby/seed-002.rb +22 -0
  428. package/dist/packages/crucible/seeds/ruby/seed-003 2.rb +25 -0
  429. package/dist/packages/crucible/seeds/ruby/seed-003.rb +25 -0
  430. package/dist/packages/crucible/seeds/ruby/seed-004 2.rb +17 -0
  431. package/dist/packages/crucible/seeds/ruby/seed-004.rb +17 -0
  432. package/dist/packages/crucible/seeds/ruby/seed-005 2.rb +21 -0
  433. package/dist/packages/crucible/seeds/ruby/seed-005.rb +21 -0
  434. package/dist/packages/crucible/seeds/ruby/seed-006 2.rb +17 -0
  435. package/dist/packages/crucible/seeds/ruby/seed-006.rb +17 -0
  436. package/dist/packages/crucible/seeds/ruby/seed-007 2.rb +16 -0
  437. package/dist/packages/crucible/seeds/ruby/seed-007.rb +16 -0
  438. package/dist/packages/crucible/seeds/ruby/seed-008 2.rb +18 -0
  439. package/dist/packages/crucible/seeds/ruby/seed-008.rb +18 -0
  440. package/dist/packages/crucible/seeds/ruby/seed-009 2.rb +20 -0
  441. package/dist/packages/crucible/seeds/ruby/seed-009.rb +20 -0
  442. package/dist/packages/crucible/seeds/ruby/seed-010 2.rb +24 -0
  443. package/dist/packages/crucible/seeds/ruby/seed-010.rb +24 -0
  444. package/dist/packages/crucible/seeds/ruby/seed-011 2.rb +21 -0
  445. package/dist/packages/crucible/seeds/ruby/seed-011.rb +21 -0
  446. package/dist/packages/crucible/seeds/ruby/seed-012 2.rb +22 -0
  447. package/dist/packages/crucible/seeds/ruby/seed-012.rb +22 -0
  448. package/dist/packages/crucible/seeds/ruby/seed-013 2.rb +21 -0
  449. package/dist/packages/crucible/seeds/ruby/seed-013.rb +21 -0
  450. package/dist/packages/crucible/seeds/ruby/seed-014 2.rb +16 -0
  451. package/dist/packages/crucible/seeds/ruby/seed-014.rb +16 -0
  452. package/dist/packages/crucible/seeds/ruby/seed-015 2.rb +18 -0
  453. package/dist/packages/crucible/seeds/ruby/seed-015.rb +18 -0
  454. package/dist/packages/crucible/seeds/ruby/seed-016 2.rb +17 -0
  455. package/dist/packages/crucible/seeds/ruby/seed-016.rb +17 -0
  456. package/dist/packages/crucible/seeds/ruby/seed-017 2.rb +25 -0
  457. package/dist/packages/crucible/seeds/ruby/seed-017.rb +25 -0
  458. package/dist/packages/crucible/seeds/ruby/seed-018 2.rb +23 -0
  459. package/dist/packages/crucible/seeds/ruby/seed-018.rb +23 -0
  460. package/dist/packages/crucible/seeds/ruby/seed-019 2.rb +20 -0
  461. package/dist/packages/crucible/seeds/ruby/seed-019.rb +20 -0
  462. package/dist/packages/crucible/seeds/ruby/seed-020 2.rb +17 -0
  463. package/dist/packages/crucible/seeds/ruby/seed-020.rb +17 -0
  464. package/dist/packages/crucible/seeds/ruby/seed-021 2.rb +20 -0
  465. package/dist/packages/crucible/seeds/ruby/seed-021.rb +20 -0
  466. package/dist/packages/crucible/seeds/ruby/seed-022 2.rb +21 -0
  467. package/dist/packages/crucible/seeds/ruby/seed-022.rb +21 -0
  468. package/dist/packages/crucible/seeds/ruby/seed-023 2.rb +19 -0
  469. package/dist/packages/crucible/seeds/ruby/seed-023.rb +19 -0
  470. package/dist/packages/crucible/seeds/ruby/seed-024 2.rb +17 -0
  471. package/dist/packages/crucible/seeds/ruby/seed-024.rb +17 -0
  472. package/dist/packages/crucible/seeds/ruby/seed-025 2.rb +17 -0
  473. package/dist/packages/crucible/seeds/ruby/seed-025.rb +17 -0
  474. package/dist/packages/crucible/seeds/ruby/seed-026 2.rb +18 -0
  475. package/dist/packages/crucible/seeds/ruby/seed-026.rb +18 -0
  476. package/dist/packages/crucible/seeds/ruby/seed-027 2.rb +21 -0
  477. package/dist/packages/crucible/seeds/ruby/seed-027.rb +21 -0
  478. package/dist/packages/crucible/seeds/ruby/seed-028 2.rb +22 -0
  479. package/dist/packages/crucible/seeds/ruby/seed-028.rb +22 -0
  480. package/dist/packages/crucible/seeds/ruby/seed-029 2.rb +19 -0
  481. package/dist/packages/crucible/seeds/ruby/seed-029.rb +19 -0
  482. package/dist/packages/crucible/seeds/ruby/seed-030 2.rb +20 -0
  483. package/dist/packages/crucible/seeds/ruby/seed-030.rb +20 -0
  484. package/dist/packages/crucible/seeds/ruby/seed-031 2.rb +17 -0
  485. package/dist/packages/crucible/seeds/ruby/seed-031.rb +17 -0
  486. package/dist/packages/crucible/seeds/ruby/seed-032 2.rb +22 -0
  487. package/dist/packages/crucible/seeds/ruby/seed-032.rb +22 -0
  488. package/dist/packages/crucible/seeds/ruby/seed-033 2.rb +18 -0
  489. package/dist/packages/crucible/seeds/ruby/seed-033.rb +18 -0
  490. package/dist/packages/crucible/seeds/ruby/seed-034 2.rb +19 -0
  491. package/dist/packages/crucible/seeds/ruby/seed-034.rb +19 -0
  492. package/dist/packages/crucible/seeds/ruby/seed-035 2.rb +19 -0
  493. package/dist/packages/crucible/seeds/ruby/seed-035.rb +19 -0
  494. package/dist/packages/crucible/seeds/ruby/seed-036 2.rb +18 -0
  495. package/dist/packages/crucible/seeds/ruby/seed-036.rb +18 -0
  496. package/dist/packages/crucible/seeds/ruby/seed-037 2.rb +21 -0
  497. package/dist/packages/crucible/seeds/ruby/seed-037.rb +21 -0
  498. package/dist/packages/crucible/seeds/ruby/seed-038 2.rb +24 -0
  499. package/dist/packages/crucible/seeds/ruby/seed-038.rb +24 -0
  500. package/dist/packages/crucible/seeds/ruby/seed-039 2.rb +24 -0
  501. package/dist/packages/crucible/seeds/ruby/seed-039.rb +24 -0
  502. package/dist/packages/crucible/seeds/ruby/seed-040 2.rb +22 -0
  503. package/dist/packages/crucible/seeds/ruby/seed-040.rb +22 -0
  504. package/dist/packages/crucible/seeds/ruby/seed-041 2.rb +23 -0
  505. package/dist/packages/crucible/seeds/ruby/seed-041.rb +23 -0
  506. package/dist/packages/crucible/seeds/ruby/seed-042 2.rb +25 -0
  507. package/dist/packages/crucible/seeds/ruby/seed-042.rb +25 -0
  508. package/dist/packages/crucible/seeds/ruby/seed-043 2.rb +23 -0
  509. package/dist/packages/crucible/seeds/ruby/seed-043.rb +23 -0
  510. package/dist/packages/crucible/seeds/ruby/seed-044 2.rb +16 -0
  511. package/dist/packages/crucible/seeds/ruby/seed-044.rb +16 -0
  512. package/dist/packages/crucible/seeds/ruby/seed-045 2.rb +22 -0
  513. package/dist/packages/crucible/seeds/ruby/seed-045.rb +22 -0
  514. package/dist/packages/crucible/seeds/ruby/seed-046 2.rb +27 -0
  515. package/dist/packages/crucible/seeds/ruby/seed-046.rb +27 -0
  516. package/dist/packages/crucible/seeds/ruby/seed-047 2.rb +26 -0
  517. package/dist/packages/crucible/seeds/ruby/seed-047.rb +26 -0
  518. package/dist/packages/crucible/seeds/ruby/seed-048 2.rb +24 -0
  519. package/dist/packages/crucible/seeds/ruby/seed-048.rb +24 -0
  520. package/dist/packages/crucible/seeds/ruby/seed-049 2.rb +20 -0
  521. package/dist/packages/crucible/seeds/ruby/seed-049.rb +20 -0
  522. package/dist/packages/crucible/seeds/ruby/seed-050 2.rb +27 -0
  523. package/dist/packages/crucible/seeds/ruby/seed-050.rb +27 -0
  524. package/dist/packages/crucible/seeds/rust/seed-001 2.rs +25 -0
  525. package/dist/packages/crucible/seeds/rust/seed-001.rs +25 -0
  526. package/dist/packages/crucible/seeds/rust/seed-002 2.rs +20 -0
  527. package/dist/packages/crucible/seeds/rust/seed-002.rs +20 -0
  528. package/dist/packages/crucible/seeds/rust/seed-003 2.rs +23 -0
  529. package/dist/packages/crucible/seeds/rust/seed-003.rs +23 -0
  530. package/dist/packages/crucible/seeds/rust/seed-004 2.rs +21 -0
  531. package/dist/packages/crucible/seeds/rust/seed-004.rs +21 -0
  532. package/dist/packages/crucible/seeds/rust/seed-005 2.rs +21 -0
  533. package/dist/packages/crucible/seeds/rust/seed-005.rs +21 -0
  534. package/dist/packages/crucible/seeds/rust/seed-006 2.rs +24 -0
  535. package/dist/packages/crucible/seeds/rust/seed-006.rs +24 -0
  536. package/dist/packages/crucible/seeds/rust/seed-007 2.rs +20 -0
  537. package/dist/packages/crucible/seeds/rust/seed-007.rs +20 -0
  538. package/dist/packages/crucible/seeds/rust/seed-008 2.rs +19 -0
  539. package/dist/packages/crucible/seeds/rust/seed-008.rs +19 -0
  540. package/dist/packages/crucible/seeds/rust/seed-009 2.rs +28 -0
  541. package/dist/packages/crucible/seeds/rust/seed-009.rs +28 -0
  542. package/dist/packages/crucible/seeds/rust/seed-010 2.rs +28 -0
  543. package/dist/packages/crucible/seeds/rust/seed-010.rs +28 -0
  544. package/dist/packages/crucible/seeds/rust/seed-011 2.rs +25 -0
  545. package/dist/packages/crucible/seeds/rust/seed-011.rs +25 -0
  546. package/dist/packages/crucible/seeds/rust/seed-012 2.rs +31 -0
  547. package/dist/packages/crucible/seeds/rust/seed-012.rs +31 -0
  548. package/dist/packages/crucible/seeds/rust/seed-013 2.rs +27 -0
  549. package/dist/packages/crucible/seeds/rust/seed-013.rs +27 -0
  550. package/dist/packages/crucible/seeds/rust/seed-014 2.rs +30 -0
  551. package/dist/packages/crucible/seeds/rust/seed-014.rs +30 -0
  552. package/dist/packages/crucible/seeds/rust/seed-015 2.rs +33 -0
  553. package/dist/packages/crucible/seeds/rust/seed-015.rs +33 -0
  554. package/dist/packages/crucible/seeds/rust/seed-016 2.rs +22 -0
  555. package/dist/packages/crucible/seeds/rust/seed-016.rs +22 -0
  556. package/dist/packages/crucible/seeds/rust/seed-017 2.rs +28 -0
  557. package/dist/packages/crucible/seeds/rust/seed-017.rs +28 -0
  558. package/dist/packages/crucible/seeds/rust/seed-018 2.rs +21 -0
  559. package/dist/packages/crucible/seeds/rust/seed-018.rs +21 -0
  560. package/dist/packages/crucible/seeds/rust/seed-019 2.rs +36 -0
  561. package/dist/packages/crucible/seeds/rust/seed-019.rs +36 -0
  562. package/dist/packages/crucible/seeds/rust/seed-020 2.rs +27 -0
  563. package/dist/packages/crucible/seeds/rust/seed-020.rs +27 -0
  564. package/dist/packages/crucible/seeds/rust/seed-021 2.rs +26 -0
  565. package/dist/packages/crucible/seeds/rust/seed-021.rs +26 -0
  566. package/dist/packages/crucible/seeds/rust/seed-022 2.rs +23 -0
  567. package/dist/packages/crucible/seeds/rust/seed-022.rs +23 -0
  568. package/dist/packages/crucible/seeds/rust/seed-023 2.rs +22 -0
  569. package/dist/packages/crucible/seeds/rust/seed-023.rs +22 -0
  570. package/dist/packages/crucible/seeds/rust/seed-024 2.rs +24 -0
  571. package/dist/packages/crucible/seeds/rust/seed-024.rs +24 -0
  572. package/dist/packages/crucible/seeds/rust/seed-025 2.rs +29 -0
  573. package/dist/packages/crucible/seeds/rust/seed-025.rs +29 -0
  574. package/dist/packages/crucible/seeds/rust/seed-026 2.rs +23 -0
  575. package/dist/packages/crucible/seeds/rust/seed-026.rs +23 -0
  576. package/dist/packages/crucible/seeds/rust/seed-027 2.rs +24 -0
  577. package/dist/packages/crucible/seeds/rust/seed-027.rs +24 -0
  578. package/dist/packages/crucible/seeds/rust/seed-028 2.rs +25 -0
  579. package/dist/packages/crucible/seeds/rust/seed-028.rs +25 -0
  580. package/dist/packages/crucible/seeds/rust/seed-029 2.rs +25 -0
  581. package/dist/packages/crucible/seeds/rust/seed-029.rs +25 -0
  582. package/dist/packages/crucible/seeds/rust/seed-030 2.rs +30 -0
  583. package/dist/packages/crucible/seeds/rust/seed-030.rs +30 -0
  584. package/dist/packages/crucible/seeds/rust/seed-031 2.rs +22 -0
  585. package/dist/packages/crucible/seeds/rust/seed-031.rs +22 -0
  586. package/dist/packages/crucible/seeds/rust/seed-032 2.rs +25 -0
  587. package/dist/packages/crucible/seeds/rust/seed-032.rs +25 -0
  588. package/dist/packages/crucible/seeds/rust/seed-033 2.rs +25 -0
  589. package/dist/packages/crucible/seeds/rust/seed-033.rs +25 -0
  590. package/dist/packages/crucible/seeds/rust/seed-034 2.rs +20 -0
  591. package/dist/packages/crucible/seeds/rust/seed-034.rs +20 -0
  592. package/dist/packages/crucible/seeds/rust/seed-035 2.rs +28 -0
  593. package/dist/packages/crucible/seeds/rust/seed-035.rs +28 -0
  594. package/dist/packages/crucible/seeds/rust/seed-036 2.rs +26 -0
  595. package/dist/packages/crucible/seeds/rust/seed-036.rs +26 -0
  596. package/dist/packages/crucible/seeds/rust/seed-037 2.rs +31 -0
  597. package/dist/packages/crucible/seeds/rust/seed-037.rs +31 -0
  598. package/dist/packages/crucible/seeds/rust/seed-038 2.rs +25 -0
  599. package/dist/packages/crucible/seeds/rust/seed-038.rs +25 -0
  600. package/dist/packages/crucible/seeds/rust/seed-039 2.rs +28 -0
  601. package/dist/packages/crucible/seeds/rust/seed-039.rs +28 -0
  602. package/dist/packages/crucible/seeds/rust/seed-040 2.rs +27 -0
  603. package/dist/packages/crucible/seeds/rust/seed-040.rs +27 -0
  604. package/dist/packages/crucible/seeds/rust/seed-041 2.rs +32 -0
  605. package/dist/packages/crucible/seeds/rust/seed-041.rs +32 -0
  606. package/dist/packages/crucible/seeds/rust/seed-042 2.rs +27 -0
  607. package/dist/packages/crucible/seeds/rust/seed-042.rs +27 -0
  608. package/dist/packages/crucible/seeds/rust/seed-043 2.rs +29 -0
  609. package/dist/packages/crucible/seeds/rust/seed-043.rs +29 -0
  610. package/dist/packages/crucible/seeds/rust/seed-044 2.rs +25 -0
  611. package/dist/packages/crucible/seeds/rust/seed-044.rs +25 -0
  612. package/dist/packages/crucible/seeds/rust/seed-045 2.rs +28 -0
  613. package/dist/packages/crucible/seeds/rust/seed-045.rs +28 -0
  614. package/dist/packages/crucible/seeds/rust/seed-046 2.rs +25 -0
  615. package/dist/packages/crucible/seeds/rust/seed-046.rs +25 -0
  616. package/dist/packages/crucible/seeds/rust/seed-047 2.rs +34 -0
  617. package/dist/packages/crucible/seeds/rust/seed-047.rs +34 -0
  618. package/dist/packages/crucible/seeds/rust/seed-048 2.rs +21 -0
  619. package/dist/packages/crucible/seeds/rust/seed-048.rs +21 -0
  620. package/dist/packages/crucible/seeds/rust/seed-049 2.rs +26 -0
  621. package/dist/packages/crucible/seeds/rust/seed-049.rs +26 -0
  622. package/dist/packages/crucible/seeds/rust/seed-050 2.rs +23 -0
  623. package/dist/packages/crucible/seeds/rust/seed-050.rs +23 -0
  624. package/dist/packages/crucible/seeds/ts/seed-001 2.ts +32 -0
  625. package/dist/packages/crucible/seeds/ts/seed-001.ts +32 -0
  626. package/dist/packages/crucible/seeds/ts/seed-002 2.ts +34 -0
  627. package/dist/packages/crucible/seeds/ts/seed-002.ts +34 -0
  628. package/dist/packages/crucible/seeds/ts/seed-003 2.ts +28 -0
  629. package/dist/packages/crucible/seeds/ts/seed-003.ts +28 -0
  630. package/dist/packages/crucible/seeds/ts/seed-004 2.ts +34 -0
  631. package/dist/packages/crucible/seeds/ts/seed-004.ts +34 -0
  632. package/dist/packages/crucible/seeds/ts/seed-005 2.ts +32 -0
  633. package/dist/packages/crucible/seeds/ts/seed-005.ts +32 -0
  634. package/dist/packages/crucible/seeds/ts/seed-006 2.ts +31 -0
  635. package/dist/packages/crucible/seeds/ts/seed-006.ts +31 -0
  636. package/dist/packages/crucible/seeds/ts/seed-007 2.ts +28 -0
  637. package/dist/packages/crucible/seeds/ts/seed-007.ts +28 -0
  638. package/dist/packages/crucible/seeds/ts/seed-008 2.ts +40 -0
  639. package/dist/packages/crucible/seeds/ts/seed-008.ts +40 -0
  640. package/dist/packages/crucible/seeds/ts/seed-009 2.ts +31 -0
  641. package/dist/packages/crucible/seeds/ts/seed-009.ts +31 -0
  642. package/dist/packages/crucible/seeds/ts/seed-010 2.ts +33 -0
  643. package/dist/packages/crucible/seeds/ts/seed-010.ts +33 -0
  644. package/dist/packages/crucible/seeds/ts/seed-011 2.ts +29 -0
  645. package/dist/packages/crucible/seeds/ts/seed-011.ts +29 -0
  646. package/dist/packages/crucible/seeds/ts/seed-012 2.ts +34 -0
  647. package/dist/packages/crucible/seeds/ts/seed-012.ts +34 -0
  648. package/dist/packages/crucible/seeds/ts/seed-013 2.ts +31 -0
  649. package/dist/packages/crucible/seeds/ts/seed-013.ts +31 -0
  650. package/dist/packages/crucible/seeds/ts/seed-014 2.ts +36 -0
  651. package/dist/packages/crucible/seeds/ts/seed-014.ts +36 -0
  652. package/dist/packages/crucible/seeds/ts/seed-015 2.ts +31 -0
  653. package/dist/packages/crucible/seeds/ts/seed-015.ts +31 -0
  654. package/dist/packages/crucible/seeds/ts/seed-016 2.ts +37 -0
  655. package/dist/packages/crucible/seeds/ts/seed-016.ts +37 -0
  656. package/dist/packages/crucible/seeds/ts/seed-017 2.ts +44 -0
  657. package/dist/packages/crucible/seeds/ts/seed-017.ts +44 -0
  658. package/dist/packages/crucible/seeds/ts/seed-018 2.ts +33 -0
  659. package/dist/packages/crucible/seeds/ts/seed-018.ts +33 -0
  660. package/dist/packages/crucible/seeds/ts/seed-019 2.ts +32 -0
  661. package/dist/packages/crucible/seeds/ts/seed-019.ts +32 -0
  662. package/dist/packages/crucible/seeds/ts/seed-020 2.ts +33 -0
  663. package/dist/packages/crucible/seeds/ts/seed-020.ts +33 -0
  664. package/dist/packages/crucible/seeds/ts/seed-021 2.ts +33 -0
  665. package/dist/packages/crucible/seeds/ts/seed-021.ts +33 -0
  666. package/dist/packages/crucible/seeds/ts/seed-022 2.ts +34 -0
  667. package/dist/packages/crucible/seeds/ts/seed-022.ts +34 -0
  668. package/dist/packages/crucible/seeds/ts/seed-023 2.ts +33 -0
  669. package/dist/packages/crucible/seeds/ts/seed-023.ts +33 -0
  670. package/dist/packages/crucible/seeds/ts/seed-024 2.ts +35 -0
  671. package/dist/packages/crucible/seeds/ts/seed-024.ts +35 -0
  672. package/dist/packages/crucible/seeds/ts/seed-025 2.ts +29 -0
  673. package/dist/packages/crucible/seeds/ts/seed-025.ts +29 -0
  674. package/dist/packages/crucible/seeds/ts/seed-026 2.ts +36 -0
  675. package/dist/packages/crucible/seeds/ts/seed-026.ts +36 -0
  676. package/dist/packages/crucible/seeds/ts/seed-027 2.ts +30 -0
  677. package/dist/packages/crucible/seeds/ts/seed-027.ts +30 -0
  678. package/dist/packages/crucible/seeds/ts/seed-028 2.ts +32 -0
  679. package/dist/packages/crucible/seeds/ts/seed-028.ts +32 -0
  680. package/dist/packages/crucible/seeds/ts/seed-029 2.ts +34 -0
  681. package/dist/packages/crucible/seeds/ts/seed-029.ts +34 -0
  682. package/dist/packages/crucible/seeds/ts/seed-030 2.ts +37 -0
  683. package/dist/packages/crucible/seeds/ts/seed-030.ts +37 -0
  684. package/dist/packages/crucible/seeds/ts/seed-031 2.ts +31 -0
  685. package/dist/packages/crucible/seeds/ts/seed-031.ts +31 -0
  686. package/dist/packages/crucible/seeds/ts/seed-032 2.ts +32 -0
  687. package/dist/packages/crucible/seeds/ts/seed-032.ts +32 -0
  688. package/dist/packages/crucible/seeds/ts/seed-033 2.ts +32 -0
  689. package/dist/packages/crucible/seeds/ts/seed-033.ts +32 -0
  690. package/dist/packages/crucible/seeds/ts/seed-034 2.ts +34 -0
  691. package/dist/packages/crucible/seeds/ts/seed-034.ts +34 -0
  692. package/dist/packages/crucible/seeds/ts/seed-035 2.ts +29 -0
  693. package/dist/packages/crucible/seeds/ts/seed-035.ts +29 -0
  694. package/dist/packages/crucible/seeds/ts/seed-036 2.ts +34 -0
  695. package/dist/packages/crucible/seeds/ts/seed-036.ts +34 -0
  696. package/dist/packages/crucible/seeds/ts/seed-037 2.ts +33 -0
  697. package/dist/packages/crucible/seeds/ts/seed-037.ts +33 -0
  698. package/dist/packages/crucible/seeds/ts/seed-038 2.ts +29 -0
  699. package/dist/packages/crucible/seeds/ts/seed-038.ts +29 -0
  700. package/dist/packages/crucible/seeds/ts/seed-039 2.ts +35 -0
  701. package/dist/packages/crucible/seeds/ts/seed-039.ts +35 -0
  702. package/dist/packages/crucible/seeds/ts/seed-040 2.ts +31 -0
  703. package/dist/packages/crucible/seeds/ts/seed-040.ts +31 -0
  704. package/dist/packages/crucible/seeds/ts/seed-041 2.ts +29 -0
  705. package/dist/packages/crucible/seeds/ts/seed-041.ts +29 -0
  706. package/dist/packages/crucible/seeds/ts/seed-042 2.ts +33 -0
  707. package/dist/packages/crucible/seeds/ts/seed-042.ts +33 -0
  708. package/dist/packages/crucible/seeds/ts/seed-043 2.ts +32 -0
  709. package/dist/packages/crucible/seeds/ts/seed-043.ts +32 -0
  710. package/dist/packages/crucible/seeds/ts/seed-044 2.ts +36 -0
  711. package/dist/packages/crucible/seeds/ts/seed-044.ts +36 -0
  712. package/dist/packages/crucible/seeds/ts/seed-045 2.ts +39 -0
  713. package/dist/packages/crucible/seeds/ts/seed-045.ts +39 -0
  714. package/dist/packages/crucible/seeds/ts/seed-046 2.ts +41 -0
  715. package/dist/packages/crucible/seeds/ts/seed-046.ts +41 -0
  716. package/dist/packages/crucible/seeds/ts/seed-047 2.ts +33 -0
  717. package/dist/packages/crucible/seeds/ts/seed-047.ts +33 -0
  718. package/dist/packages/crucible/seeds/ts/seed-048 2.ts +33 -0
  719. package/dist/packages/crucible/seeds/ts/seed-048.ts +33 -0
  720. package/dist/packages/crucible/seeds/ts/seed-049 2.ts +34 -0
  721. package/dist/packages/crucible/seeds/ts/seed-049.ts +34 -0
  722. package/dist/packages/crucible/seeds/ts/seed-050 2.ts +41 -0
  723. package/dist/packages/crucible/seeds/ts/seed-050.ts +41 -0
  724. package/dist/packages/crucible/seeds/ts/seed-051 2.ts +34 -0
  725. package/dist/packages/crucible/seeds/ts/seed-051.ts +34 -0
  726. package/dist/packages/crucible/seeds/ts/seed-052 2.ts +36 -0
  727. package/dist/packages/crucible/seeds/ts/seed-052.ts +36 -0
  728. package/dist/packages/scanner/alert-manager.js +1 -0
  729. package/dist/packages/scanner/architecture-map.js +1 -0
  730. package/dist/packages/scanner/ast-analyzer.js +1 -0
  731. package/dist/packages/scanner/benchmarks.js +1 -0
  732. package/dist/packages/scanner/cfg-analyzer.js +1 -0
  733. package/dist/packages/scanner/code-scanner.js +1 -0
  734. package/dist/packages/scanner/compliance-mapper.js +1 -0
  735. package/dist/packages/scanner/file-collector.js +1 -0
  736. package/dist/packages/scanner/file-watcher.js +1 -0
  737. package/dist/packages/scanner/ghost-code-detector.js +1 -0
  738. package/dist/packages/scanner/git-velocity.js +1 -0
  739. package/dist/packages/scanner/hallucination-detector.js +1 -0
  740. package/dist/packages/scanner/health-checker.js +1 -0
  741. package/dist/packages/scanner/investor-report.js +1 -0
  742. package/dist/packages/scanner/json-file-util.js +1 -0
  743. package/dist/packages/scanner/monitor-store.js +1 -0
  744. package/dist/packages/scanner/python_ast_helper.py +426 -0
  745. package/dist/packages/scanner/risk-valuation.js +1 -0
  746. package/dist/packages/scanner/scan-history.js +1 -0
  747. package/dist/packages/scanner/secret-scanner.js +1 -0
  748. package/dist/packages/scanner/sentinel-core.js +1 -0
  749. package/dist/packages/scanner/supply-chain.js +1 -0
  750. package/dist/packages/scanner/support-bot.js +1 -0
  751. package/dist/packages/scanner/support-knowledge.js +1 -0
  752. package/dist/packages/scanner/taint-tracker.js +1 -0
  753. package/package.json +15 -13
  754. package/cli.js +0 -2
  755. package/packages/crucible/.golden/golden-master.json +0 -414
  756. package/packages/crucible/README.md +0 -93
  757. package/packages/crucible/report-generator.js +0 -1
  758. package/packages/crucible/rules/code-scanner-core.json +0 -281
  759. package/packages/crucible/rules/command-injection.json +0 -411
  760. package/packages/crucible/rules/crypto-misuse.json +0 -35
  761. package/packages/crucible/rules/deserialization.json +0 -152
  762. package/packages/crucible/rules/env-injection.json +0 -46
  763. package/packages/crucible/rules/eval-abuse.json +0 -104
  764. package/packages/crucible/rules/file-upload.json +0 -46
  765. package/packages/crucible/rules/hallucination.json +0 -22
  766. package/packages/crucible/rules/hardcoded-secret.json +0 -397
  767. package/packages/crucible/rules/hardcoded-url.json +0 -13
  768. package/packages/crucible/rules/insecure-crypto.json +0 -302
  769. package/packages/crucible/rules/integer-overflow.json +0 -35
  770. package/packages/crucible/rules/log-injection.json +0 -33
  771. package/packages/crucible/rules/mass-assignment.json +0 -112
  772. package/packages/crucible/rules/open-redirect.json +0 -196
  773. package/packages/crucible/rules/path-traversal.json +0 -422
  774. package/packages/crucible/rules/prototype-pollution.json +0 -22
  775. package/packages/crucible/rules/sql-injection.json +0 -619
  776. package/packages/crucible/rules/ssrf.json +0 -557
  777. package/packages/crucible/rules/timing-attack.json +0 -55
  778. package/packages/crucible/rules/unsafe-block.json +0 -24
  779. package/packages/crucible/rules/xss.json +0 -663
  780. package/packages/crucible/rules/xxe.json +0 -66
  781. package/packages/crucible/rules/yaml-deserialization.json +0 -22
  782. package/packages/crucible/rules/yaml-injection.json +0 -22
  783. package/packages/crucible/seeds/csharp/seed-001.cs +0 -28
  784. package/packages/crucible/seeds/csharp/seed-002.cs +0 -24
  785. package/packages/crucible/seeds/csharp/seed-003.cs +0 -30
  786. package/packages/crucible/seeds/csharp/seed-004.cs +0 -31
  787. package/packages/crucible/seeds/csharp/seed-005.cs +0 -28
  788. package/packages/crucible/seeds/csharp/seed-006.cs +0 -25
  789. package/packages/crucible/seeds/csharp/seed-007.cs +0 -34
  790. package/packages/crucible/seeds/csharp/seed-008.cs +0 -23
  791. package/packages/crucible/seeds/csharp/seed-009.cs +0 -27
  792. package/packages/crucible/seeds/csharp/seed-010.cs +0 -29
  793. package/packages/crucible/seeds/csharp/seed-011.cs +0 -32
  794. package/packages/crucible/seeds/csharp/seed-012.cs +0 -27
  795. package/packages/crucible/seeds/csharp/seed-013.cs +0 -27
  796. package/packages/crucible/seeds/csharp/seed-014.cs +0 -26
  797. package/packages/crucible/seeds/csharp/seed-015.cs +0 -33
  798. package/packages/crucible/seeds/csharp/seed-016.cs +0 -25
  799. package/packages/crucible/seeds/csharp/seed-017.cs +0 -22
  800. package/packages/crucible/seeds/csharp/seed-018.cs +0 -26
  801. package/packages/crucible/seeds/csharp/seed-019.cs +0 -25
  802. package/packages/crucible/seeds/csharp/seed-020.cs +0 -22
  803. package/packages/crucible/seeds/csharp/seed-021.cs +0 -28
  804. package/packages/crucible/seeds/csharp/seed-022.cs +0 -25
  805. package/packages/crucible/seeds/csharp/seed-023.cs +0 -33
  806. package/packages/crucible/seeds/csharp/seed-024.cs +0 -31
  807. package/packages/crucible/seeds/csharp/seed-025.cs +0 -31
  808. package/packages/crucible/seeds/csharp/seed-026.cs +0 -25
  809. package/packages/crucible/seeds/csharp/seed-027.cs +0 -29
  810. package/packages/crucible/seeds/csharp/seed-028.cs +0 -25
  811. package/packages/crucible/seeds/csharp/seed-029.cs +0 -27
  812. package/packages/crucible/seeds/csharp/seed-030.cs +0 -27
  813. package/packages/crucible/seeds/csharp/seed-031.cs +0 -28
  814. package/packages/crucible/seeds/csharp/seed-032.cs +0 -30
  815. package/packages/crucible/seeds/csharp/seed-033.cs +0 -27
  816. package/packages/crucible/seeds/csharp/seed-034.cs +0 -25
  817. package/packages/crucible/seeds/csharp/seed-035.cs +0 -32
  818. package/packages/crucible/seeds/csharp/seed-036.cs +0 -28
  819. package/packages/crucible/seeds/csharp/seed-037.cs +0 -29
  820. package/packages/crucible/seeds/csharp/seed-038.cs +0 -28
  821. package/packages/crucible/seeds/csharp/seed-039.cs +0 -29
  822. package/packages/crucible/seeds/csharp/seed-040.cs +0 -28
  823. package/packages/crucible/seeds/csharp/seed-041.cs +0 -33
  824. package/packages/crucible/seeds/csharp/seed-042.cs +0 -27
  825. package/packages/crucible/seeds/csharp/seed-043.cs +0 -27
  826. package/packages/crucible/seeds/csharp/seed-044.cs +0 -25
  827. package/packages/crucible/seeds/csharp/seed-045.cs +0 -30
  828. package/packages/crucible/seeds/csharp/seed-046.cs +0 -29
  829. package/packages/crucible/seeds/csharp/seed-047.cs +0 -26
  830. package/packages/crucible/seeds/csharp/seed-048.cs +0 -31
  831. package/packages/crucible/seeds/csharp/seed-049.cs +0 -27
  832. package/packages/crucible/seeds/csharp/seed-050.cs +0 -30
  833. package/packages/crucible/seeds/csharp/seed-051.cs +0 -34
  834. package/packages/crucible/seeds/csharp/seed-052.cs +0 -36
  835. package/packages/crucible/seeds/go/seed-001.go +0 -29
  836. package/packages/crucible/seeds/go/seed-002.go +0 -27
  837. package/packages/crucible/seeds/go/seed-003.go +0 -31
  838. package/packages/crucible/seeds/go/seed-004.go +0 -27
  839. package/packages/crucible/seeds/go/seed-005.go +0 -27
  840. package/packages/crucible/seeds/go/seed-006.go +0 -29
  841. package/packages/crucible/seeds/go/seed-007.go +0 -24
  842. package/packages/crucible/seeds/go/seed-008.go +0 -25
  843. package/packages/crucible/seeds/go/seed-009.go +0 -30
  844. package/packages/crucible/seeds/go/seed-010.go +0 -35
  845. package/packages/crucible/seeds/go/seed-011.go +0 -24
  846. package/packages/crucible/seeds/go/seed-012.go +0 -24
  847. package/packages/crucible/seeds/go/seed-013.go +0 -31
  848. package/packages/crucible/seeds/go/seed-014.go +0 -35
  849. package/packages/crucible/seeds/go/seed-015.go +0 -25
  850. package/packages/crucible/seeds/go/seed-016.go +0 -19
  851. package/packages/crucible/seeds/go/seed-017.go +0 -23
  852. package/packages/crucible/seeds/go/seed-018.go +0 -23
  853. package/packages/crucible/seeds/go/seed-019.go +0 -22
  854. package/packages/crucible/seeds/go/seed-020.go +0 -31
  855. package/packages/crucible/seeds/go/seed-021.go +0 -22
  856. package/packages/crucible/seeds/go/seed-022.go +0 -29
  857. package/packages/crucible/seeds/go/seed-023.go +0 -26
  858. package/packages/crucible/seeds/go/seed-024.go +0 -27
  859. package/packages/crucible/seeds/go/seed-025.go +0 -23
  860. package/packages/crucible/seeds/go/seed-026.go +0 -29
  861. package/packages/crucible/seeds/go/seed-027.go +0 -26
  862. package/packages/crucible/seeds/go/seed-028.go +0 -23
  863. package/packages/crucible/seeds/go/seed-029.go +0 -28
  864. package/packages/crucible/seeds/go/seed-030.go +0 -27
  865. package/packages/crucible/seeds/go/seed-031.go +0 -28
  866. package/packages/crucible/seeds/go/seed-032.go +0 -27
  867. package/packages/crucible/seeds/go/seed-033.go +0 -29
  868. package/packages/crucible/seeds/go/seed-034.go +0 -22
  869. package/packages/crucible/seeds/go/seed-035.go +0 -32
  870. package/packages/crucible/seeds/go/seed-036.go +0 -27
  871. package/packages/crucible/seeds/go/seed-037.go +0 -27
  872. package/packages/crucible/seeds/go/seed-038.go +0 -27
  873. package/packages/crucible/seeds/go/seed-039.go +0 -26
  874. package/packages/crucible/seeds/go/seed-040.go +0 -37
  875. package/packages/crucible/seeds/go/seed-041.go +0 -23
  876. package/packages/crucible/seeds/go/seed-042.go +0 -32
  877. package/packages/crucible/seeds/go/seed-043.go +0 -35
  878. package/packages/crucible/seeds/go/seed-044.go +0 -25
  879. package/packages/crucible/seeds/go/seed-045.go +0 -26
  880. package/packages/crucible/seeds/go/seed-046.go +0 -34
  881. package/packages/crucible/seeds/go/seed-047.go +0 -26
  882. package/packages/crucible/seeds/go/seed-048.go +0 -29
  883. package/packages/crucible/seeds/go/seed-049.go +0 -24
  884. package/packages/crucible/seeds/go/seed-050.go +0 -27
  885. package/packages/crucible/seeds/go/seed-051.go +0 -38
  886. package/packages/crucible/seeds/go/seed-052.go +0 -27
  887. package/packages/crucible/seeds/java/seed-001.java +0 -23
  888. package/packages/crucible/seeds/java/seed-002.java +0 -22
  889. package/packages/crucible/seeds/java/seed-003.java +0 -28
  890. package/packages/crucible/seeds/java/seed-004.java +0 -26
  891. package/packages/crucible/seeds/java/seed-005.java +0 -33
  892. package/packages/crucible/seeds/java/seed-006.java +0 -22
  893. package/packages/crucible/seeds/java/seed-007.java +0 -21
  894. package/packages/crucible/seeds/java/seed-008.java +0 -29
  895. package/packages/crucible/seeds/java/seed-009.java +0 -24
  896. package/packages/crucible/seeds/java/seed-010.java +0 -30
  897. package/packages/crucible/seeds/java/seed-011.java +0 -25
  898. package/packages/crucible/seeds/java/seed-012.java +0 -20
  899. package/packages/crucible/seeds/java/seed-013.java +0 -26
  900. package/packages/crucible/seeds/java/seed-014.java +0 -23
  901. package/packages/crucible/seeds/java/seed-015.java +0 -25
  902. package/packages/crucible/seeds/java/seed-016.java +0 -22
  903. package/packages/crucible/seeds/java/seed-017.java +0 -24
  904. package/packages/crucible/seeds/java/seed-018.java +0 -24
  905. package/packages/crucible/seeds/java/seed-019.java +0 -38
  906. package/packages/crucible/seeds/java/seed-020.java +0 -24
  907. package/packages/crucible/seeds/java/seed-021.java +0 -22
  908. package/packages/crucible/seeds/java/seed-022.java +0 -22
  909. package/packages/crucible/seeds/java/seed-023.java +0 -22
  910. package/packages/crucible/seeds/java/seed-024.java +0 -25
  911. package/packages/crucible/seeds/java/seed-025.java +0 -27
  912. package/packages/crucible/seeds/java/seed-026.java +0 -25
  913. package/packages/crucible/seeds/java/seed-027.java +0 -22
  914. package/packages/crucible/seeds/java/seed-028.java +0 -21
  915. package/packages/crucible/seeds/java/seed-029.java +0 -28
  916. package/packages/crucible/seeds/java/seed-030.java +0 -27
  917. package/packages/crucible/seeds/java/seed-031.java +0 -23
  918. package/packages/crucible/seeds/java/seed-032.java +0 -22
  919. package/packages/crucible/seeds/java/seed-033.java +0 -24
  920. package/packages/crucible/seeds/java/seed-034.java +0 -24
  921. package/packages/crucible/seeds/java/seed-035.java +0 -29
  922. package/packages/crucible/seeds/java/seed-036.java +0 -25
  923. package/packages/crucible/seeds/java/seed-037.java +0 -30
  924. package/packages/crucible/seeds/java/seed-038.java +0 -29
  925. package/packages/crucible/seeds/java/seed-039.java +0 -26
  926. package/packages/crucible/seeds/java/seed-040.java +0 -31
  927. package/packages/crucible/seeds/java/seed-041.java +0 -20
  928. package/packages/crucible/seeds/java/seed-042.java +0 -26
  929. package/packages/crucible/seeds/java/seed-043.java +0 -31
  930. package/packages/crucible/seeds/java/seed-044.java +0 -22
  931. package/packages/crucible/seeds/java/seed-045.java +0 -25
  932. package/packages/crucible/seeds/java/seed-046.java +0 -22
  933. package/packages/crucible/seeds/java/seed-047.java +0 -26
  934. package/packages/crucible/seeds/java/seed-048.java +0 -24
  935. package/packages/crucible/seeds/java/seed-049.java +0 -28
  936. package/packages/crucible/seeds/java/seed-050.java +0 -29
  937. package/packages/crucible/seeds/java/seed-051.java +0 -25
  938. package/packages/crucible/seeds/java/seed-052.java +0 -32
  939. package/packages/crucible/seeds/js/seed-001.js +0 -27
  940. package/packages/crucible/seeds/js/seed-002.js +0 -28
  941. package/packages/crucible/seeds/js/seed-003.js +0 -30
  942. package/packages/crucible/seeds/js/seed-004.js +0 -28
  943. package/packages/crucible/seeds/js/seed-005.js +0 -31
  944. package/packages/crucible/seeds/js/seed-006.js +0 -28
  945. package/packages/crucible/seeds/js/seed-007.js +0 -26
  946. package/packages/crucible/seeds/js/seed-008.js +0 -30
  947. package/packages/crucible/seeds/js/seed-009.js +0 -30
  948. package/packages/crucible/seeds/js/seed-010.js +0 -29
  949. package/packages/crucible/seeds/js/seed-011.js +0 -34
  950. package/packages/crucible/seeds/js/seed-012.js +0 -32
  951. package/packages/crucible/seeds/js/seed-013.js +0 -29
  952. package/packages/crucible/seeds/js/seed-014.js +0 -29
  953. package/packages/crucible/seeds/js/seed-015.js +0 -31
  954. package/packages/crucible/seeds/js/seed-016.js +0 -31
  955. package/packages/crucible/seeds/js/seed-017.js +0 -30
  956. package/packages/crucible/seeds/js/seed-018.js +0 -29
  957. package/packages/crucible/seeds/js/seed-019.js +0 -32
  958. package/packages/crucible/seeds/js/seed-020.js +0 -29
  959. package/packages/crucible/seeds/js/seed-021.js +0 -31
  960. package/packages/crucible/seeds/js/seed-022.js +0 -31
  961. package/packages/crucible/seeds/js/seed-023.js +0 -29
  962. package/packages/crucible/seeds/js/seed-024.js +0 -29
  963. package/packages/crucible/seeds/js/seed-025.js +0 -34
  964. package/packages/crucible/seeds/js/seed-026.js +0 -31
  965. package/packages/crucible/seeds/js/seed-027.js +0 -31
  966. package/packages/crucible/seeds/js/seed-028.js +0 -33
  967. package/packages/crucible/seeds/js/seed-029.js +0 -33
  968. package/packages/crucible/seeds/js/seed-030.js +0 -30
  969. package/packages/crucible/seeds/js/seed-031.js +0 -31
  970. package/packages/crucible/seeds/js/seed-032.js +0 -34
  971. package/packages/crucible/seeds/js/seed-033.js +0 -33
  972. package/packages/crucible/seeds/js/seed-034.js +0 -33
  973. package/packages/crucible/seeds/js/seed-035.js +0 -30
  974. package/packages/crucible/seeds/js/seed-036.js +0 -30
  975. package/packages/crucible/seeds/js/seed-037.js +0 -29
  976. package/packages/crucible/seeds/js/seed-038.js +0 -31
  977. package/packages/crucible/seeds/js/seed-039.js +0 -34
  978. package/packages/crucible/seeds/js/seed-040.js +0 -35
  979. package/packages/crucible/seeds/js/seed-041.js +0 -32
  980. package/packages/crucible/seeds/js/seed-042.js +0 -32
  981. package/packages/crucible/seeds/js/seed-043.js +0 -27
  982. package/packages/crucible/seeds/js/seed-044.js +0 -29
  983. package/packages/crucible/seeds/js/seed-045.js +0 -33
  984. package/packages/crucible/seeds/js/seed-046.js +0 -33
  985. package/packages/crucible/seeds/js/seed-047.js +0 -29
  986. package/packages/crucible/seeds/js/seed-048.js +0 -29
  987. package/packages/crucible/seeds/js/seed-049.js +0 -34
  988. package/packages/crucible/seeds/js/seed-050.js +0 -34
  989. package/packages/crucible/seeds/js/seed-051.js +0 -30
  990. package/packages/crucible/seeds/js/seed-052.js +0 -30
  991. package/packages/crucible/seeds/js/seed-053.js +0 -26
  992. package/packages/crucible/seeds/js/seed-054.js +0 -35
  993. package/packages/crucible/seeds/js/seed-055.js +0 -33
  994. package/packages/crucible/seeds/kotlin/seed-001.kt +0 -24
  995. package/packages/crucible/seeds/kotlin/seed-002.kt +0 -27
  996. package/packages/crucible/seeds/kotlin/seed-003.kt +0 -29
  997. package/packages/crucible/seeds/kotlin/seed-004.kt +0 -24
  998. package/packages/crucible/seeds/kotlin/seed-005.kt +0 -29
  999. package/packages/crucible/seeds/kotlin/seed-006.kt +0 -21
  1000. package/packages/crucible/seeds/kotlin/seed-007.kt +0 -23
  1001. package/packages/crucible/seeds/kotlin/seed-008.kt +0 -25
  1002. package/packages/crucible/seeds/kotlin/seed-009.kt +0 -21
  1003. package/packages/crucible/seeds/kotlin/seed-010.kt +0 -28
  1004. package/packages/crucible/seeds/kotlin/seed-011.kt +0 -22
  1005. package/packages/crucible/seeds/kotlin/seed-012.kt +0 -25
  1006. package/packages/crucible/seeds/kotlin/seed-013.kt +0 -30
  1007. package/packages/crucible/seeds/kotlin/seed-014.kt +0 -27
  1008. package/packages/crucible/seeds/kotlin/seed-015.kt +0 -24
  1009. package/packages/crucible/seeds/kotlin/seed-016.kt +0 -28
  1010. package/packages/crucible/seeds/kotlin/seed-017.kt +0 -33
  1011. package/packages/crucible/seeds/kotlin/seed-018.kt +0 -31
  1012. package/packages/crucible/seeds/kotlin/seed-019.kt +0 -28
  1013. package/packages/crucible/seeds/kotlin/seed-020.kt +0 -31
  1014. package/packages/crucible/seeds/kotlin/seed-021.kt +0 -34
  1015. package/packages/crucible/seeds/kotlin/seed-022.kt +0 -29
  1016. package/packages/crucible/seeds/kotlin/seed-023.kt +0 -20
  1017. package/packages/crucible/seeds/kotlin/seed-024.kt +0 -23
  1018. package/packages/crucible/seeds/kotlin/seed-025.kt +0 -23
  1019. package/packages/crucible/seeds/kotlin/seed-026.kt +0 -26
  1020. package/packages/crucible/seeds/kotlin/seed-027.kt +0 -29
  1021. package/packages/crucible/seeds/kotlin/seed-028.kt +0 -24
  1022. package/packages/crucible/seeds/kotlin/seed-029.kt +0 -27
  1023. package/packages/crucible/seeds/kotlin/seed-030.kt +0 -26
  1024. package/packages/crucible/seeds/kotlin/seed-031.kt +0 -28
  1025. package/packages/crucible/seeds/kotlin/seed-032.kt +0 -29
  1026. package/packages/crucible/seeds/kotlin/seed-033.kt +0 -30
  1027. package/packages/crucible/seeds/kotlin/seed-034.kt +0 -26
  1028. package/packages/crucible/seeds/kotlin/seed-035.kt +0 -33
  1029. package/packages/crucible/seeds/kotlin/seed-036.kt +0 -25
  1030. package/packages/crucible/seeds/kotlin/seed-037.kt +0 -26
  1031. package/packages/crucible/seeds/kotlin/seed-038.kt +0 -25
  1032. package/packages/crucible/seeds/kotlin/seed-039.kt +0 -29
  1033. package/packages/crucible/seeds/kotlin/seed-040.kt +0 -28
  1034. package/packages/crucible/seeds/kotlin/seed-041.kt +0 -31
  1035. package/packages/crucible/seeds/kotlin/seed-042.kt +0 -27
  1036. package/packages/crucible/seeds/kotlin/seed-043.kt +0 -26
  1037. package/packages/crucible/seeds/kotlin/seed-044.kt +0 -27
  1038. package/packages/crucible/seeds/kotlin/seed-045.kt +0 -27
  1039. package/packages/crucible/seeds/kotlin/seed-046.kt +0 -33
  1040. package/packages/crucible/seeds/kotlin/seed-047.kt +0 -32
  1041. package/packages/crucible/seeds/kotlin/seed-048.kt +0 -20
  1042. package/packages/crucible/seeds/kotlin/seed-049.kt +0 -23
  1043. package/packages/crucible/seeds/kotlin/seed-050.kt +0 -19
  1044. package/packages/crucible/seeds/php/seed-001.php +0 -23
  1045. package/packages/crucible/seeds/php/seed-002.php +0 -18
  1046. package/packages/crucible/seeds/php/seed-003.php +0 -25
  1047. package/packages/crucible/seeds/php/seed-004.php +0 -21
  1048. package/packages/crucible/seeds/php/seed-005.php +0 -21
  1049. package/packages/crucible/seeds/php/seed-006.php +0 -21
  1050. package/packages/crucible/seeds/php/seed-007.php +0 -18
  1051. package/packages/crucible/seeds/php/seed-008.php +0 -19
  1052. package/packages/crucible/seeds/php/seed-009.php +0 -24
  1053. package/packages/crucible/seeds/php/seed-010.php +0 -24
  1054. package/packages/crucible/seeds/php/seed-011.php +0 -18
  1055. package/packages/crucible/seeds/php/seed-012.php +0 -24
  1056. package/packages/crucible/seeds/php/seed-013.php +0 -23
  1057. package/packages/crucible/seeds/php/seed-014.php +0 -20
  1058. package/packages/crucible/seeds/php/seed-015.php +0 -18
  1059. package/packages/crucible/seeds/php/seed-016.php +0 -18
  1060. package/packages/crucible/seeds/php/seed-017.php +0 -18
  1061. package/packages/crucible/seeds/php/seed-018.php +0 -17
  1062. package/packages/crucible/seeds/php/seed-019.php +0 -24
  1063. package/packages/crucible/seeds/php/seed-020.php +0 -19
  1064. package/packages/crucible/seeds/php/seed-021.php +0 -22
  1065. package/packages/crucible/seeds/php/seed-022.php +0 -15
  1066. package/packages/crucible/seeds/php/seed-023.php +0 -24
  1067. package/packages/crucible/seeds/php/seed-024.php +0 -22
  1068. package/packages/crucible/seeds/php/seed-025.php +0 -20
  1069. package/packages/crucible/seeds/php/seed-026.php +0 -22
  1070. package/packages/crucible/seeds/php/seed-027.php +0 -15
  1071. package/packages/crucible/seeds/php/seed-028.php +0 -15
  1072. package/packages/crucible/seeds/php/seed-029.php +0 -21
  1073. package/packages/crucible/seeds/php/seed-030.php +0 -21
  1074. package/packages/crucible/seeds/php/seed-031.php +0 -23
  1075. package/packages/crucible/seeds/php/seed-032.php +0 -18
  1076. package/packages/crucible/seeds/php/seed-033.php +0 -18
  1077. package/packages/crucible/seeds/php/seed-034.php +0 -24
  1078. package/packages/crucible/seeds/php/seed-035.php +0 -22
  1079. package/packages/crucible/seeds/php/seed-036.php +0 -17
  1080. package/packages/crucible/seeds/php/seed-037.php +0 -19
  1081. package/packages/crucible/seeds/php/seed-038.php +0 -20
  1082. package/packages/crucible/seeds/php/seed-039.php +0 -15
  1083. package/packages/crucible/seeds/php/seed-040.php +0 -21
  1084. package/packages/crucible/seeds/php/seed-041.php +0 -20
  1085. package/packages/crucible/seeds/php/seed-042.php +0 -21
  1086. package/packages/crucible/seeds/php/seed-043.php +0 -21
  1087. package/packages/crucible/seeds/php/seed-044.php +0 -25
  1088. package/packages/crucible/seeds/php/seed-045.php +0 -25
  1089. package/packages/crucible/seeds/php/seed-046.php +0 -20
  1090. package/packages/crucible/seeds/php/seed-047.php +0 -21
  1091. package/packages/crucible/seeds/php/seed-048.php +0 -19
  1092. package/packages/crucible/seeds/php/seed-049.php +0 -18
  1093. package/packages/crucible/seeds/php/seed-050.php +0 -20
  1094. package/packages/crucible/seeds/python/seed-001.py +0 -33
  1095. package/packages/crucible/seeds/python/seed-002.py +0 -39
  1096. package/packages/crucible/seeds/python/seed-003.py +0 -31
  1097. package/packages/crucible/seeds/python/seed-004.py +0 -33
  1098. package/packages/crucible/seeds/python/seed-005.py +0 -33
  1099. package/packages/crucible/seeds/python/seed-006.py +0 -34
  1100. package/packages/crucible/seeds/python/seed-007.py +0 -33
  1101. package/packages/crucible/seeds/python/seed-008.py +0 -38
  1102. package/packages/crucible/seeds/python/seed-009.py +0 -38
  1103. package/packages/crucible/seeds/python/seed-010.py +0 -42
  1104. package/packages/crucible/seeds/python/seed-011.py +0 -30
  1105. package/packages/crucible/seeds/python/seed-012.py +0 -35
  1106. package/packages/crucible/seeds/python/seed-013.py +0 -33
  1107. package/packages/crucible/seeds/python/seed-014.py +0 -40
  1108. package/packages/crucible/seeds/python/seed-015.py +0 -33
  1109. package/packages/crucible/seeds/python/seed-016.py +0 -34
  1110. package/packages/crucible/seeds/python/seed-017.py +0 -34
  1111. package/packages/crucible/seeds/python/seed-018.py +0 -30
  1112. package/packages/crucible/seeds/python/seed-019.py +0 -33
  1113. package/packages/crucible/seeds/python/seed-020.py +0 -37
  1114. package/packages/crucible/seeds/python/seed-021 2.py +0 -37
  1115. package/packages/crucible/seeds/python/seed-021.py +0 -37
  1116. package/packages/crucible/seeds/python/seed-022 2.py +0 -34
  1117. package/packages/crucible/seeds/python/seed-022.py +0 -34
  1118. package/packages/crucible/seeds/python/seed-023 2.py +0 -37
  1119. package/packages/crucible/seeds/python/seed-023.py +0 -37
  1120. package/packages/crucible/seeds/python/seed-024 2.py +0 -38
  1121. package/packages/crucible/seeds/python/seed-024.py +0 -38
  1122. package/packages/crucible/seeds/python/seed-025 2.py +0 -40
  1123. package/packages/crucible/seeds/python/seed-025.py +0 -40
  1124. package/packages/crucible/seeds/python/seed-026 2.py +0 -35
  1125. package/packages/crucible/seeds/python/seed-026.py +0 -35
  1126. package/packages/crucible/seeds/python/seed-027 2.py +0 -35
  1127. package/packages/crucible/seeds/python/seed-027.py +0 -35
  1128. package/packages/crucible/seeds/python/seed-028 2.py +0 -42
  1129. package/packages/crucible/seeds/python/seed-028.py +0 -42
  1130. package/packages/crucible/seeds/python/seed-029.py +0 -42
  1131. package/packages/crucible/seeds/python/seed-030 2.py +0 -37
  1132. package/packages/crucible/seeds/python/seed-030.py +0 -37
  1133. package/packages/crucible/seeds/python/seed-031 2.py +0 -34
  1134. package/packages/crucible/seeds/python/seed-031.py +0 -34
  1135. package/packages/crucible/seeds/python/seed-032.py +0 -33
  1136. package/packages/crucible/seeds/python/seed-033.py +0 -32
  1137. package/packages/crucible/seeds/python/seed-034.py +0 -38
  1138. package/packages/crucible/seeds/python/seed-035.py +0 -35
  1139. package/packages/crucible/seeds/python/seed-036 2.py +0 -33
  1140. package/packages/crucible/seeds/python/seed-036.py +0 -33
  1141. package/packages/crucible/seeds/python/seed-037 2.py +0 -41
  1142. package/packages/crucible/seeds/python/seed-037.py +0 -41
  1143. package/packages/crucible/seeds/python/seed-038 2.py +0 -33
  1144. package/packages/crucible/seeds/python/seed-038.py +0 -33
  1145. package/packages/crucible/seeds/python/seed-039 2.py +0 -39
  1146. package/packages/crucible/seeds/python/seed-039.py +0 -39
  1147. package/packages/crucible/seeds/python/seed-040 2.py +0 -39
  1148. package/packages/crucible/seeds/python/seed-040.py +0 -39
  1149. package/packages/crucible/seeds/python/seed-041 2.py +0 -37
  1150. package/packages/crucible/seeds/python/seed-041.py +0 -37
  1151. package/packages/crucible/seeds/python/seed-042 2.py +0 -38
  1152. package/packages/crucible/seeds/python/seed-042.py +0 -38
  1153. package/packages/crucible/seeds/python/seed-043 2.py +0 -32
  1154. package/packages/crucible/seeds/python/seed-043.py +0 -32
  1155. package/packages/crucible/seeds/python/seed-044 2.py +0 -38
  1156. package/packages/crucible/seeds/python/seed-044.py +0 -38
  1157. package/packages/crucible/seeds/python/seed-045 2.py +0 -36
  1158. package/packages/crucible/seeds/python/seed-045.py +0 -36
  1159. package/packages/crucible/seeds/python/seed-046 2.py +0 -33
  1160. package/packages/crucible/seeds/python/seed-046.py +0 -33
  1161. package/packages/crucible/seeds/python/seed-047 2.py +0 -44
  1162. package/packages/crucible/seeds/python/seed-047.py +0 -44
  1163. package/packages/crucible/seeds/python/seed-048 2.py +0 -35
  1164. package/packages/crucible/seeds/python/seed-048.py +0 -35
  1165. package/packages/crucible/seeds/python/seed-049 2.py +0 -39
  1166. package/packages/crucible/seeds/python/seed-049.py +0 -39
  1167. package/packages/crucible/seeds/python/seed-050 2.py +0 -39
  1168. package/packages/crucible/seeds/python/seed-050.py +0 -39
  1169. package/packages/crucible/seeds/python/seed-051 2.py +0 -38
  1170. package/packages/crucible/seeds/python/seed-051.py +0 -38
  1171. package/packages/crucible/seeds/python/seed-052 2.py +0 -41
  1172. package/packages/crucible/seeds/python/seed-052.py +0 -41
  1173. package/packages/crucible/seeds/ruby/seed-001 2.rb +0 -15
  1174. package/packages/crucible/seeds/ruby/seed-001.rb +0 -15
  1175. package/packages/crucible/seeds/ruby/seed-002 2.rb +0 -22
  1176. package/packages/crucible/seeds/ruby/seed-002.rb +0 -22
  1177. package/packages/crucible/seeds/ruby/seed-003 2.rb +0 -25
  1178. package/packages/crucible/seeds/ruby/seed-003.rb +0 -25
  1179. package/packages/crucible/seeds/ruby/seed-004 2.rb +0 -17
  1180. package/packages/crucible/seeds/ruby/seed-004.rb +0 -17
  1181. package/packages/crucible/seeds/ruby/seed-005 2.rb +0 -21
  1182. package/packages/crucible/seeds/ruby/seed-005.rb +0 -21
  1183. package/packages/crucible/seeds/ruby/seed-006 2.rb +0 -17
  1184. package/packages/crucible/seeds/ruby/seed-006.rb +0 -17
  1185. package/packages/crucible/seeds/ruby/seed-007 2.rb +0 -16
  1186. package/packages/crucible/seeds/ruby/seed-007.rb +0 -16
  1187. package/packages/crucible/seeds/ruby/seed-008 2.rb +0 -18
  1188. package/packages/crucible/seeds/ruby/seed-008.rb +0 -18
  1189. package/packages/crucible/seeds/ruby/seed-009 2.rb +0 -20
  1190. package/packages/crucible/seeds/ruby/seed-009.rb +0 -20
  1191. package/packages/crucible/seeds/ruby/seed-010 2.rb +0 -24
  1192. package/packages/crucible/seeds/ruby/seed-010.rb +0 -24
  1193. package/packages/crucible/seeds/ruby/seed-011 2.rb +0 -21
  1194. package/packages/crucible/seeds/ruby/seed-011.rb +0 -21
  1195. package/packages/crucible/seeds/ruby/seed-012 2.rb +0 -22
  1196. package/packages/crucible/seeds/ruby/seed-012.rb +0 -22
  1197. package/packages/crucible/seeds/ruby/seed-013 2.rb +0 -21
  1198. package/packages/crucible/seeds/ruby/seed-013.rb +0 -21
  1199. package/packages/crucible/seeds/ruby/seed-014 2.rb +0 -16
  1200. package/packages/crucible/seeds/ruby/seed-014.rb +0 -16
  1201. package/packages/crucible/seeds/ruby/seed-015 2.rb +0 -18
  1202. package/packages/crucible/seeds/ruby/seed-015.rb +0 -18
  1203. package/packages/crucible/seeds/ruby/seed-016 2.rb +0 -17
  1204. package/packages/crucible/seeds/ruby/seed-016.rb +0 -17
  1205. package/packages/crucible/seeds/ruby/seed-017 2.rb +0 -25
  1206. package/packages/crucible/seeds/ruby/seed-017.rb +0 -25
  1207. package/packages/crucible/seeds/ruby/seed-018 2.rb +0 -23
  1208. package/packages/crucible/seeds/ruby/seed-018.rb +0 -23
  1209. package/packages/crucible/seeds/ruby/seed-019 2.rb +0 -20
  1210. package/packages/crucible/seeds/ruby/seed-019.rb +0 -20
  1211. package/packages/crucible/seeds/ruby/seed-020 2.rb +0 -17
  1212. package/packages/crucible/seeds/ruby/seed-020.rb +0 -17
  1213. package/packages/crucible/seeds/ruby/seed-021 2.rb +0 -20
  1214. package/packages/crucible/seeds/ruby/seed-021.rb +0 -20
  1215. package/packages/crucible/seeds/ruby/seed-022 2.rb +0 -21
  1216. package/packages/crucible/seeds/ruby/seed-022.rb +0 -21
  1217. package/packages/crucible/seeds/ruby/seed-023 2.rb +0 -19
  1218. package/packages/crucible/seeds/ruby/seed-023.rb +0 -19
  1219. package/packages/crucible/seeds/ruby/seed-024 2.rb +0 -17
  1220. package/packages/crucible/seeds/ruby/seed-024.rb +0 -17
  1221. package/packages/crucible/seeds/ruby/seed-025 2.rb +0 -17
  1222. package/packages/crucible/seeds/ruby/seed-025.rb +0 -17
  1223. package/packages/crucible/seeds/ruby/seed-026 2.rb +0 -18
  1224. package/packages/crucible/seeds/ruby/seed-026.rb +0 -18
  1225. package/packages/crucible/seeds/ruby/seed-027 2.rb +0 -21
  1226. package/packages/crucible/seeds/ruby/seed-027.rb +0 -21
  1227. package/packages/crucible/seeds/ruby/seed-028 2.rb +0 -22
  1228. package/packages/crucible/seeds/ruby/seed-028.rb +0 -22
  1229. package/packages/crucible/seeds/ruby/seed-029 2.rb +0 -19
  1230. package/packages/crucible/seeds/ruby/seed-029.rb +0 -19
  1231. package/packages/crucible/seeds/ruby/seed-030 2.rb +0 -20
  1232. package/packages/crucible/seeds/ruby/seed-030.rb +0 -20
  1233. package/packages/crucible/seeds/ruby/seed-031 2.rb +0 -17
  1234. package/packages/crucible/seeds/ruby/seed-031.rb +0 -17
  1235. package/packages/crucible/seeds/ruby/seed-032 2.rb +0 -22
  1236. package/packages/crucible/seeds/ruby/seed-032.rb +0 -22
  1237. package/packages/crucible/seeds/ruby/seed-033 2.rb +0 -18
  1238. package/packages/crucible/seeds/ruby/seed-033.rb +0 -18
  1239. package/packages/crucible/seeds/ruby/seed-034 2.rb +0 -19
  1240. package/packages/crucible/seeds/ruby/seed-034.rb +0 -19
  1241. package/packages/crucible/seeds/ruby/seed-035 2.rb +0 -19
  1242. package/packages/crucible/seeds/ruby/seed-035.rb +0 -19
  1243. package/packages/crucible/seeds/ruby/seed-036 2.rb +0 -18
  1244. package/packages/crucible/seeds/ruby/seed-036.rb +0 -18
  1245. package/packages/crucible/seeds/ruby/seed-037 2.rb +0 -21
  1246. package/packages/crucible/seeds/ruby/seed-037.rb +0 -21
  1247. package/packages/crucible/seeds/ruby/seed-038 2.rb +0 -24
  1248. package/packages/crucible/seeds/ruby/seed-038.rb +0 -24
  1249. package/packages/crucible/seeds/ruby/seed-039 2.rb +0 -24
  1250. package/packages/crucible/seeds/ruby/seed-039.rb +0 -24
  1251. package/packages/crucible/seeds/ruby/seed-040 2.rb +0 -22
  1252. package/packages/crucible/seeds/ruby/seed-040.rb +0 -22
  1253. package/packages/crucible/seeds/ruby/seed-041 2.rb +0 -23
  1254. package/packages/crucible/seeds/ruby/seed-041.rb +0 -23
  1255. package/packages/crucible/seeds/ruby/seed-042 2.rb +0 -25
  1256. package/packages/crucible/seeds/ruby/seed-042.rb +0 -25
  1257. package/packages/crucible/seeds/ruby/seed-043 2.rb +0 -23
  1258. package/packages/crucible/seeds/ruby/seed-043.rb +0 -23
  1259. package/packages/crucible/seeds/ruby/seed-044 2.rb +0 -16
  1260. package/packages/crucible/seeds/ruby/seed-044.rb +0 -16
  1261. package/packages/crucible/seeds/ruby/seed-045 2.rb +0 -22
  1262. package/packages/crucible/seeds/ruby/seed-045.rb +0 -22
  1263. package/packages/crucible/seeds/ruby/seed-046 2.rb +0 -27
  1264. package/packages/crucible/seeds/ruby/seed-046.rb +0 -27
  1265. package/packages/crucible/seeds/ruby/seed-047 2.rb +0 -26
  1266. package/packages/crucible/seeds/ruby/seed-047.rb +0 -26
  1267. package/packages/crucible/seeds/ruby/seed-048 2.rb +0 -24
  1268. package/packages/crucible/seeds/ruby/seed-048.rb +0 -24
  1269. package/packages/crucible/seeds/ruby/seed-049 2.rb +0 -20
  1270. package/packages/crucible/seeds/ruby/seed-049.rb +0 -20
  1271. package/packages/crucible/seeds/ruby/seed-050 2.rb +0 -27
  1272. package/packages/crucible/seeds/ruby/seed-050.rb +0 -27
  1273. package/packages/crucible/seeds/rust/seed-001 2.rs +0 -25
  1274. package/packages/crucible/seeds/rust/seed-001.rs +0 -25
  1275. package/packages/crucible/seeds/rust/seed-002 2.rs +0 -20
  1276. package/packages/crucible/seeds/rust/seed-002.rs +0 -20
  1277. package/packages/crucible/seeds/rust/seed-003 2.rs +0 -23
  1278. package/packages/crucible/seeds/rust/seed-003.rs +0 -23
  1279. package/packages/crucible/seeds/rust/seed-004 2.rs +0 -21
  1280. package/packages/crucible/seeds/rust/seed-004.rs +0 -21
  1281. package/packages/crucible/seeds/rust/seed-005 2.rs +0 -21
  1282. package/packages/crucible/seeds/rust/seed-005.rs +0 -21
  1283. package/packages/crucible/seeds/rust/seed-006 2.rs +0 -24
  1284. package/packages/crucible/seeds/rust/seed-006.rs +0 -24
  1285. package/packages/crucible/seeds/rust/seed-007 2.rs +0 -20
  1286. package/packages/crucible/seeds/rust/seed-007.rs +0 -20
  1287. package/packages/crucible/seeds/rust/seed-008 2.rs +0 -19
  1288. package/packages/crucible/seeds/rust/seed-008.rs +0 -19
  1289. package/packages/crucible/seeds/rust/seed-009 2.rs +0 -28
  1290. package/packages/crucible/seeds/rust/seed-009.rs +0 -28
  1291. package/packages/crucible/seeds/rust/seed-010 2.rs +0 -28
  1292. package/packages/crucible/seeds/rust/seed-010.rs +0 -28
  1293. package/packages/crucible/seeds/rust/seed-011 2.rs +0 -25
  1294. package/packages/crucible/seeds/rust/seed-011.rs +0 -25
  1295. package/packages/crucible/seeds/rust/seed-012 2.rs +0 -31
  1296. package/packages/crucible/seeds/rust/seed-012.rs +0 -31
  1297. package/packages/crucible/seeds/rust/seed-013 2.rs +0 -27
  1298. package/packages/crucible/seeds/rust/seed-013.rs +0 -27
  1299. package/packages/crucible/seeds/rust/seed-014 2.rs +0 -30
  1300. package/packages/crucible/seeds/rust/seed-014.rs +0 -30
  1301. package/packages/crucible/seeds/rust/seed-015 2.rs +0 -33
  1302. package/packages/crucible/seeds/rust/seed-015.rs +0 -33
  1303. package/packages/crucible/seeds/rust/seed-016 2.rs +0 -22
  1304. package/packages/crucible/seeds/rust/seed-016.rs +0 -22
  1305. package/packages/crucible/seeds/rust/seed-017 2.rs +0 -28
  1306. package/packages/crucible/seeds/rust/seed-017.rs +0 -28
  1307. package/packages/crucible/seeds/rust/seed-018 2.rs +0 -21
  1308. package/packages/crucible/seeds/rust/seed-018.rs +0 -21
  1309. package/packages/crucible/seeds/rust/seed-019 2.rs +0 -36
  1310. package/packages/crucible/seeds/rust/seed-019.rs +0 -36
  1311. package/packages/crucible/seeds/rust/seed-020 2.rs +0 -27
  1312. package/packages/crucible/seeds/rust/seed-020.rs +0 -27
  1313. package/packages/crucible/seeds/rust/seed-021 2.rs +0 -26
  1314. package/packages/crucible/seeds/rust/seed-021.rs +0 -26
  1315. package/packages/crucible/seeds/rust/seed-022 2.rs +0 -23
  1316. package/packages/crucible/seeds/rust/seed-022.rs +0 -23
  1317. package/packages/crucible/seeds/rust/seed-023 2.rs +0 -22
  1318. package/packages/crucible/seeds/rust/seed-023.rs +0 -22
  1319. package/packages/crucible/seeds/rust/seed-024 2.rs +0 -24
  1320. package/packages/crucible/seeds/rust/seed-024.rs +0 -24
  1321. package/packages/crucible/seeds/rust/seed-025 2.rs +0 -29
  1322. package/packages/crucible/seeds/rust/seed-025.rs +0 -29
  1323. package/packages/crucible/seeds/rust/seed-026 2.rs +0 -23
  1324. package/packages/crucible/seeds/rust/seed-026.rs +0 -23
  1325. package/packages/crucible/seeds/rust/seed-027 2.rs +0 -24
  1326. package/packages/crucible/seeds/rust/seed-027.rs +0 -24
  1327. package/packages/crucible/seeds/rust/seed-028 2.rs +0 -25
  1328. package/packages/crucible/seeds/rust/seed-028.rs +0 -25
  1329. package/packages/crucible/seeds/rust/seed-029 2.rs +0 -25
  1330. package/packages/crucible/seeds/rust/seed-029.rs +0 -25
  1331. package/packages/crucible/seeds/rust/seed-030 2.rs +0 -30
  1332. package/packages/crucible/seeds/rust/seed-030.rs +0 -30
  1333. package/packages/crucible/seeds/rust/seed-031 2.rs +0 -22
  1334. package/packages/crucible/seeds/rust/seed-031.rs +0 -22
  1335. package/packages/crucible/seeds/rust/seed-032 2.rs +0 -25
  1336. package/packages/crucible/seeds/rust/seed-032.rs +0 -25
  1337. package/packages/crucible/seeds/rust/seed-033 2.rs +0 -25
  1338. package/packages/crucible/seeds/rust/seed-033.rs +0 -25
  1339. package/packages/crucible/seeds/rust/seed-034 2.rs +0 -20
  1340. package/packages/crucible/seeds/rust/seed-034.rs +0 -20
  1341. package/packages/crucible/seeds/rust/seed-035 2.rs +0 -28
  1342. package/packages/crucible/seeds/rust/seed-035.rs +0 -28
  1343. package/packages/crucible/seeds/rust/seed-036 2.rs +0 -26
  1344. package/packages/crucible/seeds/rust/seed-036.rs +0 -26
  1345. package/packages/crucible/seeds/rust/seed-037 2.rs +0 -31
  1346. package/packages/crucible/seeds/rust/seed-037.rs +0 -31
  1347. package/packages/crucible/seeds/rust/seed-038 2.rs +0 -25
  1348. package/packages/crucible/seeds/rust/seed-038.rs +0 -25
  1349. package/packages/crucible/seeds/rust/seed-039 2.rs +0 -28
  1350. package/packages/crucible/seeds/rust/seed-039.rs +0 -28
  1351. package/packages/crucible/seeds/rust/seed-040 2.rs +0 -27
  1352. package/packages/crucible/seeds/rust/seed-040.rs +0 -27
  1353. package/packages/crucible/seeds/rust/seed-041 2.rs +0 -32
  1354. package/packages/crucible/seeds/rust/seed-041.rs +0 -32
  1355. package/packages/crucible/seeds/rust/seed-042 2.rs +0 -27
  1356. package/packages/crucible/seeds/rust/seed-042.rs +0 -27
  1357. package/packages/crucible/seeds/rust/seed-043 2.rs +0 -29
  1358. package/packages/crucible/seeds/rust/seed-043.rs +0 -29
  1359. package/packages/crucible/seeds/rust/seed-044 2.rs +0 -25
  1360. package/packages/crucible/seeds/rust/seed-044.rs +0 -25
  1361. package/packages/crucible/seeds/rust/seed-045 2.rs +0 -28
  1362. package/packages/crucible/seeds/rust/seed-045.rs +0 -28
  1363. package/packages/crucible/seeds/rust/seed-046 2.rs +0 -25
  1364. package/packages/crucible/seeds/rust/seed-046.rs +0 -25
  1365. package/packages/crucible/seeds/rust/seed-047 2.rs +0 -34
  1366. package/packages/crucible/seeds/rust/seed-047.rs +0 -34
  1367. package/packages/crucible/seeds/rust/seed-048 2.rs +0 -21
  1368. package/packages/crucible/seeds/rust/seed-048.rs +0 -21
  1369. package/packages/crucible/seeds/rust/seed-049 2.rs +0 -26
  1370. package/packages/crucible/seeds/rust/seed-049.rs +0 -26
  1371. package/packages/crucible/seeds/rust/seed-050 2.rs +0 -23
  1372. package/packages/crucible/seeds/rust/seed-050.rs +0 -23
  1373. package/packages/crucible/seeds/ts/seed-001 2.ts +0 -32
  1374. package/packages/crucible/seeds/ts/seed-001.ts +0 -32
  1375. package/packages/crucible/seeds/ts/seed-002 2.ts +0 -34
  1376. package/packages/crucible/seeds/ts/seed-002.ts +0 -34
  1377. package/packages/crucible/seeds/ts/seed-003 2.ts +0 -28
  1378. package/packages/crucible/seeds/ts/seed-003.ts +0 -28
  1379. package/packages/crucible/seeds/ts/seed-004 2.ts +0 -34
  1380. package/packages/crucible/seeds/ts/seed-004.ts +0 -34
  1381. package/packages/crucible/seeds/ts/seed-005 2.ts +0 -32
  1382. package/packages/crucible/seeds/ts/seed-005.ts +0 -32
  1383. package/packages/crucible/seeds/ts/seed-006 2.ts +0 -31
  1384. package/packages/crucible/seeds/ts/seed-006.ts +0 -31
  1385. package/packages/crucible/seeds/ts/seed-007 2.ts +0 -28
  1386. package/packages/crucible/seeds/ts/seed-007.ts +0 -28
  1387. package/packages/crucible/seeds/ts/seed-008 2.ts +0 -40
  1388. package/packages/crucible/seeds/ts/seed-008.ts +0 -40
  1389. package/packages/crucible/seeds/ts/seed-009 2.ts +0 -31
  1390. package/packages/crucible/seeds/ts/seed-009.ts +0 -31
  1391. package/packages/crucible/seeds/ts/seed-010 2.ts +0 -33
  1392. package/packages/crucible/seeds/ts/seed-010.ts +0 -33
  1393. package/packages/crucible/seeds/ts/seed-011 2.ts +0 -29
  1394. package/packages/crucible/seeds/ts/seed-011.ts +0 -29
  1395. package/packages/crucible/seeds/ts/seed-012 2.ts +0 -34
  1396. package/packages/crucible/seeds/ts/seed-012.ts +0 -34
  1397. package/packages/crucible/seeds/ts/seed-013 2.ts +0 -31
  1398. package/packages/crucible/seeds/ts/seed-013.ts +0 -31
  1399. package/packages/crucible/seeds/ts/seed-014 2.ts +0 -36
  1400. package/packages/crucible/seeds/ts/seed-014.ts +0 -36
  1401. package/packages/crucible/seeds/ts/seed-015 2.ts +0 -31
  1402. package/packages/crucible/seeds/ts/seed-015.ts +0 -31
  1403. package/packages/crucible/seeds/ts/seed-016 2.ts +0 -37
  1404. package/packages/crucible/seeds/ts/seed-016.ts +0 -37
  1405. package/packages/crucible/seeds/ts/seed-017 2.ts +0 -44
  1406. package/packages/crucible/seeds/ts/seed-017.ts +0 -44
  1407. package/packages/crucible/seeds/ts/seed-018 2.ts +0 -33
  1408. package/packages/crucible/seeds/ts/seed-018.ts +0 -33
  1409. package/packages/crucible/seeds/ts/seed-019 2.ts +0 -32
  1410. package/packages/crucible/seeds/ts/seed-019.ts +0 -32
  1411. package/packages/crucible/seeds/ts/seed-020 2.ts +0 -33
  1412. package/packages/crucible/seeds/ts/seed-020.ts +0 -33
  1413. package/packages/crucible/seeds/ts/seed-021 2.ts +0 -33
  1414. package/packages/crucible/seeds/ts/seed-021.ts +0 -33
  1415. package/packages/crucible/seeds/ts/seed-022 2.ts +0 -34
  1416. package/packages/crucible/seeds/ts/seed-022.ts +0 -34
  1417. package/packages/crucible/seeds/ts/seed-023 2.ts +0 -33
  1418. package/packages/crucible/seeds/ts/seed-023.ts +0 -33
  1419. package/packages/crucible/seeds/ts/seed-024 2.ts +0 -35
  1420. package/packages/crucible/seeds/ts/seed-024.ts +0 -35
  1421. package/packages/crucible/seeds/ts/seed-025 2.ts +0 -29
  1422. package/packages/crucible/seeds/ts/seed-025.ts +0 -29
  1423. package/packages/crucible/seeds/ts/seed-026 2.ts +0 -36
  1424. package/packages/crucible/seeds/ts/seed-026.ts +0 -36
  1425. package/packages/crucible/seeds/ts/seed-027 2.ts +0 -30
  1426. package/packages/crucible/seeds/ts/seed-027.ts +0 -30
  1427. package/packages/crucible/seeds/ts/seed-028 2.ts +0 -32
  1428. package/packages/crucible/seeds/ts/seed-028.ts +0 -32
  1429. package/packages/crucible/seeds/ts/seed-029 2.ts +0 -34
  1430. package/packages/crucible/seeds/ts/seed-029.ts +0 -34
  1431. package/packages/crucible/seeds/ts/seed-030 2.ts +0 -37
  1432. package/packages/crucible/seeds/ts/seed-030.ts +0 -37
  1433. package/packages/crucible/seeds/ts/seed-031 2.ts +0 -31
  1434. package/packages/crucible/seeds/ts/seed-031.ts +0 -31
  1435. package/packages/crucible/seeds/ts/seed-032 2.ts +0 -32
  1436. package/packages/crucible/seeds/ts/seed-032.ts +0 -32
  1437. package/packages/crucible/seeds/ts/seed-033 2.ts +0 -32
  1438. package/packages/crucible/seeds/ts/seed-033.ts +0 -32
  1439. package/packages/crucible/seeds/ts/seed-034 2.ts +0 -34
  1440. package/packages/crucible/seeds/ts/seed-034.ts +0 -34
  1441. package/packages/crucible/seeds/ts/seed-035 2.ts +0 -29
  1442. package/packages/crucible/seeds/ts/seed-035.ts +0 -29
  1443. package/packages/crucible/seeds/ts/seed-036 2.ts +0 -34
  1444. package/packages/crucible/seeds/ts/seed-036.ts +0 -34
  1445. package/packages/crucible/seeds/ts/seed-037 2.ts +0 -33
  1446. package/packages/crucible/seeds/ts/seed-037.ts +0 -33
  1447. package/packages/crucible/seeds/ts/seed-038 2.ts +0 -29
  1448. package/packages/crucible/seeds/ts/seed-038.ts +0 -29
  1449. package/packages/crucible/seeds/ts/seed-039 2.ts +0 -35
  1450. package/packages/crucible/seeds/ts/seed-039.ts +0 -35
  1451. package/packages/crucible/seeds/ts/seed-040 2.ts +0 -31
  1452. package/packages/crucible/seeds/ts/seed-040.ts +0 -31
  1453. package/packages/crucible/seeds/ts/seed-041 2.ts +0 -29
  1454. package/packages/crucible/seeds/ts/seed-041.ts +0 -29
  1455. package/packages/crucible/seeds/ts/seed-042 2.ts +0 -33
  1456. package/packages/crucible/seeds/ts/seed-042.ts +0 -33
  1457. package/packages/crucible/seeds/ts/seed-043 2.ts +0 -32
  1458. package/packages/crucible/seeds/ts/seed-043.ts +0 -32
  1459. package/packages/crucible/seeds/ts/seed-044 2.ts +0 -36
  1460. package/packages/crucible/seeds/ts/seed-044.ts +0 -36
  1461. package/packages/crucible/seeds/ts/seed-045 2.ts +0 -39
  1462. package/packages/crucible/seeds/ts/seed-045.ts +0 -39
  1463. package/packages/crucible/seeds/ts/seed-046 2.ts +0 -41
  1464. package/packages/crucible/seeds/ts/seed-046.ts +0 -41
  1465. package/packages/crucible/seeds/ts/seed-047 2.ts +0 -33
  1466. package/packages/crucible/seeds/ts/seed-047.ts +0 -33
  1467. package/packages/crucible/seeds/ts/seed-048 2.ts +0 -33
  1468. package/packages/crucible/seeds/ts/seed-048.ts +0 -33
  1469. package/packages/crucible/seeds/ts/seed-049 2.ts +0 -34
  1470. package/packages/crucible/seeds/ts/seed-049.ts +0 -34
  1471. package/packages/crucible/seeds/ts/seed-050 2.ts +0 -41
  1472. package/packages/crucible/seeds/ts/seed-050.ts +0 -41
  1473. package/packages/crucible/seeds/ts/seed-051 2.ts +0 -34
  1474. package/packages/crucible/seeds/ts/seed-051.ts +0 -34
  1475. package/packages/crucible/seeds/ts/seed-052 2.ts +0 -36
  1476. package/packages/crucible/seeds/ts/seed-052.ts +0 -36
  1477. package/packages/scanner/alert-manager.js +0 -1
  1478. package/packages/scanner/ast-analyzer.js +0 -1
  1479. package/packages/scanner/cfg-analyzer.js +0 -1
  1480. package/packages/scanner/code-scanner.js +0 -1
  1481. package/packages/scanner/file-collector.js +0 -1
  1482. package/packages/scanner/file-watcher.js +0 -1
  1483. package/packages/scanner/ghost-code-detector.js +0 -1
  1484. package/packages/scanner/hallucination-detector.js +0 -1
  1485. package/packages/scanner/health-checker.js +0 -1
  1486. package/packages/scanner/investor-report.js +0 -1
  1487. package/packages/scanner/master-health-checker.js +0 -1
  1488. package/packages/scanner/monitor-store.js +0 -1
  1489. package/packages/scanner/python_ast_helper.py +0 -426
  1490. package/packages/scanner/secret-scanner.js +0 -1
  1491. package/packages/scanner/sentinel-core.js +0 -1
  1492. package/packages/scanner/support-bot.js +0 -1
  1493. package/packages/scanner/support-knowledge.js +0 -1
  1494. package/packages/scanner/taint-tracker.js +0 -1
  1495. /package/{packages → dist/packages}/crucible/badge-generator.js +0 -0
  1496. /package/{packages → dist/packages}/crucible/banner.js +0 -0
  1497. /package/{packages → dist/packages}/crucible/ci-integration.js +0 -0
  1498. /package/{packages → dist/packages}/crucible/golden-master.js +0 -0
  1499. /package/{packages → dist/packages}/crucible/index.js +0 -0
  1500. /package/{packages → dist/packages}/crucible/kenny-mode.js +0 -0
  1501. /package/{packages → dist/packages}/crucible/leaderboard.js +0 -0
  1502. /package/{packages → dist/packages}/crucible/mutation-engine.js +0 -0
  1503. /package/{packages → dist/packages}/crucible/pattern-learner.js +0 -0
  1504. /package/{packages → dist/packages}/crucible/rule-loader.js +0 -0
  1505. /package/{packages → dist/packages}/crucible/seeding-engine.js +0 -0
  1506. /package/{packages → dist/packages}/crucible/self-attack.js +0 -0
  1507. /package/{packages → dist/packages}/scanner/ai-confidence-scorer.js +0 -0
  1508. /package/{packages → dist/packages}/scanner/baseline-manager.js +0 -0
  1509. /package/{packages → dist/packages}/scanner/codebase-passport.js +0 -0
  1510. /package/{packages → dist/packages}/scanner/copy-paste-detector.js +0 -0
  1511. /package/{packages → dist/packages}/scanner/dependency-graph.js +0 -0
  1512. /package/{packages → dist/packages}/scanner/drift-detector.js +0 -0
  1513. /package/{packages → dist/packages}/scanner/executive-report.js +0 -0
  1514. /package/{packages → dist/packages}/scanner/export-verifier.js +0 -0
  1515. /package/{packages → dist/packages}/scanner/feedback-client.js +0 -0
  1516. /package/{packages → dist/packages}/scanner/go-ast-analyzer.js +0 -0
  1517. /package/{packages → dist/packages}/scanner/html-report.js +0 -0
  1518. /package/{packages → dist/packages}/scanner/index.js +0 -0
  1519. /package/{packages → dist/packages}/scanner/license-manager.js +0 -0
  1520. /package/{packages → dist/packages}/scanner/monitor-notifier.js +0 -0
  1521. /package/{packages → dist/packages}/scanner/monitor-service.js +0 -0
  1522. /package/{packages → dist/packages}/scanner/pre-commit-gate.js +0 -0
  1523. /package/{packages → dist/packages}/scanner/python-ast-analyzer.js +0 -0
  1524. /package/{packages → dist/packages}/scanner/read-file.js +0 -0
  1525. /package/{packages → dist/packages}/scanner/scan-diff.js +0 -0
  1526. /package/{packages → dist/packages}/scanner/scan-runner.js +0 -0
  1527. /package/{packages → dist/packages}/scanner/sentinel-knowledge.js +0 -0
  1528. /package/{packages → dist/packages}/scanner/slack-notifier.js +0 -0
  1529. /package/{packages → dist/packages}/scanner/tech-debt-analyzer.js +0 -0
  1530. /package/{packages → dist/packages}/scanner/tech-debt-cost.js +0 -0
  1531. /package/{packages → dist/packages}/scanner/widget-generator.js +0 -0
@@ -1,34 +0,0 @@
1
- // [CRUCIBLE-SEED]
2
- // category: ssrf
3
- // severity: high
4
- // language: typescript
5
- // expected: SSRF via axios with user-controlled webhook URL and redirect following
6
-
7
- import axios from 'axios';
8
- import { Request, Response, Router } from 'express';
9
-
10
- const router = Router();
11
-
12
- interface WebhookConfig {
13
- url: string;
14
- secret?: string;
15
- }
16
-
17
- router.post('/webhooks/test', async (req: Request, res: Response) => {
18
- const { url, secret } = req.body as WebhookConfig;
19
- // url user-controlled — attacker probes internal network
20
- const response = await axios.post(url, { test: true, timestamp: Date.now() }, {
21
- headers: { 'X-Webhook-Secret': secret ?? '' },
22
- maxRedirects: 5, // follows redirects — can pivot to internal services
23
- timeout: 10000,
24
- });
25
- res.json({ status: response.status, data: response.data });
26
- });
27
-
28
- router.get('/import', async (req: Request, res: Response) => {
29
- const dataUrl = req.query.source as string;
30
- const { data } = await axios.get(dataUrl, { responseType: 'arraybuffer' });
31
- res.set('Content-Type', 'application/octet-stream').send(data);
32
- });
33
-
34
- export default router;
@@ -1,41 +0,0 @@
1
- // [CRUCIBLE-SEED]
2
- // category: ssrf
3
- // severity: high
4
- // language: typescript
5
- // expected: SSRF via got library with user-controlled URL in oEmbed/link-preview feature
6
-
7
- import got from 'got';
8
- import { Request, Response, Router } from 'express';
9
-
10
- const router = Router();
11
-
12
- interface LinkPreviewResult {
13
- title: string;
14
- description: string;
15
- image?: string;
16
- url: string;
17
- }
18
-
19
- router.get('/link-preview', async (req: Request, res: Response) => {
20
- const url = req.query.url as string;
21
-
22
- // url is user-controlled — attacker can reach internal services
23
- const response = await got(url, {
24
- followRedirect: true,
25
- timeout: { request: 8000 },
26
- throwHttpErrors: false,
27
- });
28
-
29
- const titleMatch = response.body.match(/<title>(.*?)<\/title>/i);
30
- const descMatch = response.body.match(/<meta name="description" content="(.*?)"/i);
31
-
32
- const result: LinkPreviewResult = {
33
- title: titleMatch?.[1] ?? '',
34
- description: descMatch?.[1] ?? '',
35
- url,
36
- };
37
-
38
- res.json(result);
39
- });
40
-
41
- export default router;
@@ -1,41 +0,0 @@
1
- // [CRUCIBLE-SEED]
2
- // category: ssrf
3
- // severity: high
4
- // language: typescript
5
- // expected: SSRF via got library with user-controlled URL in oEmbed/link-preview feature
6
-
7
- import got from 'got';
8
- import { Request, Response, Router } from 'express';
9
-
10
- const router = Router();
11
-
12
- interface LinkPreviewResult {
13
- title: string;
14
- description: string;
15
- image?: string;
16
- url: string;
17
- }
18
-
19
- router.get('/link-preview', async (req: Request, res: Response) => {
20
- const url = req.query.url as string;
21
-
22
- // url is user-controlled — attacker can reach internal services
23
- const response = await got(url, {
24
- followRedirect: true,
25
- timeout: { request: 8000 },
26
- throwHttpErrors: false,
27
- });
28
-
29
- const titleMatch = response.body.match(/<title>(.*?)<\/title>/i);
30
- const descMatch = response.body.match(/<meta name="description" content="(.*?)"/i);
31
-
32
- const result: LinkPreviewResult = {
33
- title: titleMatch?.[1] ?? '',
34
- description: descMatch?.[1] ?? '',
35
- url,
36
- };
37
-
38
- res.json(result);
39
- });
40
-
41
- export default router;
@@ -1,34 +0,0 @@
1
- // [CRUCIBLE-SEED]
2
- // category: deserialization
3
- // severity: critical
4
- // language: typescript
5
- // expected: unsafe deserialization via class-transformer plainToClass with user-controlled type
6
-
7
- import { plainToClass } from 'class-transformer';
8
- import { IsString, IsNumber } from 'class-validator';
9
- import { Request, Response, Router } from 'express';
10
-
11
- class UserDto {
12
- @IsString() username!: string;
13
- @IsString() email!: string;
14
- @IsNumber() role!: number;
15
- }
16
-
17
- class AdminDto extends UserDto {
18
- @IsString() adminToken!: string;
19
- canDeleteUsers: boolean = true;
20
- }
21
-
22
- const router = Router();
23
-
24
- router.post('/users/import', (req: Request, res: Response) => {
25
- const { type, data } = req.body;
26
-
27
- // User controls which class to deserialize into — can escalate to AdminDto
28
- const DtoClass = type === 'admin' ? AdminDto : UserDto;
29
- const instance = plainToClass(DtoClass, data);
30
- // No validation step — properties set without checking constraints
31
- res.json({ created: instance });
32
- });
33
-
34
- export default router;
@@ -1,34 +0,0 @@
1
- // [CRUCIBLE-SEED]
2
- // category: deserialization
3
- // severity: critical
4
- // language: typescript
5
- // expected: unsafe deserialization via class-transformer plainToClass with user-controlled type
6
-
7
- import { plainToClass } from 'class-transformer';
8
- import { IsString, IsNumber } from 'class-validator';
9
- import { Request, Response, Router } from 'express';
10
-
11
- class UserDto {
12
- @IsString() username!: string;
13
- @IsString() email!: string;
14
- @IsNumber() role!: number;
15
- }
16
-
17
- class AdminDto extends UserDto {
18
- @IsString() adminToken!: string;
19
- canDeleteUsers: boolean = true;
20
- }
21
-
22
- const router = Router();
23
-
24
- router.post('/users/import', (req: Request, res: Response) => {
25
- const { type, data } = req.body;
26
-
27
- // User controls which class to deserialize into — can escalate to AdminDto
28
- const DtoClass = type === 'admin' ? AdminDto : UserDto;
29
- const instance = plainToClass(DtoClass, data);
30
- // No validation step — properties set without checking constraints
31
- res.json({ created: instance });
32
- });
33
-
34
- export default router;
@@ -1,36 +0,0 @@
1
- // [CRUCIBLE-SEED]
2
- // category: deserialization
3
- // severity: high
4
- // language: typescript
5
- // expected: unsafe deserialization via JSON.parse used to dynamically dispatch method calls
6
-
7
- import { Request, Response, Router } from 'express';
8
-
9
- interface TaskDescriptor {
10
- module: string;
11
- method: string;
12
- args: unknown[];
13
- }
14
-
15
- const allowedModules: Record<string, Record<string, (...args: unknown[]) => unknown>> = {
16
- reports: require('./reports'),
17
- notifications: require('./notifications'),
18
- };
19
-
20
- router.post('/task/run', (req: Request, res: Response) => {
21
- // task is JSON-parsed from user body without schema validation
22
- const task = JSON.parse(req.body.taskJson as string) as TaskDescriptor;
23
-
24
- const mod = allowedModules[task.module];
25
- if (!mod) return res.status(400).json({ error: 'Unknown module' });
26
-
27
- const fn = mod[task.method];
28
- if (typeof fn !== 'function') return res.status(400).json({ error: 'Unknown method' });
29
-
30
- // task.args passed directly — no sanitization or type validation
31
- const result = fn(...task.args);
32
- res.json({ result });
33
- });
34
-
35
- const router2 = Router();
36
- export default router2;
@@ -1,36 +0,0 @@
1
- // [CRUCIBLE-SEED]
2
- // category: deserialization
3
- // severity: high
4
- // language: typescript
5
- // expected: unsafe deserialization via JSON.parse used to dynamically dispatch method calls
6
-
7
- import { Request, Response, Router } from 'express';
8
-
9
- interface TaskDescriptor {
10
- module: string;
11
- method: string;
12
- args: unknown[];
13
- }
14
-
15
- const allowedModules: Record<string, Record<string, (...args: unknown[]) => unknown>> = {
16
- reports: require('./reports'),
17
- notifications: require('./notifications'),
18
- };
19
-
20
- router.post('/task/run', (req: Request, res: Response) => {
21
- // task is JSON-parsed from user body without schema validation
22
- const task = JSON.parse(req.body.taskJson as string) as TaskDescriptor;
23
-
24
- const mod = allowedModules[task.module];
25
- if (!mod) return res.status(400).json({ error: 'Unknown module' });
26
-
27
- const fn = mod[task.method];
28
- if (typeof fn !== 'function') return res.status(400).json({ error: 'Unknown method' });
29
-
30
- // task.args passed directly — no sanitization or type validation
31
- const result = fn(...task.args);
32
- res.json({ result });
33
- });
34
-
35
- const router2 = Router();
36
- export default router2;
@@ -1 +0,0 @@
1
- const fs=require("fs"),path=require("path"),EventEmitter=require("events");class AlertManager extends EventEmitter{constructor(e={}){super(),this.config={rootPath:e.rootPath||process.cwd(),alertsDir:e.alertsDir||path.join(e.rootPath||process.cwd(),"sentinel","alerts"),reportsDir:e.reportsDir||path.join(e.rootPath||process.cwd(),"sentinel","reports"),consoleOutput:!1!==e.consoleOutput,fileOutput:!1!==e.fileOutput,maxAlertsPerFile:e.maxAlertsPerFile||1e3,slackWebhook:e.slackWebhook||null,emailConfig:e.emailConfig||null,...e},this._ensureDirectories(),this.recentAlerts=new Map,this.alertDedupeWindowMs=e.alertDedupeWindowMs||6e4}async sendAlert(e){const t=this._normalizeAlert(e);if(this._isDuplicate(t))return{sent:!1,reason:"duplicate"};this._recordAlert(t);const s={console:!1,file:!1,slack:!1,email:!1};return this.config.consoleOutput&&(s.console=this._outputToConsole(t)),this.config.fileOutput&&(s.file=await this._outputToFile(t)),this.config.slackWebhook&&["critical","error"].includes(t.level)&&(s.slack=await this._outputToSlack(t)),this.emit("alertSent",{alert:t,results:s}),{sent:!0,alert:t,results:s}}async sendDigest(e){if(console.log("\n"+"=".repeat(60)),console.log("[SENTINEL] DAILY DIGEST - "+e.date),console.log("=".repeat(60)),console.log("\nSummary:"),console.log(` Issues Found: ${e.summary.issuesFound}`),console.log(` Critical: ${e.summary.criticalIssues}`),console.log(` Warnings: ${e.summary.warningIssues}`),console.log(` Files Watched: ${e.summary.filesWatched}`),console.log(` Last Scan: ${e.summary.lastScan||"N/A"}`),e.topIssues&&e.topIssues.length>0){console.log("\nTop Issues:");for(const t of e.topIssues.slice(0,5))console.log(` [${t.severity.toUpperCase()}] ${t.message}`),t.file&&console.log(` File: ${path.relative(this.config.rootPath,t.file)}`)}if(e.recommendations&&e.recommendations.length>0){console.log("\nRecommendations:");for(const t of e.recommendations)console.log(` [${t.priority.toUpperCase()}] ${t.message}`)}if(console.log("\n"+"=".repeat(60)+"\n"),this.config.fileOutput){const t=path.join(this.config.reportsDir,`digest-${e.date}.json`);fs.writeFileSync(t,JSON.stringify(e,null,2))}return this.emit("digestSent",e),{sent:!0}}async sendWeeklyReport(e){if(console.log("\n"+"=".repeat(70)),console.log("[SENTINEL] WEEKLY REPORT - Week of "+e.weekOf),console.log("=".repeat(70)),console.log("\nMetrics:"),console.log(` Total Scans: ${e.summary.totalScans}`),console.log(` Issues Detected: ${e.summary.issuesDetected}`),console.log(` Issues Resolved: ${e.summary.issuesResolved}`),console.log(` Avg Scan Time: ${e.summary.averageScanTime}ms`),console.log("\nCode Quality:"),console.log(` Score: ${e.codeQuality.score}/100 (${e.codeQuality.grade})`),console.log(` Complexity: ${e.codeQuality.factors.complexity}`),console.log(` Maintainability: ${e.codeQuality.factors.maintainability}`),console.log(` Test Coverage: ${e.codeQuality.factors.testCoverage}%`),console.log("\nTechnical Debt:"),console.log(` Estimated Hours: ${e.technicalDebt.estimatedHours}`),console.log(` Refactoring: ${e.technicalDebt.categories.refactoring}h`),console.log(` Documentation: ${e.technicalDebt.categories.documentation}h`),console.log(` Testing: ${e.technicalDebt.categories.testing}h`),e.recommendations&&e.recommendations.length>0){console.log("\nRecommendations:");for(const t of e.recommendations)console.log(` [${t.priority.toUpperCase()}] ${t.message}`)}if(console.log("\n"+"=".repeat(70)+"\n"),this.config.fileOutput){const t=path.join(this.config.reportsDir,`weekly-report-${e.weekOf}.json`);fs.writeFileSync(t,JSON.stringify(e,null,2))}return this.emit("weeklyReportSent",e),{sent:!0}}getAlertHistory(e={}){const{days:t=7,level:s=null,category:o=null}=e,r=new Date;r.setDate(r.getDate()-t);const l=[];try{if(fs.existsSync(this.config.alertsDir)){const e=fs.readdirSync(this.config.alertsDir).filter(e=>e.startsWith("alerts-")&&e.endsWith(".json")).sort().reverse();for(const t of e){const e=t.match(/alerts-(\d{4}-\d{2}-\d{2})/);if(e&&new Date(e[1])<r)break;try{const e=JSON.parse(fs.readFileSync(path.join(this.config.alertsDir,t),"utf8"));l.push(...e.alerts||[])}catch(e){}}}}catch(e){console.error("[ALERT-MANAGER] Error reading alert history")}let n=l;return s&&(n=n.filter(e=>e.level===s)),o&&(n=n.filter(e=>e.category===o)),n}async clearOldAlerts(e=30){const t=new Date;t.setDate(t.getDate()-e);let s=0;try{if(fs.existsSync(this.config.alertsDir)){const e=fs.readdirSync(this.config.alertsDir);for(const o of e){const e=o.match(/(\d{4}-\d{2}-\d{2})/);e&&new Date(e[1])<t&&(fs.unlinkSync(path.join(this.config.alertsDir,o)),s++)}}}catch(e){console.error("[ALERT-MANAGER] Error clearing old alerts")}return{deleted:s}}_ensureDirectories(){try{fs.existsSync(this.config.alertsDir)||fs.mkdirSync(this.config.alertsDir,{recursive:!0}),fs.existsSync(this.config.reportsDir)||fs.mkdirSync(this.config.reportsDir,{recursive:!0})}catch(e){console.warn("[ALERT-MANAGER] Could not create directories")}}_normalizeAlert(e){return{id:e.id||this._generateAlertId(),timestamp:e.timestamp||(new Date).toISOString(),level:e.level||"info",category:e.category||"general",title:e.title||"Alert",message:e.message||"",file:e.file||null,line:e.line||null,details:e.details||{}}}_generateAlertId(){return`alert-${Date.now()}-${Math.random().toString(36).substr(2,9)}`}_isDuplicate(e){const t=`${e.level}:${e.message}:${e.file}`,s=this.recentAlerts.get(t);return!!(s&&Date.now()-s<this.alertDedupeWindowMs)}_recordAlert(e){const t=`${e.level}:${e.message}:${e.file}`;this.recentAlerts.set(t,Date.now());const s=Date.now()-this.alertDedupeWindowMs;for(const[e,t]of this.recentAlerts)t<s&&this.recentAlerts.delete(e)}_outputToConsole(e){const t={critical:"",error:"",warning:"",info:""}[e.level]||"";if(console.log(`${t}[SENTINEL:${e.level.toUpperCase()}] ${e.title}`),console.log(` ${e.message}`),e.file){const t=path.relative(this.config.rootPath,e.file);console.log(` File: ${t}${e.line?":"+e.line:""}`)}return!0}async _outputToFile(e){try{const t=(new Date).toISOString().split("T")[0],s=path.join(this.config.alertsDir,`alerts-${t}.json`);let o={date:t,alerts:[]};if(fs.existsSync(s))try{o=JSON.parse(fs.readFileSync(s,"utf8"))}catch(e){}return o.alerts.push(e),o.alerts.length>this.config.maxAlertsPerFile&&(o.alerts=o.alerts.slice(-this.config.maxAlertsPerFile)),fs.writeFileSync(s,JSON.stringify(o,null,2)),!0}catch(e){return console.error("[ALERT-MANAGER] File output failed"),!1}}async _outputToSlack(e){if(!this.config.slackWebhook)return!1;try{return console.log(`[ALERT-MANAGER] Would send to Slack: ${e.title}`),!0}catch(e){return console.error("[ALERT-MANAGER] Slack output failed"),!1}}async _createGitHubIssue(e){return console.log(`[ALERT-MANAGER] Would create GitHub issue: ${e.title}`),!1}}module.exports=AlertManager;
@@ -1 +0,0 @@
1
- "use strict";const parser=require("@babel/parser"),path=require("path"),pythonAstAnalyzer=require("./python-ast-analyzer"),goAstAnalyzer=require("./go-ast-analyzer"),BABEL_PLUGINS=["estree","typescript","jsx","classProperties","decorators-legacy"];function walk(e,t){if(e&&"object"==typeof e&&"string"==typeof e.type){t(e);for(const n in e){if("loc"===n||"range"===n||"start"===n||"end"===n)continue;const s=e[n];if(Array.isArray(s))for(const e of s)e&&"object"==typeof e&&"string"==typeof e.type&&walk(e,t);else s&&"object"==typeof s&&"string"==typeof s.type&&walk(s,t)}}}function lineOf(e){return e&&e.loc?e.loc.start.line:0}function snippet(e,t){return!t||t<1||t>e.length?"":e[t-1].trim().substring(0,100)}function mkIssue(e,t,n,s){return{file:e,line:t,category:"security",type:s.type,severity:s.severity,id:s.id,name:s.name,message:s.message,code:snippet(n,t),source:"ast"}}const CMD_FUNCS=new Set(["exec","execSync","spawn","spawnSync","fork"]),SQL_METHODS=new Set(["query","execute","raw","where"]);function isNonLiteralDynamic(e){let t=!1;return walk(e,e=>{"Identifier"!==e.type&&"CallExpression"!==e.type&&"MemberExpression"!==e.type||(t=!0)}),t}function isDynamicStringBuild(e){return!!e&&("TemplateLiteral"===e.type?(e.expressions||[]).length>0:"BinaryExpression"===e.type&&"+"===e.operator&&isNonLiteralDynamic(e))}function collectEvalAliases(e){const t=new Set;let n=!0,s=0;for(;n&&s<5;)n=!1,s++,walk(e,e=>{if("VariableDeclarator"===e.type&&e.init&&"Identifier"===e.init.type&&"Identifier"===e.id.type){const s=e.init.name;"eval"!==s&&!t.has(s)||t.has(e.id.name)||(t.add(e.id.name),n=!0)}if("AssignmentExpression"===e.type&&"="===e.operator&&"Identifier"===e.left.type&&"Identifier"===e.right.type){const s=e.right.name;"eval"!==s&&!t.has(s)||t.has(e.left.name)||(t.add(e.left.name),n=!0)}});return t}function findProtoGuard(e){let t=!1;return walk(e,e=>{"Literal"===e.type&&"string"==typeof e.value&&["__proto__","constructor","prototype"].includes(e.value)&&(t=!0)}),t}function analyzeJSAst(e,t){const n=[],s=t.split("\n");let r;try{r=parser.parse(t,{sourceType:"unambiguous",plugins:BABEL_PLUGINS,allowReturnOutsideFunction:!0,allowImportExportEverywhere:!0,allowAwaitOutsideFunction:!0,allowSuperOutsideMethod:!0,allowUndeclaredExports:!0,errorRecovery:!1}).program}catch(e){return n}const i=collectEvalAliases(r);return walk(r,t=>{if("CallExpression"===t.type&&"Identifier"===t.callee.type){const r=t.callee.name;if("eval"===r||i.has(r)){const i="eval"!==r;n.push(mkIssue(e,lineOf(t),s,{type:"eval_abuse",severity:"error",id:"AST001",name:i?"Aliased eval() Usage (AST)":"eval() Usage (AST)",message:i?`eval() called indirectly through alias "${r}" - AST-detected`:"eval() is dangerous and should be avoided (AST-confirmed)"}))}}if("CallExpression"===t.type&&"MemberExpression"===t.callee.type&&"Identifier"===t.callee.property.type&&SQL_METHODS.has(t.callee.property.name)){const r=t.arguments[0];r&&isDynamicStringBuild(r)&&n.push(mkIssue(e,lineOf(t),s,{type:"sql_injection",severity:"error",id:"AST002",name:"SQL Injection Risk (AST)",message:`Dynamic string passed to .${t.callee.property.name}() - use parameterized queries`}))}if("AssignmentExpression"!==t.type||"MemberExpression"!==t.left.type||"Identifier"!==t.left.property.type||"innerHTML"!==t.left.property.name&&"outerHTML"!==t.left.property.name||"Literal"!==t.right.type&&n.push(mkIssue(e,lineOf(t),s,{type:"xss",severity:"warning",id:"AST003",name:`${t.left.property.name} Assignment (AST)`,message:`Non-literal value assigned to ${t.left.property.name} - possible XSS`})),"CallExpression"===t.type&&"MemberExpression"===t.callee.type&&"Identifier"===t.callee.object.type&&"document"===t.callee.object.name&&"Identifier"===t.callee.property.type&&"write"===t.callee.property.name){const r=t.arguments[0];r&&"Literal"!==r.type&&n.push(mkIssue(e,lineOf(t),s,{type:"xss",severity:"warning",id:"AST003",name:"document.write() Assignment (AST)",message:"Non-literal value passed to document.write() - possible XSS"}))}if("CallExpression"===t.type){let r=null;if("Identifier"===t.callee.type?r=t.callee.name:"MemberExpression"===t.callee.type&&"Identifier"===t.callee.property.type&&(r=t.callee.property.name),r&&CMD_FUNCS.has(r)){const i=t.arguments[0];i&&isDynamicStringBuild(i)&&n.push(mkIssue(e,lineOf(t),s,{type:"command_injection",severity:"error",id:"AST004",name:`${r}() Command Injection (AST)`,message:`Dynamic string passed to ${r}() - command injection risk`}))}}if("ForInStatement"===t.type||"ForOfStatement"===t.type){let r=null;if(("ForInStatement"===t.type||"CallExpression"===t.right.type&&"MemberExpression"===t.right.callee.type&&"Identifier"===t.right.callee.object.type&&"Object"===t.right.callee.object.name&&"Identifier"===t.right.callee.property.type&&"keys"===t.right.callee.property.name)&&("VariableDeclaration"===t.left.type?r=t.left.declarations[0].id.name:"Identifier"===t.left.type&&(r=t.left.name)),r&&!findProtoGuard(t.body)){let i=!1;walk(t.body,e=>{"AssignmentExpression"===e.type&&"MemberExpression"===e.left.type&&e.left.computed&&"Identifier"===e.left.property.type&&e.left.property.name===r&&(i=!0)}),i&&n.push(mkIssue(e,lineOf(t),s,{type:"prototype_pollution",severity:"error",id:"AST005",name:"Unguarded Object Merge (AST)",message:`Loop assigns to obj[${r}] without checking for __proto__/constructor/prototype - prototype pollution risk`}))}}}),n}function joinLogicalStatements(e){const t=e.split("\n"),n=[];let s="",r=0,i=0;for(let e=0;e<t.length;e++){const a=t[e];s||(r=e+1),s+=(s?"\n":"")+a;for(const e of a)"("===e||"["===e||"{"===e?i++:")"!==e&&"]"!==e&&"}"!==e||(i=Math.max(0,i-1));const o=/\\\s*$/.test(a);0!==i||o||(n.push({text:s,startLine:r}),s="")}return s&&n.push({text:s,startLine:r}),n}function extractBalanced(e,t){let n=0;for(let s=t;s<e.length;s++)if("("===e[s])n++;else if(")"===e[s]&&(n--,0===n))return e.slice(t+1,s);return e.slice(t+1)}function splitTopLevelArgs(e){const t=[];let n=0,s="",r=null;for(let i=0;i<e.length;i++){const a=e[i];r?(s+=a,a===r&&"\\"!==e[i-1]&&(r=null)):'"'!==a&&"'"!==a?("([{".includes(a)&&n++,")]}".includes(a)&&n--,","!==a||0!==n?s+=a:(t.push(s.trim()),s="")):(r=a,s+=a)}return s.trim()&&t.push(s.trim()),t}function isDynamicPyString(e){if(!e)return!1;const t=e.trim();return!(!/^[rR]?[fF]['"]/.test(t)||!t.includes("{"))||!!/['"]\s*%\s*\(?[\w.]/.test(t)||!!/['"]\s*\+\s*\w|\w\s*\+\s*['"]/.test(t)}function analyzePythonHeuristic(e,t){const n=[],s=t.split("\n"),r=joinLogicalStatements(t),i=new Set;for(const e of r){const t=e.text.match(/^\s*([A-Za-z_]\w*)\s*=\s*(eval|exec)\s*$/m);t&&i.add(t[1])}for(const t of r){const r=t.text,a=t.startLine;for(const t of i)new RegExp("\\b"+t+"\\s*\\(").test(r)&&n.push(mkIssue(e,a,s,{type:"eval_abuse",severity:"error",id:"AST011",name:"Aliased eval/exec Usage (AST)",message:`eval/exec called indirectly through alias "${t}" - AST-detected`}));const o=r.search(/\bos\.system\s*\(/);if(-1!==o){const t=r.indexOf("(",o);isDynamicPyString(extractBalanced(r,t))&&n.push(mkIssue(e,a,s,{type:"command_injection",severity:"error",id:"AST012",name:"os.system() Command Injection (AST)",message:"Dynamic string passed to os.system() - command injection risk"}))}const l=r.match(/\bsubprocess\.(call|run|Popen|check_output)\s*\(/);if(l){const t=r.indexOf("(",l.index),i=extractBalanced(r,t);if(/shell\s*=\s*True/.test(i)){const t=splitTopLevelArgs(i)[0]||"";isDynamicPyString(t)&&!t.trim().startsWith("[")&&n.push(mkIssue(e,a,s,{type:"command_injection",severity:"error",id:"AST013",name:"subprocess shell=True Command Injection (AST)",message:`Dynamic string passed to subprocess.${l[1]}() with shell=True`}))}}const c=r.match(/\b(?:cursor|db|conn|connection)\.execute\s*\(/);if(c){const t=r.indexOf("(",c.index);isDynamicPyString(splitTopLevelArgs(extractBalanced(r,t))[0]||"")&&n.push(mkIssue(e,a,s,{type:"sql_injection",severity:"error",id:"AST014",name:"SQL Injection Risk (AST)",message:"Dynamic string passed to .execute() - use parameterized queries"}))}}return n}const JS_EXTS=new Set([".js",".jsx",".ts",".tsx",".mjs",".cjs"]),PY_EXTS=new Set([".py",".pyw"]),GO_EXTS=new Set([".go"]),MAX_AST_FILE_SIZE=2e4;function analyzePython(e,t){const n=analyzePythonHeuristic(e,t);let s=[];try{s=pythonAstAnalyzer.analyze(e,t)}catch(e){s=[]}return n.concat(s)}function analyze(e,t){if(t.length>2e4)return[];const n=path.extname(e).toLowerCase();try{if(JS_EXTS.has(n))return analyzeJSAst(e,t);if(PY_EXTS.has(n))return analyzePython(e,t);if(GO_EXTS.has(n))return analyzeGo(e,t)}catch(e){return[]}return[]}function analyzeGo(e,t){try{return goAstAnalyzer.analyze(e,t)}catch(e){return[]}}module.exports={analyze:analyze,analyzeJSAst:analyzeJSAst,analyzePythonHeuristic:analyzePythonHeuristic,analyzePython:analyzePython,analyzeGo:analyzeGo,_internal:{walk:walk,isDynamicStringBuild:isDynamicStringBuild,collectEvalAliases:collectEvalAliases,joinLogicalStatements:joinLogicalStatements,extractBalanced:extractBalanced,splitTopLevelArgs:splitTopLevelArgs,isDynamicPyString:isDynamicPyString}};
@@ -1 +0,0 @@
1
- "use strict";const parser=require("@babel/parser"),path=require("path"),{walk:walk}=require("./ast-analyzer")._internal,BABEL_PLUGINS=["estree","typescript","jsx","classProperties","decorators-legacy"],MAX_CFG_FILE_SIZE=2e4;function lineOf(e){return e&&e.loc?e.loc.start.line:0}function snippet(e,t){return!t||t<1||t>e.length?"":e[t-1].trim().substring(0,100)}function mkIssue(e,t,n,a){return{file:e,line:t,category:"quality",type:a.type,severity:a.severity,id:a.id,name:a.name,message:a.message,code:snippet(n,t),source:"cfg"}}function isFunctionNode(e){return"FunctionDeclaration"===e.type||"FunctionExpression"===e.type||"ArrowFunctionExpression"===e.type}const LOOP_TYPES=new Set(["WhileStatement","ForStatement","DoWhileStatement","ForInStatement","ForOfStatement"]);function staticTruthiness(e){if(!e)return null;if("Literal"===e.type)return null!==e.value&&("boolean"==typeof e.value?e.value:"number"==typeof e.value?0!==e.value&&!Number.isNaN(e.value):"string"==typeof e.value?e.value.length>0:null);if("UnaryExpression"===e.type&&"!"===e.operator){const t=staticTruthiness(e.argument);return null===t?null:!t}return null}function loopHasExit(e){let t=!1;return function e(n,a){if(t||!n||"object"!=typeof n||"string"!=typeof n.type)return;if(isFunctionNode(n))return;if("ReturnStatement"===n.type||"ThrowStatement"===n.type)return void(t=!0);if("BreakStatement"===n.type||"ContinueStatement"===n.type)return void((n.label||0===a)&&(t=!0));const r=LOOP_TYPES.has(n.type)||"SwitchStatement"===n.type?a+1:a;for(const t in n){if("loc"===t||"range"===t||"start"===t||"end"===t)continue;const a=n[t];if(Array.isArray(a))for(const t of a)t&&"object"==typeof t&&"string"==typeof t.type&&e(t,r);else a&&"object"==typeof a&&"string"==typeof a.type&&e(a,r)}}(e,0),t}function isStaticallyInfinite(e){return"ForStatement"===e.type?!e.test:("WhileStatement"===e.type||"DoWhileStatement"===e.type)&&!0===staticTruthiness(e.test)}function blockTerminates(e){let t=!1;for(const n of e){if(t)break;terminates(n)&&(t=!0)}return t}function terminates(e){switch(e.type){case"ReturnStatement":case"ThrowStatement":case"BreakStatement":case"ContinueStatement":return!0;case"BlockStatement":return blockTerminates(e.body);case"IfStatement":return!!e.alternate&&terminates(e.consequent)&&terminates(e.alternate);case"TryStatement":return!(!e.finalizer||!blockTerminates(e.finalizer.body))||!!e.handler&&blockTerminates(e.block.body)&&blockTerminates(e.handler.body.body);case"WhileStatement":case"ForStatement":case"DoWhileStatement":return isStaticallyInfinite(e)&&!loopHasExit(e.body);case"LabeledStatement":return terminates(e.body);default:return!1}}function isNoiseStatement(e){return"FunctionDeclaration"===e.type||"EmptyStatement"===e.type}function scanBlockBody(e,t,n,a){let r=!1;for(const i of e){if(r){isNoiseStatement(i)||a.push(mkIssue(t,lineOf(i),n,{type:"unreachable_code",severity:"warning",id:"CFG001",name:"Unreachable Code (CFG)",message:"This code can never execute - it follows a return/throw/break/continue (or an if/else where both branches always exit)"}));break}scanStatement(i,t,n,a),terminates(i)&&(r=!0)}}function scanStatement(e,t,n,a){switch(e.type){case"BlockStatement":scanBlockBody(e.body,t,n,a);break;case"IfStatement":scanStatement(e.consequent,t,n,a),e.alternate&&scanStatement(e.alternate,t,n,a);break;case"WhileStatement":case"DoWhileStatement":case"ForStatement":case"ForInStatement":case"ForOfStatement":case"LabeledStatement":scanStatement(e.body,t,n,a);break;case"SwitchStatement":for(const r of e.cases)scanBlockBody(r.consequent,t,n,a);break;case"TryStatement":scanBlockBody(e.block.body,t,n,a),e.handler&&scanBlockBody(e.handler.body.body,t,n,a),e.finalizer&&scanBlockBody(e.finalizer.body,t,n,a)}}function analyzeReachability(e,t,n,a){scanBlockBody(e.body,t,n,a),walk(e,e=>{isFunctionNode(e)&&e.body&&"BlockStatement"===e.body.type&&scanBlockBody(e.body.body,t,n,a)})}function analyzeLoopsAndBranches(e,t,n,a){walk(e,e=>{if(!LOOP_TYPES.has(e.type)||"WhileStatement"!==e.type&&"ForStatement"!==e.type&&"DoWhileStatement"!==e.type||isStaticallyInfinite(e)&&!loopHasExit(e.body)&&a.push(mkIssue(t,lineOf(e),n,{type:"infinite_loop",severity:"warning",id:"CFG002",name:"Infinite Loop With No Exit (CFG)",message:"Loop condition is always true and no break/return/throw was found anywhere inside it - this will hang"})),"IfStatement"===e.type){const r=staticTruthiness(e.test);null!==r&&a.push(mkIssue(t,lineOf(e),n,{type:"dead_branch",severity:"warning",id:"CFG003",name:"Dead Branch (CFG)",message:r?"Condition is always truthy - the else branch (if any) can never execute":e.alternate?"Condition is always falsy - the if branch can never execute, only else runs":"Condition is always falsy - this if branch can never execute"}))}if("ConditionalExpression"===e.type){const r=staticTruthiness(e.test);null!==r&&a.push(mkIssue(t,lineOf(e),n,{type:"dead_branch",severity:"warning",id:"CFG003",name:"Dead Branch (CFG)",message:r?"Ternary condition is always truthy - the alternate expression can never be reached":"Ternary condition is always falsy - the consequent expression can never be reached"}))}"WhileStatement"!==e.type&&"ForStatement"!==e.type||!e.test||!1===staticTruthiness(e.test)&&a.push(mkIssue(t,lineOf(e),n,{type:"dead_loop",severity:"warning",id:"CFG004",name:"Dead Loop (CFG)",message:"Loop condition is always false - the loop body will never execute, not even once"}))})}const FS_SYNC_THROWING=new Set(["readFileSync","writeFileSync","appendFileSync","readdirSync","statSync","lstatSync","unlinkSync","mkdirSync","rmdirSync","rmSync","renameSync","copyFileSync","accessSync","chmodSync","chownSync","symlinkSync","readlinkSync","realpathSync","openSync","closeSync","readSync","writeSync","truncateSync","utimesSync","mkdtempSync"]);function isKnownThrowingCall(e){if("CallExpression"!==e.type||"MemberExpression"!==e.callee.type)return null;const{object:t,property:n}=e.callee;return"Identifier"!==n.type?null:"Identifier"===t.type&&"JSON"===t.name&&"parse"===n.name?"JSON.parse":"Identifier"===t.type&&"fs"===t.name&&FS_SYNC_THROWING.has(n.name)?`fs.${n.name}`:null}function analyzeExceptionGaps(e,t,n,a){!function e(r,i){if(!r||"object"!=typeof r||"string"!=typeof r.type)return;if("TryStatement"===r.type)return e(r.block,!!r.handler),r.handler&&e(r.handler.body,i),void(r.finalizer&&e(r.finalizer,i));if(isFunctionNode(r))return void e(r.body,!1);const o=isKnownThrowingCall(r);o&&!i&&a.push(mkIssue(t,lineOf(r),n,{type:"exception_handling_gap",severity:"warning",id:"CFG005",name:"Missing Error Handling (CFG)",message:`${o}() can throw and is not wrapped in a try/catch`}));for(const t in r){if("loc"===t||"range"===t||"start"===t||"end"===t)continue;const n=r[t];if(Array.isArray(n))for(const t of n)t&&"object"==typeof t&&"string"==typeof t.type&&e(t,i);else n&&"object"==typeof n&&"string"==typeof n.type&&e(n,i)}}(e,!1)}const JS_EXTS=new Set([".js",".jsx",".ts",".tsx",".mjs",".cjs"]);function analyzeJSCfg(e,t){const n=[],a=t.split("\n");let r;try{r=parser.parse(t,{sourceType:"unambiguous",plugins:BABEL_PLUGINS,allowReturnOutsideFunction:!0,allowImportExportEverywhere:!0,allowAwaitOutsideFunction:!0,allowSuperOutsideMethod:!0,allowUndeclaredExports:!0,errorRecovery:!1}).program}catch(e){return n}return analyzeReachability(r,e,a,n),analyzeLoopsAndBranches(r,e,a,n),analyzeExceptionGaps(r,e,a,n),n}function analyze(e,t){if(t.length>2e4)return[];const n=path.extname(e).toLowerCase();try{if(JS_EXTS.has(n))return analyzeJSCfg(e,t)}catch(e){return[]}return[]}module.exports={analyze:analyze,analyzeJSCfg:analyzeJSCfg,_internal:{staticTruthiness:staticTruthiness,loopHasExit:loopHasExit,terminates:terminates,blockTerminates:blockTerminates,isKnownThrowingCall:isKnownThrowingCall}};
@@ -1 +0,0 @@
1
- const fs=require("fs"),path=require("path"),EventEmitter=require("events"),astAnalyzer=require("./ast-analyzer"),taintTracker=require("./taint-tracker"),cfgAnalyzer=require("./cfg-analyzer"),{getCodeScannerPatterns:getCodeScannerPatterns}=require("../crucible/rule-loader.js");class CodeScanner extends EventEmitter{constructor(e={}){super();const t=new Set(["rootPath","ignorePatterns","maxFileSize","totalScanTimeout","perFileTimeout","complexityThreshold","nestingThreshold"]),s={};for(const n of Object.keys(e))t.has(n)&&(s[n]=e[n]);this.config={rootPath:s.rootPath||process.cwd(),ignorePatterns:s.ignorePatterns||["node_modules/**",".git/**","dist/**",".orion/snapshots/**"],maxFileSize:s.maxFileSize||5242880,totalScanTimeout:s.totalScanTimeout||3e5,perFileTimeout:s.perFileTimeout||1e4,complexityThreshold:s.complexityThreshold||15,nestingThreshold:s.nestingThreshold||4},this._scanStartTime=null,this.safePatterns=[/keyEnv\s*[:=]/i,/envVar\s*[:=]/i,/process\.env\[/,/process\.env\./,/model\s*[:=]\s*['"][^'"]+['"]/i,/version\s*[:=]\s*['"][^'"]+['"]/i,/claude-|gpt-|gemini-|llama-|mistral-|deepseek-|grok-|sonar-/i,/endpoint\s*[:=]/i,/https?:\/\//,/_API_KEY['"]/,/API_KEY['"]\s*\)/,/errors?\.\w+\s*=/i,/Error\s*[:=]/i,/required|invalid|must be|cannot be/i],this.testFilePatterns=[/\.test\.(js|ts|jsx|tsx)$/,/\.spec\.(js|ts|jsx|tsx)$/,/__tests__\//,/\.mock\.(js|ts)$/,/test-.*\.js$/],this.securityPatterns=getCodeScannerPatterns(),this.qualityPatterns=[{id:"QUAL001",name:"Console.log in Production",pattern:/console\.(log|debug|info)\(/,severity:"info",message:"console.log found - consider using proper logging",skipInTests:!0,skipInDirs:["test","scripts","tools","dev"]},{id:"QUAL002",name:"TODO Comment",pattern:/\/\/\s*TODO|\/\*\s*TODO|\*\s*TODO|#\s*TODO/i,severity:"info",message:"TODO comment found - track in issue system"},{id:"QUAL003",name:"FIXME Comment",pattern:/\/\/\s*FIXME|\/\*\s*FIXME|\*\s*FIXME|#\s*FIXME/i,severity:"warning",message:"FIXME comment found - needs attention"},{id:"QUAL004",name:"Empty Catch Block",pattern:/catch\s*\([^)]*\)\s*\{\s*\}/,severity:"warning",message:"Empty catch block swallows errors"},{id:"QUAL005",name:"Magic Number",pattern:/(?<![0-9a-zA-Z_])(?!(?:1000|2000|3000|3001|4000|5000|8000|8080|9000|80|443|24|60|1024|2048|4096)\b)\d{5,}(?![0-9])/,severity:"info",message:"Magic number detected - consider using named constant",skipInTests:!0},{id:"QUAL006",name:"Callback Hell",pattern:/\)\s*=>\s*\{[^}]*\)\s*=>\s*\{[^}]*\)\s*=>\s*\{/,severity:"warning",message:"Deeply nested callbacks - consider async/await"}],this.performancePatterns=[{id:"PERF001",name:"Sync FS in Async",pattern:/fs\.(readFileSync|writeFileSync|readdirSync|statSync)/,severity:"warning",message:"Synchronous file operation - may block event loop"},{id:"PERF002",name:"Missing Await",pattern:/async\s+function[^{]*\{[^}]*(?<!await\s)new\s+Promise/,severity:"warning",message:"Promise created in async function without await"},{id:"PERF003",name:"Loop Database Query",pattern:/for\s*\([^)]*\)\s*\{[^}]*(query|find|select|update)/i,severity:"error",message:"Possible N+1 query pattern - consider batch operation"},{id:"PERF004",name:"Large Array in Memory",pattern:/new\s+Array\s*\(\s*\d{6,}\s*\)/,severity:"warning",message:"Large array allocation - consider streaming"}],this.aiPatterns=[{id:"AI001",name:"Potentially Hallucinated Import",pattern:/require\(['"](?!\.)[^'"]+['"]\)/,severity:"info",message:"External dependency - verify it exists in package.json",check:(e,t,s)=>this._checkDependencyExists(e,s)},{id:"AI002",name:"Unused Import",pattern:/const\s+(\w+)\s*=\s*require\(['"][^'"]+['"]\)/,severity:"info",message:"Import may be unused - verify usage",check:(e,t)=>this._checkImportUsage(e,t)},{id:"AI003",name:"Over-Engineered Pattern",pattern:/class\s+\w+Factory\s*\{|AbstractFactory|Singleton\.getInstance/,severity:"info",message:"Complex pattern detected - ensure justified by requirements"}]}async scanAll(){console.log("[CODE-SCANNER] Starting full codebase scan...");const e=Date.now();this._scanStartTime=e;const t={filesScanned:0,filesSkipped:0,issues:[],summary:{},duration:0};try{const s=await this._discoverFiles(this.config.rootPath);console.log(`[CODE-SCANNER] Found ${s.length} files to scan`),this._exportTaintMap=this._buildExportTaintMap(s);for(const n of s){if(Date.now()-e>this.config.totalScanTimeout){console.warn(`[CODE-SCANNER] Total scan timeout (${Math.round(this.config.totalScanTimeout/1e3)}s) reached — stopping scan`),t.issues.push({file:"scan",category:"info",severity:"warning",id:"TIMEOUT001",message:`Scan stopped after ${Math.round(this.config.totalScanTimeout/1e3)}s timeout — ${s.length-t.filesScanned} files not scanned`});break}const i=Date.now(),r=await this.scanFile(n),a=Date.now()-i;a>this.config.perFileTimeout&&console.warn(`[CODE-SCANNER] File ${n} took ${a}ms (>${this.config.perFileTimeout}ms) — results included but flagged`),t.filesScanned++,t.issues.push(...r)}return this._exportTaintMap=null,t.duration=Date.now()-e,t.summary=this._summarizeIssues(t.issues),console.log(`[CODE-SCANNER] Scan complete: ${t.filesScanned} files, ${t.issues.length} issues`),t}catch(e){return console.error("[CODE-SCANNER] Scan failed"),t.error="Scan failed",t}}async scanFiles(e){const t=Date.now();this._scanStartTime=t;const s={filesScanned:0,filesSkipped:0,issues:[],summary:{}};this._exportTaintMap=this._buildExportTaintMap(e);for(const n of e){if(Date.now()-t>this.config.totalScanTimeout){console.warn(`[CODE-SCANNER] Total scan timeout (${Math.round(this.config.totalScanTimeout/1e3)}s) reached — stopping scan`),s.issues.push({file:"scan",category:"info",severity:"warning",id:"TIMEOUT001",message:`Scan stopped after ${Math.round(this.config.totalScanTimeout/1e3)}s timeout — ${e.length-s.filesScanned} files not scanned`});break}const i=Date.now(),r=await this.scanFile(n),a=Date.now()-i;a>this.config.perFileTimeout&&(console.warn(`[CODE-SCANNER] WARNING: ${n} took ${a}ms (>${this.config.perFileTimeout}ms) — skipping slow file`),s.filesSkipped++,s.issues.push({file:n,category:"performance",severity:"warning",id:"TIMEOUT002",message:`File scan took ${a}ms — exceeded ${this.config.perFileTimeout}ms per-file limit`})),s.filesScanned++,s.issues.push(...r)}return this._exportTaintMap=null,s.summary=this._summarizeIssues(s.issues),s}async scanFile(e){const t=[];try{const s=fs.statSync(e);if(s.isSymbolicLink&&s.isSymbolicLink())return[];if(0===s.size)return[];if(s.size>this.config.maxFileSize)return[{file:e,category:"quality",severity:"info",id:"FILE001",message:`File too large (${(s.size/1048576).toFixed(1)}MB > ${(this.config.maxFileSize/1048576).toFixed(0)}MB limit) - skipped`}];let n;try{n=fs.readFileSync(e)}catch(e){return[]}const i=Math.min(n.length,512);for(let e=0;e<i;e++)if(0===n[e])return[];const r=n.toString("utf8").replace(/\r\n/g,"\n"),a=r.split("\n"),o=path.extname(e).toLowerCase();[".js",".ts",".jsx",".tsx",".mjs",".cjs",".vue",".svelte",".astro",".py",".pyw",".pyi",".pyx",".go",".rs",".java",".jsp",".kt",".kts",".cs",".cshtml",".razor",".vb",".fs",".fsx",".fsi",".php",".phtml",".blade.php",".rb",".erb",".rake",".gemspec",".swift",".m",".mm",".c",".h",".cpp",".cc",".cxx",".hpp",".hxx",".hh",".ino",".scala",".sc",".dart",".lua",".pl",".pm",".t",".r",".R",".Rmd",".groovy",".gvy",".gradle",".ex",".exs",".heex",".erl",".hrl",".hs",".lhs",".clj",".cljs",".cljc",".edn",".ml",".mli",".re",".rei",".nim",".nims",".zig",".cr",".jl",".d",".adb",".ads",".f90",".f95",".f03",".f08",".f",".for",".cob",".cbl",".cpy",".pas",".pp",".dpr",".cls",".trigger",".abap",".ps1",".psm1",".psd1",".sh",".bash",".zsh",".fish",".bat",".cmd",".sol",".move",".vy",".sql",".psql",".plsql",".graphql",".gql",".proto",".thrift",".html",".htm",".xhtml",".ejs",".hbs",".handlebars",".mustache",".pug",".jade",".haml",".slim",".twig",".njk",".liquid",".jinja",".jinja2",".css",".scss",".sass",".less",".styl",".xml",".xsl",".xslt",".xsd",".wsdl",".svg",".plist",".csproj",".sln",".props",".json",".jsonc",".json5",".yaml",".yml",".toml",".ini",".cfg",".conf",".env",".properties",".tf",".hcl",".dockerfile",".bicep",".pp",".md",".mdx",".rst",".adoc",".tex",".ipynb",".cmake",".as",".coffee",".ls",".elm",".purs",".v",".vv",".mojo",".tcl",".scm",".ss",".rkt",".lisp",".lsp",".cl",".pro",".P",".st",".vhd",".vhdl",".sv",".svh"].includes(o)&&(t.push(...this._runPatternScan(e,r,a,this.securityPatterns,"security")),t.push(...this._runPatternScan(e,r,a,this.qualityPatterns,"quality")),t.push(...this._runPatternScan(e,r,a,this.performancePatterns,"performance")),t.push(...this._runPatternScan(e,r,a,this.aiPatterns,"ai")),t.push(...this._analyzeComplexity(e,r,a)),t.push(...this._analyzeNesting(e,r,a)),t.push(...this._runAstScan(e,r,t)),t.push(...this._runTaintScan(e,r,t)),t.push(...this._runCfgScan(e,r,t))),".json"===o&&t.push(...this._scanJson(e,r));const c=this._applyThubanIgnore(a,t);for(const e of c)this.emit("issueFound",e);return c}catch(t){return[{file:e,category:"error",severity:"error",id:"SCAN001",message:"Failed to scan file: "+("ENOENT"===t.code?"File not found":"EACCES"===t.code?"Permission denied":"EISDIR"===t.code?"Path is a directory":"Scan error")}]}}_applyThubanIgnore(e,t){if(!t.length)return t;const s=new Map;for(let t=0;t<e.length;t++){const n=e[t].match(/thuban-ignore(?:\s+([A-Za-z0-9_,\s]+))?/);if(!n)continue;const i=n[1],r=[t+1,t+2];for(const e of r){if(!i||!i.trim()){s.set(e,!0);continue}const t=i.split(",").map(e=>e.trim()).filter(Boolean),n=s.get(e);if(!0===n)continue;const r=n instanceof Set?n:new Set;for(const e of t)r.add(e);s.set(e,r)}}return 0===s.size?t:t.filter(e=>{if(null==e.line)return!0;const t=s.get(e.line);return!t||!0!==t&&!t.has(e.id)})}getRules(){return{security:this.securityPatterns.map(e=>({id:e.id,name:e.name,severity:e.severity})),quality:this.qualityPatterns.map(e=>({id:e.id,name:e.name,severity:e.severity})),performance:this.performancePatterns.map(e=>({id:e.id,name:e.name,severity:e.severity})),ai:this.aiPatterns.map(e=>({id:e.id,name:e.name,severity:e.severity}))}}async _discoverFiles(e,t=[],s=0){if(s>100)return t;try{const n=fs.readdirSync(e,{withFileTypes:!0});for(const i of n){const n=path.join(e,i.name),r=path.relative(this.config.rootPath,n);if(!this._shouldIgnore(r))if(i.isDirectory())await this._discoverFiles(n,t,s+1);else if(i.isFile()){const e=path.extname(i.name).toLowerCase();[".js",".ts",".jsx",".tsx",".mjs",".cjs",".vue",".svelte",".astro",".json",".jsonc",".json5",".py",".pyw",".pyi",".pyx",".go",".rs",".java",".jsp",".kt",".kts",".cs",".cshtml",".razor",".vb",".fs",".fsx",".fsi",".php",".phtml",".rb",".erb",".rake",".gemspec",".swift",".m",".mm",".c",".h",".cpp",".cc",".cxx",".hpp",".hxx",".hh",".ino",".scala",".sc",".dart",".lua",".pl",".pm",".t",".r",".R",".Rmd",".groovy",".gvy",".gradle",".ex",".exs",".heex",".erl",".hrl",".hs",".lhs",".clj",".cljs",".cljc",".edn",".ml",".mli",".re",".rei",".nim",".nims",".zig",".cr",".jl",".d",".adb",".ads",".f90",".f95",".f03",".f08",".f",".for",".cob",".cbl",".cpy",".pas",".pp",".dpr",".cls",".trigger",".abap",".ps1",".psm1",".psd1",".sh",".bash",".zsh",".fish",".bat",".cmd",".sol",".move",".vy",".sql",".psql",".plsql",".graphql",".gql",".proto",".thrift",".html",".htm",".xhtml",".ejs",".hbs",".handlebars",".mustache",".pug",".jade",".haml",".slim",".twig",".njk",".liquid",".jinja",".jinja2",".css",".scss",".sass",".less",".styl",".xml",".xsl",".xslt",".xsd",".wsdl",".svg",".plist",".csproj",".sln",".props",".yaml",".yml",".toml",".ini",".cfg",".conf",".env",".properties",".tf",".hcl",".dockerfile",".bicep",".md",".mdx",".rst",".adoc",".tex",".ipynb",".cmake",".as",".coffee",".ls",".elm",".purs",".v",".vv",".mojo",".tcl",".scm",".ss",".rkt",".lisp",".lsp",".cl",".pro",".P",".st",".vhd",".vhdl",".sv",".svh"].includes(e)&&t.push(n)}}}catch(e){}return t}_shouldIgnore(e){const t=e.replace(/\\/g,"/"),s=["node_modules",".git","dist",".vite"];for(const e of s)if(t.includes("/"+e+"/")||t.startsWith(e+"/")||t===e||t.endsWith("/"+e))return!0;for(const e of this.config.ignorePatterns){const s=e.replace(/\\/g,"/"),n=s.split("/")[0].replace(/\*/g,"");if(n&&(t===n||t.startsWith(n+"/")))return!0;let i=s.replace(/\./g,"\\.").replace(/\*\*/g,".*").replace(/\*/g,"[^/]*");if(new RegExp("^"+i).test(t))return!0}return!1}_runPatternScan(e,t,s,n,i){const r=[],a=path.basename(e),o=this.testFilePatterns.some(e=>e.test(a))||this.testFilePatterns.some(t=>t.test(e)&&!t.source.includes("\\.js$")),c=path.relative(this.config.rootPath,e).replace(/\\/g,"/");for(const a of n){if(a.skipInTests&&o)continue;if(a.skipInDirs&&a.skipInDirs.some(e=>c.startsWith(e+"/")||c.includes("/"+e+"/")))continue;if(a.excludeExtensions){const t=path.extname(e).toLowerCase();if(a.excludeExtensions.includes(t))continue}if(a.context&&!a.lineContext&&!a.context.test(t))continue;let n=0;for(const o of s){if(n++,!a.matchInComments){const e=o.trim();if((e.startsWith("*")||e.startsWith("//")||e.startsWith("/*"))&&"QUAL002"!==a.id&&"QUAL003"!==a.id)continue}const s=o.match(a.pattern);if(s){if(a.skipIfSafe&&this.safePatterns.some(e=>e.test(o)))continue;if(a.check&&!a.check(s,t,e))continue;if(("sql_injection"===a.type||"xss"===a.type)&&/\b(?:parseInt|parseFloat|Number|int|float|str|strconv\.(?:Atoi|Itoa|ParseInt|ParseFloat|ParseBool|FormatInt)|\.to_i|\.to_f|\.to_s|CGI\.escapeHTML|ERB::Util\.html_escape|html\.EscapeString|url\.QueryEscape|encodeURIComponent|encodeURI|htmlspecialchars|htmlentities)\b/.test(o))continue;r.push({file:e,line:n,column:s.index,category:i,type:a.type||i,severity:a.severity,id:a.id,name:a.name,message:a.message,code:o.trim().substring(0,100),...a.owasp&&{owasp:a.owasp},...a.cwe&&{cwe:a.cwe}})}}}return r}_runAstScan(e,t,s){let n;try{n=astAnalyzer.analyze(e,t)}catch(e){return[]}if(!n||0===n.length)return[];const i=new Set(s.map(e=>`${e.line}:${e.type}`));return n.filter(e=>!i.has(`${e.line}:${e.type}`))}_buildExportTaintMap(e){try{return taintTracker.buildExportTaintMap(e)}catch(e){return new Map}}_runTaintScan(e,t,s){let n;try{const s=path.extname(e).toLowerCase();if(new Set([".js",".jsx",".ts",".tsx",".mjs",".cjs"]).has(s)){let s;if(this._exportTaintMap){const n=taintTracker._internal.parseJS(t);n&&(s=taintTracker.buildImportSeeds(e,n,this._exportTaintMap,fs.existsSync))}n=taintTracker.analyzeJSTaint(e,t,s&&s.size?s:void 0)}else n=taintTracker.analyze(e,t)}catch(e){return[]}return n&&0!==n.length?n:[]}_runCfgScan(e,t,s){let n;try{n=cfgAnalyzer.analyze(e,t)}catch(e){return[]}if(!n||0===n.length)return[];const i=new Set(s.map(e=>`${e.line}:${e.type}`));return n.filter(e=>!i.has(`${e.line}:${e.type}`))}_analyzeComplexity(e,t,s){const n=[],i=t.match(/(?:^|\n)\s*(?:export\s+)?(?:async\s+)?function\s+\w+|=>\s*\{|(?:^|\n)\s*func\s+(?:\([^)]*\)\s+)?\w+\s*\(|(?:^|\n)\s*(?:pub\s+)?(?:async\s+)?fn\s+\w+|(?:^|\n)\s*def\s+(?:self\.)?\w+|(?:^|\n)\s*(?:public|private|protected|internal)?\s*(?:fun|suspend\s+fun)\s+\w+/gm)||[],r=t.match(/\b(if|else|for|while|switch|case|catch|&&|\|\||\?)\b/g)||[],a=i.length>0?r.length/i.length:0;return a>this.config.complexityThreshold&&n.push({file:e,category:"quality",severity:"warning",id:"CMPLX001",name:"High Complexity",message:`Average cyclomatic complexity is ${a.toFixed(1)} (threshold: ${this.config.complexityThreshold})`}),s.length>500&&n.push({file:e,category:"quality",severity:"info",id:"CMPLX002",name:"Long File",message:`File has ${s.length} lines - consider splitting`}),n}_analyzeNesting(e,t,s){const n=[],i=path.extname(e).toLowerCase();let r=0,a=0,o=0;if(".rb"===i){let e=0;for(const t of s){e++;const s=t.replace(/#.*$/,"").trim();if(!s)continue;const n=(s.match(/\b(?:def|do|if|unless|while|until|for|begin|case|class|module)\b/g)||[]).length;a+=n-(/\b(?:if|unless|while|until)\b/.test(s)&&!s.match(/^\s*(?:if|unless|while|until|elsif)\b/)&&1===n?1:0)-(s.match(/\bend\b/g)||[]).length,a<0&&(a=0),a>r&&(r=a,o=e)}}else if(".py"===i||".pyw"===i){let e=0;for(const n of s){if(e++,!n.trim()||n.trim().startsWith("#"))continue;const s=n.match(/^(\s*)/)[1].length,i=Math.floor(s/(t.includes("\t")?1:4));i>r&&(r=i,o=e)}}else{let e=0;for(const t of s)e++,a+=(t.match(/\{/g)||[]).length-(t.match(/\}/g)||[]).length,a>r&&(r=a,o=e)}return r>this.config.nestingThreshold&&n.push({file:e,line:o,category:"quality",severity:"warning",id:"NEST001",name:"Deep Nesting",message:`Max nesting depth is ${r} at line ${o} (threshold: ${this.config.nestingThreshold})`}),n}_scanJson(e,t){const s=[];try{JSON.parse(t)}catch(t){s.push({file:e,category:"quality",severity:"error",id:"JSON001",name:"Invalid JSON",message:`JSON parse error: ${t.message}`})}return/(password|secret|api[_-]?key|token)/i.test(t)&&s.push({file:e,category:"security",severity:"warning",id:"JSON002",name:"Sensitive Data in JSON",message:"Possible sensitive data in JSON file - verify not committed"}),s}_checkDependencyExists(e,t){const s=e[0].match(/require\(['"]([^'"]+)['"]\)/);if(!s)return!0;const n=s[1];if(n.startsWith("."))return!1;const i=n.startsWith("node:")?n.slice(5).split("/")[0]:n.split("/")[0];if(["assert","async_hooks","buffer","child_process","cluster","console","constants","crypto","dgram","diagnostics_channel","dns","domain","events","fs","http","http2","https","inspector","module","net","os","path","perf_hooks","process","punycode","querystring","readline","repl","stream","string_decoder","sys","test","timers","tls","trace_events","tty","url","util","v8","vm","wasi","worker_threads","zlib"].includes(i))return!1;const r=n.startsWith("@")?n.split("/").slice(0,2).join("/"):i;let a=path.dirname(t);const o=this.config.rootPath;for(;a.length>=o.length;){try{const e=path.join(a,"package.json");if(fs.existsSync(e)){const t=JSON.parse(fs.readFileSync(e,"utf8")),s={...t.dependencies||{},...t.devDependencies||{},...t.peerDependencies||{}};if(s[r]||s[n])return!1}}catch(e){}const e=path.dirname(a);if(e===a)break;a=e}return!0}_checkImportUsage(e,t){const s=e[1];if(!s)return!1;const n=new RegExp("\\b"+s+"\\b","g");return(t.match(n)||[]).length<=1}_summarizeIssues(e){return{total:e.length,bySeverity:{critical:e.filter(e=>"critical"===e.severity).length,error:e.filter(e=>"error"===e.severity).length,warning:e.filter(e=>"warning"===e.severity).length,info:e.filter(e=>"info"===e.severity).length},byCategory:e.reduce((e,t)=>(e[t.category]=(e[t.category]||0)+1,e),{}),topFiles:this._getTopFiles(e,10)}}_getTopFiles(e,t){const s=e.reduce((e,t)=>(e[t.file]=(e[t.file]||0)+1,e),{});return Object.entries(s).sort((e,t)=>t[1]-e[1]).slice(0,t).map(([e,t])=>({file:path.relative(this.config.rootPath,e),count:t}))}}module.exports=CodeScanner;
@@ -1 +0,0 @@
1
- const fs=require("fs"),path=require("path"),MAX_IGNORE_PATTERNS=1e3;function loadThubanIgnore(e){const t=[];try{const n=path.join(e,".thubanignore");if(fs.existsSync(n)){if(fs.statSync(n).size>262144)return console.warn("[THUBAN] WARNING: .thubanignore exceeds 256KB — ignoring to prevent DoS"),t;const e=fs.readFileSync(n,"utf-8");for(const n of e.split(/\r?\n/)){const e=n.trim();if(e&&!e.startsWith("#")&&(t.push(e),t.length>=1e3)){console.warn("[THUBAN] WARNING: .thubanignore has >1000 patterns — truncating to prevent DoS");break}}}}catch{}return t}function matchesIgnorePattern(e,t){const n=e.replace(/\\/g,"/");for(const e of t){const t=e.replace(/\\/g,"/").replace(/\/+$/,"");if(t&&"."!==t&&"*"!==t&&"**"!==t){if(t.endsWith("/**")){const e=t.slice(0,-3);if(!e||"."===e)continue;if(n===e||n.startsWith(e+"/"))return!0}if(n===t)return!0;if(n.startsWith(t+"/"))return!0}}return!1}function collectFiles(e,t=[]){const n=["node_modules",".git","dist","build",".next","__pycache__",".venv","venv","coverage",".cache",".turbo",...t],i=[".js",".ts",".jsx",".tsx",".mjs",".cjs",".py",".pyw",".go",".rs",".java",".kt",".cs",".php",".rb",".json"],s=1048576,r=[],o=(new Set,path.resolve(e)),c=loadThubanIgnore(o);let a=0,l=0;function u(e){const t=o+path.sep,n=path.resolve(e);return n===o||n.startsWith(t)}if(function e(t,f){if(r.length>=5e4)return;if(f>100)return;if(!u(t))return;let h;try{h=fs.readdirSync(t,{withFileTypes:!0})}catch(e){if("ENOTDIR"===e.code)try{const e=fs.lstatSync(t);if(e.isSymbolicLink())return;if(!u(t))return;e.isFile()&&i.some(e=>t.endsWith(e))&&e.size>0&&e.size<=s&&r.push(t)}catch{}return}for(const p of h){if(r.length>=5e4)return;if(n.some(e=>p.name===e))continue;if(p.name.includes("\0"))continue;const h=path.join(t,p.name),g=path.resolve(h);if(!u(g))continue;const d=path.relative(o,g);if(d.startsWith(".."))continue;if(c.length>0&&matchesIgnorePattern(d,c)){a++;continue}let y;try{y=fs.lstatSync(h)}catch{continue}y.isSymbolicLink()||(y.isDirectory()?e(h,f+1):y.isFile()&&i.some(e=>p.name.normalize("NFC").endsWith(e))&&(l++,y.size>0&&y.size<=s&&r.push(h)))}}(e,0),c.length>0&&l>0){const e=r.length+a;if(e>0){const t=a/e;t>.9&&console.warn(`[THUBAN] WARNING: .thubanignore is excluding ${a} of ${e} files (${Math.round(100*t)}%). This may indicate a malicious ignore file designed to suppress scan findings. Review .thubanignore carefully.`)}}return r}module.exports={collectFiles:collectFiles};
@@ -1 +0,0 @@
1
- const fs=require("fs"),path=require("path"),EventEmitter=require("events");class FileWatcher extends EventEmitter{constructor(t={}){super(),this.config={rootPath:t.rootPath||process.cwd(),watchPatterns:t.watchPatterns||["**/*.js","**/*.ts","**/*.json"],ignorePatterns:t.ignorePatterns||["node_modules/**",".git/**","dist/**","build/**",".orion/snapshots/**","coverage/**","*.log"],debounceMs:t.debounceMs||300,...t},this.watchers=[],this.watchedFiles=new Set,this.debounceTimers=new Map,this.isRunning=!1}async start(){if(this.isRunning)return{success:!0,message:"Already watching"};console.log("[FILE-WATCHER] Starting file watcher..."),console.log(`[FILE-WATCHER] Root path: ${this.config.rootPath}`);try{return await this._discoverFiles(this.config.rootPath),this._setupWatchers(),this.isRunning=!0,console.log(`[FILE-WATCHER] Watching ${this.watchedFiles.size} files`),{success:!0,filesWatched:this.watchedFiles.size}}catch(t){return console.error("[FILE-WATCHER] Start failed"),{success:!1,error:"Start failed"}}}async stop(){console.log("[FILE-WATCHER] Stopping file watcher...");for(const t of this.watchers)try{t.close()}catch(t){}for(const t of this.debounceTimers.values())clearTimeout(t);return this.watchers=[],this.debounceTimers.clear(),this.isRunning=!1,console.log("[FILE-WATCHER] Stopped"),{success:!0}}getWatchedCount(){return this.watchedFiles.size}getWatchedFiles(){return Array.from(this.watchedFiles)}shouldIgnore(t){const e=path.relative(this.config.rootPath,t);for(const t of this.config.ignorePatterns)if(this._matchPattern(e,t))return!0;return!1}shouldWatch(t){const e=path.relative(this.config.rootPath,t);if(this.shouldIgnore(t))return!1;for(const t of this.config.watchPatterns)if(this._matchPattern(e,t))return!0;return!1}async _discoverFiles(t,e=0){if(!(e>100))try{const s=fs.readdirSync(t,{withFileTypes:!0});for(const i of s){const s=path.join(t,i.name);i.isDirectory()?this.shouldIgnore(s)||await this._discoverFiles(s,e+1):i.isFile()&&this.shouldWatch(s)&&this.watchedFiles.add(s)}}catch(t){"ENOENT"!==t.code&&"EACCES"!==t.code&&console.warn("[FILE-WATCHER] Error scanning directory")}}_setupWatchers(){const t=new Set;for(const e of this.watchedFiles)t.add(path.dirname(e));for(const e of t)try{const t=fs.watch(e,{persistent:!0},(t,s)=>{if(s){const i=path.join(e,s);this._handleFileEvent(t,i)}});t.on("error",()=>{}),this.watchers.push(t)}catch(t){console.warn("[FILE-WATCHER] Could not watch directory")}try{const t=fs.watch(this.config.rootPath,{recursive:!0},(t,e)=>{if(e){const s=path.join(this.config.rootPath,e);this._handleFileEvent(t,s)}});t.on("error",()=>{}),this.watchers.push(t)}catch(t){}}_handleFileEvent(t,e){this.shouldIgnore(e)||(this.debounceTimers.has(e)&&clearTimeout(this.debounceTimers.get(e)),this.debounceTimers.set(e,setTimeout(()=>{this.debounceTimers.delete(e),this._processFileEvent(t,e)},this.config.debounceMs)))}_processFileEvent(t,e){const s=fs.existsSync(e),i=s&&fs.statSync(e).isFile();let o;s?i&&this.shouldWatch(e)&&(this.watchedFiles.has(e)?o={type:"change",filePath:e,timestamp:(new Date).toISOString()}:(this.watchedFiles.add(e),o={type:"add",filePath:e,timestamp:(new Date).toISOString()})):this.watchedFiles.has(e)&&(this.watchedFiles.delete(e),o={type:"delete",filePath:e,timestamp:(new Date).toISOString()}),o&&(this.emit(o.type,o),this.emit("any",o))}_matchPattern(t,e){const s=t.replace(/\\/g,"/");let i=e.replace(/\\/g,"/").replace(/\./g,"\\.").replace(/\*\*/g,"<<<GLOBSTAR>>>").replace(/\*/g,"[^/]*").replace(/<<<GLOBSTAR>>>/g,".*").replace(/\?/g,".");i="^"+i+"$";try{return new RegExp(i).test(s)}catch(t){return!1}}}module.exports=FileWatcher;
@@ -1 +0,0 @@
1
- const fs=require("fs"),path=require("path");class GhostCodeDetector{constructor(e={}){this.rootPath=e.rootPath||process.cwd()}scan(e){const t=[],s={},n=new Map,i=new Map;for(const o of e){let e;try{if(fs.statSync(o).size>524288)continue;e=fs.readFileSync(o,"utf-8").replace(/\r\n/g,"\n")}catch(e){continue}const r=path.relative(this.rootPath,o);if(this._isSkippable(r))continue;const c=e.split("\n");n.set(r,e),i.set(r,c);for(let e=0;e<c.length;e++){const n=c[e],i=this._extractFunction(n,e,c);if(i){i.file=r,i.line=e+1,i.lineCount=this._countFunctionLines(c,e),i.declKind="function",t.push(i),s[i.name]||(s[i.name]=0);continue}const o=this._extractClass(n);if(o){o.file=r,o.line=e+1,o.lineCount=this._countFunctionLines(c,e),o.declKind="class",t.push(o),s[o.name]||(s[o.name]=0);continue}const a=this._extractConstDeclaration(n);if(a){a.file=r,a.line=e+1,a.lineCount=1,a.declKind="const",t.push(a),s[a.name]||(s[a.name]=0);continue}const l=this._extractImports(n);for(const n of l)n.file=r,n.line=e+1,n.lineCount=1,n.declKind="import",t.push(n),s[n.name]||(s[n.name]=0)}}for(const i of e){const e=path.relative(this.rootPath,i),o=n.get(e);if(void 0===o)continue;const r=this._stripCommentsAndStrings(o);for(const n of t){if(n.name.length<3)continue;const t=new RegExp(`\\b${this._escapeRegex(n.name)}\\b`,"g"),i=r.match(t);if(i){const t=e===n.file;s[n.name]+=i.length-(t?1:0)}}}const o=t.filter(e=>"function"===e.declKind).filter(e=>(s[e.name]||0)<=0&&!e.isLifecycle&&e.lineCount>=3).map(e=>({...e,references:s[e.name]||0,wastedLines:e.lineCount,category:"ghost",severity:e.isExport?"low":e.lineCount>30?"high":"medium",message:`${e.name}() — ${e.lineCount} lines, never called${e.isExport?" (exported — verify no external consumers)":""}`})),r=t.filter(e=>"class"===e.declKind).filter(e=>(s[e.name]||0)<=0).map(e=>({...e,references:s[e.name]||0,wastedLines:e.lineCount,category:"ghost_class",severity:e.isExport?"low":"medium",message:`class ${e.name} — ${e.lineCount} lines, never referenced${e.isExport?" (exported — verify no external consumers)":""}`})),c=t.filter(e=>"const"===e.declKind).filter(e=>(s[e.name]||0)<=0).map(e=>({...e,references:s[e.name]||0,wastedLines:e.lineCount,category:"ghost_const",severity:e.isExport?"low":"medium",message:`${e.kind} ${e.name} — declared but never used${e.isExport?" (exported — verify no external consumers)":""}`})),a=t.filter(e=>"import"===e.declKind).filter(e=>(s[e.name]||0)<=0).map(e=>({...e,references:s[e.name]||0,wastedLines:e.lineCount,category:"ghost_import",severity:"low",message:`import '${e.name}' from '${e.source}' — never used`})),l=this._findDeadClusters(t.filter(e=>"function"===e.declKind),n,s),f=[...o,...r,...c,...a,...l].sort((e,t)=>t.wastedLines-e.wastedLines),u=f.reduce((e,t)=>e+t.wastedLines,0),p=e.reduce((e,t)=>{try{return e+fs.readFileSync(t,"utf-8").replace(/\r\n/g,"\n").split("\n").length}catch(t){return e}},0);return{ghosts:f,totalGhosts:f.length,totalWastedLines:u,wastedPercent:p>0?Math.round(u/p*1e3)/10:0,totalLines:p,breakdown:{functions:o.length,classes:r.length,consts:c.length,imports:a.length,deadClusters:l.length}}}_extractFunction(e,t,s){const n=e.trim();let i=n.match(/^(?:async\s+)?function\s+([a-zA-Z_$][a-zA-Z0-9_$]*)\s*\(/);return i?{name:i[1],type:"function",isExport:this._isExported(e,t,s),isLifecycle:this._isLifecycle(i[1])}:(i=n.match(/^(?:const|let|var)\s+([a-zA-Z_$][a-zA-Z0-9_$]*)\s*=\s*(?:async\s+)?function/),i?{name:i[1],type:"const-function",isExport:this._isExported(e,t,s),isLifecycle:this._isLifecycle(i[1])}:(i=n.match(/^(?:const|let|var)\s+([a-zA-Z_$][a-zA-Z0-9_$]*)\s*=\s*(?:async\s+)?\(?/),i&&(n.includes("=>")||t+1<s.length&&s[t+1].includes("=>"))?{name:i[1],type:"arrow",isExport:this._isExported(e,t,s),isLifecycle:this._isLifecycle(i[1])}:(i=n.match(/^(?:private\s+|public\s+|internal\s+|protected\s+)?(?:suspend\s+)?fun\s+([a-zA-Z_][a-zA-Z0-9_]*)\s*[(<]/),i?{name:i[1],type:"kotlin-fun",isExport:!n.startsWith("private"),isLifecycle:this._isLifecycle(i[1])}:(i=n.match(/^func\s+(?:\([^)]*\)\s+)?([a-zA-Z_][a-zA-Z0-9_]*)\s*\(/),i?{name:i[1],type:"go-func",isExport:/^[A-Z]/.test(i[1]),isLifecycle:this._isLifecycle(i[1])}:(i=n.match(/^(?:pub(?:\([^)]*\))?\s+)?(?:async\s+)?fn\s+([a-zA-Z_][a-zA-Z0-9_]*)\s*[(<]/),i?{name:i[1],type:"rust-fn",isExport:/^pub/.test(n),isLifecycle:this._isLifecycle(i[1])}:(i=n.match(/^(?:(?:public|private|protected|static)\s+)*function\s+([a-zA-Z_][a-zA-Z0-9_]*)\s*\(/),i?{name:i[1],type:"php-function",isExport:!/private/.test(n),isLifecycle:this._isLifecycle(i[1])}:(i=n.match(/^def\s+(?:self\.)?([a-zA-Z_][a-zA-Z0-9_?!]*)\s*[(\s]?/),i?{name:i[1],type:"ruby-def",isExport:/^def\s+self\./.test(n),isLifecycle:this._isLifecycle(i[1])}:(i=n.match(/^(?:async\s+)?([a-zA-Z_$][a-zA-Z0-9_$]*)\s*\([^)]*\)\s*{/),i&&!["if","for","while","switch","catch","constructor","render","toString"].includes(i[1])?{name:i[1],type:"method",isExport:!1,isLifecycle:this._isLifecycle(i[1])}:null))))))))}_isExported(e,t,s){return!!/^export\s/.test(e.trim())||!!/module\.exports/.test(e)}_extractClass(e){const t=e.trim(),s=t.match(/^(?:export\s+(?:default\s+)?)?class\s+([a-zA-Z_$][a-zA-Z0-9_$]*)/);return s?{name:s[1],type:"class",isExport:/^export\s/.test(t),isLifecycle:!1}:null}_extractConstDeclaration(e){const t=e.trim().match(/^(export\s+)?(const|let|var)\s+([a-zA-Z_$][a-zA-Z0-9_$]*)\s*=\s*(.+)$/);if(!t)return null;const[,s,n,i,o]=t;return/^(?:async\s+)?function\b/.test(o)||/=>/.test(o)||""===o.trim()||/^\(/.test(o.trim())&&/=>/.test(o)||/require\s*\(/.test(o)?null:{name:i,kind:n,type:"const-declaration",isExport:!!s,isLifecycle:!1}}_extractImports(e){const t=e.trim(),s=[];let n=t.match(/^import\s*\{([^}]+)\}\s*from\s*['"]([^'"]+)['"]/);if(n){const e=n[1].split(",").map(e=>e.trim()).filter(Boolean);for(const t of e){const e=t.split(/\s+as\s+/),i=(e[1]||e[0]).trim();i&&s.push({name:i,source:n[2],type:"import"})}return s}if(n=t.match(/^import\s+([a-zA-Z_$][a-zA-Z0-9_$]*)\s*(?:,|from)/),n&&!/^import\s*\{/.test(t)){const e=t.match(/from\s*['"]([^'"]+)['"]/);return s.push({name:n[1],source:e?e[1]:"",type:"import"}),s}if(n=t.match(/^import\s*\*\s*as\s+([a-zA-Z_$][a-zA-Z0-9_$]*)\s*from\s*['"]([^'"]+)['"]/),n)return s.push({name:n[1],source:n[2],type:"import"}),s;if(n=t.match(/^(?:const|let|var)\s*\{([^}]+)\}\s*=\s*require\s*\(\s*['"]([^'"]+)['"]\s*\)/),n){const e=n[1].split(",").map(e=>e.trim()).filter(Boolean);for(const t of e){const e=t.split(":").map(e=>e.trim()),i=(e[1]||e[0]).trim();i&&s.push({name:i,source:n[2],type:"import"})}return s}return n=t.match(/^(?:const|let|var)\s+([a-zA-Z_$][a-zA-Z0-9_$]*)\s*=\s*require\s*\(\s*['"]([^'"]+)['"]\s*\)/),n?(s.push({name:n[1],source:n[2],type:"import"}),s):s}_findDeadClusters(e,t,s){const n=[],i=new Map;for(const t of e)t.isExport||t.isLifecycle||i.set(t.name,t);if(i.size<2)return n;const o=new Map;for(const[e,s]of i){const n=t.get(s.file);if(!n){o.set(e,new Set);continue}const r=n.split("\n").slice(s.line-1,s.line-1+s.lineCount),c=this._stripCommentsAndStrings(r.join("\n")),a=new Set;for(const[t]of i)t!==e&&new RegExp(`\\b${this._escapeRegex(t)}\\b`).test(c)&&a.add(t);o.set(e,a)}const r=new Map,c=e=>{r.has(e)||r.set(e,e);let t=e;for(;r.get(t)!==t;)t=r.get(t);let s=e;for(;r.get(s)!==t;){const e=r.get(s);r.set(s,t),s=e}return t},a=(e,t)=>{const s=c(e),n=c(t);s!==n&&r.set(s,n)};for(const[e,t]of o){c(e);for(const s of t)c(s),a(e,s)}const l=new Map;for(const e of i.keys()){const t=c(e);l.has(t)||l.set(t,[]),l.get(t).push(e)}for(const[,e]of l){if(e.length<2)continue;let t=!1;for(const s of e){for(const n of o.get(s)||[])if(e.includes(n)&&(o.get(n)||new Set).has(s)){t=!0;break}if(t)break}if(!t)continue;let r=!1;for(const t of e)if((s[t]||0)-e.reduce((e,s)=>s===t?e:e+((o.get(s)||new Set).has(t)?1:0),0)>0){r=!0;break}if(r)continue;const c=e.reduce((e,t)=>e+(i.get(t).lineCount||0),0);n.push({name:e.join(", "),file:i.get(e[0]).file,line:i.get(e[0]).line,lineCount:c,wastedLines:c,references:0,category:"dead_cluster",severity:"high",message:`Dead cluster: ${e.join(" ↔ ")} — mutually reference each other but nothing outside the cluster calls them`})}return n}_isLifecycle(e){return["constructor","render","componentDidMount","componentWillUnmount","componentDidUpdate","shouldComponentUpdate","getSnapshotBeforeUpdate","getDerivedStateFromProps","useEffect","useState","useMemo","toString","valueOf","toJSON","inspect","setup","teardown","beforeEach","afterEach","beforeAll","afterAll","init","destroy","configure","bootstrap","main","get","set","post","put","delete","patch","handle","onCreate","onStart","onResume","onPause","onStop","onDestroy","onCreateView","onViewCreated","onDestroyView","hashCode","equals","new","default","drop","fmt","from","into","clone","copy","initialize","to_s","to_str","inspect","freeze","dup","__construct","__destruct","__toString","__get","__set","__call"].includes(e)||/^__/.test(e)||/^on[A-Z]/.test(e)}_countFunctionLines(e,t){const s=(e[t]||"").trim();if(/^def\s/.test(s)){let s=1,n=1;for(let i=t+1;i<e.length&&i<t+200;i++){n++;const t=e[i].trim();if(/^(?:def|class|module|begin|case)\b/.test(t)&&s++,/^(?:if|unless|while|until|for)\b/.test(t)&&!/\bthen\b/.test(t)&&s++,/\bdo\s*(\|[^|]*\|)?\s*$/.test(t)&&s++,/^end\b/.test(t)&&s--,s<=0)break}return n}let n=0,i=!1,o=0;for(let s=t;s<e.length&&s<t+200;s++){const t=e[s];o++;for(const e of t)"{"===e&&(n++,i=!0),"}"===e&&n--;if(i&&n<=0)break}return o}_isSkippable(e){return[/\.test\./i,/\.spec\./i,/test[\/\\]/i,/spec[\/\\]/i,/__test__/i,/__mocks__/i,/\.config\./i,/\.d\.ts$/,/index\.(js|ts)$/,/server\.(js|ts)$/,/app\.(js|ts)$/,/routes?\.(js|ts)$/,/middleware/i].some(t=>t.test(e))}_escapeRegex(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}_stripCommentsAndStrings(e){return e.replace(/`[^`\\]*(?:\\[\s\S][^`\\]*)*`/g,'""').replace(/"[^"\\\r\n]*(?:\\.[^"\\\r\n]*)*"/g,'""').replace(/'[^'\\\r\n]*(?:\\.[^'\\\r\n]*)*'/g,"''").replace(/\/\*[\s\S]*?\*\//g," ").replace(/\/\/[^\r\n]*/g," ").replace(/#[^\r\n]*/g," ")}}module.exports=GhostCodeDetector;
@@ -1 +0,0 @@
1
- const fs=require("fs"),path=require("path"),exportVerifier=require("./export-verifier");class HallucinationDetector{constructor(e={}){const t=new Set(["rootPath","ignorePatterns","maxFileSize"]),s={};for(const n of Object.keys(e))t.has(n)&&(s[n]=e[n]);this.config={rootPath:s.rootPath||process.cwd()},this.builtins=new Set(["assert","async_hooks","buffer","child_process","cluster","console","constants","crypto","dgram","diagnostics_channel","dns","domain","events","fs","http","http2","https","inspector","module","net","os","path","perf_hooks","process","punycode","querystring","readline","repl","stream","string_decoder","sys","test","timers","tls","trace_events","tty","url","util","v8","vm","wasi","worker_threads","zlib","node:fs","node:path","node:os","node:crypto","node:http","node:https","node:events","node:util","node:stream","node:child_process","node:url","node:querystring","node:buffer","node:net","node:tls","node:dns","node:readline","node:zlib","node:worker_threads","node:cluster","node:vm","node:assert","node:timers","node:timers/promises","node:test","fs/promises","stream/promises","timers/promises","dns/promises","readline/promises"]),this.phantomPackages=new Set(["node-fetch-extra","express-async","mongoose-v2","react-native-web-view","axios-retry-enhanced","lodash-extended","moment-timezone-v2","socket.io-extra","graphql-tools-v2","next-auth-v5","prisma-client-v2","tailwind-utils","react-query-v4","jest-extended-v2"]),this.knownRealPackages=new Set(["express","koa","fastify","hapi","nest","@nestjs/core","@nestjs/common","next","nuxt","gatsby","remix","@remix-run/node","@remix-run/react","react","react-dom","react-native","react-router","react-router-dom","@tanstack/react-query","react-query","react-hook-form","react-redux","redux","@reduxjs/toolkit","zustand","jotai","recoil","mobx","vue","vuex","pinia","vue-router","@vue/compiler-sfc","@angular/core","@angular/common","@angular/router","@angular/forms","lodash","lodash-es","underscore","ramda","date-fns","dayjs","moment","uuid","nanoid","chalk","colors","debug","dotenv","cross-env","commander","yargs","inquirer","ora","glob","minimatch","semver","minimist","meow","execa","shelljs","fs-extra","rimraf","mkdirp","del","cpy","globby","fast-glob","chokidar","nodemon","axios","node-fetch","got","superagent","ky","undici","isomorphic-fetch","cors","helmet","body-parser","cookie-parser","compression","express-validator","joi","yup","zod","ajv","mongoose","sequelize","typeorm","prisma","@prisma/client","knex","pg","mysql","mysql2","sqlite3","better-sqlite3","redis","ioredis","mongodb","drizzle-orm","objection","bookshelf","jsonwebtoken","bcrypt","bcryptjs","passport","passport-local","passport-jwt","express-session","cookie-session","csurf","hpp","rate-limiter-flexible","express-rate-limit","next-auth","@auth/core","jest","mocha","chai","sinon","vitest","@testing-library/react","@testing-library/jest-dom","supertest","nock","cypress","playwright","@playwright/test","enzyme","nyc","istanbul","c8","ava","tap","webpack","vite","esbuild","rollup","parcel","turbo","tsup","babel-loader","@babel/core","@babel/preset-env","@babel/preset-react","@babel/preset-typescript","ts-node","tsx","typescript","tailwindcss","postcss","autoprefixer","sass","less","styled-components","@emotion/react","@emotion/styled","css-modules","classnames","clsx","winston","pino","bunyan","morgan","log4js","loglevel","sentry","@sentry/node","@sentry/react","newrelic","datadog-metrics","aws-sdk","@aws-sdk/client-s3","@aws-sdk/client-dynamodb","@google-cloud/storage","@google-cloud/pubsub","@google-cloud/firestore","firebase","firebase-admin","@supabase/supabase-js","socket.io","socket.io-client","ws","mqtt","amqplib","bull","bullmq","multer","sharp","jimp","formidable","busboy","csv-parse","csv-parser","papaparse","xlsx","exceljs","pdfkit","puppeteer","cheerio","jsdom","graphql","apollo-server","@apollo/server","@apollo/client","graphql-tag","type-graphql","graphql-yoga","urql","async","bluebird","rxjs","immutable","immer","p-limit","p-queue","eventemitter3","mitt","cron","node-cron","agenda","handlebars","ejs","pug","nunjucks","mustache","marked","markdown-it","remark","rehype","unified","nodemailer","twilio","stripe","@stripe/stripe-js","i18next","intl","i18n","luxon","eslint","prettier","stylelint","lint-staged","husky","lerna","nx","@nrwl/workspace","changesets","@changesets/cli"]),this.phantomAPIs=[{pattern:/fs\.readFileAsync\s*\(/,suggestion:"Use fs.promises.readFile() or fs.readFileSync()",name:"fs.readFileAsync",id:"HALL_API001"},{pattern:/fs\.writeFileAsync\s*\(/,suggestion:"Use fs.promises.writeFile() or fs.writeFileSync()",name:"fs.writeFileAsync",id:"HALL_API002"},{pattern:/fs\.existsAsync\s*\(/,suggestion:"Use fs.promises.access() or fs.existsSync()",name:"fs.existsAsync",id:"HALL_API003"},{pattern:/path\.exists\s*\(/,suggestion:"Use fs.existsSync() — path module has no exists()",name:"path.exists",id:"HALL_API004"},{pattern:/path\.isFile\s*\(/,suggestion:"Use fs.statSync().isFile() — path module has no isFile()",name:"path.isFile",id:"HALL_API005"},{pattern:/path\.isDirectory\s*\(/,suggestion:"Use fs.statSync().isDirectory()",name:"path.isDirectory",id:"HALL_API006"},{pattern:/console\.success\s*\(/,suggestion:"Use console.log() — console.success() does not exist",name:"console.success",id:"HALL_API007"},{pattern:/console\.verbose\s*\(/,suggestion:"Use console.log() or console.debug()",name:"console.verbose",id:"HALL_API008"},{pattern:/JSON\.tryParse\s*\(/,suggestion:"Use try/catch with JSON.parse()",name:"JSON.tryParse",id:"HALL_API009"},{pattern:/JSON\.safeStringify\s*\(/,suggestion:"Use JSON.stringify() with a replacer",name:"JSON.safeStringify",id:"HALL_API010"},{pattern:/Array\.flatten\s*\(/,suggestion:"Use Array.prototype.flat()",name:"Array.flatten",id:"HALL_API011"},{pattern:/Object\.deepClone\s*\(/,suggestion:"Use structuredClone() or JSON.parse(JSON.stringify())",name:"Object.deepClone",id:"HALL_API012"},{pattern:/Object\.deepMerge\s*\(/,suggestion:"Use a library like lodash.merge or write a custom function",name:"Object.deepMerge",id:"HALL_API013"},{pattern:/String\.prototype\.replaceAll\s*&&.*polyfill/i,suggestion:"replaceAll() is native since ES2021 — no polyfill needed",name:"replaceAll polyfill",id:"HALL_API014"},{pattern:/require\s*\(\s*['"]fs\/sync['"]\s*\)/,suggestion:"fs/sync is not a real module — use fs directly",name:"fs/sync",id:"HALL_API015"},{pattern:/require\s*\(\s*['"]http\/server['"]\s*\)/,suggestion:"http/server is not a real module — use http.createServer()",name:"http/server",id:"HALL_API016"},{pattern:/process\.env\.get\s*\(/,suggestion:"Use process.env.VAR_NAME — process.env is a plain object, not a Map",name:"process.env.get()",id:"HALL_API017"},{pattern:/process\.exit\s*\(\s*['"]/,suggestion:"process.exit() takes a number, not a string",name:"process.exit(string)",id:"HALL_API018"}],this.pythonPhantomAPIs=[{pattern:/os\.path\.exists_sync\s*\(/,suggestion:"Use os.path.exists() — exists_sync does not exist in Python",name:"os.path.exists_sync",id:"PY_HALL001"},{pattern:/json\.tryParse\s*\(/,suggestion:"Use json.loads() with try/except",name:"json.tryParse",id:"PY_HALL002"},{pattern:/\w+\.flatMap\s*\(/,suggestion:"Python lists have no flatMap — use list comprehension or itertools.chain.from_iterable()",name:"list.flatMap",id:"PY_HALL003"},{pattern:/\w+\.merge\s*\((?!.*\bself\b)/,suggestion:"Use {**dict1, **dict2} or dict1 | dict2 (3.9+)",name:"dict.merge",id:"PY_HALL004"},{pattern:/\w+\.format_map\s*\(/,suggestion:"str.format_map exists but is rarely correct — did you mean .format()?",name:"string.format_map misuse",id:"PY_HALL005"},{pattern:/from\s+collections\s+import\s+OrderedDict.*#.*maintain\s+order/i,suggestion:"Regular dict maintains order since Python 3.7 — OrderedDict is unnecessary",name:"Unnecessary OrderedDict",id:"PY_HALL006"},{pattern:/async\s+def\s+\w+.*asyncio\.sleep\s*\(\s*0\s*\)\s*#.*yield/i,suggestion:"asyncio.sleep(0) to yield is a code smell — review async design",name:"asyncio.sleep(0) hack",id:"PY_HALL007"},{pattern:/import\s+tensorflow\.v2/,suggestion:"tensorflow.v2 is not a real module — use import tensorflow",name:"tensorflow.v2",id:"PY_HALL008"},{pattern:/from\s+sklearn\.model_selection\s+import\s+train_test_split_v2/,suggestion:"train_test_split_v2 does not exist — use train_test_split",name:"sklearn v2 hallucination",id:"PY_HALL009"},{pattern:/requests\.async_get\s*\(/,suggestion:"requests has no async_get — use aiohttp or httpx",name:"requests.async_get",id:"PY_HALL010"}],this.pythonDeprecated=[{pattern:/from\s+distutils/,suggestion:"distutils removed in Python 3.12 — use setuptools",since:"Python 3.12",name:"distutils",id:"PY_DEPR001"},{pattern:/from\s+imp\s+import/,suggestion:"imp removed in Python 3.12 — use importlib",since:"Python 3.12",name:"imp module",id:"PY_DEPR002"},{pattern:/asyncio\.get_event_loop\(\)/,suggestion:"Deprecated in 3.10+ — use asyncio.run() or get_running_loop()",since:"Python 3.10",name:"asyncio.get_event_loop()",id:"PY_DEPR003"},{pattern:/collections\.MutableMapping/,suggestion:"Moved to collections.abc.MutableMapping in Python 3.3+",since:"Python 3.9",name:"collections.MutableMapping",id:"PY_DEPR004"},{pattern:/optparse\.OptionParser/,suggestion:"optparse deprecated since Python 3.2 — use argparse",since:"Python 3.2",name:"optparse",id:"PY_DEPR005"},{pattern:/cgi\.parse_header\s*\(/,suggestion:"cgi module deprecated in Python 3.11, removed in 3.13",since:"Python 3.11",name:"cgi module",id:"PY_DEPR006"},{pattern:/from\s+typing\s+import\s+(List|Dict|Tuple|Set)\b/,suggestion:"Use built-in list, dict, tuple, set for type hints (Python 3.9+)",since:"Python 3.9",name:"typing.List/Dict/Tuple",id:"PY_DEPR007"},{pattern:/unittest\.makeSuite\s*\(/,suggestion:"makeSuite deprecated — use TestLoader.loadTestsFromTestCase",since:"Python 3.11",name:"unittest.makeSuite",id:"PY_DEPR008"}],this.pythonSmells=[{pattern:/print\s*\(\s*f?['"]\s*debug/i,id:"PY_SMELL001",name:"Debug Print",message:"Debug print statement left in code"},{pattern:/except\s*:\s*$|except\s+Exception\s*:\s*\n\s*pass/m,id:"PY_SMELL002",name:"Bare Except",message:"Bare except or swallowed exception — hides real errors"},{pattern:/#\s*TODO:?\s*(implement|add|fix|complete|finish)/i,id:"PY_SMELL003",name:"Placeholder TODO",message:"AI-generated placeholder — likely unfinished"},{pattern:/raise\s+NotImplementedError\s*\(?\s*\)?/,id:"PY_SMELL004",name:"Not Implemented",message:"Stub implementation — function body was not generated"},{pattern:/['"]your.api.key.here['"]|['"]sk-[.]{3,}['"]/i,id:"PY_SMELL005",name:"Dummy Credential",message:"Placeholder credential — will fail at runtime"},{pattern:/localhost:\d{4}(?!.*(?:dev|test|local|development))/i,id:"PY_SMELL006",name:"Hardcoded Localhost",message:"Hardcoded localhost URL — will fail in production"},{pattern:/import\s+\*/,id:"PY_SMELL007",name:"Wildcard Import",message:"Wildcard import — pollutes namespace, hides dependencies"}],this.goDeprecated=[{pattern:/ioutil\.ReadFile\s*\(/,suggestion:"ioutil removed in Go 1.16 — use os.ReadFile()",since:"Go 1.16",name:"ioutil.ReadFile",id:"GO_DEPR001"},{pattern:/ioutil\.WriteFile\s*\(/,suggestion:"ioutil removed in Go 1.16 — use os.WriteFile()",since:"Go 1.16",name:"ioutil.WriteFile",id:"GO_DEPR002"},{pattern:/ioutil\.TempDir\s*\(/,suggestion:"ioutil removed in Go 1.16 — use os.MkdirTemp()",since:"Go 1.16",name:"ioutil.TempDir",id:"GO_DEPR003"},{pattern:/ioutil\.ReadAll\s*\(/,suggestion:"ioutil removed in Go 1.16 — use io.ReadAll()",since:"Go 1.16",name:"ioutil.ReadAll",id:"GO_DEPR004"},{pattern:/strings\.Title\s*\(/,suggestion:"strings.Title deprecated in Go 1.18 — use cases.Title from golang.org/x/text",since:"Go 1.18",name:"strings.Title",id:"GO_DEPR005"}],this.goSmells=[{pattern:/\/\/\s*TODO:?\s*(implement|add|fix|complete|finish)/i,id:"GO_SMELL001",name:"Placeholder TODO",message:"AI-generated placeholder — likely unfinished"},{pattern:/panic\s*\(\s*["']not implemented["']\s*\)/,id:"GO_SMELL002",name:"Panic Not Implemented",message:"Stub implementation — will panic at runtime"},{pattern:/localhost:\d{4}(?!.*(?:dev|test|local|development))/i,id:"GO_SMELL003",name:"Hardcoded Localhost",message:"Hardcoded localhost URL — will fail in production"}],this.rustPhantomAPIs=[{pattern:/std::fs::File::open_async\s*\(/,suggestion:"Use tokio::fs::File::open() for async file I/O",name:"File::open_async",id:"RS_HALL001"},{pattern:/Vec::flatten\s*\(/,suggestion:"Use .into_iter().flatten() — Vec has no flatten() method",name:"Vec::flatten",id:"RS_HALL002"},{pattern:/HashMap::get_or_default\s*\(/,suggestion:"Use .get().unwrap_or(&default) or entry().or_insert()",name:"HashMap::get_or_default",id:"RS_HALL003"},{pattern:/String::from_utf8_lossy_owned\s*\(/,suggestion:"Use String::from_utf8_lossy().into_owned()",name:"String::from_utf8_lossy_owned",id:"RS_HALL004"},{pattern:/\.async_iter\s*\(/,suggestion:"Use futures::stream::iter() from the futures crate",name:".async_iter()",id:"RS_HALL005"},{pattern:/std::net::TcpStream::connect_async\s*\(/,suggestion:"Use tokio::net::TcpStream::connect()",name:"TcpStream::connect_async",id:"RS_HALL006"},{pattern:/std::thread::sleep_async\s*\(/,suggestion:"Use tokio::time::sleep() for async sleep",name:"thread::sleep_async",id:"RS_HALL007"},{pattern:/Vec::remove_all\s*\(/,suggestion:"Use .retain(|x| condition) or .clear()",name:"Vec::remove_all",id:"RS_HALL008"},{pattern:/str::split_whitespace_n\s*\(/,suggestion:"Use .splitn(n, char::is_whitespace) instead",name:"str::split_whitespace_n",id:"RS_HALL009"},{pattern:/\.map_async\s*\(/,suggestion:"Use futures::future::join_all() or tokio::task::spawn",name:".map_async()",id:"RS_HALL010"}],this.rustDeprecated=[{pattern:/std::sync::ONCE_INIT/,suggestion:"std::sync::ONCE_INIT removed — use Once::new()",since:"Rust 1.38",name:"ONCE_INIT",id:"RS_DEPR001"},{pattern:/\bstd::mem::uninitialized\s*\(/,suggestion:"std::mem::uninitialized() removed — use MaybeUninit::uninit()",since:"Rust 1.39",name:"mem::uninitialized",id:"RS_DEPR002"},{pattern:/\btry!\s*\(/,suggestion:"try!() macro removed — use the ? operator",since:"Rust 2018",name:"try!() macro",id:"RS_DEPR003"},{pattern:/extern\s+crate\s+std\s*;/,suggestion:"extern crate std is implicit since Rust 2018 edition",since:"Rust 2018",name:"extern crate std",id:"RS_DEPR004"},{pattern:/extern\s+crate\s+alloc\s*;/,suggestion:"extern crate alloc is implicit in 2018+ edition",since:"Rust 2018",name:"extern crate alloc",id:"RS_DEPR005"},{pattern:/std::error::Error::cause\s*\(/,suggestion:".cause() deprecated — use .source() instead",since:"Rust 1.33",name:"Error::cause()",id:"RS_DEPR006"}],this.rustSmells=[{pattern:/todo!\s*\(\s*\)/,id:"RS_SMELL001",name:"todo! macro",message:"todo!() macro — will panic at runtime"},{pattern:/unimplemented!\s*\(\s*\)/,id:"RS_SMELL002",name:"unimplemented! macro",message:"unimplemented!() macro — will panic at runtime"},{pattern:/\/\/\s*TODO:?\s*(implement|add|fix|complete|finish)/i,id:"RS_SMELL003",name:"Placeholder TODO",message:"AI-generated placeholder — likely unfinished"},{pattern:/unwrap\(\).*unwrap\(\)/,id:"RS_SMELL004",name:"Double Unwrap",message:"Chained unwrap() — will panic on None/Err"},{pattern:/localhost:\d{4}(?!.*(?:dev|test|local|development))/i,id:"RS_SMELL005",name:"Hardcoded Localhost",message:"Hardcoded localhost URL — will fail in production"},{pattern:/unsafe\s*\{/,id:"RS_SMELL006",name:"Unsafe Block",message:"unsafe block — verify memory safety guarantees"},{pattern:/\.unwrap\(\)\s*;/,id:"RS_SMELL007",name:"Bare unwrap()",message:".unwrap() will panic on None/Err — use ? or match"},{pattern:/println!\s*\(\s*["'].*[Dd]ebug/,id:"RS_SMELL008",name:"Debug println!",message:"Debug println! left in code — use the log crate"},{pattern:/eprintln!\s*\(\s*["'].*[Dd]ebug/,id:"RS_SMELL009",name:"Debug eprintln!",message:"Debug eprintln! left in code — use the log crate"},{pattern:/#\[allow\(dead_code\)\]/,id:"RS_SMELL010",name:"Suppressed Dead Code",message:"#[allow(dead_code)] suppresses warnings — remove unused code"}],this.javaSmells=[{pattern:/System\.out\.println\s*\(.*debug/i,id:"JAVA_SMELL001",name:"Debug Println",message:"Debug System.out.println — use a logger"},{pattern:/\/\/\s*TODO:?\s*(implement|add|fix|complete|finish)/i,id:"JAVA_SMELL002",name:"Placeholder TODO",message:"AI-generated placeholder — likely unfinished"},{pattern:/throw\s+new\s+(?:Runtime)?Exception\s*\(\s*["']Not\s+implemented["']/i,id:"JAVA_SMELL003",name:"Not Implemented",message:"Stub implementation — will throw at runtime"},{pattern:/catch\s*\(\s*Exception\s+\w+\s*\)\s*\{\s*\}/,id:"JAVA_SMELL004",name:"Empty Catch",message:"Empty catch block — swallows all exceptions"},{pattern:/localhost:\d{4}(?!.*(?:dev|test|local|development))/i,id:"JAVA_SMELL005",name:"Hardcoded Localhost",message:"Hardcoded localhost URL — will fail in production"}],this.csharpSmells=[{pattern:/Console\.WriteLine\s*\(.*[Dd]ebug/i,id:"CS_SMELL001",name:"Debug WriteLine",message:"Debug Console.WriteLine — use ILogger or Debug.Write"},{pattern:/\/\/\s*TODO:?\s*(implement|add|fix|complete|finish)/i,id:"CS_SMELL002",name:"Placeholder TODO",message:"AI-generated placeholder — likely unfinished"},{pattern:/throw\s+new\s+(?:NotImplementedException)\s*\(/,id:"CS_SMELL003",name:"Not Implemented",message:"Stub implementation — will throw at runtime"},{pattern:/catch\s*\(\s*Exception\s+\w+\s*\)\s*\{\s*\}/,id:"CS_SMELL004",name:"Empty Catch",message:"Empty catch block — swallows all exceptions"},{pattern:/localhost:\d{4}(?!.*(?:dev|test|local|development))/i,id:"CS_SMELL005",name:"Hardcoded Localhost",message:"Hardcoded localhost URL — will fail in production"}],this.kotlinPhantomAPIs=[{pattern:/\.flatMap\s*\{[^}]*\}(?!.*asSequence)/,suggestion:"Use .flatMap { } — verify this is not confusing sequence vs list behavior",name:"flatMap confusion",id:"KT_HALL001"},{pattern:/listOf\(\)\.stream\s*\(/,suggestion:"Kotlin lists have no .stream() — use .asSequence() or direct collection ops",name:"listOf().stream()",id:"KT_HALL002"},{pattern:/String\.format\s*\(/,suggestion:'Prefer Kotlin string templates "$variable" over String.format()',name:"String.format Java-style",id:"KT_HALL003"},{pattern:/\bObject\s*\(\s*\)/,suggestion:"Kotlin uses Any() not Object() — or use object keyword for singletons",name:"Object() Java-style",id:"KT_HALL004"},{pattern:/\.forEach\s*\(\s*::println\s*\)(?!.*debug)/i,suggestion:"println is for debug output — use a logger",name:"println via forEach",id:"KT_HALL005"},{pattern:/coroutineScope\s*\{\s*launch\s*\{[^}]*\}\s*\}(?!\s*\.join)/,suggestion:"Unjoined coroutine in coroutineScope may cause issues — ensure structured concurrency",name:"Unawaited launch",id:"KT_HALL006"},{pattern:/Dispatchers\.IO\s*\+\s*Dispatchers/,suggestion:"Combining Dispatchers is not valid — use one dispatcher at a time",name:"Combined Dispatchers",id:"KT_HALL007"},{pattern:/\.toList\(\)\.stream\(\)/,suggestion:"Use Kotlin sequences (.asSequence()) instead of .toList().stream()",name:"toList().stream()",id:"KT_HALL008"},{pattern:/companion object.*getInstance/i,suggestion:"Kotlin idiom for singletons is object keyword, not companion object + getInstance()",name:"Java-style singleton",id:"KT_HALL009"},{pattern:/lateinit var.*\?/,suggestion:"lateinit properties cannot be nullable — remove ? or use by lazy {}",name:"lateinit nullable",id:"KT_HALL010"}],this.kotlinDeprecated=[{pattern:/\bapply\s+plugin:\s*['"]kotlin-android-extensions['"]/,suggestion:"kotlin-android-extensions deprecated — use view binding or Jetpack ViewBinding",since:"Kotlin 1.8",name:"kotlin-android-extensions",id:"KT_DEPR001"},{pattern:/\bkotlinx\.android\.synthetic/,suggestion:"Synthetic imports deprecated — use view binding or findViewById",since:"Kotlin 1.8",name:"Synthetic imports",id:"KT_DEPR002"},{pattern:/\bCoroutineScope\(EmptyCoroutineContext\)/,suggestion:"EmptyCoroutineContext coroutine scope is error-prone — use viewModelScope or lifecycleScope",since:"Kotlin Coroutines 1.6",name:"EmptyCoroutineContext scope",id:"KT_DEPR003"},{pattern:/\bBuildersKt\.launch\b/,suggestion:"Internal BuildersKt APIs are deprecated — use coroutineScope { launch {} }",since:"Kotlin Coroutines 1.5",name:"BuildersKt.launch",id:"KT_DEPR004"},{pattern:/\basyncLazy\s*\{/,suggestion:"asyncLazy {} is not a standard Kotlin API — use lazy {} or async {}",since:"Kotlin 1.6",name:"asyncLazy",id:"KT_DEPR005"}],this.kotlinSmells=[{pattern:/\bprintln\s*\(/,id:"KT_SMELL001",name:"Debug println",message:"println() is for debug output — use a proper logger"},{pattern:/\/\/\s*TODO:?\s*(implement|add|fix|complete|finish)/i,id:"KT_SMELL002",name:"Placeholder TODO",message:"AI-generated placeholder — likely unfinished"},{pattern:/TODO\s*\(\s*\)/,id:"KT_SMELL003",name:"TODO() stub",message:"TODO() will throw NotImplementedError at runtime"},{pattern:/!!\s*\./,id:"KT_SMELL004",name:"Non-null assertion chain",message:"!! non-null assertion — will throw NullPointerException if null"},{pattern:/\bas\s+\w+\b(?!.*\?)/,suggestion:"Unsafe cast — prefer safe cast (as? Type) with null check",id:"KT_SMELL005",name:"Unsafe cast",message:"Unsafe cast with as — will throw ClassCastException if wrong type"},{pattern:/localhost:\d{4}(?!.*(?:dev|test|local|development))/i,id:"KT_SMELL006",name:"Hardcoded Localhost",message:"Hardcoded localhost URL — will fail in production"},{pattern:/catch\s*\(\s*e:\s*Exception\s*\)\s*\{\s*\}/,id:"KT_SMELL007",name:"Empty Catch",message:"Empty catch block — swallows all exceptions"},{pattern:/throw\s+NotImplementedError\s*\(/,id:"KT_SMELL008",name:"Not Implemented",message:"Stub implementation — will throw at runtime"}],this.phpPhantomAPIs=[{pattern:/array_flatten\s*\(/,suggestion:"PHP has no array_flatten() — use array_merge(...$array) or a recursive function",name:"array_flatten",id:"PHP_HALL001"},{pattern:/str_contains_all\s*\(/,suggestion:"PHP has no str_contains_all() — use multiple str_contains() calls",name:"str_contains_all",id:"PHP_HALL002"},{pattern:/array_unique_values\s*\(/,suggestion:"PHP has no array_unique_values() — use array_values(array_unique())",name:"array_unique_values",id:"PHP_HALL003"},{pattern:/\$pdo->fetchAll\s*\(/,suggestion:"fetchAll() is on PDOStatement not PDO — call $stmt->fetchAll()",name:"PDO::fetchAll",id:"PHP_HALL004"},{pattern:/json_decode_safe\s*\(/,suggestion:"PHP has no json_decode_safe() — wrap json_decode() with json_last_error() check",name:"json_decode_safe",id:"PHP_HALL005"},{pattern:/str_replace_all\s*\(/,suggestion:"PHP has no str_replace_all() — use str_replace() which already replaces all occurrences",name:"str_replace_all",id:"PHP_HALL006"},{pattern:/array_map_keys\s*\(/,suggestion:"PHP has no array_map_keys() — use array_combine(array_map(...), array_keys())",name:"array_map_keys",id:"PHP_HALL007"},{pattern:/\$request->getJson\s*\(/,suggestion:'Not a standard PHP function — use json_decode(file_get_contents("php://input"))',name:"$request->getJson",id:"PHP_HALL008"},{pattern:/Date::now\s*\(/,suggestion:"PHP has no Date::now() — use new DateTime() or time()",name:"Date::now",id:"PHP_HALL009"},{pattern:/\bawait\s+/,suggestion:"PHP has no await keyword — use synchronous code or ReactPHP for async",name:"await keyword",id:"PHP_HALL010"}],this.phpDeprecated=[{pattern:/\bmysql_connect\s*\(/,suggestion:"mysql_* functions removed in PHP 7 — use PDO or MySQLi",since:"PHP 7.0",name:"mysql_connect",id:"PHP_DEPR001"},{pattern:/\bmysql_query\s*\(/,suggestion:"mysql_* functions removed in PHP 7 — use PDO or MySQLi",since:"PHP 7.0",name:"mysql_query",id:"PHP_DEPR002"},{pattern:/\bmysql_fetch_array\s*\(/,suggestion:"mysql_* functions removed in PHP 7 — use PDO or MySQLi",since:"PHP 7.0",name:"mysql_fetch_array",id:"PHP_DEPR003"},{pattern:/\bereg\s*\(/,suggestion:"ereg() removed in PHP 7 — use preg_match()",since:"PHP 7.0",name:"ereg()",id:"PHP_DEPR004"},{pattern:/\bsplit\s*\(/,suggestion:"split() removed in PHP 7 — use preg_split() or explode()",since:"PHP 7.0",name:"split()",id:"PHP_DEPR005"},{pattern:/\bcreate_function\s*\(/,suggestion:"create_function() removed in PHP 8 — use anonymous functions (closures)",since:"PHP 8.0",name:"create_function",id:"PHP_DEPR006"},{pattern:/\bmagic_quotes_gpc\b/,suggestion:"magic_quotes_gpc removed in PHP 7 — sanitize inputs manually",since:"PHP 7.0",name:"magic_quotes_gpc",id:"PHP_DEPR007"},{pattern:/\beach\s*\(/,suggestion:"each() deprecated in PHP 7.2, removed in PHP 8 — use foreach",since:"PHP 8.0",name:"each()",id:"PHP_DEPR008"},{pattern:/\bmcrypt_/,suggestion:"mcrypt removed in PHP 7.2 — use OpenSSL functions",since:"PHP 7.2",name:"mcrypt functions",id:"PHP_DEPR009"}],this.phpSmells=[{pattern:/\beval\s*\(/,id:"PHP_SMELL001",name:"eval() Usage",message:"eval() is dangerous — code injection risk"},{pattern:/\bextract\s*\(\s*\$_(?:GET|POST|REQUEST)/,id:"PHP_SMELL002",name:"extract() from superglobal",message:"extract($_GET/_POST) — variable injection vulnerability"},{pattern:/\$\$\w+/,id:"PHP_SMELL003",name:"Variable variable",message:"Variable variables ($$var) — hard to trace and injection risk"},{pattern:/\bshell_exec\s*\(/,id:"PHP_SMELL004",name:"shell_exec()",message:"shell_exec() — remote code execution risk if input unsanitized"},{pattern:/\bsystem\s*\(/,id:"PHP_SMELL005",name:"system()",message:"system() — remote code execution risk if input unsanitized"},{pattern:/\bpassthru\s*\(/,id:"PHP_SMELL006",name:"passthru()",message:"passthru() — remote code execution risk if input unsanitized"},{pattern:/\/\/\s*TODO:?\s*(implement|add|fix|complete|finish)/i,id:"PHP_SMELL007",name:"Placeholder TODO",message:"AI-generated placeholder — likely unfinished"},{pattern:/localhost:\d{4}(?!.*(?:dev|test|local|development))/i,id:"PHP_SMELL008",name:"Hardcoded Localhost",message:"Hardcoded localhost URL — will fail in production"},{pattern:/\$_(?:GET|POST|REQUEST)\[.*\].*SELECT.*\./i,id:"PHP_SMELL009",name:"SQL Injection Risk",message:"User input directly in SQL string — use prepared statements"},{pattern:/\bvar_dump\s*\(/,id:"PHP_SMELL010",name:"Debug var_dump",message:"var_dump() is for debug only — remove before production"}],this.rubyPhantomAPIs=[{pattern:/\.flatten_map\s*\{/,suggestion:"Ruby has no .flatten_map — use .flat_map { }",name:".flatten_map",id:"RB_HALL001"},{pattern:/Array\.of\s*\(/,suggestion:"Ruby has no Array.of() — use Array() or []",name:"Array.of()",id:"RB_HALL002"},{pattern:/Hash\.from_array\s*\(/,suggestion:"Ruby has no Hash.from_array() — use array.to_h or Hash[array]",name:"Hash.from_array",id:"RB_HALL003"},{pattern:/\.async\s*\{/,suggestion:"Ruby has no .async {} — use Thread.new or concurrent-ruby gem",name:".async block",id:"RB_HALL004"},{pattern:/String\.format\s*\(/,suggestion:"Ruby has no String.format() — use string interpolation or % operator",name:"String.format",id:"RB_HALL005"},{pattern:/\bpromise\s*\{/,suggestion:"Ruby has no built-in promise {} — use concurrent-ruby gem or Thread",name:"promise block",id:"RB_HALL006"},{pattern:/\.try!\s*\(/,suggestion:"Ruby has no .try!() — use &. (safe navigation) or Rails .try()",name:".try!()",id:"RB_HALL007"},{pattern:/JSON\.safe_parse\s*\(/,suggestion:"Ruby has no JSON.safe_parse — use JSON.parse with rescue",name:"JSON.safe_parse",id:"RB_HALL008"},{pattern:/ActiveRecord::Base\.execute\s*\(/,suggestion:"ActiveRecord::Base has no .execute() — use connection.execute() or where()",name:"Base.execute",id:"RB_HALL009"},{pattern:/\.collect_map\s*\{/,suggestion:"Ruby has no .collect_map — use .map { }.flatten(1) or .flat_map",name:".collect_map",id:"RB_HALL010"}],this.rubyDeprecated=[{pattern:/\brequire\s+['"]thread['"]/,suggestion:'require "thread" is deprecated — Thread is now built-in without require',since:"Ruby 2.0",name:'require "thread"',id:"RB_DEPR001"},{pattern:/\bObject#type\b|\.type\s*==/,suggestion:".type is deprecated — use .class or .is_a?",since:"Ruby 1.8",name:"Object#type",id:"RB_DEPR002"},{pattern:/\bERB::Util\.html_escape\b/,suggestion:"ERB::Util.html_escape deprecated — use CGI.escapeHTML or h() in views",since:"Ruby 2.6",name:"ERB::Util.html_escape",id:"RB_DEPR003"},{pattern:/\bFile\.exists\?\s*\(/,suggestion:"File.exists? deprecated — use File.exist? (no s)",since:"Ruby 2.2",name:"File.exists?",id:"RB_DEPR004"},{pattern:/\bDir\.exists\?\s*\(/,suggestion:"Dir.exists? deprecated — use Dir.exist? (no s)",since:"Ruby 2.2",name:"Dir.exists?",id:"RB_DEPR005"},{pattern:/\bObject#returning\b|\s+returning\s+/,suggestion:"Object#returning removed from Rails core — use tap { |obj| }",since:"Rails 3.0",name:"Object#returning",id:"RB_DEPR006"}],this.rubySmells=[{pattern:/\bputs\s+(?!STDOUT)/,id:"RB_SMELL001",name:"Debug puts",message:"puts is for debug output — use Rails logger or a logging library"},{pattern:/\bp\s+\w/,id:"RB_SMELL002",name:"Debug p()",message:"p() is for debug output — remove before production"},{pattern:/\beval\s*\(/,id:"RB_SMELL003",name:"eval() Usage",message:"eval() is dangerous — code injection risk"},{pattern:/\bsystem\s*\(/,id:"RB_SMELL004",name:"system() Shell Call",message:"system() call — command injection risk if input unsanitized"},{pattern:/`[^`]+`/,id:"RB_SMELL005",name:"Backtick Shell Exec",message:"Backtick shell execution — command injection risk"},{pattern:/\bexec\s*\(/,id:"RB_SMELL006",name:"exec() call",message:"exec() replaces the process — ensure this is intentional"},{pattern:/\brescue\s*$|\brescue\s+Exception\b/,id:"RB_SMELL007",name:"Bare rescue",message:"Bare rescue catches all exceptions including fatal ones — be specific"},{pattern:/["'].*#\{.*sql.*\}.*["']/i,id:"RB_SMELL008",name:"SQL String Interpolation",message:"SQL built with string interpolation — use parameterized queries"},{pattern:/\/\/\s*TODO:?\s*(implement|add|fix|complete|finish)/i,id:"RB_SMELL009",name:"Placeholder TODO",message:"AI-generated placeholder — likely unfinished"},{pattern:/raise\s+NotImplementedError/,id:"RB_SMELL010",name:"Not Implemented",message:"Stub implementation — will raise at runtime"}],this.jsExtensions=new Set([".js",".ts",".jsx",".tsx",".mjs",".cjs"]),this.pyExtensions=new Set([".py",".pyw"]),this.goExtensions=new Set([".go"]),this.rustExtensions=new Set([".rs"]),this.javaExtensions=new Set([".java",".kt"]),this.csharpExtensions=new Set([".cs"]),this.phpExtensions=new Set([".php"]),this.rubyExtensions=new Set([".rb"]),this.aiCodeSmells=[{pattern:/\/\/\s*TODO:?\s*(implement|add|fix|complete|finish)\s*(this|here|later)/i,id:"AI_SMELL001",name:"Placeholder TODO",message:"AI-generated placeholder — likely unfinished implementation"},{pattern:/throw new Error\(['"]Not implemented['"]\)/,id:"AI_SMELL002",name:"Not Implemented",message:"Stub implementation — function body was not generated"},{pattern:/\/\/\s*\.\.\.\s*(rest|remaining|more|other|additional)/i,id:"AI_SMELL003",name:"Truncated Code",message:"AI output was truncated — code is incomplete"},{pattern:/\/\/\s*(your|replace|insert|put)\s+(code|logic|implementation|api[_\s]?key)/i,id:"AI_SMELL004",name:"Template Placeholder",message:"Template placeholder left in code — needs real implementation"},{pattern:/['"]your-api-key-here['"]|['"]sk-[.]{3,}['"]|['"]xxx+['"]/i,id:"AI_SMELL005",name:"Dummy Credential",message:"Placeholder credential — will fail at runtime"},{pattern:/example\.com|test@test\.com|john@doe\.com|foo@bar\.com/i,id:"AI_SMELL006",name:"Example Domain",message:"Example domain/email in production code"},{pattern:/localhost:\d{4}(?!.*(?:dev|test|local|development))/i,id:"AI_SMELL007",name:"Hardcoded Localhost",message:"Hardcoded localhost URL — will fail in production"}],this.deprecatedAPIs=[{pattern:/new Buffer\s*\(/,suggestion:"Use Buffer.from(), Buffer.alloc(), or Buffer.allocUnsafe()",since:"Node 6",name:"new Buffer()",id:"DEPR_API001"},{pattern:/require\s*\(\s*['"]sys['"]\s*\)/,suggestion:'Use require("util") — sys was removed in Node 1.0',since:"Node 1.0",name:'require("sys")',id:"DEPR_API002"},{pattern:/fs\.exists\s*\((?!Sync)/,suggestion:"Use fs.access() or fs.stat() — fs.exists() is deprecated",since:"Node 1.0",name:"fs.exists()",id:"DEPR_API003"},{pattern:/domain\.create\s*\(/,suggestion:"Use async_hooks or try/catch — domain module is deprecated",since:"Node 4",name:"domain.create()",id:"DEPR_API004",fixable:!1},{pattern:/require\s*\(\s*['"]punycode['"]\s*\)/,suggestion:"Use userland punycode package — built-in is deprecated",since:"Node 7",name:'require("punycode")',id:"DEPR_API005",fixable:!1},{pattern:/url\.parse\s*\(/,suggestion:"Use new URL() — url.parse() is legacy",since:"Node 11",name:"url.parse()",id:"DEPR_API006"},{pattern:/querystring\.(parse|stringify)\s*\(/,suggestion:"Use URLSearchParams — querystring is legacy",since:"Node 14",name:"querystring",id:"DEPR_API007",fixable:!1},{pattern:/util\.isArray\s*\(/,suggestion:"Use Array.isArray() — util type checks are deprecated",since:"Node 4",name:"util.isArray()",id:"DEPR_API008"},{pattern:/util\.isFunction\s*\(/,suggestion:'Use typeof fn === "function"',since:"Node 4",name:"util.isFunction()",id:"DEPR_API009"},{pattern:/util\.pump\s*\(/,suggestion:"Use stream.pipeline() — util.pump() was removed",since:"Node 1.0",name:"util.pump()",id:"DEPR_API010",fixable:!1}]}async scan(e){const t=Date.now(),s={phantomImports:[],phantomAPIs:[],aiSmells:[],deprecatedAPIs:[],unresolvedDeps:[],stats:{filesScanned:0,totalIssues:0,scanTime:0}},n=this._loadDeclaredDeps(),i=this._loadIgnoreRules();for(const t of e)try{const e=path.extname(t).toLowerCase(),a=this.jsExtensions.has(e),o=this.pyExtensions.has(e),r=this.goExtensions.has(e),l=this.rustExtensions.has(e),c=this.javaExtensions.has(e),d=this.csharpExtensions.has(e),p=this.phpExtensions.has(e),m=this.rubyExtensions.has(e);if(!(a||o||r||l||c||d||p||m))continue;const u=path.relative(this.config.rootPath,t);if(i.some(e=>u.includes(e)||t.includes(e)))continue;const g=fs.readFileSync(t,"utf-8").replace(/\r\n/g,"\n"),h=g.split("\n"),f=new Set;for(let e=0;e<h.length;e++)h[e].includes("thuban-ignore")&&(f.add(e+1),f.add(e+2));const _=this._isPatternDefinitionFile(g);s.stats.filesScanned++,a?(this._checkPhantomImports(u,t,g,h,n,s,f),_||this._checkPhantomAPIs(u,g,h,s,f),this._checkAISmells(u,g,h,s,f),_||this._checkDeprecatedAPIs(u,g,h,s,f),_||this._checkNamedExports(u,t,g,s,f)):o?(this._checkLanguagePatterns(u,g,h,s,f,this.pythonPhantomAPIs,"phantomAPIs"),this._checkLanguagePatterns(u,g,h,s,f,this.pythonDeprecated,"deprecatedAPIs"),this._checkLanguageSmells(u,g,h,s,f,this.pythonSmells)):p?(this._checkLanguagePatterns(u,g,h,s,f,this.phpPhantomAPIs,"phantomAPIs"),this._checkLanguagePatterns(u,g,h,s,f,this.phpDeprecated,"deprecatedAPIs"),this._checkLanguageSmells(u,g,h,s,f,this.phpSmells)):m?(this._checkLanguagePatterns(u,g,h,s,f,this.rubyPhantomAPIs,"phantomAPIs"),this._checkLanguagePatterns(u,g,h,s,f,this.rubyDeprecated,"deprecatedAPIs"),this._checkLanguageSmells(u,g,h,s,f,this.rubySmells)):r?(this._checkLanguagePatterns(u,g,h,s,f,this.goDeprecated,"deprecatedAPIs"),this._checkLanguageSmells(u,g,h,s,f,this.goSmells)):l?(this._checkLanguagePatterns(u,g,h,s,f,this.rustPhantomAPIs,"phantomAPIs"),this._checkLanguagePatterns(u,g,h,s,f,this.rustDeprecated,"deprecatedAPIs"),this._checkLanguageSmells(u,g,h,s,f,this.rustSmells)):c?".kt"===e?(this._checkLanguagePatterns(u,g,h,s,f,this.kotlinPhantomAPIs,"phantomAPIs"),this._checkLanguagePatterns(u,g,h,s,f,this.kotlinDeprecated,"deprecatedAPIs"),this._checkLanguageSmells(u,g,h,s,f,this.kotlinSmells)):this._checkLanguageSmells(u,g,h,s,f,this.javaSmells):d&&this._checkLanguageSmells(u,g,h,s,f,this.csharpSmells)}catch(e){}return s.stats.totalIssues=s.phantomImports.length+s.phantomAPIs.length+s.aiSmells.length+s.deprecatedAPIs.length+s.unresolvedDeps.length,s.stats.scanTime=Date.now()-t,s}_safeRegexTest(e,t,s=1e3){const n=Date.now();try{const i=e.test(t),a=Date.now()-n;return a>s?(console.warn(`[HALLUCINATION-DETECTOR] WARNING: Regex ${e.source.substring(0,50)}... took ${a}ms on input (${t.length} chars) — skipping pattern`),null):i}catch(e){return console.warn("[HALLUCINATION-DETECTOR] Regex error during scan"),null}}_safeRegexExec(e,t,s=1e3){const n=Date.now();try{const i=e.exec(t),a=Date.now()-n;return a>s?(console.warn(`[HALLUCINATION-DETECTOR] WARNING: Regex exec ${e.source.substring(0,50)}... took ${a}ms — skipping pattern`),null):i}catch(e){return console.warn("[HALLUCINATION-DETECTOR] Regex exec error during scan"),null}}_checkLanguagePatterns(e,t,s,n,i,a,o){for(let t=0;t<s.length;t++){if(i.has(t+1))continue;const r=s[t];for(const s of a){const i=this._safeRegexTest(s.pattern,r);if(null!==i&&i){const i={file:e,line:t+1,name:s.name,id:s.id};s.suggestion&&(i.suggestion=s.suggestion),s.since&&(i.since=s.since,i.fix=s.suggestion),"deprecatedAPIs"===o?n.deprecatedAPIs.push(i):n.phantomAPIs.push(i)}}}}_checkLanguageSmells(e,t,s,n,i,a){for(let t=0;t<s.length;t++){if(i.has(t+1))continue;const o=s[t];for(const s of a){const i=this._safeRegexTest(s.pattern,o);null!==i&&i&&n.aiSmells.push({file:e,line:t+1,id:s.id,name:s.name,message:s.message,type:"ai_smell",severity:"medium"})}}}formatReport(e){const t="",s="",n="",i="",a="",o="",r="",l="";let c="";if(c+=`\n${l} ╔══════════════════════════════════════════════╗${t}\n`,c+=`${l} ║${s} THUBAN HALLUCINATION REPORT ${t}${l}║${t}\n`,c+=`${l} ╚══════════════════════════════════════════════╝${t}\n\n`,0===e.stats.totalIssues)return c+=` ${i}${s}No hallucinations detected.${t} ${r}Clean codebase.${t}\n\n`,c;if(e.phantomImports.length>0){c+=` ${n}${s}Phantom Imports (${e.phantomImports.length})${t}\n`,c+=` ${r}Packages that don't exist in package.json or node_modules${t}\n\n`;for(const s of e.phantomImports.slice(0,10))c+=` ${n}✗${t} ${o}${s.file}${t}:${s.line}\n`,c+=` ${a}${s.module}${t} ${r}— ${s.reason}${t}\n`;e.phantomImports.length>10&&(c+=` ${r}... and ${e.phantomImports.length-10} more${t}\n`),c+="\n"}if(e.phantomAPIs.length>0){c+=` ${n}${s}Phantom APIs (${e.phantomAPIs.length})${t}\n`,c+=` ${r}Methods/properties that don't exist on their objects${t}\n\n`;for(const s of e.phantomAPIs.slice(0,10))c+=` ${n}✗${t} ${s.id?`${r}[${s.id}]${t} `:""}${o}${s.file}${t}:${s.line}\n`,c+=` ${a}${s.name}${t} ${r}— ${s.suggestion}${t}\n`,c+=` ${r}Suppress: // thuban-ignore ${s.id||"HALL_API"}${t}\n`;e.phantomAPIs.length>10&&(c+=` ${r}... and ${e.phantomAPIs.length-10} more${t}\n`),c+="\n"}if(e.aiSmells.length>0){c+=` ${a}${s}AI Code Smells (${e.aiSmells.length})${t}\n`,c+=` ${r}Patterns typical of AI-generated code that needs review${t}\n\n`;for(const s of e.aiSmells.slice(0,10))c+=` ${a}!${t} ${o}${s.file}${t}:${s.line}\n`,c+=` ${r}${s.message}${t}\n`;e.aiSmells.length>10&&(c+=` ${r}... and ${e.aiSmells.length-10} more${t}\n`),c+="\n"}if(e.deprecatedAPIs.length>0){c+=` ${a}${s}Deprecated APIs (${e.deprecatedAPIs.length})${t}\n`,c+=` ${r}APIs that LLMs still suggest but are deprecated or removed${t}\n\n`;for(const s of e.deprecatedAPIs.slice(0,10))c+=` ${a}⚠${t} ${o}${s.file}${t}:${s.line}\n`,c+=` ${a}${s.name}${t} ${r}(deprecated since ${s.since})${t}\n`,c+=` ${i}→${t} ${r}${s.suggestion}${t}\n`;e.deprecatedAPIs.length>10&&(c+=` ${r}... and ${e.deprecatedAPIs.length-10} more${t}\n`),c+="\n"}return c+=` ${s}Summary:${t} ${o}${e.stats.filesScanned}${t} files scanned, `,c+=`${e.stats.totalIssues>0?n:i}${e.stats.totalIssues}${t} hallucination issues found `,c+=`${r}(${e.stats.scanTime}ms)${t}\n\n`,c}_loadDeclaredDeps(){const e=new Set;return this._packageJsonPaths=new Map,this._collectPackageJsonDeps(this.config.rootPath,e,0),e}_collectPackageJsonDeps(e,t,s){if(!(s>5))try{const n=path.join(e,"package.json");if(fs.existsSync(n)){const s=JSON.parse(fs.readFileSync(n,"utf-8")),i=new Set;for(const e of Object.keys(s.dependencies||{}))t.add(e),i.add(e);for(const e of Object.keys(s.devDependencies||{}))t.add(e),i.add(e);for(const e of Object.keys(s.peerDependencies||{}))t.add(e),i.add(e);this._packageJsonPaths.set(e,i)}const i=new Set(["node_modules",".git","dist","build","coverage",".next",".cache","vendor"]),a=fs.readdirSync(e,{withFileTypes:!0});for(const n of a)!n.isDirectory()||i.has(n.name)||n.name.startsWith(".")||this._collectPackageJsonDeps(path.join(e,n.name),t,s+1)}catch(e){}}_checkPhantomImports(e,t,s,n,i,a,o=new Set){const r=[/require\s*\(\s*['"]([^'"]+)['"]\s*\)/g,/import\s+.*?from\s+['"]([^'"]+)['"]/g,/import\s*\(\s*['"]([^'"]+)['"]\s*\)/g];for(const n of r){let r;for(;null!==(r=n.exec(s));){const n=r[1];if(n.startsWith(".")||path.isAbsolute(n))continue;if(/^[@~#$][/\\]/.test(n))continue;const l=n.split("/")[0];if(this.builtins.has(n)||this.builtins.has(l))continue;if(l.startsWith("node:")&&this.builtins.has(l.slice(5)))continue;const c=n.startsWith("@")?n.split("/").slice(0,2).join("/"):l;if(!this._isSelfReference(t,c)&&!i.has(c)){if(this.knownRealPackages.has(c))continue;if(!this._findInNodeModules(t,c)){const t=this._findLineNumber(s,r.index);if(o.has(t))continue;const i=this.phantomPackages.has(n);a.phantomImports.push({file:e,line:t,module:n,reason:i?"Known AI-hallucinated package — does not exist on npm":"Not in package.json and not in node_modules",severity:i?"critical":"high",fixable:!1})}}}}}_checkNamedExports(e,t,s,n,i=new Set){let a;try{a=exportVerifier.verifyFile(t,s)}catch(e){return}for(const t of a)i.has(t.line)||n.phantomImports.push({file:e,line:t.line,module:t.source,reason:t.message,severity:"critical",fixable:!1,source:"export-verifier"})}_checkPhantomAPIs(e,t,s,n,i=new Set){for(const a of this.phantomAPIs){let o;const r=new RegExp(a.pattern.source,a.pattern.flags+(a.pattern.flags.includes("g")?"":"g"));for(;null!==(o=this._safeRegexExec(r,t));){const r=this._findLineNumber(t,o.index);if(i.has(r))continue;const l=s[r-1]||"";this._isInsidePattern(l,o[0])||n.phantomAPIs.push({file:e,line:r,name:a.name,id:a.id,suggestion:a.suggestion,severity:"high",fixable:!0,fixAction:"replace_phantom_api"})}}this._checkDynamicBuiltinCalls(e,t,s,n,i)}_checkDynamicBuiltinCalls(e,t,s,n,i){const a=new Map,o=/(?:const|let|var)\s+(\w+)\s*=\s*require\s*\(\s*['"](?:node:)?(\w+)['"]\s*\)/g;let r;for(;null!==(r=o.exec(t));){const e=r[1],t=r[2];this.builtins.has(t)&&a.set(e,t)}const l=/import\s+(?:\*\s+as\s+)?(\w+)\s+from\s+['"](?:node:)?(\w+)['"]/g;let c;for(;null!==(c=l.exec(t));){const e=c[1],t=c[2];this.builtins.has(t)&&a.set(e,t)}if(0!==a.size){this._builtinMethodCache||(this._builtinMethodCache=new Map);for(const[o,r]of a){if(!this._builtinMethodCache.has(r))try{const e=require(r),t=new Set(Object.keys(e));"object"==typeof e&&null!==e&&Object.getOwnPropertyNames(e).forEach(e=>t.add(e)),this._builtinMethodCache.set(r,t)}catch{this._builtinMethodCache.set(r,null);continue}const a=this._builtinMethodCache.get(r);if(!a)continue;const l=new RegExp(`\\b${o}\\.(\\w+)\\s*\\(`,"g");let c;for(;null!==(c=l.exec(t));){const o=c[1],l=this._findLineNumber(t,c.index);if(i.has(l))continue;const d=s[l-1]||"";if(!this._isInsidePattern(d,c[0])&&!a.has(o)){if(n.phantomAPIs.some(t=>t.file===e&&t.line===l))continue;n.phantomAPIs.push({file:e,line:l,name:`${r}.${o}`,id:"HALL_DYN",suggestion:`'${o}' does not exist on the '${r}' module — this is a hallucinated API`,severity:"critical",fixable:!1})}}}}}_checkAISmells(e,t,s,n,i=new Set){for(const a of this.aiCodeSmells){let o;const r=new RegExp(a.pattern.source,a.pattern.flags+(a.pattern.flags.includes("g")?"":"g"));for(;null!==(o=this._safeRegexExec(r,t));){const r=this._findLineNumber(t,o.index);i.has(r)||n.aiSmells.push({file:e,line:r,id:a.id,name:a.name,message:a.message,severity:"warning",code:s[r-1]?.trim().substring(0,100)})}}}_checkDeprecatedAPIs(e,t,s,n,i=new Set){for(const a of this.deprecatedAPIs){let o;const r=new RegExp(a.pattern.source,a.pattern.flags+(a.pattern.flags.includes("g")?"":"g"));for(;null!==(o=this._safeRegexExec(r,t));){const r=this._findLineNumber(t,o.index);if(i.has(r))continue;const l=s[r-1]||"";this._isInsidePattern(l,o[0])||n.deprecatedAPIs.push({file:e,line:r,name:a.name,id:a.id,suggestion:a.suggestion,since:a.since,severity:"warning",fixable:!0,fixAction:"update_deprecated_api"})}}}_findLineNumber(e,t){let s=1;for(let n=0;n<t&&n<e.length;n++)"\n"===e[n]&&s++;return s}_isPatternDefinitionFile(e){const t=(e.match(/pattern:\s*\//g)||[]).length,s=(e.match(/phantom|hallucin/gi)||[]).length;return t>5&&s>2}_isInsidePattern(e,t){const s=e.trim();return!!(/pattern:\s*\//.test(s)||s.startsWith("//")||s.startsWith("*")||/(?:name|suggestion|message|description):\s*['"]/.test(s))}_loadIgnoreRules(){const e=[];try{const t=path.join(this.config.rootPath,".thubanrc.json"),s=JSON.parse(fs.readFileSync(t,"utf-8"));s.hallucination?.ignore&&e.push(...s.hallucination.ignore),s.ignore&&e.push(...s.ignore)}catch(e){}return e}_findInNodeModules(e,t){let s=path.dirname(e);const n=this.config.rootPath;for(;s.length>=n.length;){const e=path.join(s,"node_modules",t);try{if(fs.existsSync(e))return!0}catch(e){}const n=path.dirname(s);if(n===s)break;s=n}return!1}_isSelfReference(e,t){let s=path.dirname(e);const n=this.config.rootPath;for(;s.length>=n.length;){try{const e=path.join(s,"package.json");if(fs.existsSync(e)){const n=JSON.parse(fs.readFileSync(e,"utf-8"));if(n.name===t)return!0;if(n.workspaces){const e=Array.isArray(n.workspaces)?n.workspaces:n.workspaces.packages||[];for(const n of e){const e=n.replace(/\/?\*.*$/,""),i=path.join(s,e);try{if(fs.existsSync(i)){const e=fs.readdirSync(i,{withFileTypes:!0});for(const s of e)if(s.isDirectory()){const e=path.join(i,s.name,"package.json");try{if(fs.existsSync(e)&&JSON.parse(fs.readFileSync(e,"utf-8")).name===t)return!0}catch(e){}}}}catch(e){}}}break}}catch(e){}const e=path.dirname(s);if(e===s)break;s=e}return!1}}module.exports=HallucinationDetector;
@@ -1 +0,0 @@
1
- const fs=require("fs"),path=require("path"),EventEmitter=require("events");class HealthChecker extends EventEmitter{constructor(e={}){super(),this.config={rootPath:e.rootPath||process.cwd(),serverPath:e.serverPath||path.join(e.rootPath||process.cwd(),"server"),checkTimeout:e.checkTimeout||5e3,...e},this.systemChecks=[{id:"senate",name:"Senate",description:"Multi-model orchestration",check:()=>this._checkSenate()},{id:"citadel",name:"Citadel",description:"5-layer safety system",check:()=>this._checkCitadel()},{id:"forge",name:"Forge",description:"Build system",check:()=>this._checkForge()},{id:"ocee",name:"OCEE",description:"Orchestrated continuous execution",check:()=>this._checkOCEE()},{id:"handoff",name:"Handoff",description:"Human-AI collaboration",check:()=>this._checkHandoff()},{id:"shadow_realm",name:"Shadow Realm",description:"Validation sandbox",check:()=>this._checkShadowRealm()},{id:"knowledge",name:"Knowledge Manager",description:"Build tracking and learning",check:()=>this._checkKnowledge()},{id:"server",name:"Express Server",description:"API server health",check:()=>this._checkServer()}]}async checkAll(){console.log("[HEALTH-CHECKER] Running full health check...");const e=Date.now(),s={timestamp:(new Date).toISOString(),duration:0,overall:"healthy",systems:[],healthySystems:[],unhealthySystems:[],summary:{}};for(const e of this.systemChecks)try{const t=await Promise.race([e.check(),this._timeout(this.config.checkTimeout)]),i={id:e.id,name:e.name,description:e.description,status:t.healthy?"healthy":"unhealthy",healthy:t.healthy,details:t.details||{},issues:t.issues||[],lastChecked:(new Date).toISOString()};s.systems.push(i),i.healthy?s.healthySystems.push(e.id):s.unhealthySystems.push(e.id)}catch(t){s.systems.push({id:e.id,name:e.name,description:e.description,status:"error",healthy:!1,error:t.message,lastChecked:(new Date).toISOString()}),s.unhealthySystems.push(e.id)}return 0===s.unhealthySystems.length?s.overall="healthy":s.unhealthySystems.length<=2?s.overall="degraded":s.overall="unhealthy",s.duration=Date.now()-e,s.summary={total:this.systemChecks.length,healthy:s.healthySystems.length,unhealthy:s.unhealthySystems.length},console.log(`[HEALTH-CHECKER] Health check complete: ${s.overall} (${s.summary.healthy}/${s.summary.total} systems healthy)`),this.emit("checkComplete",s),s}async checkSystem(e){const s=this.systemChecks.find(s=>s.id===e);if(!s)return{error:`Unknown system: ${e}`};try{const e=await s.check();return{id:s.id,name:s.name,...e,lastChecked:(new Date).toISOString()}}catch(e){return{id:s.id,name:s.name,healthy:!1,error:e.message,lastChecked:(new Date).toISOString()}}}getAvailableChecks(){return this.systemChecks.map(e=>({id:e.id,name:e.name,description:e.description}))}async _checkSenate(){const e={healthy:!0,details:{},issues:[]};try{const s=[path.join(this.config.serverPath,"senate.js"),path.join(this.config.serverPath,"senate-v2.js"),path.join(this.config.serverPath,"data","model-registry.json"),path.join(this.config.serverPath,"data","senate-weights-v2.json")];let t=0;for(const e of s)fs.existsSync(e)&&t++;e.details.filesFound=t,e.details.totalFiles=s.length;const i=path.join(this.config.serverPath,"data","model-registry.json");if(fs.existsSync(i)){const s=JSON.parse(fs.readFileSync(i,"utf8"));e.details.providersConfigured=Object.keys(s.providers||{}).length,e.details.modelsRegistered=Object.values(s.providers||{}).reduce((e,s)=>e+(s.models?.length||0),0)}t<2&&(e.healthy=!1,e.issues.push("Core Senate files missing"))}catch(s){e.healthy=!1,e.issues.push(`Senate check failed: ${s.message}`)}return e}async _checkCitadel(){const e={healthy:!0,details:{},issues:[]};try{const s=path.join(this.config.rootPath,"citadel"),t=["enforcer.js","watchers.js","constitution-loader.js","file-guard.js"];let i=0;for(const e of t)fs.existsSync(path.join(s,e))&&i++;e.details.filesFound=i,e.details.totalFiles=t.length;const a=path.join(s,"audit");if(fs.existsSync(a)){const s=fs.readdirSync(a).filter(e=>e.endsWith(".json"));if(e.details.auditFilesCount=s.length,s.length>0){const t=s.sort().pop(),i=path.join(a,t),n=fs.statSync(i);e.details.lastAudit=n.mtime.toISOString();const o=(Date.now()-n.mtime.getTime())/36e5;o>24&&e.issues.push(`No audit activity in ${Math.round(o)} hours`)}}i<3&&(e.healthy=!1,e.issues.push("Core Citadel files missing"))}catch(s){e.healthy=!1,e.issues.push(`Citadel check failed: ${s.message}`)}return e}async _checkForge(){const e={healthy:!0,details:{},issues:[]};try{const s=path.join(this.config.rootPath,"forge"),t=["forge-core.js","task-decomposer.js","intent-matcher.js","diagnostician-v2.js","prescriber.js","forge-loop.js"];let i=0;for(const e of t)fs.existsSync(path.join(s,e))&&i++;e.details.filesFound=i,e.details.totalFiles=t.length,e.details.completeness=Math.round(i/t.length*100)+"%",i<4&&(e.healthy=!1,e.issues.push("Core Forge components missing"))}catch(s){e.healthy=!1,e.issues.push(`Forge check failed: ${s.message}`)}return e}async _checkOCEE(){const e={healthy:!0,details:{},issues:[]};try{const s=path.join(this.config.serverPath,"ocee"),t=["ocee-core.js","persistent-task-queue.js","checkpoint-manager.js","build-session-manager.js","build-graph-generator.js"];let i=0;for(const e of t)fs.existsSync(path.join(s,e))&&i++;e.details.filesFound=i,e.details.totalFiles=t.length;const a=path.join(s,"queue");if(fs.existsSync(a))try{const s=fs.readdirSync(a);e.details.pendingTasks=s.length}catch(s){e.details.pendingTasks="unknown"}i<3&&(e.healthy=!1,e.issues.push("Core OCEE components missing"))}catch(s){e.healthy=!1,e.issues.push(`OCEE check failed: ${s.message}`)}return e}async _checkHandoff(){const e={healthy:!0,details:{},issues:[]};try{const s=path.join(this.config.serverPath,"handoff"),t=["index.js","risk-scorer.js","gate-checker.js","mission-state.js","audit-logger.js","evidence-bundle.js","cost-tracker.js"];let i=0;for(const e of t)fs.existsSync(path.join(s,e))&&i++;e.details.filesFound=i,e.details.totalFiles=t.length,i<5&&(e.healthy=!1,e.issues.push("Core Handoff components missing"))}catch(s){e.healthy=!1,e.issues.push(`Handoff check failed: ${s.message}`)}return e}async _checkShadowRealm(){const e={healthy:!0,details:{},issues:[]};try{const s=path.join(this.config.rootPath,"build-engine","orion-core"),t=["shadow-realm-v2.js","foreman.js","healing-loop.js"];let i=0;for(const e of t)fs.existsSync(path.join(s,e))&&i++;e.details.filesFound=i,e.details.totalFiles=t.length;try{const t=require(path.join(s,"shadow-realm-v2.js")).validateInSandbox('console.log("test");',"test.js");e.details.validationWorking=!0===t.syntaxValid}catch(s){e.details.validationWorking=!1,e.issues.push(`Shadow Realm validation test failed: ${s.message}`)}i<2&&(e.healthy=!1,e.issues.push("Core Shadow Realm components missing"))}catch(s){e.healthy=!1,e.issues.push(`Shadow Realm check failed: ${s.message}`)}return e}async _checkKnowledge(){const e={healthy:!0,details:{},issues:[]};try{const s=path.join(this.config.rootPath,"orion-knowledge.json");if(fs.existsSync(s)){const t=JSON.parse(fs.readFileSync(s,"utf8"));if(e.details.buildsTracked=t.builds?.length||0,e.details.capabilitiesTracked=t.capabilities?.length||0,t.builds&&t.builds.length>0){const s=t.builds[t.builds.length-1];e.details.lastBuild=s.timestamp||s.date}}else e.healthy=!1,e.issues.push("orion-knowledge.json not found")}catch(s){e.healthy=!1,e.issues.push(`Knowledge check failed: ${s.message}`)}return e}async _checkServer(){const e={healthy:!0,details:{},issues:[]};try{const s=[path.join(this.config.serverPath,"package.json"),path.join(this.config.serverPath,"index.js")];let t=0;for(const e of s)fs.existsSync(e)&&t++;e.details.filesFound=t;const i=path.join(this.config.serverPath,"package.json");if(fs.existsSync(i)){const s=JSON.parse(fs.readFileSync(i,"utf8"));e.details.dependencies=Object.keys(s.dependencies||{}).length,e.details.nodeVersion=s.engines?.node||"not specified"}const a=path.join(this.config.serverPath,"node_modules");e.details.nodeModulesInstalled=fs.existsSync(a),e.details.nodeModulesInstalled||e.issues.push("node_modules not installed - run npm install")}catch(s){e.healthy=!1,e.issues.push(`Server check failed: ${s.message}`)}return e}_timeout(e){return new Promise((s,t)=>setTimeout(()=>t(new Error("Health check timeout")),e))}}module.exports=HealthChecker;