gina 0.7.2-alpha.1 → 0.7.2

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 (628) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/README.md +39 -44
  3. package/ROADMAP.md +3 -0
  4. package/framework/v0.7.2/VERSION +1 -0
  5. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/js/gina.js +351 -24
  6. package/framework/v0.7.2/core/asset/plugin/dist/vendor/gina/js/gina.min.js +726 -0
  7. package/framework/v0.7.2/core/asset/plugin/dist/vendor/gina/js/gina.min.js.br +0 -0
  8. package/framework/v0.7.2/core/asset/plugin/dist/vendor/gina/js/gina.min.js.gz +0 -0
  9. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/sqlite/lib/session-store.js +24 -6
  10. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/controller.js +90 -9
  11. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/controller.render-nunjucks.js +12 -5
  12. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/controller.render-xml.js +10 -2
  13. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/gna.js +15 -1
  14. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/validator/src/main.js +301 -12
  15. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/server.isaac.js +95 -13
  16. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/server.js +232 -7
  17. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/index.js +2 -1
  18. package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/conf/templates.json +1 -0
  19. package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/inc/name.js +1 -1
  20. package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/inc/name.js +1 -1
  21. package/framework/v0.7.2/lib/error-ref/package.json +7 -0
  22. package/framework/v0.7.2/lib/error-ref/src/main.js +70 -0
  23. package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/index.js +12 -0
  24. package/framework/v0.7.2/lib/lane/package.json +7 -0
  25. package/framework/v0.7.2/lib/lane/src/main.js +1440 -0
  26. package/framework/v0.7.2/lib/sri/src/main.js +518 -0
  27. package/framework/{v0.7.2-alpha.1 → v0.7.2}/package.json +1 -1
  28. package/gna.js +4 -4
  29. package/llms.txt +11 -9
  30. package/package.json +6 -6
  31. package/schema/routing.json +7 -1
  32. package/types/index.d.ts +28 -0
  33. package/framework/v0.7.2-alpha.1/VERSION +0 -1
  34. package/framework/v0.7.2-alpha.1/core/asset/plugin/dist/vendor/gina/js/gina.min.js +0 -720
  35. package/framework/v0.7.2-alpha.1/core/asset/plugin/dist/vendor/gina/js/gina.min.js.br +0 -0
  36. package/framework/v0.7.2-alpha.1/core/asset/plugin/dist/vendor/gina/js/gina.min.js.gz +0 -0
  37. package/framework/v0.7.2-alpha.1/lib/sri/src/main.js +0 -237
  38. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/AUTHORS +0 -0
  39. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/LICENSE +0 -0
  40. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/html/nolayout.html +0 -0
  41. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/html/static.html +0 -0
  42. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/img/android-chrome-192x192.png +0 -0
  43. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/img/android-chrome-512x512.png +0 -0
  44. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/img/apple-touch-icon.png +0 -0
  45. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/img/favicon-16x16.png +0 -0
  46. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/img/favicon-32x32.png +0 -0
  47. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/img/favicon.ico +0 -0
  48. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/README.md +0 -0
  49. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/beemaster/beemaster.css +0 -0
  50. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/beemaster/beemaster.js +0 -0
  51. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/beemaster/index.html +0 -0
  52. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/css/gina.min.css +0 -0
  53. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/css/gina.min.css.br +0 -0
  54. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/css/gina.min.css.gz +0 -0
  55. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/html/statusbar.html +0 -0
  56. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/html/statusbar.html.br +0 -0
  57. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/html/statusbar.html.gz +0 -0
  58. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/inspector/have_heart_one-webfont.woff2 +0 -0
  59. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/inspector/index.html +0 -0
  60. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/inspector/inspector.css +0 -0
  61. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/inspector/inspector.js +0 -0
  62. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/inspector/logo.svg +0 -0
  63. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js +0 -0
  64. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js.br +0 -0
  65. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js.gz +0 -0
  66. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/config.js +0 -0
  67. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/config.requirements-anchor.js +0 -0
  68. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/ai/index.js +0 -0
  69. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/ai/lib/connector.js +0 -0
  70. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/couchbase/index.js +0 -0
  71. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/couchbase/lib/connector.js +0 -0
  72. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/couchbase/lib/connector.v3.js +0 -0
  73. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/couchbase/lib/connector.v4.js +0 -0
  74. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/couchbase/lib/n1ql.js +0 -0
  75. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/couchbase/lib/session-store.js +0 -0
  76. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/couchbase/lib/session-store.v3.js +0 -0
  77. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/couchbase/lib/session-store.v4.js +0 -0
  78. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/couchbase/lib/storage-store.js +0 -0
  79. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/duckdb/index.js +0 -0
  80. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/duckdb/lib/connector.js +0 -0
  81. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/mongodb/index.js +0 -0
  82. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/mongodb/lib/connector.js +0 -0
  83. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/mongodb/lib/job-store.js +0 -0
  84. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/mongodb/lib/pipeline-loader.js +0 -0
  85. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/mongodb/lib/session-store.js +0 -0
  86. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/mysql/index.js +0 -0
  87. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/mysql/lib/connector.js +0 -0
  88. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/param-redact.js +0 -0
  89. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/postgresql/index.js +0 -0
  90. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/postgresql/lib/connector.js +0 -0
  91. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/redis/index.js +0 -0
  92. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/redis/lib/connector.js +0 -0
  93. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/redis/lib/job-store.js +0 -0
  94. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/redis/lib/kv-store.js +0 -0
  95. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/redis/lib/render-cache-store.js +0 -0
  96. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/redis/lib/session-store.js +0 -0
  97. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/scylladb/index.js +0 -0
  98. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/scylladb/lib/connector.js +0 -0
  99. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/scylladb/lib/session-store.js +0 -0
  100. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/settle-once.js +0 -0
  101. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/sql-parser.js +0 -0
  102. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/sqlite/index.js +0 -0
  103. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/sqlite/lib/connector.js +0 -0
  104. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/sqlite/lib/job-store.js +0 -0
  105. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/connectors/sqlite/lib/kv-store.js +0 -0
  106. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/content.encoding +0 -0
  107. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/controller.framework.js +0 -0
  108. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/controller.render-json.js +0 -0
  109. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/controller.render-nunjucks-async.js +0 -0
  110. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/controller.render-stream.js +0 -0
  111. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/controller.render-swig-async.js +0 -0
  112. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/controller.render-swig.js +0 -0
  113. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/controller.render-v1.js +0 -0
  114. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/index.js +0 -0
  115. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/inline-script.js +0 -0
  116. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/inspector-window-emit.js +0 -0
  117. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/controller/release-banner.js +0 -0
  118. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/dev/index.js +0 -0
  119. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/dev/lib/class.js +0 -0
  120. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/dev/lib/factory.js +0 -0
  121. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/dev/lib/tools.js +0 -0
  122. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/locales/README.md +0 -0
  123. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/locales/currency.json +0 -0
  124. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/locales/dist/language/en.json +0 -0
  125. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/locales/dist/language/fr.json +0 -0
  126. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/locales/dist/region/en.json +0 -0
  127. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/locales/dist/region/fr.json +0 -0
  128. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/locales/index.js +0 -0
  129. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/mime.types +0 -0
  130. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/model/entity.js +0 -0
  131. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/model/index.js +0 -0
  132. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/model/template/entityFactory.js +0 -0
  133. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/model/template/index.js +0 -0
  134. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/README.md +0 -0
  135. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/index.js +0 -0
  136. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/csrf/README.md +0 -0
  137. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/csrf/package.json +0 -0
  138. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/csrf/src/main.js +0 -0
  139. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/README.md +0 -0
  140. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/coep/README.md +0 -0
  141. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/coep/package.json +0 -0
  142. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/coep/src/main.js +0 -0
  143. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/coop/README.md +0 -0
  144. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/coop/package.json +0 -0
  145. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/coop/src/main.js +0 -0
  146. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/corp/README.md +0 -0
  147. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/corp/package.json +0 -0
  148. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/corp/src/main.js +0 -0
  149. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/csp/README.md +0 -0
  150. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/csp/package.json +0 -0
  151. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/csp/src/main.js +0 -0
  152. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/hide-powered-by/README.md +0 -0
  153. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/hide-powered-by/package.json +0 -0
  154. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/hide-powered-by/src/main.js +0 -0
  155. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/hsts/README.md +0 -0
  156. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/hsts/package.json +0 -0
  157. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/hsts/src/main.js +0 -0
  158. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/origin-agent-cluster/README.md +0 -0
  159. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/origin-agent-cluster/package.json +0 -0
  160. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/origin-agent-cluster/src/main.js +0 -0
  161. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/package.json +0 -0
  162. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/referrer-policy/README.md +0 -0
  163. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/referrer-policy/package.json +0 -0
  164. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/referrer-policy/src/main.js +0 -0
  165. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/src/main.js +0 -0
  166. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-content-type-options/README.md +0 -0
  167. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-content-type-options/package.json +0 -0
  168. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-content-type-options/src/main.js +0 -0
  169. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-dns-prefetch-control/README.md +0 -0
  170. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-dns-prefetch-control/package.json +0 -0
  171. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-dns-prefetch-control/src/main.js +0 -0
  172. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-download-options/README.md +0 -0
  173. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-download-options/package.json +0 -0
  174. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-download-options/src/main.js +0 -0
  175. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-frame-options/README.md +0 -0
  176. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-frame-options/package.json +0 -0
  177. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-frame-options/src/main.js +0 -0
  178. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-permitted-cross-domain-policies/README.md +0 -0
  179. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-permitted-cross-domain-policies/package.json +0 -0
  180. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-permitted-cross-domain-policies/src/main.js +0 -0
  181. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-xss-protection/README.md +0 -0
  182. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-xss-protection/package.json +0 -0
  183. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/security-headers/x-xss-protection/src/main.js +0 -0
  184. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/session/README.md +0 -0
  185. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/session/package.json +0 -0
  186. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/session/src/main.js +0 -0
  187. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/storage/README.md +0 -0
  188. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/storage/build.json +0 -0
  189. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/storage/package.json +0 -0
  190. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/storage/src/main.js +0 -0
  191. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/validator/README.md +0 -0
  192. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/validator/build.json +0 -0
  193. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/validator/package.json +0 -0
  194. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/plugins/lib/validator/src/form-validator.js +0 -0
  195. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/router.js +0 -0
  196. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/server.express.js +0 -0
  197. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/server.isaac.rapid-reset.js +0 -0
  198. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/server.route-candidates.js +0 -0
  199. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/status.codes +0 -0
  200. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/_gitignore +0 -0
  201. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/config/app.json +0 -0
  202. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/config/connectors.json +0 -0
  203. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/config/routing.json +0 -0
  204. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/config/settings.json +0 -0
  205. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/config/settings.server.json +0 -0
  206. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/config/templates.json +0 -0
  207. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/config/watchers.json +0 -0
  208. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/controllers/controller.content.js +0 -0
  209. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/controllers/controller.js +0 -0
  210. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/controllers/setup.js +0 -0
  211. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle/locales/en.json +0 -0
  212. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_namespace/controllers/controller.js +0 -0
  213. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_public/css/default.css +0 -0
  214. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_public/css/home.css +0 -0
  215. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_public/css/vendor/readme.md +0 -0
  216. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_public/favicon.ico +0 -0
  217. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_public/js/components/x-checklist.js +0 -0
  218. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_public/js/vendor/readme.md +0 -0
  219. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_public/manifest.webmanifest +0 -0
  220. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_public/readme.md +0 -0
  221. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_public/sw.js +0 -0
  222. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_templates/handlers/main.js +0 -0
  223. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_templates/html/content/homepage.html +0 -0
  224. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_templates/html/includes/error-msg-noscript.html +0 -0
  225. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_templates/html/includes/error-msg-outdated-browser.html +0 -0
  226. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_templates/html/includes/x-checklist.html +0 -0
  227. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/boilerplate/bundle_templates/html/layouts/main.html +0 -0
  228. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/command/gina.bat.tpl +0 -0
  229. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/command/gina.tpl +0 -0
  230. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/conf/env.json +0 -0
  231. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/conf/manifest.json +0 -0
  232. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/conf/package.json +0 -0
  233. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/conf/settings.json +0 -0
  234. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/conf/statics.json +0 -0
  235. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/error/client/json/401.json +0 -0
  236. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/error/client/json/403.json +0 -0
  237. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/error/client/json/404.json +0 -0
  238. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/error/server/html/50x.html +0 -0
  239. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/error/server/json/500.json +0 -0
  240. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/error/server/json/503.json +0 -0
  241. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/core/template/extensions/logger/config.json +0 -0
  242. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/console.js +0 -0
  243. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/context.js +0 -0
  244. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/data/LICENSE +0 -0
  245. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/data/README.md +0 -0
  246. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/data/package.json +0 -0
  247. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/data/src/main.js +0 -0
  248. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/dateFormat.js +0 -0
  249. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/index.js +0 -0
  250. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/json/LICENSE +0 -0
  251. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/json/README.md +0 -0
  252. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/json/package.json +0 -0
  253. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/json/src/main.js +0 -0
  254. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/path.js +0 -0
  255. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/plugins/README.md +0 -0
  256. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/plugins/package.json +0 -0
  257. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/plugins/src/api-error.js +0 -0
  258. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/plugins/src/main.js +0 -0
  259. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/prototypes.js +0 -0
  260. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/task.js +0 -0
  261. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/helpers/text.js +0 -0
  262. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/admin/package.json +0 -0
  263. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/admin/src/main.js +0 -0
  264. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/archiver/README.md +0 -0
  265. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/archiver/build.json +0 -0
  266. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/archiver/package.json +0 -0
  267. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/archiver/src/dep/jszip.min.js +0 -0
  268. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/archiver/src/main.js +0 -0
  269. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/async/package.json +0 -0
  270. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/async/src/main.js +0 -0
  271. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/audit/package.json +0 -0
  272. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/audit/src/main.js +0 -0
  273. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/audit-store.js +0 -0
  274. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/authn/package.json +0 -0
  275. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/authn/src/lockout.js +0 -0
  276. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/authn/src/main.js +0 -0
  277. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/authn/src/totp.js +0 -0
  278. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/authz-gate/package.json +0 -0
  279. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/authz-gate/src/main.js +0 -0
  280. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cache/README.md +0 -0
  281. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cache/build.json +0 -0
  282. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cache/package.json +0 -0
  283. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cache/src/main.js +0 -0
  284. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/aliases.json +0 -0
  285. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/audit/arguments.json +0 -0
  286. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/audit/help.txt +0 -0
  287. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/audit/verify.js +0 -0
  288. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/add.js +0 -0
  289. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/arguments.json +0 -0
  290. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/build.js +0 -0
  291. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/copy.js +0 -0
  292. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/cp.js +0 -0
  293. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/help.js +0 -0
  294. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/help.txt +0 -0
  295. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/inc/boot-lines.js +0 -0
  296. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/inc/name-rewrite.js +0 -0
  297. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/list.js +0 -0
  298. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/man.js +0 -0
  299. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/mcp-start.js +0 -0
  300. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/mcp.js +0 -0
  301. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/oas.js +0 -0
  302. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/openapi.js +0 -0
  303. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/remove.js +0 -0
  304. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/rename.js +0 -0
  305. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/restart.js +0 -0
  306. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/rm.js +0 -0
  307. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/start.js +0 -0
  308. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/status.js +0 -0
  309. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/stop.js +0 -0
  310. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/bundle/types.js +0 -0
  311. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/cache/arguments.json +0 -0
  312. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/cache/clear.js +0 -0
  313. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/cache/help.txt +0 -0
  314. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/cache/stats.js +0 -0
  315. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/add.js +0 -0
  316. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/arguments.json +0 -0
  317. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/help.js +0 -0
  318. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/help.txt +0 -0
  319. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/infer.js +0 -0
  320. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/list.js +0 -0
  321. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/migrate.js +0 -0
  322. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/models.js +0 -0
  323. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/remove.js +0 -0
  324. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/rm.js +0 -0
  325. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/connector/test.js +0 -0
  326. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/container/arguments.json +0 -0
  327. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/container/help.js +0 -0
  328. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/container/help.txt +0 -0
  329. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/container/man.js +0 -0
  330. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/container/ps.js +0 -0
  331. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/container/stop.js +0 -0
  332. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/add.js +0 -0
  333. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/arguments.json +0 -0
  334. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/help.txt +0 -0
  335. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/inc/args.js +0 -0
  336. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/inc/namespace.js +0 -0
  337. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/inc/reference-rewrite.js +0 -0
  338. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/inc/reference-scan.js +0 -0
  339. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/inc/scaffold.js +0 -0
  340. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/remove.js +0 -0
  341. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/rename.js +0 -0
  342. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/controller/rm.js +0 -0
  343. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/add.js +0 -0
  344. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/get.js +0 -0
  345. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/help.js +0 -0
  346. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/help.txt +0 -0
  347. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/inc/name.js +0 -0
  348. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/link-dev.js +0 -0
  349. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/list.js +0 -0
  350. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/remove.js +0 -0
  351. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/rm.js +0 -0
  352. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/set.js +0 -0
  353. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/unset.js +0 -0
  354. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/env/use.js +0 -0
  355. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/add.js +0 -0
  356. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/arguments.json +0 -0
  357. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/build.js +0 -0
  358. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/dot.js +0 -0
  359. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/get.js +0 -0
  360. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/help.js +0 -0
  361. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/help.txt +0 -0
  362. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/inc/ps-titles.js +0 -0
  363. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/init.js +0 -0
  364. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/link-node-modules.js +0 -0
  365. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/link.js +0 -0
  366. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/list.js +0 -0
  367. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/man.js +0 -0
  368. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/msg.json +0 -0
  369. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/open.js +0 -0
  370. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/remove.js +0 -0
  371. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/reset.js +0 -0
  372. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/restart.js +0 -0
  373. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/set.js +0 -0
  374. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/start.js +0 -0
  375. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/status.js +0 -0
  376. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/stop.js +0 -0
  377. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/tail.js +0 -0
  378. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/update.js +0 -0
  379. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/framework/version.js +0 -0
  380. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/gina-dev.1.md +0 -0
  381. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/gina-framework.1.md +0 -0
  382. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/gina.1.md +0 -0
  383. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/helper.js +0 -0
  384. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/i18n/add.js +0 -0
  385. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/i18n/arguments.json +0 -0
  386. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/i18n/export.js +0 -0
  387. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/i18n/help.js +0 -0
  388. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/i18n/help.txt +0 -0
  389. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/i18n/import.js +0 -0
  390. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/i18n/scan.js +0 -0
  391. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/image/_host.js +0 -0
  392. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/image/arguments.json +0 -0
  393. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/image/build.js +0 -0
  394. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/image/help.js +0 -0
  395. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/image/help.txt +0 -0
  396. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/image/list.js +0 -0
  397. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/image/man.js +0 -0
  398. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/image/rm.js +0 -0
  399. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/image/run.js +0 -0
  400. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/index.js +0 -0
  401. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/inspector/help.js +0 -0
  402. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/inspector/help.txt +0 -0
  403. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/inspector/open.js +0 -0
  404. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/man-render.js +0 -0
  405. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/minion/arguments.json +0 -0
  406. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/minion/help.js +0 -0
  407. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/minion/help.txt +0 -0
  408. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/minion/kill.js +0 -0
  409. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/minion/list.js +0 -0
  410. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/msg.json +0 -0
  411. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/port/help.js +0 -0
  412. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/port/help.txt +0 -0
  413. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/port/inc/scan.js +0 -0
  414. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/port/list.js +0 -0
  415. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/port/reset.js +0 -0
  416. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/port/set.js +0 -0
  417. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/add.js +0 -0
  418. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/arguments.json +0 -0
  419. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/backup.js +0 -0
  420. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/build.js +0 -0
  421. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/help.js +0 -0
  422. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/help.txt +0 -0
  423. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/import.js +0 -0
  424. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/list.js +0 -0
  425. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/man.js +0 -0
  426. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/move.js +0 -0
  427. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/remove.js +0 -0
  428. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/rename.js +0 -0
  429. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/restart.js +0 -0
  430. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/restore.js +0 -0
  431. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/rm.js +0 -0
  432. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/start.js +0 -0
  433. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/status.js +0 -0
  434. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/project/stop.js +0 -0
  435. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/protocol/arguments.json +0 -0
  436. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/protocol/help.js +0 -0
  437. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/protocol/help.txt +0 -0
  438. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/protocol/list.js +0 -0
  439. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/protocol/remove.js +0 -0
  440. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/protocol/set.js +0 -0
  441. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/scope/add.js +0 -0
  442. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/scope/help.js +0 -0
  443. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/scope/help.txt +0 -0
  444. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/scope/inc/name.js +0 -0
  445. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/scope/link-local.js +0 -0
  446. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/scope/link-production.js +0 -0
  447. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/scope/list.js +0 -0
  448. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/scope/remove.js +0 -0
  449. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/scope/rm.js +0 -0
  450. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/scope/use.js +0 -0
  451. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/secrets/arguments.json +0 -0
  452. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/secrets/check.js +0 -0
  453. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/secrets/help.js +0 -0
  454. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/secrets/help.txt +0 -0
  455. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/secrets/scan.js +0 -0
  456. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/service/help.js +0 -0
  457. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/service/help.txt +0 -0
  458. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/service/list.js +0 -0
  459. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/service/man.js +0 -0
  460. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/service/start.js +0 -0
  461. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/storage/arguments.json +0 -0
  462. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/storage/gc.js +0 -0
  463. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/storage/help.txt +0 -0
  464. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/storage/stats.js +0 -0
  465. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/storage/verify.js +0 -0
  466. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd/view/add.js +0 -0
  467. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd-status-format/package.json +0 -0
  468. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cmd-status-format/src/main.js +0 -0
  469. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/collection/README.md +0 -0
  470. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/collection/build.json +0 -0
  471. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/collection/package.json +0 -0
  472. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/collection/src/main.js +0 -0
  473. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/conf-view/package.json +0 -0
  474. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/conf-view/src/main.js +0 -0
  475. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/config.js +0 -0
  476. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/connector-config/package.json +0 -0
  477. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/connector-config/src/main.js +0 -0
  478. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/connector-error/package.json +0 -0
  479. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/connector-error/src/main.js +0 -0
  480. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/connector-registry/package.json +0 -0
  481. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/connector-registry/src/main.js +0 -0
  482. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cron/README.md +0 -0
  483. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cron/package.json +0 -0
  484. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/cron/src/main.js +0 -0
  485. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/domain/LICENSE +0 -0
  486. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/domain/README.md +0 -0
  487. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/domain/package.json +0 -0
  488. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/domain/src/main.js +0 -0
  489. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/dto/package.json +0 -0
  490. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/dto/src/main.js +0 -0
  491. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/dto-pipe/package.json +0 -0
  492. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/dto-pipe/src/main.js +0 -0
  493. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/dto-types/package.json +0 -0
  494. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/dto-types/src/main.js +0 -0
  495. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/duration/package.json +0 -0
  496. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/duration/src/main.js +0 -0
  497. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/generator/index.js +0 -0
  498. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/i18n/package.json +0 -0
  499. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/i18n/src/main.js +0 -0
  500. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/idempotency/package.json +0 -0
  501. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/idempotency/src/main.js +0 -0
  502. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/image-build/package.json +0 -0
  503. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/image-build/src/main.js +0 -0
  504. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/inherits/LICENSE +0 -0
  505. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/inherits/README.md +0 -0
  506. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/inherits/package.json +0 -0
  507. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/inherits/src/main.js +0 -0
  508. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/inspector-events/package.json +0 -0
  509. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/inspector-events/src/main.js +0 -0
  510. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/inspector-redact/package.json +0 -0
  511. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/inspector-redact/src/main.js +0 -0
  512. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/instrument/package.json +0 -0
  513. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/instrument/src/main.js +0 -0
  514. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/job/package.json +0 -0
  515. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/job/src/main.js +0 -0
  516. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/job-store.js +0 -0
  517. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/json-config-header/package.json +0 -0
  518. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/json-config-header/src/main.js +0 -0
  519. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/kv/package.json +0 -0
  520. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/kv/src/main.js +0 -0
  521. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/kv-store.js +0 -0
  522. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/loading-state/package.json +0 -0
  523. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/loading-state/src/main.js +0 -0
  524. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/logger/README.md +0 -0
  525. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/logger/package.json +0 -0
  526. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/logger/src/containers/default/index.js +0 -0
  527. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/logger/src/containers/file/index.js +0 -0
  528. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/logger/src/containers/mq/index.js +0 -0
  529. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/logger/src/containers/mq/listener.js +0 -0
  530. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/logger/src/containers/mq/speaker.js +0 -0
  531. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/logger/src/helper.js +0 -0
  532. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/logger/src/main.js +0 -0
  533. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/logger/src/redact.js +0 -0
  534. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/maintenance/package.json +0 -0
  535. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/maintenance/src/main.js +0 -0
  536. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/math/index.js +0 -0
  537. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/mcp-dispatch/package.json +0 -0
  538. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/mcp-dispatch/src/main.js +0 -0
  539. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/mcp-http/package.json +0 -0
  540. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/mcp-http/src/main.js +0 -0
  541. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/mcp-server/package.json +0 -0
  542. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/mcp-server/src/main.js +0 -0
  543. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/merge/README.md +0 -0
  544. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/merge/package.json +0 -0
  545. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/merge/src/main.js +0 -0
  546. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/message-validator/package.json +0 -0
  547. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/message-validator/src/main.js +0 -0
  548. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/metrics/package.json +0 -0
  549. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/metrics/src/main.js +0 -0
  550. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/model.js +0 -0
  551. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/money/package.json +0 -0
  552. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/money/src/main.js +0 -0
  553. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/multipart/package.json +0 -0
  554. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/multipart/src/main.js +0 -0
  555. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/net-locality/package.json +0 -0
  556. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/net-locality/src/main.js +0 -0
  557. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/nunjucks-filters/README.md +0 -0
  558. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/nunjucks-filters/package.json +0 -0
  559. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/nunjucks-filters/src/main.js +0 -0
  560. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/nunjucks-resolver/package.json +0 -0
  561. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/nunjucks-resolver/src/main.js +0 -0
  562. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/priority/package.json +0 -0
  563. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/priority/src/main.js +0 -0
  564. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/proc.js +0 -0
  565. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/push/package.json +0 -0
  566. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/push/src/main.js +0 -0
  567. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/rate-limit/package.json +0 -0
  568. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/rate-limit/src/main.js +0 -0
  569. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/release-watch/package.json +0 -0
  570. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/release-watch/src/main.js +0 -0
  571. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/render-cache/package.json +0 -0
  572. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/render-cache/src/main.js +0 -0
  573. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/render-cache-store.js +0 -0
  574. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/routing/README.md +0 -0
  575. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/routing/build.json +0 -0
  576. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/routing/package.json +0 -0
  577. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/routing/src/main.js +0 -0
  578. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/routing-introspect/package.json +0 -0
  579. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/routing-introspect/src/main.js +0 -0
  580. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/secrets/package.json +0 -0
  581. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/secrets/src/backends/env.js +0 -0
  582. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/secrets/src/backends/exec.js +0 -0
  583. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/secrets/src/backends/file.js +0 -0
  584. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/secrets/src/declaration.js +0 -0
  585. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/secrets/src/env-file.js +0 -0
  586. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/secrets/src/main.js +0 -0
  587. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/secrets/src/sources.js +0 -0
  588. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/security-headers-emitter/package.json +0 -0
  589. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/security-headers-emitter/src/main.js +0 -0
  590. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/session-lifetime/package.json +0 -0
  591. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/session-lifetime/src/main.js +0 -0
  592. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/session-store.js +0 -0
  593. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/shell.js +0 -0
  594. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/sqlite-driver.js +0 -0
  595. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/sri/package.json +0 -0
  596. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/state.js +0 -0
  597. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/storage/package.json +0 -0
  598. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/storage/src/local-cas.js +0 -0
  599. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/storage/src/local-stream.js +0 -0
  600. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/storage/src/local.js +0 -0
  601. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/storage/src/main.js +0 -0
  602. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/storage/src/meta-store.js +0 -0
  603. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/storage/src/s3.js +0 -0
  604. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/storage/src/util.js +0 -0
  605. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/storage-store.js +0 -0
  606. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/swig-filters/README.md +0 -0
  607. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/swig-filters/package.json +0 -0
  608. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/swig-filters/src/main.js +0 -0
  609. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/swig-resolver/package.json +0 -0
  610. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/swig-resolver/src/main.js +0 -0
  611. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/template-loaders/package.json +0 -0
  612. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/template-loaders/src/loaders/http.js +0 -0
  613. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/template-loaders/src/loaders/memory.js +0 -0
  614. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/template-loaders/src/main.js +0 -0
  615. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/url/README.md +0 -0
  616. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/url/index.js +0 -0
  617. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/url/routing.json +0 -0
  618. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/uuid/package.json +0 -0
  619. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/uuid/src/main.js +0 -0
  620. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/validator.js +0 -0
  621. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/watcher/package.json +0 -0
  622. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/watcher/src/main.js +0 -0
  623. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/ws-framing/package.json +0 -0
  624. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/ws-framing/src/main.js +0 -0
  625. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/ws-query/package.json +0 -0
  626. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/ws-query/src/main.js +0 -0
  627. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/ws-session/package.json +0 -0
  628. /package/framework/{v0.7.2-alpha.1 → v0.7.2}/lib/ws-session/src/main.js +0 -0
@@ -0,0 +1,1440 @@
1
+ /*
2
+ * This file is part of the gina package.
3
+ * Copyright (c) 2009-2026 Rhinostone <contact@gina.io>
4
+ *
5
+ * For the full copyright and license information, please view the LICENSE
6
+ * file that was distributed with this source code.
7
+ */
8
+ 'use strict';
9
+
10
+ /**
11
+ * @module gina/lib/lane
12
+ *
13
+ * #P49 — the fast lane: opt-in, controller-free dispatch for JSON routes.
14
+ *
15
+ * A route opts in from `routing.json` with `param.lane`, naming a module under the
16
+ * bundle's `lanes/` directory, and keeps `param.control` for the name of the export
17
+ * that answers it:
18
+ *
19
+ * "users-list": {
20
+ * "url" : "/users",
21
+ * "method": "GET",
22
+ * "param" : { "lane": "users", "control": "list" }
23
+ * }
24
+ *
25
+ * // <bundle>/lanes/users.js
26
+ * module.exports.list = function (ctx) {
27
+ * ctx.json({ users: [] });
28
+ * };
29
+ *
30
+ * Such a route is matched exactly like any other (statics, CORS, maintenance, the
31
+ * route match, `validator::` requirements, the HEAD alias and the render-cache read
32
+ * all run unchanged above it), then it skips the controller: no controller file is
33
+ * required, no `new Controller()`, no `setOptions()`, no per-request option clones.
34
+ * On the isaac engine the bundle's own middleware chain (session, CSRF, …) still runs
35
+ * and the lane is its terminal, so `req.session` and `csrfExempt` behave as on any
36
+ * route; on the express engine those layers ran before gina's request handler.
37
+ *
38
+ * This module owns four things:
39
+ *
40
+ * - **the boot registry** — `registerRoutes()` runs once per bundle from
41
+ * `core/server.js` `init()`, lints every `param.lane` route, requires its module
42
+ * and records `{ fn, module, … }` on `process.gina._lanes` under
43
+ * `<bundle>::<lane>#<control>`. Every author error refuses to boot, naming the
44
+ * route: a quietly-skipped gate or a route that silently falls back to a
45
+ * controller would be worse than a startup error (the `param.requireAuth` lint's
46
+ * reasoning). In this first slice a lane route cannot declare a gate
47
+ * (authorization, rate limit, idempotency, message validation, request DTO): the
48
+ * lane does not run them yet, so declaring one refuses the boot.
49
+ * - **the request context** — `LaneContext`, the single argument a handler
50
+ * receives. Prototype methods only, so building it is one allocation.
51
+ * - **the two writers** — `ctx.json()` mirrors `controller.render-json.js` (status
52
+ * from a `status` key, `param.responseDto` projection, one `JSON.stringify`, the
53
+ * idempotency record, the access line, HEAD, and the raw HTTP/2, #B562 shim and
54
+ * HTTP/1.x writes), and `ctx.error()` answers with the controller's JSON error
55
+ * envelope (`status`, `error`, `message`, `fields` / `errors`, a `stack` in local
56
+ * scope only, and the #ERRREF `ref`), with one pairing log line per error.
57
+ * - **dispatch** — `dispatch()` is called by `core/server.js` at the end of the
58
+ * isaac middleware chain, or directly on express. A synchronous throw or a
59
+ * rejected promise from the handler answers 500 through `ctx.error()`.
60
+ *
61
+ * In dev mode the handler modules hot-reload: `core/gna.js` watches the lane
62
+ * directories (`watchDirs()`) and sets `__hotReload.lane`; the next dispatch
63
+ * re-requires the registered modules and prunes this module's `children`.
64
+ *
65
+ * Server-side only; plain-required by the registry (`lib.lane`), never
66
+ * hot-reloaded itself: `core/server.js` captures it at load.
67
+ */
68
+
69
+ var nodePath = require('path');
70
+ var fs = require('fs');
71
+ var logger = require('../../logger');
72
+ var errorRef = require('../../error-ref');
73
+ var authzGate = require('../../authz-gate');
74
+ var confView = require('../../conf-view');
75
+ var dto = require('../../dto');
76
+ var idempotency = require('../../idempotency');
77
+ var JSONClone = require('./../../../../../utils/prototypes.json_clone');
78
+
79
+
80
+ /**
81
+ * One path segment of a `param.lane` value: it must start with a letter, a digit
82
+ * or `_` (so `.`, `..` and hidden names are out) and may then hold `.` and `-`.
83
+ * Segments are joined with `/`. The charset also keeps the value safe where
84
+ * `lib/routing`'s `getRoute()` compiles non-reserved `param` values into a
85
+ * `RegExp`, and away from a leading `:`, which routing reads as a URL binding.
86
+ *
87
+ * @constant
88
+ * @type {RegExp}
89
+ * @private
90
+ */
91
+ var LANE_SEGMENT = /^[A-Za-z0-9_][A-Za-z0-9_.\-]*$/;
92
+
93
+ /**
94
+ * Action names the framework reserves; `core/router.js` refuses them per request,
95
+ * the lane refuses them at boot.
96
+ *
97
+ * @constant
98
+ * @type {string[]}
99
+ * @private
100
+ */
101
+ var RESERVED_CONTROLS = ['onReady', 'setup'];
102
+
103
+ /**
104
+ * The stack-frame detector the controller and server error writers use (#B131,
105
+ * #B670): a string holding a `\n at ` line carries a stack.
106
+ *
107
+ * @constant
108
+ * @type {RegExp}
109
+ * @private
110
+ */
111
+ var STACK_FRAME = /\n\s+at\s/;
112
+
113
+ /**
114
+ * Error-body keys whose stack-bearing text is cut to its first line outside local
115
+ * scope, and appended to the pairing line when the logged detail lacks it.
116
+ *
117
+ * @constant
118
+ * @type {string[]}
119
+ * @private
120
+ */
121
+ var DETAIL_KEYS = ['title', 'message', 'error'];
122
+
123
+ var _isDev = null;
124
+ var _isLocal = null;
125
+
126
+ /**
127
+ * Dev mode (`NODE_ENV_IS_DEV`), read once on first use.
128
+ *
129
+ * @inner
130
+ * @private
131
+ * @returns {boolean}
132
+ */
133
+ function isDev() {
134
+ if ( _isDev === null ) {
135
+ _isDev = /^true$/i.test(process.env.NODE_ENV_IS_DEV || '');
136
+ }
137
+ return _isDev;
138
+ }
139
+
140
+ /**
141
+ * Local scope (`NODE_SCOPE_IS_LOCAL`), read once on first use — the stack egress
142
+ * gate of the error writer.
143
+ *
144
+ * @inner
145
+ * @private
146
+ * @returns {boolean}
147
+ */
148
+ function isLocalScope() {
149
+ if ( _isLocal === null ) {
150
+ _isLocal = /^true$/i.test(process.env.NODE_SCOPE_IS_LOCAL || '');
151
+ }
152
+ return _isLocal;
153
+ }
154
+
155
+ /**
156
+ * Own-property test that cannot be fooled by a key named `hasOwnProperty`.
157
+ *
158
+ * @inner
159
+ * @private
160
+ * @param {object} obj
161
+ * @param {string|number} key
162
+ * @returns {boolean}
163
+ */
164
+ function hasOwn(obj, key) {
165
+ return obj !== null && typeof(obj) != 'undefined' && Object.prototype.hasOwnProperty.call(obj, key);
166
+ }
167
+
168
+ /**
169
+ * Node's own rule for a status `writeHead()` accepts: an integer from 100 to 999
170
+ * (the controller's `_isValidHttpStatus`, #B466).
171
+ *
172
+ * @inner
173
+ * @private
174
+ * @param {*} v - candidate status
175
+ * @returns {boolean}
176
+ */
177
+ function isValidHttpStatus(v) {
178
+ var n = Number(v);
179
+ return Number.isInteger(n) && n >= 100 && n <= 999;
180
+ }
181
+
182
+ /**
183
+ * Short, log-safe rendering of an author-supplied value for a boot refusal.
184
+ *
185
+ * @inner
186
+ * @private
187
+ * @param {*} value
188
+ * @returns {string}
189
+ */
190
+ function describeValue(value) {
191
+ try {
192
+ return JSON.stringify(value);
193
+ } catch (err) {
194
+ return String(value);
195
+ }
196
+ }
197
+
198
+ /**
199
+ * The process-wide registry, created on first use.
200
+ *
201
+ * @inner
202
+ * @private
203
+ * @returns {object} `process.gina._lanes`, a prototype-less map
204
+ */
205
+ function registry() {
206
+ if ( !process.gina ) {
207
+ process.gina = {};
208
+ }
209
+ if ( !process.gina._lanes ) {
210
+ process.gina._lanes = Object.create(null);
211
+ }
212
+ return process.gina._lanes;
213
+ }
214
+
215
+ /**
216
+ * Whether a `param.lane` value is a well-formed module name under `lanes/`.
217
+ *
218
+ * @memberof module:gina/lib/lane
219
+ * @param {*} value - the declared `param.lane`
220
+ * @returns {boolean} `true` for `"users"`, `"admin/users"`, `"v2.users"`; `false` for
221
+ * anything else, including `""`, `"../x"`, `"./x"`, `"/x"`, `"a//b"` and non-strings
222
+ *
223
+ * @example
224
+ * lane.isLaneName('admin/users'); // true
225
+ * lane.isLaneName('../secrets'); // false
226
+ * lane.isLaneName(42); // false
227
+ */
228
+ function isLaneName(value) {
229
+ if ( typeof(value) != 'string' || value === '' ) {
230
+ return false;
231
+ }
232
+ var segments = value.split('/');
233
+ for (var i = 0; i < segments.length; ++i) {
234
+ if ( !LANE_SEGMENT.test(segments[i]) ) {
235
+ return false;
236
+ }
237
+ }
238
+ return true;
239
+ }
240
+
241
+ /**
242
+ * The gate keys a route declares, which a lane route cannot carry in this slice.
243
+ *
244
+ * `param.requireAuth: false` and `rateLimit: false` are explicit "no" values and are
245
+ * not gates.
246
+ *
247
+ * @inner
248
+ * @private
249
+ * @param {object} route - a `routing.json` rule
250
+ * @returns {string[]} the declared gate keys, in the gate order
251
+ */
252
+ function gateKeysOf(route) {
253
+ var p = route.param;
254
+ var keys = [];
255
+ if ( typeof(p.requireAuth) != 'undefined' && p.requireAuth !== false ) {
256
+ keys.push('param.requireAuth');
257
+ }
258
+ if ( typeof(p.roles) != 'undefined' ) {
259
+ keys.push('param.roles');
260
+ }
261
+ if ( typeof(p.policy) != 'undefined' ) {
262
+ keys.push('param.policy');
263
+ }
264
+ if ( typeof(route.rateLimit) != 'undefined' && route.rateLimit !== null && route.rateLimit !== false ) {
265
+ keys.push('rateLimit');
266
+ }
267
+ if ( typeof(route.idempotency) != 'undefined' && route.idempotency !== null && route.idempotency !== false ) {
268
+ keys.push('idempotency');
269
+ }
270
+ if ( typeof(p.messageValidator) != 'undefined' && p.messageValidator !== null && p.messageValidator !== '' ) {
271
+ keys.push('param.messageValidator');
272
+ }
273
+ if ( typeof(p.dto) != 'undefined' && p.dto !== null && p.dto !== '' ) {
274
+ keys.push('param.dto');
275
+ }
276
+ return keys;
277
+ }
278
+
279
+ /**
280
+ * Require a lane module and resolve the export a route names.
281
+ *
282
+ * @inner
283
+ * @private
284
+ * @param {string} file - absolute path of `<bundle>/lanes/<lane>.js`
285
+ * @param {string} rule - the route name, for the refusal
286
+ * @param {string} lane - the declared `param.lane`
287
+ * @param {string} control - the declared `param.control` (the export)
288
+ * @param {string} bundle - the bundle the route belongs to
289
+ * @returns {object} the registry entry
290
+ * @throws {Error} a `[ SERVER ] Route …` refusal when the module is missing, does not
291
+ * load, or lacks the export
292
+ */
293
+ function loadEntry(file, rule, lane, control, bundle) {
294
+ if ( !fs.existsSync(file) ) {
295
+ throw new Error('[ SERVER ] Route `'+ rule +'` declares `param.lane` `'+ lane +'` but `'+ file +'` is missing'+ ( /\.js$/.test(lane) ? ' (name the module without its `.js` extension)' : '' ) +'.');
296
+ }
297
+ var resolved = require.resolve(file);
298
+ var mod = null;
299
+ try {
300
+ mod = require(resolved);
301
+ } catch (err) {
302
+ throw new Error('[ SERVER ] Route `'+ rule +'`: lane module `lanes/'+ lane +'.js` could not be loaded ('+ file +'):\n'+ ( err && ( err.stack || err.message ) || String(err) ));
303
+ }
304
+ if ( mod === null || ( typeof(mod) != 'object' && typeof(mod) != 'function' ) || !hasOwn(mod, control) || typeof(mod[control]) != 'function' ) {
305
+ throw new Error('[ SERVER ] Route `'+ rule +'`: lane module `lanes/'+ lane +'.js` does not export a function named `'+ control +'` (the route\'s `param.control`). The contract is `module.exports.'+ control +' = function (ctx) { … };`.');
306
+ }
307
+ return {
308
+ fn : mod[control],
309
+ module : mod,
310
+ file : file,
311
+ resolved : resolved,
312
+ lane : lane,
313
+ control : control,
314
+ bundle : bundle,
315
+ rule : rule,
316
+ error : null
317
+ };
318
+ }
319
+
320
+ /**
321
+ * @typedef {object} LaneRegisterOptions
322
+ * @property {string} bundle - the bundle being booted (`core/server.js` `self.appName`)
323
+ * @property {string} bundlesPath - the project's bundles source directory
324
+ * @property {object} [settings] - the bundle's `settings.json` content (reads `auth.requireAuthByDefault`)
325
+ * @property {object} [server] - the bundle's resolved `server` block (reads `rateLimit.enabled`)
326
+ */
327
+
328
+ /**
329
+ * Lint and register every `param.lane` route of one bundle (the boot walk).
330
+ *
331
+ * Called once per bundle from `core/server.js` `init()`, before the server listens.
332
+ * A route opts in with a non-empty `param.lane`; every other route is skipped
333
+ * untouched. For each lane route this refuses to boot — throwing a
334
+ * `[ SERVER ] Route \`<rule>\`: …` error, which `init()` turns into an exit — when:
335
+ *
336
+ * 1. `param.lane` is not a module name under `lanes/` (see `isLaneName()`), or
337
+ * `param.control` is not a non-empty string, names a reserved action
338
+ * (`onReady`, `setup`) or is `redirect` (a redirect route);
339
+ * 2. the route belongs to another bundle (a lane module lives in its own bundle);
340
+ * 3. it carries middleware (route-level or from `routing.global.json`), `cache`,
341
+ * `negotiate`, a route-level `namespace`, or is a `method: "ws"` route —
342
+ * features that need a controller, or a cache write the lane does not perform;
343
+ * 4. it declares a gate (`param.requireAuth`, `param.roles`, `param.policy`,
344
+ * `rateLimit`, `idempotency`, `param.messageValidator`, `param.dto`), or the
345
+ * bundle gates it implicitly — `auth.requireAuthByDefault` without
346
+ * `param.public: true`, or `server.rateLimit.enabled` without `rateLimit: false`
347
+ * — because this slice of the lane does not run the gates;
348
+ * 5. `lanes/<lane>.js` is missing, fails to load, or does not export a function
349
+ * named after `param.control`.
350
+ *
351
+ * `param.responseDto` is allowed (the JSON writer projects it), as are
352
+ * `csrfExempt` (read by the bundle's own CSRF middleware), `requirements`,
353
+ * `scopes`, `param.public`, `param.requireAuth: false` and `rateLimit: false`.
354
+ *
355
+ * @memberof module:gina/lib/lane
356
+ * @param {object} routing - the bundle's routing table (`rule` → route)
357
+ * @param {LaneRegisterOptions} opt
358
+ * @returns {number} the number of lane routes registered
359
+ * @throws {Error} a route-named refusal, see above
360
+ *
361
+ * @example
362
+ * var count = lib.lane.registerRoutes(serverOpt.routing, {
363
+ * bundle : 'api',
364
+ * bundlesPath : '/srv/project/src',
365
+ * settings : conf.content.settings,
366
+ * server : conf.server
367
+ * });
368
+ * // count === 3, and process.gina._lanes['api::users#list'] holds the handler
369
+ */
370
+ function registerRoutes(routing, opt) {
371
+ opt = opt || {};
372
+ var bundle = opt.bundle;
373
+ var settings = ( opt.settings && typeof(opt.settings) == 'object' ) ? opt.settings : {};
374
+ var server = ( opt.server && typeof(opt.server) == 'object' ) ? opt.server : {};
375
+ var defaultDeny = !!( settings.auth && typeof(settings.auth) == 'object' && settings.auth.requireAuthByDefault === true );
376
+ var rateLimitOn = !!( server.rateLimit && typeof(server.rateLimit) == 'object' && server.rateLimit.enabled === true );
377
+ var reg = registry();
378
+ var count = 0;
379
+
380
+ for (var rule in routing) {
381
+ var route = routing[rule];
382
+ if ( typeof(route) != 'object' || route === null || typeof(route.param) != 'object' || route.param === null ) {
383
+ continue;
384
+ }
385
+ var lane = route.param.lane;
386
+ if ( typeof(lane) == 'undefined' || lane === null || lane === '' ) {
387
+ continue;
388
+ }
389
+ var where = '[ SERVER ] Route `'+ rule +'`: ';
390
+
391
+ // 1. the module name and the export
392
+ if ( !isLaneName(lane) ) {
393
+ throw new Error(where +'`param.lane` must name a module under `lanes/` — letters, digits and `_`, then `.` or `-`, with `/` between directories; no `..`, no leading `.` or `/` (got '+ describeValue(lane) +').');
394
+ }
395
+ var control = route.param.control;
396
+ if ( typeof(control) != 'string' || control === '' ) {
397
+ throw new Error(where +'`param.lane` routes name the module export to run in `param.control`, which must be a non-empty string (got '+ describeValue(control) +').');
398
+ }
399
+ if ( RESERVED_CONTROLS.indexOf(control) > -1 ) {
400
+ throw new Error(where +'`param.control` `'+ control +'` is reserved for the framework.');
401
+ }
402
+ if ( /^redirect$/i.test(control) ) {
403
+ throw new Error(where +'`param.control: "redirect"` marks a redirect route, which cannot be a lane route. Name the lane export something else.');
404
+ }
405
+ // 2. a lane module lives in its own bundle
406
+ if ( typeof(route.bundle) != 'undefined' && route.bundle !== null && route.bundle !== bundle ) {
407
+ throw new Error(where +'it belongs to bundle `'+ route.bundle +'` but is declared for bundle `'+ bundle +'`. A lane route must belong to the bundle whose `lanes/` directory holds its module.');
408
+ }
409
+ // 3. features that need a controller or a cache write
410
+ if ( Array.isArray(route.middleware) && route.middleware.length > 0 ) {
411
+ throw new Error(where +'a lane route cannot run route middleware (it declares or inherits from `routing.global.json`: '+ route.middleware.join(', ') +'). Middleware is built on the controller, which a lane route never builds. Drop `param.lane` to keep the middleware.');
412
+ }
413
+ if ( route.cache ) {
414
+ throw new Error(where +'a lane route cannot declare `cache`: the lane does not write the render cache, so the entry would never warm. Drop `cache`, or drop `param.lane` to cache the route through its controller.');
415
+ }
416
+ if ( route.negotiate ) {
417
+ throw new Error(where +'a lane route answers JSON only, so it cannot declare `negotiate`.');
418
+ }
419
+ if ( typeof(route.namespace) != 'undefined' && route.namespace !== null && route.namespace !== '' ) {
420
+ throw new Error(where +'a lane route cannot declare `namespace`: it selects a controller file, which a lane route never loads.');
421
+ }
422
+ if ( /^ws$/i.test(route.method || '') ) {
423
+ throw new Error(where +'a `method: "ws"` route is answered by the WebSocket handler, so it cannot be a lane route.');
424
+ }
425
+ // 4. gates, declared or implied
426
+ var gates = gateKeysOf(route);
427
+ if ( gates.length > 0 ) {
428
+ throw new Error(where +'a lane route cannot declare '+ gates.map(function(k){ return '`'+ k +'`'; }).join(', ') +' yet: the fast lane does not run the authorization, rate-limit, idempotency, message-validation or DTO gates in this release, so the gate would be silently skipped. Remove the key, or drop `param.lane` to serve the route through its controller.');
429
+ }
430
+ if ( defaultDeny && route.param.public !== true ) {
431
+ throw new Error(where +'`auth.requireAuthByDefault` gates every route not marked `"public": true`, and the fast lane does not run the authorization gate yet, so this route would be served unauthenticated. Mark it `"public": true` if it is meant to be open, or drop `param.lane`.');
432
+ }
433
+ if ( rateLimitOn && route.rateLimit !== false ) {
434
+ throw new Error(where +'`server.rateLimit` is enabled and applies to every route that does not declare `"rateLimit": false`, and the fast lane does not run the rate-limit gate yet, so this route would escape the quota. Declare `"rateLimit": false` to exempt it explicitly, or drop `param.lane`.');
435
+ }
436
+ // 5. the module
437
+ if ( typeof(opt.bundlesPath) != 'string' || opt.bundlesPath === '' || typeof(bundle) != 'string' || bundle === '' ) {
438
+ throw new Error(where +'cannot resolve `lanes/'+ lane +'.js`: the lane registry was called without the bundle name and the bundles path.');
439
+ }
440
+ var file = nodePath.join(opt.bundlesPath, bundle, 'lanes', lane + '.js');
441
+ var entry = loadEntry(file, rule, lane, control, bundle);
442
+ reg[ bundle +'::'+ lane +'#'+ control ] = entry;
443
+ ++count;
444
+ }
445
+ return count;
446
+ }
447
+
448
+ /**
449
+ * Find the registry entry for a matched route.
450
+ *
451
+ * `core/server.js` calls it only when `routing.param.lane` is set. A declared lane
452
+ * the registry does not hold (a route added after the boot, say) yields an entry
453
+ * marked `missing`, which `dispatch()` answers with a 500 naming it, rather than
454
+ * letting the route fall through to a controller.
455
+ *
456
+ * @memberof module:gina/lib/lane
457
+ * @param {object} routing - `req.routing` (`bundle`, `rule`, `param.lane`, `param.control`)
458
+ * @returns {?object} `null` when the route declares no lane; else the entry, or a
459
+ * `{ missing: true, … }` placeholder
460
+ *
461
+ * @example
462
+ * var entry = lib.lane.lookup(req.routing); // process.gina._lanes['api::users#list']
463
+ */
464
+ function lookup(routing) {
465
+ var param = ( routing ) ? routing.param : null;
466
+ if ( !param || typeof(param.lane) != 'string' || param.lane === '' ) {
467
+ return null;
468
+ }
469
+ var key = routing.bundle +'::'+ param.lane +'#'+ param.control;
470
+ var reg = ( process.gina ) ? process.gina._lanes : null;
471
+ var entry = ( reg ) ? reg[key] : undefined;
472
+ if ( entry ) {
473
+ return entry;
474
+ }
475
+ return { missing: true, key: key, bundle: routing.bundle, lane: param.lane, control: param.control, rule: routing.rule };
476
+ }
477
+
478
+ /**
479
+ * The directories to watch for dev-mode hot reload: the bundle's `lanes/` root
480
+ * and every directory under it holding a registered module (a directory watch
481
+ * does not descend). Empty when the bundle registered no lane route, so a bundle
482
+ * without lanes watches nothing.
483
+ *
484
+ * @memberof module:gina/lib/lane
485
+ * @param {string} lanesRoot - `<bundle>/lanes`
486
+ * @returns {string[]} absolute directory paths, the root first
487
+ *
488
+ * @example
489
+ * lib.lane.watchDirs('/srv/project/src/api/lanes');
490
+ * // ['/srv/project/src/api/lanes', '/srv/project/src/api/lanes/admin']
491
+ */
492
+ function watchDirs(lanesRoot) {
493
+ var root = nodePath.resolve(lanesRoot);
494
+ var reg = registry();
495
+ var out = [];
496
+ var seen = Object.create(null);
497
+ for (var key in reg) {
498
+ var dir = nodePath.dirname(nodePath.resolve(reg[key].file));
499
+ if ( dir !== root && dir.indexOf(root + nodePath.sep) !== 0 ) {
500
+ continue;
501
+ }
502
+ if ( out.length === 0 ) {
503
+ out.push(root);
504
+ seen[root] = true;
505
+ }
506
+ if ( !seen[dir] ) {
507
+ seen[dir] = true;
508
+ out.push(dir);
509
+ }
510
+ }
511
+ return out;
512
+ }
513
+
514
+ /**
515
+ * Drop this module's dead `children` after a re-require (the #B32 rule: a
516
+ * cache-miss `require()` pushes the fresh `Module` onto the requiring module's
517
+ * `children`, so an evicted handler would stay reachable from here forever).
518
+ *
519
+ * @inner
520
+ * @private
521
+ * @returns {void}
522
+ */
523
+ function pruneChildren() {
524
+ if ( module.children && module.children.length > 0 ) {
525
+ module.children = module.children.filter(function onLanePruneFilter(child) {
526
+ return require.cache[child.id] === child;
527
+ });
528
+ }
529
+ }
530
+
531
+ /**
532
+ * Dev mode: re-require every registered lane module and re-resolve each entry's
533
+ * export. A module that fails to load, or no longer exports the function, marks
534
+ * its entries with an `error` that `dispatch()` answers as a 500 until the file is
535
+ * fixed (the next watcher event reloads again).
536
+ *
537
+ * @inner
538
+ * @private
539
+ * @returns {void}
540
+ */
541
+ function reloadModules() {
542
+ var reg = registry();
543
+ var byFile = Object.create(null);
544
+ var key, file;
545
+ for (key in reg) {
546
+ file = reg[key].resolved;
547
+ if ( !byFile[file] ) {
548
+ byFile[file] = [];
549
+ }
550
+ byFile[file].push(reg[key]);
551
+ }
552
+ for (file in byFile) {
553
+ delete require.cache[file];
554
+ }
555
+ for (file in byFile) {
556
+ var mod = null;
557
+ var loadErr = null;
558
+ try {
559
+ mod = require(file);
560
+ } catch (err) {
561
+ loadErr = err;
562
+ }
563
+ var entries = byFile[file];
564
+ for (var i = 0; i < entries.length; ++i) {
565
+ var entry = entries[i];
566
+ if ( loadErr ) {
567
+ entry.error = new Error('lane module `lanes/'+ entry.lane +'.js` could not be reloaded ('+ entry.file +'):\n'+ ( loadErr.stack || loadErr.message || String(loadErr) ));
568
+ continue;
569
+ }
570
+ if ( mod === null || ( typeof(mod) != 'object' && typeof(mod) != 'function' ) || !hasOwn(mod, entry.control) || typeof(mod[entry.control]) != 'function' ) {
571
+ entry.error = new Error('lane module `lanes/'+ entry.lane +'.js` no longer exports a function named `'+ entry.control +'` (route `'+ entry.rule +'`).');
572
+ continue;
573
+ }
574
+ entry.fn = mod[entry.control];
575
+ entry.module = mod;
576
+ entry.error = null;
577
+ }
578
+ }
579
+ pruneChildren();
580
+ }
581
+
582
+ /**
583
+ * Dev mode: reload the lane modules when the watcher flagged a change (or on every
584
+ * request when no watcher runs — the controllers' #M6 fallback), then clear the flag.
585
+ *
586
+ * @inner
587
+ * @private
588
+ * @returns {void}
589
+ */
590
+ function reloadIfDirty() {
591
+ var hot = ( typeof(getContext) == 'function' ) ? getContext('__hotReload') : null;
592
+ if ( hot && !hot.lane ) {
593
+ return;
594
+ }
595
+ reloadModules();
596
+ if ( hot ) {
597
+ hot.lane = false;
598
+ }
599
+ }
600
+
601
+ /**
602
+ * Null the context's request and response once an answer is written — the
603
+ * released-response guard (#B31): a later `json()` / `error()` logs and no-ops.
604
+ *
605
+ * @inner
606
+ * @private
607
+ * @param {LaneContext} ctx
608
+ * @returns {void}
609
+ */
610
+ function release(ctx) {
611
+ ctx.req = null;
612
+ ctx.res = null;
613
+ }
614
+
615
+ /**
616
+ * Whether the response can no longer be written.
617
+ *
618
+ * @inner
619
+ * @private
620
+ * @param {object} res
621
+ * @returns {boolean}
622
+ */
623
+ function isAnswered(res) {
624
+ if ( res.headersSent || res.writableEnded ) {
625
+ return true;
626
+ }
627
+ var stream = res.stream;
628
+ return !!( stream && ( stream.destroyed || stream.closed ) );
629
+ }
630
+
631
+ /**
632
+ * Log a write attempted on a released or already-answered response.
633
+ *
634
+ * @inner
635
+ * @private
636
+ * @param {string} what - `json()` or `error()`
637
+ * @param {*} payload - what the late call carried
638
+ * @returns {void}
639
+ */
640
+ function logLateCall(what, payload) {
641
+ var text = '';
642
+ try {
643
+ text = ( payload instanceof Error ) ? ( payload.stack || payload.message )
644
+ : ( payload && typeof(payload) == 'object' ) ? JSON.stringify(payload)
645
+ : String(typeof(payload) == 'undefined' ? '' : payload);
646
+ } catch (err) {
647
+ text = String(payload);
648
+ }
649
+ logger.warn('[ Lane ] '+ what +' called after the response was released — ignoring: '+ text);
650
+ }
651
+
652
+ /**
653
+ * Fold the headers already set on the compat response into a raw HTTP/2 header
654
+ * frame, keeping the frame's own keys (the delegate's `getHeaders()` merge — what
655
+ * carries CORS, security headers, `X-Request-Id` and anything a middleware set).
656
+ *
657
+ * @inner
658
+ * @private
659
+ * @param {object} res - the compat response
660
+ * @param {object} headers - the frame being built (mutated)
661
+ * @returns {object} `headers`
662
+ */
663
+ function foldPendingHeaders(res, headers) {
664
+ var pending = ( typeof(res.getHeaders) == 'function' ) ? res.getHeaders() : null;
665
+ for (var k in pending) {
666
+ if ( !(k in headers) ) {
667
+ headers[k] = pending[k];
668
+ }
669
+ }
670
+ return headers;
671
+ }
672
+
673
+ /**
674
+ * Push the closing Inspector Flow bars for a lane response (`response-write`,
675
+ * `total`) when the request carries a timeline (Inspector open, or a production
676
+ * instrumentation window).
677
+ *
678
+ * @inner
679
+ * @private
680
+ * @param {LaneContext} ctx
681
+ * @param {object} req
682
+ * @returns {void}
683
+ */
684
+ function pushWriteTimeline(ctx, req) {
685
+ var tl = req._devTimeline;
686
+ if ( !tl || !tl.entries ) {
687
+ return;
688
+ }
689
+ var now = Date.now();
690
+ var start = ctx._t0 || now;
691
+ tl.entries.push({ label: 'response-write', cat: 'response', startMs: start, endMs: now, durationMs: now - start, detail: null });
692
+ tl.entries.push({ label: 'total', cat: 'total', startMs: tl.requestStart, endMs: now, durationMs: now - tl.requestStart, detail: null });
693
+ }
694
+
695
+ /**
696
+ * The JSON writer behind `ctx.json()` — `controller.render-json.js`'s contract
697
+ * without a controller.
698
+ *
699
+ * @inner
700
+ * @private
701
+ * @param {LaneContext} ctx
702
+ * @param {*} data - the payload (a string is parsed; a falsy value sends `{}`)
703
+ * @returns {boolean} `true` when written, `false` when the call was ignored
704
+ */
705
+ function writeJson(ctx, data) {
706
+ var req = ctx.req;
707
+ var res = ctx.res;
708
+ if ( res == null ) {
709
+ logLateCall('json()', data);
710
+ return false;
711
+ }
712
+ if ( isAnswered(res) ) {
713
+ if ( res.stream && ( res.stream.destroyed || res.stream.closed ) ) {
714
+ logger.warn('[ Lane ] Stream already destroyed — client disconnected before the response was sent ('+ req.url +')');
715
+ } else {
716
+ logLateCall('json()', data);
717
+ }
718
+ release(ctx);
719
+ return false;
720
+ }
721
+
722
+ var conf = ctx._conf;
723
+ var core = conf.server.coreConfiguration;
724
+ var contentType = core.mime['json'] + '; charset='+ conf.encoding;
725
+ var isH2Conf = /http\/2/.test(conf.server.protocol);
726
+ var stream = ( typeof(res.stream) != 'undefined' && res.stream !== null ) ? res.stream : null;
727
+
728
+ if ( !data ) {
729
+ data = {};
730
+ }
731
+ try {
732
+ if ( typeof(data) == 'string' ) {
733
+ data = JSON.parse(data);
734
+ }
735
+ res.setHeader('content-type', contentType);
736
+
737
+ // the status: a `status` key naming a listed non-200 code (or an `errno`
738
+ // payload whose `status` is listed); `errno` alone never sets it
739
+ if (
740
+ typeof(data.errno) != 'undefined' && res.statusCode == 200 && hasOwn(core.statusCodes, data.status)
741
+ ||
742
+ typeof(data.status) != 'undefined' && data.status != 200 && hasOwn(core.statusCodes, data.status)
743
+ ) {
744
+ try {
745
+ res.statusCode = data.status;
746
+ // HTTP/2 carries no reason phrase (RFC 9113 §8.3.2)
747
+ if ( !isH2Conf ) {
748
+ res.statusMessage = core.statusCodes[data.status];
749
+ }
750
+ } catch (statusErr) {
751
+ res.statusCode = 500;
752
+ logger.error('[ Lane ] status resolution failed: ', statusErr.stack || statusErr.message || statusErr);
753
+ if ( !isH2Conf ) {
754
+ res.statusMessage = 'Internal Server Error';
755
+ }
756
+ }
757
+ }
758
+
759
+ logger.info(req.method +' ['+ res.statusCode +'] '+ req.url);
760
+ pushWriteTimeline(ctx, req);
761
+
762
+ // #DTO2 — `param.responseDto` shapes a 2xx payload (registered at boot)
763
+ if (
764
+ typeof(data) == 'object' && data !== null
765
+ && res.statusCode >= 200 && res.statusCode < 300
766
+ && req.routing && req.routing.param
767
+ && typeof(req.routing.param.responseDto) == 'string' && req.routing.param.responseDto !== ''
768
+ ) {
769
+ var respDto = dto.get(req.routing.param.responseDto);
770
+ if ( respDto ) {
771
+ if ( isDev() ) {
772
+ var respSchema = respDto.toJsonSchema(null, { dropExcluded: true });
773
+ var respMissing = (respSchema.required || []).filter(function onRequiredField(f) {
774
+ return ( typeof(data[f]) == 'undefined' );
775
+ });
776
+ if ( respMissing.length > 0 ) {
777
+ logger.warn('[ Lane ] responseDto `'+ req.routing.param.responseDto +'` declares required field(s) the payload does not carry: '+ respMissing.join(', '));
778
+ }
779
+ }
780
+ data = respDto.apply(data);
781
+ } else {
782
+ logger.warn('[ Lane ] responseDto `'+ req.routing.param.responseDto +'` is not registered — the payload is sent unshaped.');
783
+ }
784
+ }
785
+
786
+ var body = JSON.stringify(data);
787
+ // #FIN6 — the idempotency record reads the status and content-type set above
788
+ if ( req._idemCapture ) {
789
+ idempotency.record(req, res, body);
790
+ }
791
+ var status = res.statusCode || 200;
792
+
793
+ if ( stream && ( stream.destroyed || stream.closed ) ) {
794
+ logger.warn('[ Lane ] Stream already destroyed — client disconnected before the response was sent ('+ req.url +')');
795
+ release(ctx);
796
+ return false;
797
+ }
798
+
799
+ // HEAD: the headers, with the length the body would have had, and no body
800
+ if ( /^HEAD$/i.test(req.method) ) {
801
+ var headLen = Buffer.byteLength(body, 'utf8');
802
+ if ( stream ) {
803
+ var sendHead = function onLaneSendHead() {
804
+ if ( !stream.headersSent ) {
805
+ stream.respond(foldPendingHeaders(res, { 'content-type': contentType, 'content-length': headLen, ':status': status }));
806
+ }
807
+ stream.end();
808
+ };
809
+ if ( res._ginaSendShim ) {
810
+ // #B562 — let a middleware wrapping writeHead/end run first
811
+ res._ginaRawSend = sendHead;
812
+ res.writeHead(status);
813
+ res.end();
814
+ } else {
815
+ sendHead();
816
+ }
817
+ } else {
818
+ res.setHeader('content-length', headLen);
819
+ res.end();
820
+ }
821
+ release(ctx);
822
+ return true;
823
+ }
824
+
825
+ if ( stream ) {
826
+ var sendBody = function onLaneSendBody(chunk) {
827
+ if ( !stream.headersSent ) {
828
+ stream.respond(foldPendingHeaders(res, { 'content-type': contentType, ':status': status }));
829
+ }
830
+ stream.end(chunk);
831
+ };
832
+ if ( res._ginaSendShim ) {
833
+ // #B562 — the shim hands the buffered body to sendBody after the
834
+ // wrapping middleware ran (a session cookie, a save-on-end)
835
+ res._ginaRawSend = sendBody;
836
+ res.writeHead(status);
837
+ res.end(body);
838
+ } else {
839
+ sendBody(body);
840
+ }
841
+ release(ctx);
842
+ return true;
843
+ }
844
+
845
+ // HTTP/1.x
846
+ res.setHeader('content-length', Buffer.byteLength(body, 'utf8'));
847
+ res.end(body);
848
+ release(ctx);
849
+ return true;
850
+ } catch (err) {
851
+ return writeError(ctx, [500, err]);
852
+ }
853
+ }
854
+
855
+ /**
856
+ * The status text for a code, warning when the table does not list it (the
857
+ * controller's `[ ApiValidator ]` diagnostic).
858
+ *
859
+ * @inner
860
+ * @private
861
+ * @param {object} statusCodes
862
+ * @param {number|string} code
863
+ * @returns {?string}
864
+ */
865
+ function statusText(statusCodes, code) {
866
+ if ( hasOwn(statusCodes, code) ) {
867
+ return statusCodes[code];
868
+ }
869
+ logger.warn('[ Lane ] statusCode `'+ code +'` not matching any definition in the status codes table');
870
+ return null;
871
+ }
872
+
873
+ /**
874
+ * Fill the keys `source` has and `target` lacks into a COPY of `target` — what
875
+ * `lib/merge(target, source)` produces for the controller's ApiError merge
876
+ * (target wins, key order kept, missing keys appended), without editing the
877
+ * caller's object.
878
+ *
879
+ * @inner
880
+ * @private
881
+ * @param {object} target
882
+ * @param {object} source
883
+ * @returns {object} a new plain object
884
+ */
885
+ function fillMissing(target, source) {
886
+ var out = {};
887
+ var k;
888
+ for (k in target) {
889
+ if ( hasOwn(target, k) ) {
890
+ out[k] = target[k];
891
+ }
892
+ }
893
+ for (k in source) {
894
+ if ( typeof(out[k]) == 'undefined' ) {
895
+ out[k] = source[k];
896
+ }
897
+ }
898
+ return out;
899
+ }
900
+
901
+ /**
902
+ * Whether a value is a response object (the controller's `(res, code, msg)` shape).
903
+ *
904
+ * @inner
905
+ * @private
906
+ * @param {*} value
907
+ * @returns {boolean}
908
+ */
909
+ function isResponseLike(value) {
910
+ return !!( value && typeof(value) == 'object' && typeof(value.writeHead) == 'function' && typeof(value.setHeader) == 'function' );
911
+ }
912
+
913
+ /**
914
+ * Build the error body from the arguments of `ctx.error()` — the controller
915
+ * `throwError` resolution for the same call shapes (`core/controller/controller.js`),
916
+ * so a lane route answers an error with the envelope a controller route would:
917
+ *
918
+ * - `(errorObj)` — `{ status, error, fields | flash | errors, … }` keeps the
919
+ * object's keys (the gates' shape); a plain `{ status, error }` keeps those two;
920
+ * - `(err)` — an `Error`; its `status` when valid, else 500; `error` and `message`
921
+ * carry its message, `stack` its stack;
922
+ * - `(status, message)` / `(status, err)` — `error` is the status text, `message`
923
+ * the sentence;
924
+ * - `(status, { message, ref, … })` and the controller's `(res, status, msg)` —
925
+ * same envelope; a leading response object is ignored;
926
+ * - `(status)` and `()` — the status text alone (a controller throws on these).
927
+ *
928
+ * @inner
929
+ * @private
930
+ * @param {Array} args - the call's arguments
931
+ * @param {object} statusCodes - `coreConfiguration.statusCodes`
932
+ * @returns {{errorObject: object, code: number|string, msg: *}}
933
+ */
934
+ function buildErrorObject(args, statusCodes) {
935
+ var a = Array.prototype.slice.call(args);
936
+ if ( a.length > 0 && isResponseLike(a[0]) ) {
937
+ a[0] = {}; // the controller reads no error, message, stack or status off a response
938
+ } else if ( a.length > 1 && ( a[0] === null || typeof(a[0]) == 'undefined' ) ) {
939
+ a[0] = {}; // a controller ignores this call as a late one; the lane still answers
940
+ }
941
+ if ( a.length === 0 ) {
942
+ a = [{ status: 500 }];
943
+ }
944
+ var n = a.length;
945
+ var res = a[0];
946
+ var code = a[1];
947
+ var msg = a[2];
948
+ var last = a[n - 1];
949
+ var errorObject = null;
950
+ var std = null;
951
+
952
+ // the 2-arg (status, Error|string) shift
953
+ if ( typeof(res) == 'number' && n === 2 && ( a[1] instanceof Error || typeof(a[1]) == 'string' ) ) {
954
+ msg = a[1];
955
+ code = res;
956
+ res = {};
957
+ }
958
+ // #B560 — a falsy 1-arg payload is a 500, not a late call
959
+ if ( n === 1 && !res ) {
960
+ res = { status: 500 };
961
+ }
962
+
963
+ if (
964
+ a[0] instanceof Error
965
+ || n == 1 && typeof(res) == 'object'
966
+ || last instanceof Error
967
+ || typeof(last) == 'string' && !(a[0] instanceof Error)
968
+ ) {
969
+ msg = ( !/^\d+$/.test(code) && typeof(msg) == 'undefined' ) ? code : msg;
970
+ code = isValidHttpStatus(code) ? code : ( res && isValidHttpStatus(res.status) ) ? res.status : 500;
971
+ std = statusText(statusCodes, code);
972
+ errorObject = {
973
+ status : code,
974
+ error : res.error || res.message || std
975
+ };
976
+ if ( res instanceof Error || typeof(res.stack) != 'undefined' ) {
977
+ errorObject.stack = res.stack;
978
+ if ( res.message && typeof(res.message) == 'string' ) {
979
+ errorObject.message = res.message;
980
+ } else if ( res.message ) {
981
+ logger.warn('[ Lane ] Ignoring message because of the format.\n'+ res.message);
982
+ }
983
+ } else if ( typeof(last) == 'string' ) {
984
+ errorObject.message = last || msg;
985
+ } else if ( last instanceof Error || typeof(res) == 'object' && typeof(res.stack) != 'undefined' ) {
986
+ if ( last instanceof Error ) {
987
+ if ( last.message ) { errorObject.message = last.message; }
988
+ if ( last.stack ) { errorObject.stack = last.stack; }
989
+ if ( !errorObject.error ) { errorObject.error = last.message || std; }
990
+ } else {
991
+ errorObject = fillMissing(last, errorObject);
992
+ }
993
+ } else if (
994
+ !(last instanceof Error) && typeof(res) == 'object' && typeof(res.error) != 'undefined'
995
+ && ( typeof(res.fields) != 'undefined' || typeof(res.flash) != 'undefined' || typeof(res.errors) != 'undefined' )
996
+ ) {
997
+ errorObject = fillMissing(last, errorObject);
998
+ }
999
+ } else if ( n < 3 ) {
1000
+ msg = code || null;
1001
+ code = ( res !== null && typeof(res) == 'object' ) ? res : isValidHttpStatus(res) ? res : 500;
1002
+ }
1003
+
1004
+ if ( code !== null && typeof(code) == 'object' && !msg && typeof(code.status) != 'undefined' && typeof(code.error) != 'undefined' ) {
1005
+ msg = code.error || code.message;
1006
+ code = isValidHttpStatus(code.status) ? code.status : 500;
1007
+ }
1008
+ if ( !isValidHttpStatus(code) ) {
1009
+ code = 500;
1010
+ }
1011
+ if ( !errorObject ) {
1012
+ std = statusText(statusCodes, code);
1013
+ errorObject = {
1014
+ status : code,
1015
+ error : std || ( msg && msg.error ) || msg
1016
+ };
1017
+ if ( msg !== null && typeof(msg) != 'undefined' ) {
1018
+ errorObject.message = msg.message || msg;
1019
+ errorObject.stack = msg.stack;
1020
+ }
1021
+ }
1022
+ return { errorObject: errorObject, code: code, msg: msg };
1023
+ }
1024
+
1025
+ /**
1026
+ * The error writer behind `ctx.error()` / `ctx.throwError()`: the controller's
1027
+ * JSON error envelope, one #ERRREF pairing log line, the local-scope stack gate.
1028
+ *
1029
+ * Always JSON: a lane route has no HTML error page, no `fallback` redirect.
1030
+ * Headers already set on the response (`Retry-After`, `RateLimit-*`,
1031
+ * `WWW-Authenticate`, CORS, security headers, `X-Request-Id`) are kept.
1032
+ *
1033
+ * @inner
1034
+ * @private
1035
+ * @param {LaneContext} ctx
1036
+ * @param {Array} args - the call's arguments
1037
+ * @returns {boolean} `true` when written, `false` when the call was ignored
1038
+ */
1039
+ function writeError(ctx, args) {
1040
+ var req = ctx.req;
1041
+ var res = ctx.res;
1042
+ if ( res == null || isAnswered(res) ) {
1043
+ logLateCall('error()', ( args.length > 1 ) ? args[args.length - 1] : args[0]);
1044
+ if ( res != null ) {
1045
+ release(ctx);
1046
+ }
1047
+ return false;
1048
+ }
1049
+ var conf = ctx._conf;
1050
+ var core = conf.server.coreConfiguration;
1051
+ var built = buildErrorObject(args, core.statusCodes);
1052
+ var errorObject = built.errorObject;
1053
+ var msg = built.msg;
1054
+ var code = Number(built.code);
1055
+
1056
+ errorObject.ref = errorRef.mint(
1057
+ errorObject.ref || ( ( msg && typeof(msg) == 'object' ) ? msg.ref : undefined )
1058
+ );
1059
+ // #ERRREF — the ONE full-detail line, before the egress strip below
1060
+ var detail = errorObject.stack || errorObject.message
1061
+ || ( ( errorObject.error && typeof(errorObject.error) === 'object' ) ? JSON.stringify(errorObject.error) : errorObject.error )
1062
+ || '';
1063
+ for (var dk = 0; dk < DETAIL_KEYS.length; ++dk) {
1064
+ var dv = errorObject[DETAIL_KEYS[dk]];
1065
+ if ( typeof(dv) == 'string' && STACK_FRAME.test(dv) && String(detail).indexOf(dv) < 0 ) {
1066
+ detail += '\n'+ dv;
1067
+ }
1068
+ }
1069
+ if ( msg && typeof(msg) == 'object' && msg.cause ) {
1070
+ detail += '\ncaused by: '+ ( msg.cause.stack || msg.cause.message || msg.cause );
1071
+ }
1072
+ var bundle = conf.bundle || ( req.routing && req.routing.bundle ) || '-';
1073
+ logger.error('[ BUNDLE ][ '+ bundle +' ][ Lane ][ ref '+ errorObject.ref +' ][ req '+ ( req._ginaReqId || '-' ) +' ] '+ req.method +' [ '+ ( errorObject.status || code ) +' ] '+ req.url + ( detail ? '\n'+ detail : '' ));
1074
+
1075
+ // outside local scope: no `stack`, and a stack-bearing string keeps its first line (#B670)
1076
+ if ( !isLocalScope() ) {
1077
+ delete errorObject.stack;
1078
+ for (var wk = 0; wk < DETAIL_KEYS.length; ++wk) {
1079
+ var wv = errorObject[DETAIL_KEYS[wk]];
1080
+ if ( typeof(wv) == 'string' && STACK_FRAME.test(wv) ) {
1081
+ errorObject[DETAIL_KEYS[wk]] = wv.split('\n')[0];
1082
+ }
1083
+ }
1084
+ }
1085
+
1086
+ var body = JSON.stringify(errorObject);
1087
+ try {
1088
+ res.statusCode = code;
1089
+ res.writeHead(code, {
1090
+ 'content-type' : core.mime['json'] + '; charset='+ conf.encoding,
1091
+ 'content-length' : Buffer.byteLength(body, 'utf8')
1092
+ });
1093
+ res.end(body);
1094
+ } catch (writeErr) {
1095
+ logger.error('[ Lane ] could not write the error response ('+ req.url +'): '+ ( writeErr.stack || writeErr.message || writeErr ));
1096
+ }
1097
+ release(ctx);
1098
+ return true;
1099
+ }
1100
+
1101
+ /**
1102
+ * Answer a handler's synchronous throw or rejection with a 500.
1103
+ *
1104
+ * @inner
1105
+ * @private
1106
+ * @param {LaneContext} ctx
1107
+ * @param {*} err - what was thrown or rejected
1108
+ * @returns {boolean}
1109
+ */
1110
+ function handlerFailed(ctx, err) {
1111
+ if ( !(err instanceof Error) && typeof(err) != 'string' ) {
1112
+ err = new Error('lane handler failed with a non-Error value: '+ describeValue(err));
1113
+ }
1114
+ return writeError(ctx, [500, err]);
1115
+ }
1116
+
1117
+
1118
+ /**
1119
+ * The single argument a lane handler receives: the live request and response,
1120
+ * what the route resolved to, and the methods that answer.
1121
+ *
1122
+ * Methods live on the prototype, so a handler that passes one around detached
1123
+ * must bind it (`ctx.json.bind(ctx)`).
1124
+ *
1125
+ * @class LaneContext
1126
+ * @constructor
1127
+ * @memberof module:gina/lib/lane
1128
+ * @param {object} req - the request (its `routing`, `params`, method bags and `body` are set)
1129
+ * @param {object} res - the response
1130
+ * @param {object} entry - the registry entry being dispatched
1131
+ * @param {object} conf - the bundle's configuration (`conf[bundle][env]`)
1132
+ * @param {object} [serverInstance] - the engine instance
1133
+ *
1134
+ * @property {object} req - the request; `null` once the response is written
1135
+ * @property {object} res - the response; `null` once the response is written
1136
+ * @property {object} params - URL parameters (`req.params`)
1137
+ * @property {object} get - the query parameters (`req.get`)
1138
+ * @property {object} body - the parsed body (`req.body`)
1139
+ * @property {object} routing - the matched route (`req.routing`)
1140
+ * @property {string} requestId - the request correlation id (`X-Request-Id`)
1141
+ * @property {string} [culture] - the negotiated culture (`req.culture`)
1142
+ *
1143
+ * @example
1144
+ * // <bundle>/lanes/users.js
1145
+ * module.exports.get = async function (ctx) {
1146
+ * var user = await users.byId(ctx.params.id);
1147
+ * if (!user) {
1148
+ * return ctx.error(404, 'No user ' + ctx.params.id);
1149
+ * }
1150
+ * ctx.json({ user: user });
1151
+ * };
1152
+ */
1153
+ function LaneContext(req, res, entry, conf, serverInstance) {
1154
+ this.req = req;
1155
+ this.res = res;
1156
+ this.params = req.params;
1157
+ this.get = req.get;
1158
+ this.body = req.body;
1159
+ this.routing = req.routing;
1160
+ this.requestId = req._ginaReqId;
1161
+ this.culture = req.culture;
1162
+ this._entry = entry;
1163
+ this._conf = conf;
1164
+ this._server = serverInstance || null;
1165
+ this._t0 = ( req._devTimeline ) ? Date.now() : 0;
1166
+ }
1167
+
1168
+ /**
1169
+ * The session the bundle's session middleware attached (`req.session`), or
1170
+ * `undefined` without one, or once the response is written.
1171
+ *
1172
+ * @name session
1173
+ * @memberof module:gina/lib/lane.LaneContext
1174
+ * @instance
1175
+ * @type {object|undefined}
1176
+ */
1177
+ Object.defineProperty(LaneContext.prototype, 'session', {
1178
+ get: function getLaneSession() {
1179
+ return ( this.req ) ? this.req.session : undefined;
1180
+ }
1181
+ });
1182
+
1183
+ /**
1184
+ * Send a JSON response.
1185
+ *
1186
+ * A `status` key naming a listed non-200 code sets the response status (the key
1187
+ * stays in the body); an `errno` key alone does not. On a 2xx, a route's
1188
+ * `param.responseDto` shapes the payload. A string is parsed first; a falsy value
1189
+ * sends `{}`. Writes once: a second call, or a call after `error()`, is logged and
1190
+ * ignored.
1191
+ *
1192
+ * @memberof module:gina/lib/lane.LaneContext
1193
+ * @param {object|Array|string} [data] - the payload
1194
+ * @returns {boolean} `true` when the response was written, `false` when ignored
1195
+ *
1196
+ * @example
1197
+ * ctx.json({ items: items }); // 200
1198
+ * ctx.json({ status: 201, id: created.id }); // 201
1199
+ * ctx.json({ status: 409, error: 'Already exists' }); // 409, the body as given
1200
+ */
1201
+ LaneContext.prototype.json = function(data) {
1202
+ return writeJson(this, data);
1203
+ };
1204
+
1205
+ /**
1206
+ * Send a JSON error response — the controller `throwError()` envelope:
1207
+ * `{ status, error, message?, fields? | errors?, stack? (local scope only), ref }`,
1208
+ * where `error` is the status text and `message` the sentence you passed, plus one
1209
+ * error-level log line pairing the `ref` with the full detail and the request id.
1210
+ *
1211
+ * @memberof module:gina/lib/lane.LaneContext
1212
+ * @param {number|Error|object|string} [status] - the HTTP status, an `Error` (its
1213
+ * `status` property, else 500), or an error object `{ status, error, … }`
1214
+ * @param {string|Error|object} [message] - the sentence, an `Error`, or `{ message, ref }`
1215
+ * @returns {boolean} `true` when the response was written, `false` when ignored
1216
+ *
1217
+ * @example
1218
+ * ctx.error(404, 'No such invoice'); // {"status":404,"error":"Not Found","message":"No such invoice","ref":"A1B2C3"}
1219
+ * ctx.error(500, err); // the message, and the stack in local scope only
1220
+ * ctx.error({ status: 422, error: 'Validation failed', fields: { email: { isEmail: 'Invalid' } } });
1221
+ * ctx.error(500, { ref: 'ORDER-42', message: 'payment capture failed' }); // a relay-safe ref is kept
1222
+ */
1223
+ LaneContext.prototype.error = function() {
1224
+ return writeError(this, arguments);
1225
+ };
1226
+
1227
+ /**
1228
+ * Alias of `error()`, under the name the framework's gate libraries call on the
1229
+ * object they answer through.
1230
+ *
1231
+ * @memberof module:gina/lib/lane.LaneContext
1232
+ * @function
1233
+ * @param {number|Error|object|string} [status]
1234
+ * @param {string|Error|object} [message]
1235
+ * @returns {boolean}
1236
+ *
1237
+ * @example
1238
+ * ctx.throwError({ status: 401, error: 'Unauthorized' });
1239
+ */
1240
+ LaneContext.prototype.throwError = LaneContext.prototype.error;
1241
+
1242
+ /**
1243
+ * The bundle configuration, or one config file's content by name — the controller
1244
+ * `getConfig()` contract: a per-call copy-on-write view (a deep clone when
1245
+ * `settings.json > controller.getConfig.mode` is `"clone"`), with `hostname` /
1246
+ * `host` resolved against this request's proxy classification.
1247
+ *
1248
+ * @memberof module:gina/lib/lane.LaneContext
1249
+ * @param {string} [name] - a config name without its extension (`'app'`, `'settings'`, …)
1250
+ * @returns {object|undefined} the view — `undefined` for an unknown `name`
1251
+ *
1252
+ * @example
1253
+ * var app = ctx.getConfig('app'); // a private view of config/app.json
1254
+ */
1255
+ LaneContext.prototype.getConfig = function(name) {
1256
+ var conf = this._conf;
1257
+ var settings = ( conf && conf.content ) ? conf.content.settings : null;
1258
+ var cloneMode = !!( settings && settings.controller && settings.controller.getConfig && settings.controller.getConfig.mode == 'clone' );
1259
+ var tmp = null;
1260
+ if ( typeof(name) != 'undefined' ) {
1261
+ try {
1262
+ tmp = ( cloneMode ) ? JSONClone(conf.content[name]) : confView.create(conf.content[name]);
1263
+ } catch (err) {
1264
+ return undefined;
1265
+ }
1266
+ } else {
1267
+ tmp = ( cloneMode ) ? JSONClone(conf) : confView.create(conf);
1268
+ }
1269
+ // #B66 — this request's proxy classification, the worker-global latch as the fallback
1270
+ var req = this.req;
1271
+ var isProxyHost = ( req && typeof(req._ginaIsProxyHost) != 'undefined' ) ? req._ginaIsProxyHost : ( ( typeof(getContext) == 'function' && getContext('isProxyHost') ) || false );
1272
+ var proxyHostname = ( req && req._ginaProxyHostname ) ? req._ginaProxyHostname : ( process.gina && process.gina.PROXY_HOSTNAME );
1273
+ var proxyHost = ( req && req._ginaProxyHost ) ? req._ginaProxyHost : ( process.gina && process.gina.PROXY_HOST );
1274
+ if (
1275
+ isProxyHost
1276
+ && tmp && typeof(tmp) == 'object'
1277
+ && typeof(tmp.hostname) != 'undefined'
1278
+ && typeof(proxyHostname) != 'undefined'
1279
+ ) {
1280
+ tmp.hostname = proxyHostname;
1281
+ tmp.host = proxyHost;
1282
+ }
1283
+ return tmp;
1284
+ };
1285
+
1286
+ /**
1287
+ * Whether the authenticated caller holds `role` — the session user when present,
1288
+ * else a machine caller the authorization gate verified (`req.machineCaller`),
1289
+ * read through `lib/authz-gate` like the controller's `hasRole()`.
1290
+ *
1291
+ * @memberof module:gina/lib/lane.LaneContext
1292
+ * @param {string} role
1293
+ * @returns {boolean} `false` without a principal, and once the response is written
1294
+ *
1295
+ * @example
1296
+ * if ( ctx.hasRole('admin') ) { payload.audit = doc.audit; }
1297
+ */
1298
+ LaneContext.prototype.hasRole = function(role) {
1299
+ var req = this.req;
1300
+ if ( req == null ) {
1301
+ return false;
1302
+ }
1303
+ var session = req.session;
1304
+ var user = ( session && session.user )
1305
+ ? session.user
1306
+ : ( ( req.machineCaller && typeof(req.machineCaller) == 'object' ) ? req.machineCaller : null );
1307
+ return authzGate.hasAnyRole(user, [ role ]);
1308
+ };
1309
+
1310
+ /**
1311
+ * Whether the request is an XHR / API call (`req.isXMLRequest`).
1312
+ *
1313
+ * @memberof module:gina/lib/lane.LaneContext
1314
+ * @returns {boolean}
1315
+ *
1316
+ * @example
1317
+ * if ( !ctx.isXMLRequest() ) { … }
1318
+ */
1319
+ LaneContext.prototype.isXMLRequest = function() {
1320
+ return !!( this.req && this.req.isXMLRequest === true );
1321
+ };
1322
+
1323
+ /**
1324
+ * Snapshot the request as `haltedRequest` in `requestStorage` (default
1325
+ * `req.session`) so it can be replayed after a login — the controller
1326
+ * `pauseRequest()` snapshot: `{ url, routing, method, data, params? }`.
1327
+ *
1328
+ * @memberof module:gina/lib/lane.LaneContext
1329
+ * @param {object} data - the request data to keep (`req[method]`)
1330
+ * @param {object} [requestStorage] - where to store it; defaults to `req.session`
1331
+ * @returns {object|undefined} `requestStorage`; `undefined` once the response is
1332
+ * written, or after answering 424 when there is no storage
1333
+ *
1334
+ * @example
1335
+ * ctx.pauseRequest(ctx.get); // req.session.haltedRequest = { url, routing, method: 'get', data }
1336
+ */
1337
+ LaneContext.prototype.pauseRequest = function(data, requestStorage) {
1338
+ var req = this.req;
1339
+ if ( req == null ) {
1340
+ return;
1341
+ }
1342
+ var haltedRequest = {
1343
+ url : req.originalUrl || req.url,
1344
+ routing : req.routing,
1345
+ method : req.method.toLowerCase(),
1346
+ data : JSONClone(data)
1347
+ };
1348
+ if ( typeof(requestStorage) == 'undefined' && typeof(req.session) != 'undefined' ) {
1349
+ requestStorage = req.session;
1350
+ }
1351
+ if ( typeof(requestStorage) == 'undefined' ) {
1352
+ var storageErr = new Error('`requestStorage` is required');
1353
+ storageErr.status = 424;
1354
+ this.error(storageErr);
1355
+ return;
1356
+ }
1357
+ var requestParams = {};
1358
+ var i = 0;
1359
+ for (var p in req.params) {
1360
+ if ( i > 0 ) {
1361
+ requestParams[p] = req.params[p];
1362
+ }
1363
+ ++i;
1364
+ }
1365
+ if ( Object.keys(requestParams).length > 0 ) {
1366
+ haltedRequest.params = requestParams;
1367
+ }
1368
+ requestStorage.haltedRequest = haltedRequest;
1369
+ return requestStorage;
1370
+ };
1371
+
1372
+
1373
+ /**
1374
+ * Run a lane route's handler (called by `core/server.js` at the end of the isaac
1375
+ * middleware chain, or directly on express).
1376
+ *
1377
+ * In dev mode the registered modules are reloaded first when the watcher flagged
1378
+ * a change. An entry the registry does not hold, or one whose module failed to
1379
+ * reload, answers 500 naming it. The handler runs as `fn.call(module, ctx)`; a
1380
+ * synchronous throw, or a rejection of the promise it returns, answers 500 through
1381
+ * `ctx.error()` (or is logged when the handler had already answered). Never calls
1382
+ * `next`: the lane answers every request itself.
1383
+ *
1384
+ * @memberof module:gina/lib/lane
1385
+ * @param {object} entry - from `lookup()`
1386
+ * @param {object} req - the request
1387
+ * @param {object} res - the response
1388
+ * @param {function} [next] - the engine's next (express); unused
1389
+ * @param {object} [serverInstance] - the engine instance
1390
+ * @param {object} conf - the bundle's configuration (`conf[bundle][env]`)
1391
+ * @returns {void} never the handler's promise, so a rejection cannot escape
1392
+ *
1393
+ * @example
1394
+ * lib.lane.dispatch(lib.lane.lookup(req.routing), req, res, next, instance, conf);
1395
+ */
1396
+ function dispatch(entry, req, res, next, serverInstance, conf) {
1397
+ if ( isDev() ) {
1398
+ reloadIfDirty();
1399
+ }
1400
+ var ctx = new LaneContext(req, res, entry, conf, serverInstance);
1401
+ if ( entry.missing ) {
1402
+ ctx.error(500, 'lane route `'+ entry.rule +'` names `'+ entry.lane +'#'+ entry.control +'`, which is not registered for bundle `'+ entry.bundle +'` (lane routes are registered at boot; a route added since needs a restart)');
1403
+ return;
1404
+ }
1405
+ if ( entry.error ) {
1406
+ ctx.error(500, entry.error);
1407
+ return;
1408
+ }
1409
+ // the Flow bar opens before the handler so it precedes the writer's bars
1410
+ var tlEntry = null;
1411
+ if ( ctx._t0 && req._devTimeline && req._devTimeline.entries ) {
1412
+ tlEntry = { label: 'lane-dispatch', cat: 'controller', startMs: ctx._t0, endMs: ctx._t0, durationMs: 0, detail: entry.lane +'#'+ entry.control };
1413
+ req._devTimeline.entries.push(tlEntry);
1414
+ }
1415
+ var result = null;
1416
+ try {
1417
+ result = entry.fn.call(entry.module, ctx);
1418
+ } catch (err) {
1419
+ handlerFailed(ctx, err);
1420
+ result = null;
1421
+ }
1422
+ if ( tlEntry ) {
1423
+ tlEntry.endMs = Date.now();
1424
+ tlEntry.durationMs = tlEntry.endMs - tlEntry.startMs;
1425
+ }
1426
+ if ( result && typeof(result.then) == 'function' ) {
1427
+ result.then(null, function onLaneRejected(err) {
1428
+ handlerFailed(ctx, err);
1429
+ });
1430
+ }
1431
+ }
1432
+
1433
+ module.exports = {
1434
+ registerRoutes : registerRoutes,
1435
+ lookup : lookup,
1436
+ dispatch : dispatch,
1437
+ watchDirs : watchDirs,
1438
+ isLaneName : isLaneName,
1439
+ LaneContext : LaneContext
1440
+ };