@tinyrack/issuary-server 0.31.0 → 0.32.1

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 (456) hide show
  1. package/dist/entities/auth-budget.entity.d.ts +20 -0
  2. package/dist/entities/auth-budget.entity.d.ts.map +1 -0
  3. package/dist/entities/auth-budget.entity.js +11 -0
  4. package/dist/entities/auth-budget.entity.js.map +1 -0
  5. package/dist/entities/browser-session.entity.d.ts +32 -0
  6. package/dist/entities/browser-session.entity.d.ts.map +1 -0
  7. package/dist/entities/browser-session.entity.js +12 -0
  8. package/dist/entities/browser-session.entity.js.map +1 -0
  9. package/dist/entities/email-verification.entity.d.ts +18 -0
  10. package/dist/entities/email-verification.entity.d.ts.map +1 -1
  11. package/dist/entities/email-verification.entity.js +2 -0
  12. package/dist/entities/email-verification.entity.js.map +1 -1
  13. package/dist/entities/oauth-client.entity.d.ts +120 -0
  14. package/dist/entities/oauth-client.entity.d.ts.map +1 -1
  15. package/dist/entities/oauth-code.entity.d.ts +120 -0
  16. package/dist/entities/oauth-code.entity.d.ts.map +1 -1
  17. package/dist/entities/oauth-code.entity.js +3 -0
  18. package/dist/entities/oauth-code.entity.js.map +1 -1
  19. package/dist/entities/oauth-device-code.entity.d.ts +120 -0
  20. package/dist/entities/oauth-device-code.entity.d.ts.map +1 -1
  21. package/dist/entities/oauth-device-code.entity.js +3 -0
  22. package/dist/entities/oauth-device-code.entity.js.map +1 -1
  23. package/dist/entities/oauth-grant.entity.d.ts +52 -0
  24. package/dist/entities/oauth-grant.entity.d.ts.map +1 -0
  25. package/dist/entities/oauth-grant.entity.js +19 -0
  26. package/dist/entities/oauth-grant.entity.js.map +1 -0
  27. package/dist/entities/password-reset.entity.d.ts +18 -0
  28. package/dist/entities/password-reset.entity.d.ts.map +1 -1
  29. package/dist/entities/password-reset.entity.js +2 -0
  30. package/dist/entities/password-reset.entity.js.map +1 -1
  31. package/dist/entities/pending-oauth-registration.entity.d.ts +9 -0
  32. package/dist/entities/pending-oauth-registration.entity.d.ts.map +1 -1
  33. package/dist/entities/pending-oauth-registration.entity.js +1 -0
  34. package/dist/entities/pending-oauth-registration.entity.js.map +1 -1
  35. package/dist/entities/revoked-token.entity.d.ts +120 -0
  36. package/dist/entities/revoked-token.entity.d.ts.map +1 -1
  37. package/dist/entities/terms-content.entity.d.ts +36 -0
  38. package/dist/entities/terms-content.entity.d.ts.map +1 -1
  39. package/dist/entities/terms.entity.d.ts +36 -0
  40. package/dist/entities/terms.entity.d.ts.map +1 -1
  41. package/dist/entities/user-consent.entity.d.ts +120 -0
  42. package/dist/entities/user-consent.entity.d.ts.map +1 -1
  43. package/dist/entities/user-terms-consent.entity.d.ts +36 -0
  44. package/dist/entities/user-terms-consent.entity.d.ts.map +1 -1
  45. package/dist/entities/user-totp-recovery-code.entity.d.ts +36 -0
  46. package/dist/entities/user-totp-recovery-code.entity.d.ts.map +1 -1
  47. package/dist/entities/user-totp.entity.d.ts +36 -0
  48. package/dist/entities/user-totp.entity.d.ts.map +1 -1
  49. package/dist/entities/user-totp.entity.js +1 -0
  50. package/dist/entities/user-totp.entity.js.map +1 -1
  51. package/dist/entities/user.entity.d.ts +36 -0
  52. package/dist/entities/user.entity.d.ts.map +1 -1
  53. package/dist/entities/user.entity.js +3 -0
  54. package/dist/entities/user.entity.js.map +1 -1
  55. package/dist/entrypoints/app.d.ts +438 -427
  56. package/dist/entrypoints/app.d.ts.map +1 -1
  57. package/dist/entrypoints/app.js +78 -6
  58. package/dist/entrypoints/app.js.map +1 -1
  59. package/dist/entrypoints/database/postgres/compiled-functions.d.ts +326 -200
  60. package/dist/entrypoints/database/postgres/compiled-functions.js +1849 -518
  61. package/dist/entrypoints/database/postgres/compiled-functions.js.map +1 -1
  62. package/dist/entrypoints/database/sqlite/compiled-functions.d.ts +326 -200
  63. package/dist/entrypoints/database/sqlite/compiled-functions.js +1849 -518
  64. package/dist/entrypoints/database/sqlite/compiled-functions.js.map +1 -1
  65. package/dist/entrypoints/database/sqlite/sqlite.d.ts.map +1 -1
  66. package/dist/entrypoints/database/sqlite/sqlite.js +1 -0
  67. package/dist/entrypoints/database/sqlite/sqlite.js.map +1 -1
  68. package/dist/entrypoints/scheduler/database.d.ts +3 -1
  69. package/dist/entrypoints/scheduler/database.d.ts.map +1 -1
  70. package/dist/entrypoints/scheduler/database.js +13 -2
  71. package/dist/entrypoints/scheduler/database.js.map +1 -1
  72. package/dist/entrypoints/scheduler/distributed-runner.d.ts +4 -0
  73. package/dist/entrypoints/scheduler/distributed-runner.d.ts.map +1 -1
  74. package/dist/entrypoints/scheduler/distributed-runner.js +26 -1
  75. package/dist/entrypoints/scheduler/distributed-runner.js.map +1 -1
  76. package/dist/lib/config/email.d.ts +1 -0
  77. package/dist/lib/config/email.d.ts.map +1 -1
  78. package/dist/lib/config/email.js.map +1 -1
  79. package/dist/lib/database/entities.d.ts.map +1 -1
  80. package/dist/lib/database/entities.js +6 -0
  81. package/dist/lib/database/entities.js.map +1 -1
  82. package/dist/lib/openapi.d.ts +2 -0
  83. package/dist/lib/openapi.d.ts.map +1 -1
  84. package/dist/lib/openapi.js +36 -1
  85. package/dist/lib/openapi.js.map +1 -1
  86. package/dist/lib/request-ip.d.ts +4 -0
  87. package/dist/lib/request-ip.d.ts.map +1 -0
  88. package/dist/lib/request-ip.js +39 -0
  89. package/dist/lib/request-ip.js.map +1 -0
  90. package/dist/middleware/auth-budget.d.ts +3 -0
  91. package/dist/middleware/auth-budget.d.ts.map +1 -0
  92. package/dist/middleware/auth-budget.js +80 -0
  93. package/dist/middleware/auth-budget.js.map +1 -0
  94. package/dist/middleware/session.d.ts +23 -5
  95. package/dist/middleware/session.d.ts.map +1 -1
  96. package/dist/middleware/session.js +152 -12
  97. package/dist/middleware/session.js.map +1 -1
  98. package/dist/middleware/strict-input.d.ts +4 -0
  99. package/dist/middleware/strict-input.d.ts.map +1 -0
  100. package/dist/middleware/strict-input.js +144 -0
  101. package/dist/middleware/strict-input.js.map +1 -0
  102. package/dist/migrations/postgres/Migration20260910120000_api_security.d.ts +6 -0
  103. package/dist/migrations/postgres/Migration20260910120000_api_security.d.ts.map +1 -0
  104. package/dist/migrations/postgres/Migration20260910120000_api_security.js +20 -0
  105. package/dist/migrations/postgres/Migration20260910120000_api_security.js.map +1 -0
  106. package/dist/migrations/postgres/Migration20260910160000_security_followup.d.ts +6 -0
  107. package/dist/migrations/postgres/Migration20260910160000_security_followup.d.ts.map +1 -0
  108. package/dist/migrations/postgres/Migration20260910160000_security_followup.js +23 -0
  109. package/dist/migrations/postgres/Migration20260910160000_security_followup.js.map +1 -0
  110. package/dist/migrations/postgres/Migration20260910200000_authentication_epoch.d.ts +6 -0
  111. package/dist/migrations/postgres/Migration20260910200000_authentication_epoch.d.ts.map +1 -0
  112. package/dist/migrations/postgres/Migration20260910200000_authentication_epoch.js +28 -0
  113. package/dist/migrations/postgres/Migration20260910200000_authentication_epoch.js.map +1 -0
  114. package/dist/migrations/postgres/Migration20260910220000_flow_revocation.d.ts +6 -0
  115. package/dist/migrations/postgres/Migration20260910220000_flow_revocation.d.ts.map +1 -0
  116. package/dist/migrations/postgres/Migration20260910220000_flow_revocation.js +19 -0
  117. package/dist/migrations/postgres/Migration20260910220000_flow_revocation.js.map +1 -0
  118. package/dist/migrations/postgres/index.d.ts.map +1 -1
  119. package/dist/migrations/postgres/index.js +8 -0
  120. package/dist/migrations/postgres/index.js.map +1 -1
  121. package/dist/migrations/sqlite/Migration20260910120000_api_security.d.ts +6 -0
  122. package/dist/migrations/sqlite/Migration20260910120000_api_security.d.ts.map +1 -0
  123. package/dist/migrations/sqlite/Migration20260910120000_api_security.js +20 -0
  124. package/dist/migrations/sqlite/Migration20260910120000_api_security.js.map +1 -0
  125. package/dist/migrations/sqlite/Migration20260910160000_security_followup.d.ts +6 -0
  126. package/dist/migrations/sqlite/Migration20260910160000_security_followup.d.ts.map +1 -0
  127. package/dist/migrations/sqlite/Migration20260910160000_security_followup.js +23 -0
  128. package/dist/migrations/sqlite/Migration20260910160000_security_followup.js.map +1 -0
  129. package/dist/migrations/sqlite/Migration20260910200000_authentication_epoch.d.ts +8 -0
  130. package/dist/migrations/sqlite/Migration20260910200000_authentication_epoch.d.ts.map +1 -0
  131. package/dist/migrations/sqlite/Migration20260910200000_authentication_epoch.js +72 -0
  132. package/dist/migrations/sqlite/Migration20260910200000_authentication_epoch.js.map +1 -0
  133. package/dist/migrations/sqlite/Migration20260910220000_flow_revocation.d.ts +6 -0
  134. package/dist/migrations/sqlite/Migration20260910220000_flow_revocation.d.ts.map +1 -0
  135. package/dist/migrations/sqlite/Migration20260910220000_flow_revocation.js +19 -0
  136. package/dist/migrations/sqlite/Migration20260910220000_flow_revocation.js.map +1 -0
  137. package/dist/migrations/sqlite/index.d.ts.map +1 -1
  138. package/dist/migrations/sqlite/index.js +8 -0
  139. package/dist/migrations/sqlite/index.js.map +1 -1
  140. package/dist/repositories/email-verification.repository.d.ts +1 -0
  141. package/dist/repositories/email-verification.repository.d.ts.map +1 -1
  142. package/dist/repositories/email-verification.repository.js +8 -17
  143. package/dist/repositories/email-verification.repository.js.map +1 -1
  144. package/dist/repositories/oauth-code.repository.d.ts +2 -0
  145. package/dist/repositories/oauth-code.repository.d.ts.map +1 -1
  146. package/dist/repositories/oauth-code.repository.js +8 -0
  147. package/dist/repositories/oauth-code.repository.js.map +1 -1
  148. package/dist/repositories/oauth-device-code.repository.d.ts +3 -0
  149. package/dist/repositories/oauth-device-code.repository.d.ts.map +1 -1
  150. package/dist/repositories/oauth-device-code.repository.js +64 -29
  151. package/dist/repositories/oauth-device-code.repository.js.map +1 -1
  152. package/dist/repositories/password-reset.repository.d.ts +1 -0
  153. package/dist/repositories/password-reset.repository.d.ts.map +1 -1
  154. package/dist/repositories/password-reset.repository.js +6 -19
  155. package/dist/repositories/password-reset.repository.js.map +1 -1
  156. package/dist/repositories/pending-oauth-registration.repository.d.ts +2 -0
  157. package/dist/repositories/pending-oauth-registration.repository.d.ts.map +1 -1
  158. package/dist/repositories/pending-oauth-registration.repository.js +16 -2
  159. package/dist/repositories/pending-oauth-registration.repository.js.map +1 -1
  160. package/dist/repositories/terms.repository.d.ts.map +1 -1
  161. package/dist/repositories/terms.repository.js +1 -0
  162. package/dist/repositories/terms.repository.js.map +1 -1
  163. package/dist/repositories/user-consent.repository.d.ts.map +1 -1
  164. package/dist/repositories/user-consent.repository.js +1 -1
  165. package/dist/repositories/user-consent.repository.js.map +1 -1
  166. package/dist/repositories/user-terms-consent.repository.d.ts.map +1 -1
  167. package/dist/repositories/user-terms-consent.repository.js +2 -0
  168. package/dist/repositories/user-terms-consent.repository.js.map +1 -1
  169. package/dist/repositories/user-totp-recovery-code.repository.d.ts +24 -0
  170. package/dist/repositories/user-totp-recovery-code.repository.d.ts.map +1 -1
  171. package/dist/repositories/user-totp.repository.d.ts +36 -0
  172. package/dist/repositories/user-totp.repository.d.ts.map +1 -1
  173. package/dist/routes/.well-known/openid-configuration/get.d.ts.map +1 -1
  174. package/dist/routes/.well-known/openid-configuration/get.js +5 -1
  175. package/dist/routes/.well-known/openid-configuration/get.js.map +1 -1
  176. package/dist/routes/api/admin/console/index.d.ts.map +1 -1
  177. package/dist/routes/api/admin/console/index.js +29 -14
  178. package/dist/routes/api/admin/console/index.js.map +1 -1
  179. package/dist/routes/api/admin/me/get.js +2 -3
  180. package/dist/routes/api/admin/me/get.js.map +1 -1
  181. package/dist/routes/api/admin/users/index.d.ts.map +1 -1
  182. package/dist/routes/api/admin/users/index.js +59 -52
  183. package/dist/routes/api/admin/users/index.js.map +1 -1
  184. package/dist/routes/api/auth/accounts/remove.post.d.ts +5 -5
  185. package/dist/routes/api/auth/accounts/select.post.d.ts +6 -6
  186. package/dist/routes/api/auth/email/resend/post.d.ts.map +1 -1
  187. package/dist/routes/api/auth/email/resend/post.js +3 -24
  188. package/dist/routes/api/auth/email/resend/post.js.map +1 -1
  189. package/dist/routes/api/auth/email/verify/post.d.ts.map +1 -1
  190. package/dist/routes/api/auth/email/verify/post.js +29 -12
  191. package/dist/routes/api/auth/email/verify/post.js.map +1 -1
  192. package/dist/routes/api/auth/login/post.d.ts.map +1 -1
  193. package/dist/routes/api/auth/login/post.js +4 -3
  194. package/dist/routes/api/auth/login/post.js.map +1 -1
  195. package/dist/routes/api/auth/passkey/verify/post.d.ts.map +1 -1
  196. package/dist/routes/api/auth/passkey/verify/post.js +25 -11
  197. package/dist/routes/api/auth/passkey/verify/post.js.map +1 -1
  198. package/dist/routes/api/auth/password/forgot/post.d.ts.map +1 -1
  199. package/dist/routes/api/auth/password/forgot/post.js +2 -19
  200. package/dist/routes/api/auth/password/forgot/post.js.map +1 -1
  201. package/dist/routes/api/auth/register/post.d.ts.map +1 -1
  202. package/dist/routes/api/auth/register/post.js +4 -3
  203. package/dist/routes/api/auth/register/post.js.map +1 -1
  204. package/dist/routes/api/auth/totp/recovery/verify/post.d.ts.map +1 -1
  205. package/dist/routes/api/auth/totp/recovery/verify/post.js +7 -5
  206. package/dist/routes/api/auth/totp/recovery/verify/post.js.map +1 -1
  207. package/dist/routes/api/auth/totp/verify/post.d.ts.map +1 -1
  208. package/dist/routes/api/auth/totp/verify/post.js +7 -5
  209. package/dist/routes/api/auth/totp/verify/post.js.map +1 -1
  210. package/dist/routes/api/consent/post.d.ts.map +1 -1
  211. package/dist/routes/api/consent/post.js +141 -120
  212. package/dist/routes/api/consent/post.js.map +1 -1
  213. package/dist/routes/api/docs/get.d.ts.map +1 -1
  214. package/dist/routes/api/docs/get.js +8 -1
  215. package/dist/routes/api/docs/get.js.map +1 -1
  216. package/dist/routes/api/index.d.ts +379 -379
  217. package/dist/routes/api/oauth/_provider/authorize/get.d.ts.map +1 -1
  218. package/dist/routes/api/oauth/_provider/authorize/get.js +5 -1
  219. package/dist/routes/api/oauth/_provider/authorize/get.js.map +1 -1
  220. package/dist/routes/api/oauth/_provider/callback/get.d.ts.map +1 -1
  221. package/dist/routes/api/oauth/_provider/callback/get.js +30 -6
  222. package/dist/routes/api/oauth/_provider/callback/get.js.map +1 -1
  223. package/dist/routes/api/oauth/_provider/callback/post.d.ts +9 -9
  224. package/dist/routes/api/oauth/_provider/callback/post.d.ts.map +1 -1
  225. package/dist/routes/api/oauth/_provider/callback/post.js +31 -31
  226. package/dist/routes/api/oauth/_provider/callback/post.js.map +1 -1
  227. package/dist/routes/api/oauth/_provider/delete.d.ts.map +1 -1
  228. package/dist/routes/api/oauth/_provider/delete.js +14 -11
  229. package/dist/routes/api/oauth/_provider/delete.js.map +1 -1
  230. package/dist/routes/api/terms/consent/post.d.ts.map +1 -1
  231. package/dist/routes/api/terms/consent/post.js +59 -43
  232. package/dist/routes/api/terms/consent/post.js.map +1 -1
  233. package/dist/routes/api/user/delete.d.ts.map +1 -1
  234. package/dist/routes/api/user/delete.js +8 -8
  235. package/dist/routes/api/user/delete.js.map +1 -1
  236. package/dist/routes/api/user/passkeys/_id/delete.d.ts.map +1 -1
  237. package/dist/routes/api/user/passkeys/_id/delete.js +17 -29
  238. package/dist/routes/api/user/passkeys/_id/delete.js.map +1 -1
  239. package/dist/routes/api/user/passkeys/_id/patch.d.ts.map +1 -1
  240. package/dist/routes/api/user/passkeys/_id/patch.js +16 -13
  241. package/dist/routes/api/user/passkeys/_id/patch.js.map +1 -1
  242. package/dist/routes/api/user/passkeys/register/verify/post.d.ts.map +1 -1
  243. package/dist/routes/api/user/passkeys/register/verify/post.js +27 -19
  244. package/dist/routes/api/user/passkeys/register/verify/post.js.map +1 -1
  245. package/dist/routes/api/user/password/delete.d.ts.map +1 -1
  246. package/dist/routes/api/user/password/delete.js +13 -10
  247. package/dist/routes/api/user/password/delete.js.map +1 -1
  248. package/dist/routes/api/user/password/post.d.ts.map +1 -1
  249. package/dist/routes/api/user/password/post.js +13 -10
  250. package/dist/routes/api/user/password/post.js.map +1 -1
  251. package/dist/routes/api/user/password/put.d.ts.map +1 -1
  252. package/dist/routes/api/user/password/put.js +13 -10
  253. package/dist/routes/api/user/password/put.js.map +1 -1
  254. package/dist/routes/api/user/totp/confirm/post.d.ts.map +1 -1
  255. package/dist/routes/api/user/totp/confirm/post.js +33 -18
  256. package/dist/routes/api/user/totp/confirm/post.js.map +1 -1
  257. package/dist/routes/api/user/totp/delete.d.ts.map +1 -1
  258. package/dist/routes/api/user/totp/delete.js +13 -18
  259. package/dist/routes/api/user/totp/delete.js.map +1 -1
  260. package/dist/routes/api/user/totp/recovery/regenerate/post.d.ts.map +1 -1
  261. package/dist/routes/api/user/totp/recovery/regenerate/post.js +13 -10
  262. package/dist/routes/api/user/totp/recovery/regenerate/post.js.map +1 -1
  263. package/dist/routes/api/user/totp/setup/post.d.ts.map +1 -1
  264. package/dist/routes/api/user/totp/setup/post.js +13 -8
  265. package/dist/routes/api/user/totp/setup/post.js.map +1 -1
  266. package/dist/routes/api/user/totp/verify/post.d.ts.map +1 -1
  267. package/dist/routes/api/user/totp/verify/post.js +23 -12
  268. package/dist/routes/api/user/totp/verify/post.js.map +1 -1
  269. package/dist/routes/index.d.ts +224 -214
  270. package/dist/routes/index.d.ts.map +1 -1
  271. package/dist/routes/oauth/authorize/get.d.ts.map +1 -1
  272. package/dist/routes/oauth/authorize/get.js +12 -4
  273. package/dist/routes/oauth/authorize/get.js.map +1 -1
  274. package/dist/routes/oauth/device/get-post.d.ts +10 -0
  275. package/dist/routes/oauth/device/get-post.d.ts.map +1 -1
  276. package/dist/routes/oauth/device/get-post.js +32 -3
  277. package/dist/routes/oauth/device/get-post.js.map +1 -1
  278. package/dist/routes/oauth/device-authorization/post.d.ts.map +1 -1
  279. package/dist/routes/oauth/device-authorization/post.js +13 -7
  280. package/dist/routes/oauth/device-authorization/post.js.map +1 -1
  281. package/dist/routes/oauth/end-session/get.d.ts +9 -9
  282. package/dist/routes/oauth/end-session/get.d.ts.map +1 -1
  283. package/dist/routes/oauth/end-session/get.js +2 -3
  284. package/dist/routes/oauth/end-session/get.js.map +1 -1
  285. package/dist/routes/oauth/index.d.ts +10 -0
  286. package/dist/routes/oauth/index.d.ts.map +1 -1
  287. package/dist/routes/oauth/revoke/post.d.ts.map +1 -1
  288. package/dist/routes/oauth/revoke/post.js +10 -2
  289. package/dist/routes/oauth/revoke/post.js.map +1 -1
  290. package/dist/routes/oauth/token/post.d.ts.map +1 -1
  291. package/dist/routes/oauth/token/post.js +69 -57
  292. package/dist/routes/oauth/token/post.js.map +1 -1
  293. package/dist/schemas/error.d.ts +75 -0
  294. package/dist/schemas/error.d.ts.map +1 -1
  295. package/dist/schemas/error.js +3 -0
  296. package/dist/schemas/error.js.map +1 -1
  297. package/dist/schemas/field.d.ts.map +1 -1
  298. package/dist/schemas/field.js +3 -0
  299. package/dist/schemas/field.js.map +1 -1
  300. package/dist/seeders/config.seeder.d.ts +1 -1
  301. package/dist/seeders/config.seeder.d.ts.map +1 -1
  302. package/dist/seeders/config.seeder.js +100 -36
  303. package/dist/seeders/config.seeder.js.map +1 -1
  304. package/dist/services/admin-console.service.d.ts.map +1 -1
  305. package/dist/services/admin-console.service.js +137 -100
  306. package/dist/services/admin-console.service.js.map +1 -1
  307. package/dist/services/auth-budget.service.d.ts +6 -0
  308. package/dist/services/auth-budget.service.d.ts.map +1 -0
  309. package/dist/services/auth-budget.service.js +30 -0
  310. package/dist/services/auth-budget.service.js.map +1 -0
  311. package/dist/services/authentication-epoch.d.ts +5 -0
  312. package/dist/services/authentication-epoch.d.ts.map +1 -0
  313. package/dist/services/authentication-epoch.js +22 -0
  314. package/dist/services/authentication-epoch.js.map +1 -0
  315. package/dist/services/authorization-browser.service.d.ts +18 -0
  316. package/dist/services/authorization-browser.service.d.ts.map +1 -0
  317. package/dist/services/authorization-browser.service.js +28 -0
  318. package/dist/services/authorization-browser.service.js.map +1 -0
  319. package/dist/services/browser-security.service.d.ts +14 -0
  320. package/dist/services/browser-security.service.d.ts.map +1 -0
  321. package/dist/services/browser-security.service.js +85 -0
  322. package/dist/services/browser-security.service.js.map +1 -0
  323. package/dist/services/browser-session.service.d.ts +25 -0
  324. package/dist/services/browser-session.service.d.ts.map +1 -0
  325. package/dist/services/browser-session.service.js +102 -0
  326. package/dist/services/browser-session.service.js.map +1 -0
  327. package/dist/services/cleanup.service.d.ts +1 -0
  328. package/dist/services/cleanup.service.d.ts.map +1 -1
  329. package/dist/services/cleanup.service.js +31 -0
  330. package/dist/services/cleanup.service.js.map +1 -1
  331. package/dist/services/client-security.d.ts +641 -0
  332. package/dist/services/client-security.d.ts.map +1 -0
  333. package/dist/services/client-security.js +10 -0
  334. package/dist/services/client-security.js.map +1 -0
  335. package/dist/services/container.d.ts +2 -0
  336. package/dist/services/container.d.ts.map +1 -1
  337. package/dist/services/container.js +6 -2
  338. package/dist/services/container.js.map +1 -1
  339. package/dist/services/email.service.d.ts +2 -14
  340. package/dist/services/email.service.d.ts.map +1 -1
  341. package/dist/services/email.service.js +35 -29
  342. package/dist/services/email.service.js.map +1 -1
  343. package/dist/services/jwt.service.d.ts +1 -0
  344. package/dist/services/jwt.service.d.ts.map +1 -1
  345. package/dist/services/jwt.service.js +13 -1
  346. package/dist/services/jwt.service.js.map +1 -1
  347. package/dist/services/mail-queue.service.d.ts +24 -0
  348. package/dist/services/mail-queue.service.d.ts.map +1 -0
  349. package/dist/services/mail-queue.service.js +223 -0
  350. package/dist/services/mail-queue.service.js.map +1 -0
  351. package/dist/services/mikro.service.d.ts.map +1 -1
  352. package/dist/services/mikro.service.js +2 -0
  353. package/dist/services/mikro.service.js.map +1 -1
  354. package/dist/services/oauth-authorize.service.d.ts +3 -0
  355. package/dist/services/oauth-authorize.service.d.ts.map +1 -1
  356. package/dist/services/oauth-authorize.service.js +131 -101
  357. package/dist/services/oauth-authorize.service.js.map +1 -1
  358. package/dist/services/oauth-browser-security.service.d.ts +7 -0
  359. package/dist/services/oauth-browser-security.service.d.ts.map +1 -0
  360. package/dist/services/oauth-browser-security.service.js +67 -0
  361. package/dist/services/oauth-browser-security.service.js.map +1 -0
  362. package/dist/services/oauth-client.service.d.ts +24 -1
  363. package/dist/services/oauth-client.service.d.ts.map +1 -1
  364. package/dist/services/oauth-client.service.js +52 -13
  365. package/dist/services/oauth-client.service.js.map +1 -1
  366. package/dist/services/oauth-connect.service.d.ts +37 -3
  367. package/dist/services/oauth-connect.service.d.ts.map +1 -1
  368. package/dist/services/oauth-connect.service.js +236 -212
  369. package/dist/services/oauth-connect.service.js.map +1 -1
  370. package/dist/services/oauth-token.service.d.ts +6 -4
  371. package/dist/services/oauth-token.service.d.ts.map +1 -1
  372. package/dist/services/oauth-token.service.js +295 -209
  373. package/dist/services/oauth-token.service.js.map +1 -1
  374. package/dist/services/passkey.service.d.ts +26 -7
  375. package/dist/services/passkey.service.d.ts.map +1 -1
  376. package/dist/services/passkey.service.js +71 -42
  377. package/dist/services/passkey.service.js.map +1 -1
  378. package/dist/services/password-auth.service.d.ts +5 -1
  379. package/dist/services/password-auth.service.d.ts.map +1 -1
  380. package/dist/services/password-auth.service.js +79 -52
  381. package/dist/services/password-auth.service.js.map +1 -1
  382. package/dist/services/password-reset.service.d.ts.map +1 -1
  383. package/dist/services/password-reset.service.js +34 -15
  384. package/dist/services/password-reset.service.js.map +1 -1
  385. package/dist/services/security.service.d.ts +3 -1
  386. package/dist/services/security.service.d.ts.map +1 -1
  387. package/dist/services/security.service.js +11 -2
  388. package/dist/services/security.service.js.map +1 -1
  389. package/dist/services/terms-policy.service.d.ts +7 -0
  390. package/dist/services/terms-policy.service.d.ts.map +1 -0
  391. package/dist/services/terms-policy.service.js +26 -0
  392. package/dist/services/terms-policy.service.js.map +1 -0
  393. package/dist/services/totp.service.d.ts +4 -5
  394. package/dist/services/totp.service.d.ts.map +1 -1
  395. package/dist/services/totp.service.js +116 -86
  396. package/dist/services/totp.service.js.map +1 -1
  397. package/dist/services/user-security.service.d.ts +15 -0
  398. package/dist/services/user-security.service.d.ts.map +1 -0
  399. package/dist/services/user-security.service.js +57 -0
  400. package/dist/services/user-security.service.js.map +1 -0
  401. package/dist/services/user.service.d.ts +6 -4
  402. package/dist/services/user.service.d.ts.map +1 -1
  403. package/dist/services/user.service.js +143 -121
  404. package/dist/services/user.service.js.map +1 -1
  405. package/frontend/client/assets/{auth-layout-BedWIZ7L.js → auth-layout-sea6nww4.js} +1 -1
  406. package/frontend/client/assets/{auth-page-header-C6Z6Air-.js → auth-page-header-CV85AJLW.js} +1 -1
  407. package/frontend/client/assets/document-navigation-FZbb5ldf.js +1 -0
  408. package/frontend/client/assets/i18n-vfKY-byx.js +1 -0
  409. package/frontend/client/assets/{language-selector-CeLHnp1n.js → language-selector-Jso2cQNI.js} +1 -1
  410. package/frontend/client/assets/manifest-90703545.js +1 -0
  411. package/frontend/client/assets/{passkey-Bkqvhjwb.js → passkey-CJhT-7yO.js} +1 -1
  412. package/frontend/client/assets/{promise-CepnkPDw.js → promise-BP9iSIs-.js} +1 -1
  413. package/frontend/client/assets/{root-CM8lJbh5.js → root-BkavuloG.js} +1 -1
  414. package/frontend/client/assets/{route-Y1_yJKhW.js → route-B0udr9eT.js} +1 -1
  415. package/frontend/client/assets/{route-CdPHVY9W.js → route-B3Uv9aTa.js} +1 -1
  416. package/frontend/client/assets/{route-CF1S7UUy.js → route-B6hIfgxz.js} +1 -1
  417. package/frontend/client/assets/{route-BcXtt6V2.js → route-BEWds2g-.js} +1 -1
  418. package/frontend/client/assets/route-Bm9LsorH.js +1 -0
  419. package/frontend/client/assets/route-Btv5Y69z.js +1 -0
  420. package/frontend/client/assets/route-BvyDzziE.js +1 -0
  421. package/frontend/client/assets/route-C6kG9u7j.js +1 -0
  422. package/frontend/client/assets/{route-1rid8j-3.js → route-C7C3Z0vI.js} +1 -1
  423. package/frontend/client/assets/{route-DphbGk_G.js → route-CVyefM3x.js} +1 -1
  424. package/frontend/client/assets/{route-DZvCkU11.js → route-CXth2Wqz.js} +1 -1
  425. package/frontend/client/assets/route-D0IqOurp.js +1 -0
  426. package/frontend/client/assets/route-DHmYUnJR.js +1 -0
  427. package/frontend/client/assets/route-DTjZQ_Fl.js +1 -0
  428. package/frontend/client/assets/route-D_dTeu1b.js +1 -0
  429. package/frontend/client/assets/{route-DkoXJmYM.js → route-Dj8gVemC.js} +1 -1
  430. package/frontend/client/assets/{route-DrtpzI6u.js → route-DnhPlHOi.js} +1 -1
  431. package/frontend/client/assets/route-FY92YQhF.js +1 -0
  432. package/frontend/client/assets/{route-CKiun7AR.js → route-PcLpZHbT.js} +1 -1
  433. package/frontend/client/assets/{route-BwhQptmx.js → route-qpE7i22X.js} +1 -1
  434. package/frontend/client/assets/{route-HA9dma-h.js → route-wK89gmoS.js} +1 -1
  435. package/frontend/client/assets/security-error-message-CMsTsiWf.js +1 -0
  436. package/frontend/client/assets/{shell-header-bar-CjPlfRKT.js → shell-header-bar-DRx10tE5.js} +1 -1
  437. package/frontend/client/assets/{terms-BGJD_l_i.js → terms-Bu9Itxxs.js} +1 -1
  438. package/frontend/client/assets/{use-totp-setup-Cwuds2tR.js → use-totp-setup-CoOXWOcT.js} +1 -1
  439. package/frontend/server/assets/{hydration-B63_G0fd.js → hydration-DWMjpNav.js} +1 -1
  440. package/frontend/server/assets/{root-loader.server-DUIBlg_3.js → root-loader.server-B4OqoLGG.js} +3 -3
  441. package/frontend/server/assets/{route-runtime.server-DiqwWb8W.js → route-runtime.server-03_pjVDT.js} +1 -1
  442. package/frontend/server/assets/{session-BaAt7WMI.js → session-sJkmzJie.js} +36 -24
  443. package/frontend/server/index.js +239 -193
  444. package/package.json +1 -1
  445. package/frontend/client/assets/document-navigation-Cnp3Alf0.js +0 -1
  446. package/frontend/client/assets/i18n-Dzv9HKFm.js +0 -1
  447. package/frontend/client/assets/manifest-71025d92.js +0 -1
  448. package/frontend/client/assets/route-B4jDMFTW.js +0 -1
  449. package/frontend/client/assets/route-C-DecXPL.js +0 -1
  450. package/frontend/client/assets/route-CGTMMDiX.js +0 -1
  451. package/frontend/client/assets/route-CMJbXiDe.js +0 -1
  452. package/frontend/client/assets/route-DBpAiakW.js +0 -1
  453. package/frontend/client/assets/route-DS92RKs5.js +0 -1
  454. package/frontend/client/assets/route-Dc6G2aDX.js +0 -1
  455. package/frontend/client/assets/route-DqAmRSJE.js +0 -1
  456. package/frontend/client/assets/route-Ezzcj26w.js +0 -1
@@ -258,6 +258,16 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
258
258
  } & {
259
259
  "/device": {
260
260
  $post: {
261
+ output: undefined;
262
+ outputFormat: "redirect";
263
+ status: 303;
264
+ input: {
265
+ form: {
266
+ user_code: import("hono/types").ParsedFormValue[] | import("hono/types").ParsedFormValue;
267
+ decision?: "approve" | "deny" | undefined;
268
+ };
269
+ };
270
+ } | {
261
271
  output: {
262
272
  status: string;
263
273
  client_id: string;
@@ -305,10 +315,34 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
305
315
  };
306
316
  };
307
317
  }, "/">, "/oauth"> | import("hono/types").MergeSchemaPath<import("hono/types").BlankSchema | import("hono/types").MergeSchemaPath<import("hono/types").BlankSchema, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
308
- "/auth/accounts/remove": {
318
+ "/admin/me": {
319
+ $get: {
320
+ output: {
321
+ user: {
322
+ managed_by: "config" | "database";
323
+ sub: string;
324
+ email: string;
325
+ role: "admin" | "user";
326
+ email_verified: boolean;
327
+ email_verification_required: boolean;
328
+ has_password: boolean;
329
+ totp_registered: boolean;
330
+ totp_recovery_codes_missing: boolean;
331
+ second_factor_required: boolean;
332
+ passkey_count: number;
333
+ };
334
+ };
335
+ outputFormat: "json";
336
+ status: 200;
337
+ input: {};
338
+ };
339
+ };
340
+ }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
341
+ "/auth/accounts/select": {
309
342
  $post: {
310
343
  output: {
311
344
  ok: true;
345
+ active_sub: string;
312
346
  };
313
347
  outputFormat: "json";
314
348
  status: 200;
@@ -332,54 +366,34 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
332
366
  };
333
367
  };
334
368
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
335
- "/auth/login": {
369
+ "/auth/logout": {
336
370
  $post: {
337
371
  output: {
338
- user: {
339
- managed_by: "config" | "database";
340
- sub: string;
341
- email: string;
342
- role: "admin" | "user";
343
- email_verified: boolean;
344
- email_verification_required: boolean;
345
- has_password: boolean;
346
- totp_registered: boolean;
347
- totp_recovery_codes_missing: boolean;
348
- second_factor_required: boolean;
349
- passkey_count: number;
350
- };
372
+ ok: true;
351
373
  };
352
374
  outputFormat: "json";
353
375
  status: 200;
354
- input: {
355
- json: {
356
- email: string;
357
- password: string;
358
- };
359
- };
376
+ input: {};
360
377
  };
361
378
  };
362
379
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
363
- "/auth/password/forgot": {
380
+ "/auth/password/reset": {
364
381
  $post: {
365
382
  output: {
366
- ok: true;
383
+ message: string;
367
384
  };
368
385
  outputFormat: "json";
369
386
  status: 200;
370
387
  input: {
371
- header: {
372
- 'accept-language'?: string | undefined;
373
- };
374
- } & {
375
388
  json: {
376
- email: string;
389
+ token: string;
390
+ password: string;
377
391
  };
378
392
  };
379
393
  };
380
394
  };
381
395
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
382
- "/auth/totp/recovery/verify": {
396
+ "/auth/totp/verify": {
383
397
  $post: {
384
398
  output: {
385
399
  user: {
@@ -406,154 +420,36 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
406
420
  };
407
421
  };
408
422
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
409
- "/config": {
423
+ "/docs": {
410
424
  $get: {
411
- output: {
412
- i18n: {
413
- supported_languages: string[];
414
- default_language: string;
415
- fallback_language: string;
416
- };
417
- branding: {
418
- icon_url?: string | undefined;
419
- logo_url?: string | undefined;
420
- title: {
421
- [x: string]: string;
422
- };
423
- subtitle: {
424
- [x: string]: string;
425
- };
426
- login_method_description: {
427
- [x: string]: string;
428
- };
429
- };
430
- registration: {
431
- public_registration: boolean;
432
- email_pattern_filter_enabled: boolean;
433
- email_verification_required: boolean;
434
- signup_notice?: {
435
- [x: string]: string;
436
- } | undefined;
437
- };
438
- database: {
439
- enabled: boolean;
440
- };
441
- email: {
442
- enabled: boolean;
443
- };
444
- admin: {
445
- enabled: boolean;
446
- };
447
- auth: {
448
- password: {
449
- enabled: boolean;
450
- two_factor: {
451
- enrollment_required: boolean;
452
- };
453
- totp: {
454
- enabled: boolean;
455
- issuer: string;
456
- };
457
- policy: {
458
- min_length: number;
459
- max_length: number;
460
- };
461
- };
462
- passkey: {
463
- enabled: boolean;
464
- rp_id?: string | undefined;
465
- origins?: string[] | undefined;
466
- };
467
- };
468
- identity_providers: {
469
- id: string;
470
- type: "apple" | "generic_oauth" | "github" | "google";
471
- display_name: string;
472
- icon_url?: string | undefined;
473
- }[];
474
- account_deletion: {
475
- enabled: boolean;
476
- retention: string;
477
- };
478
- };
479
- outputFormat: "json";
480
- status: 200;
425
+ output: {};
426
+ outputFormat: string;
427
+ status: import("hono/utils/http-status").StatusCode;
481
428
  input: {};
482
429
  };
483
430
  };
484
431
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
485
- "/consent": {
432
+ "/health/ready": {
486
433
  $get: {
487
434
  output: {
488
- client: {
489
- id: string;
490
- clientId: string;
491
- name: string;
492
- };
493
- scopes: {
494
- name: string;
495
- description: string;
496
- }[];
497
- user: {
498
- sub: import("@mikro-orm/core").Opt<string>;
499
- email: string;
435
+ status: 'ok';
436
+ checks: {
437
+ database: 'ok';
500
438
  };
501
439
  };
502
440
  outputFormat: "json";
503
441
  status: 200;
504
- input: {
505
- query: {
506
- client_id: string | string[];
507
- redirect_uri: string | string[];
508
- response_type: string | string[];
509
- prompt?: string | undefined;
510
- scope?: string | undefined;
511
- };
512
- };
513
- };
514
- };
515
- }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
516
- "/consent": {
517
- $post: {
442
+ input: {};
443
+ } | {
518
444
  output: {
519
- redirect_url: string;
520
- };
521
- outputFormat: "json";
522
- status: 200;
523
- input: {
524
- json: {
525
- client_id: string;
526
- redirect_uri: string;
527
- response_type: string;
528
- scope?: string | undefined;
529
- state?: string | undefined;
530
- nonce?: string | undefined;
531
- code_challenge?: string | undefined;
532
- code_challenge_method?: "S256" | "plain" | undefined;
533
- prompt?: string | undefined;
534
- max_age?: unknown;
535
- reauthenticated?: "1" | undefined;
536
- display?: "page" | "popup" | "touch" | "wap" | undefined;
537
- response_mode?: "form_post" | "fragment" | "query" | undefined;
538
- login_hint?: string | undefined;
539
- ui_locales?: string | undefined;
540
- id_token_hint?: string | undefined;
541
- acr_values?: string | undefined;
542
- account_selected?: unknown;
543
- account_selection_state?: string | undefined;
544
- decision: "allow" | "deny";
445
+ status: 'error';
446
+ checks: {
447
+ database: "error";
545
448
  };
546
- };
547
- };
548
- };
549
- }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
550
- "/health/live": {
551
- $get: {
552
- output: {
553
- status: 'ok';
449
+ error: string | undefined;
554
450
  };
555
451
  outputFormat: "json";
556
- status: 200;
452
+ status: 503;
557
453
  input: {};
558
454
  };
559
455
  };
@@ -1154,29 +1050,6 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
1154
1050
  };
1155
1051
  };
1156
1052
  };
1157
- }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1158
- "/admin/me": {
1159
- $get: {
1160
- output: {
1161
- user: {
1162
- managed_by: "config" | "database";
1163
- sub: string;
1164
- email: string;
1165
- role: "admin" | "user";
1166
- email_verified: boolean;
1167
- email_verification_required: boolean;
1168
- has_password: boolean;
1169
- totp_registered: boolean;
1170
- totp_recovery_codes_missing: boolean;
1171
- second_factor_required: boolean;
1172
- passkey_count: number;
1173
- };
1174
- };
1175
- outputFormat: "json";
1176
- status: 200;
1177
- input: {};
1178
- };
1179
- };
1180
1053
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1181
1054
  "/auth/accounts": {
1182
1055
  $get: {
@@ -1203,11 +1076,10 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
1203
1076
  };
1204
1077
  };
1205
1078
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1206
- "/auth/accounts/select": {
1079
+ "/auth/accounts/remove": {
1207
1080
  $post: {
1208
1081
  output: {
1209
1082
  ok: true;
1210
- active_sub: string;
1211
1083
  };
1212
1084
  outputFormat: "json";
1213
1085
  status: 200;
@@ -1242,14 +1114,31 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
1242
1114
  };
1243
1115
  };
1244
1116
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1245
- "/auth/logout": {
1117
+ "/auth/login": {
1246
1118
  $post: {
1247
1119
  output: {
1248
- ok: true;
1120
+ user: {
1121
+ managed_by: "config" | "database";
1122
+ sub: string;
1123
+ email: string;
1124
+ role: "admin" | "user";
1125
+ email_verified: boolean;
1126
+ email_verification_required: boolean;
1127
+ has_password: boolean;
1128
+ totp_registered: boolean;
1129
+ totp_recovery_codes_missing: boolean;
1130
+ second_factor_required: boolean;
1131
+ passkey_count: number;
1132
+ };
1249
1133
  };
1250
1134
  outputFormat: "json";
1251
1135
  status: 200;
1252
- input: {};
1136
+ input: {
1137
+ json: {
1138
+ email: string;
1139
+ password: string;
1140
+ };
1141
+ };
1253
1142
  };
1254
1143
  };
1255
1144
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
@@ -1290,17 +1179,20 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
1290
1179
  };
1291
1180
  };
1292
1181
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1293
- "/auth/password/reset": {
1182
+ "/auth/password/forgot": {
1294
1183
  $post: {
1295
1184
  output: {
1296
- message: string;
1185
+ ok: true;
1297
1186
  };
1298
1187
  outputFormat: "json";
1299
1188
  status: 200;
1300
1189
  input: {
1190
+ header: {
1191
+ 'accept-language'?: string | undefined;
1192
+ };
1193
+ } & {
1301
1194
  json: {
1302
- token: string;
1303
- password: string;
1195
+ email: string;
1304
1196
  };
1305
1197
  };
1306
1198
  };
@@ -1352,7 +1244,7 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
1352
1244
  };
1353
1245
  };
1354
1246
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1355
- "/auth/totp/verify": {
1247
+ "/auth/totp/recovery/verify": {
1356
1248
  $post: {
1357
1249
  output: {
1358
1250
  user: {
@@ -1570,14 +1462,146 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
1570
1462
  };
1571
1463
  };
1572
1464
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1573
- "/docs": {
1465
+ "/config": {
1574
1466
  $get: {
1575
- output: {};
1576
- outputFormat: string;
1577
- status: import("hono/utils/http-status").StatusCode;
1467
+ output: {
1468
+ i18n: {
1469
+ supported_languages: string[];
1470
+ default_language: string;
1471
+ fallback_language: string;
1472
+ };
1473
+ branding: {
1474
+ icon_url?: string | undefined;
1475
+ logo_url?: string | undefined;
1476
+ title: {
1477
+ [x: string]: string;
1478
+ };
1479
+ subtitle: {
1480
+ [x: string]: string;
1481
+ };
1482
+ login_method_description: {
1483
+ [x: string]: string;
1484
+ };
1485
+ };
1486
+ registration: {
1487
+ public_registration: boolean;
1488
+ email_pattern_filter_enabled: boolean;
1489
+ email_verification_required: boolean;
1490
+ signup_notice?: {
1491
+ [x: string]: string;
1492
+ } | undefined;
1493
+ };
1494
+ database: {
1495
+ enabled: boolean;
1496
+ };
1497
+ email: {
1498
+ enabled: boolean;
1499
+ };
1500
+ admin: {
1501
+ enabled: boolean;
1502
+ };
1503
+ auth: {
1504
+ password: {
1505
+ enabled: boolean;
1506
+ two_factor: {
1507
+ enrollment_required: boolean;
1508
+ };
1509
+ totp: {
1510
+ enabled: boolean;
1511
+ issuer: string;
1512
+ };
1513
+ policy: {
1514
+ min_length: number;
1515
+ max_length: number;
1516
+ };
1517
+ };
1518
+ passkey: {
1519
+ enabled: boolean;
1520
+ rp_id?: string | undefined;
1521
+ origins?: string[] | undefined;
1522
+ };
1523
+ };
1524
+ identity_providers: {
1525
+ id: string;
1526
+ type: "apple" | "generic_oauth" | "github" | "google";
1527
+ display_name: string;
1528
+ icon_url?: string | undefined;
1529
+ }[];
1530
+ account_deletion: {
1531
+ enabled: boolean;
1532
+ retention: string;
1533
+ };
1534
+ };
1535
+ outputFormat: "json";
1536
+ status: 200;
1578
1537
  input: {};
1579
1538
  };
1580
1539
  };
1540
+ }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1541
+ "/consent": {
1542
+ $get: {
1543
+ output: {
1544
+ client: {
1545
+ id: string;
1546
+ clientId: string;
1547
+ name: string;
1548
+ };
1549
+ scopes: {
1550
+ name: string;
1551
+ description: string;
1552
+ }[];
1553
+ user: {
1554
+ sub: import("@mikro-orm/core").Opt<string>;
1555
+ email: string;
1556
+ };
1557
+ };
1558
+ outputFormat: "json";
1559
+ status: 200;
1560
+ input: {
1561
+ query: {
1562
+ client_id: string | string[];
1563
+ redirect_uri: string | string[];
1564
+ response_type: string | string[];
1565
+ prompt?: string | undefined;
1566
+ scope?: string | undefined;
1567
+ };
1568
+ };
1569
+ };
1570
+ };
1571
+ }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1572
+ "/consent": {
1573
+ $post: {
1574
+ output: {
1575
+ redirect_url: string;
1576
+ };
1577
+ outputFormat: "json";
1578
+ status: 200;
1579
+ input: {
1580
+ json: {
1581
+ client_id: string;
1582
+ redirect_uri: string;
1583
+ response_type: string;
1584
+ scope?: string | undefined;
1585
+ state?: string | undefined;
1586
+ nonce?: string | undefined;
1587
+ code_challenge?: string | undefined;
1588
+ code_challenge_method?: "S256" | "plain" | undefined;
1589
+ prompt?: string | undefined;
1590
+ max_age?: unknown;
1591
+ reauthenticated?: "1" | undefined;
1592
+ display?: "page" | "popup" | "touch" | "wap" | undefined;
1593
+ response_mode?: "form_post" | "fragment" | "query" | undefined;
1594
+ login_hint?: string | undefined;
1595
+ ui_locales?: string | undefined;
1596
+ id_token_hint?: string | undefined;
1597
+ acr_values?: string | undefined;
1598
+ account_selected?: unknown;
1599
+ account_selection_state?: string | undefined;
1600
+ decision: "allow" | "deny";
1601
+ };
1602
+ };
1603
+ };
1604
+ };
1581
1605
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1582
1606
  "/health": {
1583
1607
  $get: {
@@ -1606,28 +1630,14 @@ export declare const routes: import("hono/hono-base").HonoBase<AppEnv, import("h
1606
1630
  };
1607
1631
  };
1608
1632
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
1609
- "/health/ready": {
1633
+ "/health/live": {
1610
1634
  $get: {
1611
1635
  output: {
1612
1636
  status: 'ok';
1613
- checks: {
1614
- database: 'ok';
1615
- };
1616
1637
  };
1617
1638
  outputFormat: "json";
1618
1639
  status: 200;
1619
1640
  input: {};
1620
- } | {
1621
- output: {
1622
- status: 'error';
1623
- checks: {
1624
- database: "error";
1625
- };
1626
- error: string | undefined;
1627
- };
1628
- outputFormat: "json";
1629
- status: 503;
1630
- input: {};
1631
1641
  };
1632
1642
  };
1633
1643
  }, "/">, "/"> | import("hono/types").MergeSchemaPath<import("hono/types").MergeSchemaPath<{
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/routes/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAKhD,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iCAGsB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../../../src/routes/oauth/authorize/get.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AAUtD,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBAoQxB,CAAC"}
1
+ {"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../../../src/routes/oauth/authorize/get.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AActD,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBAiRxB,CAAC"}
@@ -2,17 +2,18 @@ import { Hono } from 'hono';
2
2
  import { describeRoute, resolver, validator } from 'hono-openapi';
3
3
  import { z } from 'zod';
4
4
  import { escapeHtml } from '../../../lib/escape-html.js';
5
- import { OPENAPI_SECURITY } from '../../../lib/openapi.js';
5
+ import { OPENAPI_SECURITY, securityMutationDocumentation, } from '../../../lib/openapi.js';
6
6
  import { TAGS } from '../../../lib/swagger-tags.js';
7
7
  import { verifyAuth } from '../../../middleware/auth.js';
8
8
  import { e } from '../../../schemas/error.js';
9
9
  import { f } from '../../../schemas/field.js';
10
10
  import { r } from '../../../schemas/response.js';
11
+ import { completeBrowserAuthorization } from '../../../services/authorization-browser.service.js';
11
12
  export const authorizeGet = new Hono().get('/authorize', describeRoute({
12
13
  tags: [TAGS.OPENID],
13
14
  security: OPENAPI_SECURITY.optionalCookieSession,
14
15
  summary: 'Authorize',
15
- description: 'OAuth2 Authorization Endpoint',
16
+ description: 'OAuth2 Authorization Endpoint. Grant issuance and browser session persistence commit atomically; revoked browser authentication returns 401 without authorization credentials. Final issuance rechecks current scope consent, consent exemption and mandatory terms under policy locks. Newly required consent or terms returns to the corresponding screen, or an OAuth interaction error for prompt=none, without issuing authorization credentials.',
16
17
  responses: {
17
18
  302: {
18
19
  description: 'Redirect',
@@ -66,7 +67,7 @@ export const authorizeGet = new Hono().get('/authorize', describeRoute({
66
67
  ui_locales: z.string().min(1).max(1000).optional(),
67
68
  id_token_hint: z.string().min(1).max(4000).optional(),
68
69
  acr_values: z.string().min(1).max(1000).optional(),
69
- })), verifyAuth({ optional: true }), async (c) => {
70
+ })), verifyAuth({ optional: true }), securityMutationDocumentation, async (c) => {
70
71
  const query = c.req.valid('query');
71
72
  const { oauthAuthorizeService } = c.var.services;
72
73
  // Helper function to redirect with error
@@ -125,7 +126,11 @@ export const authorizeGet = new Hono().get('/authorize', describeRoute({
125
126
  authorizeParams.setAccountSelectionSession = (state) => c.var.session.set('accountSelection', state);
126
127
  authorizeParams.setReauthenticationSession = (state) => c.var.session.set('reauthentication', state);
127
128
  authorizeParams.clearAccountSelectionSession = () => c.var.session.set('accountSelection', undefined);
128
- const result = await oauthAuthorizeService.authorize(authorizeParams);
129
+ const result = await oauthAuthorizeService.authorize({
130
+ ...authorizeParams,
131
+ completeAuthorization: (proof, operation) => completeBrowserAuthorization(c, proof, operation),
132
+ authenticationEpochs: c.var.session.authorization.security?.grants ?? {},
133
+ });
129
134
  if (result.type === 'form_post') {
130
135
  return c.html(buildFormPostResponse(result.url, result.params ?? {}));
131
136
  }
@@ -133,6 +138,9 @@ export const authorizeGet = new Hono().get('/authorize', describeRoute({
133
138
  return c.redirect(result.url);
134
139
  }
135
140
  catch (error) {
141
+ if (error instanceof e.Unauthorized.Error ||
142
+ error instanceof e.ConcurrentSecurityChange.Error)
143
+ throw error;
136
144
  // RFC 6749 §4.1.2.1: If client_id is invalid or redirect_uri validation fails,
137
145
  // do NOT redirect to the provided redirect_uri
138
146
  if (error instanceof e.OAuthClientNotFound.Error) {