failproofai 0.0.11-beta.2 → 0.0.11-beta.3
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.
- package/.next/standalone/.next/BUILD_ID +1 -1
- package/.next/standalone/.next/app-path-routes-manifest.json +8 -1
- package/.next/standalone/.next/build-manifest.json +10 -10
- package/.next/standalone/.next/prerender-manifest.json +3 -32
- package/.next/standalone/.next/required-server-files.json +2 -1
- package/.next/standalone/.next/routes-manifest.json +45 -3
- package/.next/standalone/.next/server/app/_global-error/page/build-manifest.json +7 -7
- package/.next/standalone/.next/server/app/_global-error/page/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/server/app/_global-error/page.js +6 -6
- package/.next/standalone/.next/server/app/_global-error/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_global-error.html +1 -1
- package/.next/standalone/.next/server/app/_global-error.rsc +7 -7
- package/.next/standalone/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +7 -7
- package/.next/standalone/.next/server/app/_global-error.segments/_head.segment.rsc +3 -3
- package/.next/standalone/.next/server/app/_global-error.segments/_index.segment.rsc +3 -3
- package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_not-found/page/build-manifest.json +7 -7
- package/.next/standalone/.next/server/app/_not-found/page/next-font-manifest.json +2 -6
- package/.next/standalone/.next/server/app/_not-found/page/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/server/app/_not-found/page.js +12 -13
- package/.next/standalone/.next/server/app/_not-found/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_not-found.html +1 -1
- package/.next/standalone/.next/server/app/_not-found.rsc +16 -16
- package/.next/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +16 -16
- package/.next/standalone/.next/server/app/_not-found.segments/_head.segment.rsc +4 -4
- package/.next/standalone/.next/server/app/_not-found.segments/_index.segment.rsc +10 -10
- package/.next/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/_not-found.segments/_not-found.segment.rsc +3 -3
- package/.next/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/api/audit/run/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/audit/run/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/audit/run/route.js +8 -0
- package/.next/standalone/.next/server/app/api/audit/run/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/audit/run/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/audit/status/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/audit/status/route/build-manifest.json +9 -0
- package/.next/standalone/.next/server/app/api/audit/status/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/audit/status/route.js +6 -0
- package/.next/standalone/.next/server/app/api/audit/status/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/audit/status/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/audit/status/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/auth/login-request/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/auth/login-request/route/build-manifest.json +9 -0
- package/.next/standalone/.next/server/app/api/auth/login-request/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/auth/login-request/route.js +6 -0
- package/.next/standalone/.next/server/app/api/auth/login-request/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/auth/login-request/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/auth/login-request/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/auth/login-verify/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/auth/login-verify/route/build-manifest.json +9 -0
- package/.next/standalone/.next/server/app/api/auth/login-verify/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/auth/login-verify/route.js +7 -0
- package/.next/standalone/.next/server/app/api/auth/login-verify/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/auth/login-verify/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/auth/login-verify/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/auth/logout/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/auth/logout/route/build-manifest.json +9 -0
- package/.next/standalone/.next/server/app/api/auth/logout/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/auth/logout/route.js +7 -0
- package/.next/standalone/.next/server/app/api/auth/logout/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/auth/logout/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/auth/logout/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/auth/reminder/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/auth/reminder/route/build-manifest.json +9 -0
- package/.next/standalone/.next/server/app/api/auth/reminder/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/auth/reminder/route.js +7 -0
- package/.next/standalone/.next/server/app/api/auth/reminder/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/auth/reminder/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/auth/reminder/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/auth/status/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/auth/status/route/build-manifest.json +9 -0
- package/.next/standalone/.next/server/app/api/auth/status/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/auth/status/route.js +7 -0
- package/.next/standalone/.next/server/app/api/auth/status/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/auth/status/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/auth/status/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/download/[project]/[session]/route.js +3 -3
- package/.next/standalone/.next/server/app/api/download/[project]/[session]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/audit/page/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/audit/page/build-manifest.json +18 -0
- package/.next/standalone/.next/server/app/audit/page/next-font-manifest.json +6 -0
- package/.next/standalone/.next/server/app/audit/page/react-loadable-manifest.json +1 -0
- package/.next/standalone/.next/server/app/audit/page/server-reference-manifest.json +29 -0
- package/.next/standalone/.next/server/app/audit/page.js +17 -0
- package/.next/standalone/.next/server/app/audit/page.js.map +5 -0
- package/.next/standalone/.next/server/app/audit/page.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/audit/page_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/index.html +1 -1
- package/.next/standalone/.next/server/app/index.rsc +16 -17
- package/.next/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/index.segments/_full.segment.rsc +16 -17
- package/.next/standalone/.next/server/app/index.segments/_head.segment.rsc +4 -4
- package/.next/standalone/.next/server/app/index.segments/_index.segment.rsc +10 -10
- package/.next/standalone/.next/server/app/index.segments/_tree.segment.rsc +2 -3
- package/.next/standalone/.next/server/app/page/build-manifest.json +7 -7
- package/.next/standalone/.next/server/app/page/next-font-manifest.json +2 -6
- package/.next/standalone/.next/server/app/page/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/server/app/page.js +14 -15
- package/.next/standalone/.next/server/app/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/policies/page/build-manifest.json +7 -7
- package/.next/standalone/.next/server/app/policies/page/next-font-manifest.json +2 -6
- package/.next/standalone/.next/server/app/policies/page/server-reference-manifest.json +8 -8
- package/.next/standalone/.next/server/app/policies/page.js +16 -16
- package/.next/standalone/.next/server/app/policies/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/policies/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/project/[name]/page/build-manifest.json +7 -7
- package/.next/standalone/.next/server/app/project/[name]/page/next-font-manifest.json +2 -6
- package/.next/standalone/.next/server/app/project/[name]/page/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/server/app/project/[name]/page.js +16 -17
- package/.next/standalone/.next/server/app/project/[name]/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/project/[name]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page/build-manifest.json +7 -7
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page/next-font-manifest.json +2 -6
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page/react-loadable-manifest.json +2 -2
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page/server-reference-manifest.json +2 -2
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page.js +19 -20
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/projects/page/build-manifest.json +7 -7
- package/.next/standalone/.next/server/app/projects/page/next-font-manifest.json +2 -6
- package/.next/standalone/.next/server/app/projects/page/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/server/app/projects/page.js +15 -16
- package/.next/standalone/.next/server/app/projects/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/projects/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app-paths-manifest.json +8 -1
- package/.next/standalone/.next/server/chunks/[externals]__14odj07._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[externals]__0z0j--b._.js → [externals]__1nl3dvw._.js} +1 -1
- package/.next/standalone/.next/server/chunks/{[externals]__0-p9.k~._.js → [externals]__1s61mel._.js} +1 -1
- package/.next/standalone/.next/server/chunks/{[externals]_node_os_06ur78j._.js → [externals]_node_os_0by37l-._.js} +1 -1
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__07tgnzi._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0kjo7d_._.js → [root-of-the-server]__0_0xu5z._.js} +2 -2
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0cag8qd._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0z-180.._.js → [root-of-the-server]__0cycwg6._.js} +2 -2
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__08px0ym._.js → [root-of-the-server]__0f7mikp._.js} +1 -1
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0oeun7z._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0q-v9z2._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0rv7m0k._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0g48iv.._.js → [root-of-the-server]__0sb_5m8._.js} +2 -2
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0j8-xkl._.js → [root-of-the-server]__0xuaoik._.js} +2 -2
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__12pit4m._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__13h8pzr._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__13ra2jq._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__17g9wh7._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0d_ob4n._.js → [root-of-the-server]__1_mqemn._.js} +2 -2
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1b9z5-i._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0vlhtkc._.js → [root-of-the-server]__1hgv_75._.js} +1 -1
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1ixjiy8._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0wu7fr7._.js → [root-of-the-server]__1jm9fw6._.js} +1 -1
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1legmza._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0fwb7ao._.js → [root-of-the-server]__1m2_4t0._.js} +2 -2
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0yfq1yr._.js → [root-of-the-server]__1mhmdzs._.js} +1 -1
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0zso~62._.js → [root-of-the-server]__1ou2ehh._.js} +1 -1
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1qxztj-._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1rhmvod._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0.~nmr9._.js → [root-of-the-server]__1w9zl9-._.js} +1 -1
- package/.next/standalone/.next/server/chunks/{_0ebx_lc._.js → _0p53ge1._.js} +2 -2
- package/.next/standalone/.next/server/chunks/_1-1804f._.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_audit_run_route_actions_1qgp9io.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_audit_status_route_actions_1f7pjof.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_auth_login-request_route_actions_1c49co0.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_auth_login-verify_route_actions_1r3slzk.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_auth_logout_route_actions_0regwyr.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_auth_reminder_route_actions_1kjgxf8.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_auth_status_route_actions_1aho9zu.js +3 -0
- package/.next/standalone/.next/server/chunks/{_next-internal_server_app_api_download_[project]_[session]_route_actions_0wb00i-.js → _next-internal_server_app_api_download_[project]_[session]_route_actions_1is7vs7.js} +1 -1
- package/.next/standalone/.next/server/chunks/{lib_logger_ts_047tt9f._.js → lib_logger_ts_07e65t5._.js} +1 -1
- package/.next/standalone/.next/server/chunks/node_modules_next_dist_esm_build_templates_app-route_17k9e3w.js +23 -0
- package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_01r25oi._.js +3 -0
- package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_09z9-p7._.js +3 -0
- package/.next/standalone/.next/server/chunks/{package_json_[json]_cjs_0z7w.hh._.js → package_json_[json]_cjs_1nxcc4v._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/{[externals]__12dv.x0._.js → [externals]__1_g_b3t._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{[externals]_node_async_hooks_0v0ln8c._.js → [externals]_node_async_hooks_1gjz99j._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__00jkjmt._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__013du6r._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0989_dx._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0e85wxv._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0gfxvb1._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0h12me5._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0l13qf2._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0ts150~._.js → [root-of-the-server]__0ywoypf._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1-scthx._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__100hdar._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__11rtg6s._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__14dd6h8._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1cd25c7._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0t5l7a5._.js → [root-of-the-server]__1d8omgc._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0tcyn68._.js → [root-of-the-server]__1dky4g0._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__098zro9._.js → [root-of-the-server]__1fax1sl._.js} +4 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1hlrq6y._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1ihxdo5._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1mt35_w._.js +221 -0
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0-wn51s._.js → [root-of-the-server]__1pcxxwg._.js} +3 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1usf8v2._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1vvfde2._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__212nf49._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{_03d7qyt._.js → _05whahf._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_11_p9y8._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{_0xb8ngh._.js → _1kje4fm._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{_0zx~s__._.js → _1p0-leb._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{app_04qfs8z._.js → app_087bt9w._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{app_0uosk1e._.js → app_1fvisnp._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{app_13f0ohr._.js → app_209u41o._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_audit__components_audit-dashboard_tsx_0p9ud47._.js +43 -0
- package/.next/standalone/.next/server/chunks/ssr/app_audit_loading_tsx_1j1kc6j._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{app_error_tsx_11t4ysq._.js → app_error_tsx_1zds1ns._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{app_global-error_tsx_0m9qisk._.js → app_global-error_tsx_113y3za._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_global-error_tsx_1kp6l3x._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/app_policies_hooks-client_tsx_19dqvpc._.js +8 -0
- package/.next/standalone/.next/server/chunks/ssr/{app_project_[name]_error_tsx_0.9-fod._.js → app_project_[name]_error_tsx_1v02_5n._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{app_project_[name]_loading_tsx_03g9xy0._.js → app_project_[name]_loading_tsx_05-l4uf._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{app_project_[name]_session_[sessionId]_error_tsx_0ler-mr._.js → app_project_[name]_session_[sessionId]_error_tsx_0-lj3nd._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{app_project_[name]_session_[sessionId]_loading_tsx_0c0e3yx._.js → app_project_[name]_session_[sessionId]_loading_tsx_0l4aixs._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_projects_loading_tsx_20-3u8b._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{lib_codex-projects_ts_0eosib~._.js → lib_codex-projects_ts_0pqlw37._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{lib_copilot-projects_ts_0r8xkn8._.js → lib_copilot-projects_ts_19wl7tp._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{lib_cursor-projects_ts_0qt1scg._.js → lib_cursor-projects_ts_18-iwyk._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{lib_gemini-projects_ts_0sl~yqr._.js → lib_gemini-projects_ts_1c7bgx-._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{lib_opencode-projects_ts_0op9gyp._.js → lib_opencode-projects_ts_15bjxkm._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{lib_pi-projects_ts_103tsh1._.js → lib_pi-projects_ts_1wikofb._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{lib_utils_ts_068jk73._.js → lib_utils_ts_0az0sfq._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/node_modules_1ynf7el._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/node_modules_html2canvas_dist_html2canvas_esm_05gja40.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/node_modules_html2canvas_dist_html2canvas_esm_1n-0xws.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{node_modules_next_0rd0oc-._.js → node_modules_next_1a1kch7._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{node_modules_next_dist_0h9llsw._.js → node_modules_next_dist_0uboya6._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/{node_modules_next_dist_11dij6w._.js → node_modules_next_dist_1d_onnt._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/{node_modules_next_dist_client_components_0inhx6q._.js → node_modules_next_dist_client_components_0wpq8j3._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{node_modules_next_dist_client_components_builtin_forbidden_0ghu-f7.js → node_modules_next_dist_client_components_builtin_forbidden_0symwr9.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{node_modules_next_dist_client_components_builtin_unauthorized_0cjv-23.js → node_modules_next_dist_client_components_builtin_unauthorized_0l_sp0x.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0-uvagv.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_03c7gi5.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_09p-8om.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0v-kfiu.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/{node_modules_next_dist_esm_build_templates_app-page_0j79~gv.js → node_modules_next_dist_esm_build_templates_app-page_0xrgzyz.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_1806lsc.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_1j6dd-e.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_1sa65r-.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/node_modules_posthog-node_dist_entrypoints_index_node_mjs_11bnuzn._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_1ezd2jf._.js +5 -0
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_1tnuifj._.js +5 -0
- package/.next/standalone/.next/server/functions-config-manifest.json +3 -0
- package/.next/standalone/.next/server/instrumentation.js +1 -1
- package/.next/standalone/.next/server/middleware-build-manifest.js +10 -10
- package/.next/standalone/.next/server/middleware.js +2 -2
- package/.next/standalone/.next/server/next-font-manifest.js +1 -1
- package/.next/standalone/.next/server/next-font-manifest.json +2 -21
- package/.next/standalone/.next/server/pages/404.html +1 -1
- package/.next/standalone/.next/server/pages/500.html +1 -1
- package/.next/standalone/.next/server/server-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/server-reference-manifest.json +27 -9
- package/.next/standalone/.next/static/chunks/{07uz2g0_38qia.js → 03fmihek9n986.js} +1 -1
- package/.next/standalone/.next/static/chunks/09ueq8s1as8xs.css +2 -0
- package/.next/standalone/.next/static/chunks/0ehe4dh0grngk.js +41 -0
- package/.next/standalone/.next/static/chunks/{0bke.~atnsbeb.js → 0gdm-xaez4l7t.js} +1 -1
- package/.next/standalone/.next/static/chunks/{11w14gnqzprir.js → 0kdglk0vtzymo.js} +1 -1
- package/.next/standalone/.next/static/chunks/0qassxjx1ef04.js +1 -0
- package/.next/standalone/.next/static/chunks/0zbxssxh53n-3.js +1 -0
- package/.next/standalone/.next/static/chunks/13f1kmjea-0md.js +2 -0
- package/.next/standalone/.next/static/chunks/1btx2c49fk9xt.css +1 -0
- package/.next/standalone/.next/static/chunks/1fmco3pvq_twz.js +1 -0
- package/.next/standalone/.next/static/chunks/2b1fzuhuk-42n.js +1 -0
- package/.next/standalone/.next/static/chunks/{0bv1oyxspkpkb.js → 2dtip-mvmihiu.js} +1 -1
- package/.next/standalone/.next/static/chunks/2srzafd1_ha5y.js +1 -0
- package/.next/standalone/.next/static/chunks/{0d3shmwh5_nmn.js → 33u59vf_8xpd-.js} +1 -1
- package/.next/standalone/.next/static/chunks/3gti1qdk5epqn.js +1 -0
- package/.next/standalone/.next/static/chunks/{0dvhi-prcsh3~.js → 3krzy-lhwfrmz.js} +1 -1
- package/.next/standalone/.next/static/chunks/{17mubwtqwijpu.js → 3w8d8k_dca5rp.js} +1 -1
- package/.next/standalone/.next/static/chunks/43lnq0c1rnflb.js +6 -0
- package/.next/standalone/.next/static/chunks/{turbopack-0nh.aopesgj~5.js → turbopack-00qy7zfa7m--m.js} +1 -1
- package/.next/standalone/SECURITY.md +73 -0
- package/.next/standalone/app/actions/get-audit-result.ts +24 -0
- package/.next/standalone/app/api/audit/_state.ts +72 -0
- package/.next/standalone/app/api/audit/run/route.ts +89 -0
- package/.next/standalone/app/api/audit/status/route.ts +23 -0
- package/.next/standalone/app/api/auth/login-request/route.ts +91 -0
- package/.next/standalone/app/api/auth/login-verify/route.ts +98 -0
- package/.next/standalone/app/api/auth/logout/route.ts +48 -0
- package/.next/standalone/app/api/auth/reminder/route.ts +213 -0
- package/.next/standalone/app/api/auth/status/route.ts +42 -0
- package/.next/standalone/app/audit/_components/audit-dashboard.tsx +364 -0
- package/.next/standalone/app/audit/_components/auth-dialog.tsx +401 -0
- package/.next/standalone/app/audit/_components/empty-state.tsx +146 -0
- package/.next/standalone/app/audit/_components/findings-section.tsx +135 -0
- package/.next/standalone/app/audit/_components/identity-section.tsx +126 -0
- package/.next/standalone/app/audit/_components/policies-section.tsx +194 -0
- package/.next/standalone/app/audit/_components/report-footer.tsx +35 -0
- package/.next/standalone/app/audit/_components/rerun-button.tsx +81 -0
- package/.next/standalone/app/audit/_components/return-section.tsx +428 -0
- package/.next/standalone/app/audit/_components/run-progress.tsx +120 -0
- package/.next/standalone/app/audit/_components/score-section.tsx +179 -0
- package/.next/standalone/app/audit/_components/share-dock.tsx +265 -0
- package/.next/standalone/app/audit/_components/share-templates.ts +67 -0
- package/.next/standalone/app/audit/_components/show-off-cta.tsx +135 -0
- package/.next/standalone/app/audit/_components/sigil.tsx +93 -0
- package/.next/standalone/app/audit/_components/strengths-section.tsx +57 -0
- package/.next/standalone/app/audit/audit-styles.css +2066 -0
- package/.next/standalone/app/audit/loading.tsx +24 -0
- package/.next/standalone/app/audit/page.tsx +53 -0
- package/.next/standalone/app/globals.css +570 -137
- package/.next/standalone/app/layout.tsx +16 -9
- package/.next/standalone/app/policies/hooks-client.tsx +223 -129
- package/.next/standalone/app/project/[name]/page.tsx +89 -39
- package/.next/standalone/app/projects/loading.tsx +30 -8
- package/.next/standalone/app/projects/page.tsx +76 -18
- package/.next/standalone/assets/audit/Audit Report.html +22 -0
- package/.next/standalone/assets/audit/Show Off Your Agent.html +22 -0
- package/.next/standalone/assets/audit/archetypes.jsx +277 -0
- package/.next/standalone/assets/audit/assets/fonts/bitcount-prop-single.woff2 +0 -0
- package/.next/standalone/assets/audit/audit.jsx +825 -0
- package/.next/standalone/assets/audit/poster-styles.css +424 -0
- package/.next/standalone/assets/audit/poster.jsx +247 -0
- package/.next/standalone/assets/audit/screenshots/poster-optimist.png +0 -0
- package/.next/standalone/assets/audit/screenshots/poster-scrolled.png +0 -0
- package/.next/standalone/assets/audit/styles.css +1225 -0
- package/.next/standalone/assets/audit/tweaks-panel.jsx +425 -0
- package/.next/standalone/assets/logos/company/icon.svg +1 -0
- package/.next/standalone/assets/logos/company/logo.svg +1 -0
- package/.next/standalone/components/navbar.tsx +154 -65
- package/.next/standalone/components/reach-developers.tsx +37 -9
- package/.next/standalone/lib/atomic-write.ts +67 -0
- package/.next/standalone/lib/auth/api-server-client.ts +281 -0
- package/.next/standalone/lib/auth/auth-store.ts +250 -0
- package/.next/standalone/lib/client-telemetry.ts +2 -0
- package/.next/standalone/lib/fetch-with-timeout.ts +42 -0
- package/.next/standalone/lib/share-card.ts +120 -0
- package/.next/standalone/lib/telemetry.ts +12 -7
- package/.next/standalone/node_modules/@next/env/package.json +1 -1
- package/.next/standalone/node_modules/next/dist/build/swc/index.js +1 -1
- package/.next/standalone/node_modules/next/dist/client/dev/debug-channel.js +102 -2
- package/.next/standalone/node_modules/next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js +11 -11
- package/.next/standalone/node_modules/next/dist/compiled/next-server/app-page-turbo.runtime.prod.js +13 -13
- package/.next/standalone/node_modules/next/dist/compiled/next-server/app-route-turbo.runtime.prod.js +2 -2
- package/.next/standalone/node_modules/next/dist/compiled/next-server/pages-turbo.runtime.prod.js +1 -1
- package/.next/standalone/node_modules/next/dist/lib/patch-incorrect-lockfile.js +3 -3
- package/.next/standalone/node_modules/next/dist/server/app-render/action-handler.js +18 -8
- package/.next/standalone/node_modules/next/dist/server/config-schema.js +1 -0
- package/.next/standalone/node_modules/next/dist/server/config.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/dev/hot-reloader-turbopack.js +2 -2
- package/.next/standalone/node_modules/next/dist/server/dev/hot-reloader-webpack.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/lib/app-info-log.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/lib/encode-cache-tag.js +45 -0
- package/.next/standalone/node_modules/next/dist/server/lib/implicit-tags.js +6 -3
- package/.next/standalone/node_modules/next/dist/server/lib/patch-fetch.js +5 -1
- package/.next/standalone/node_modules/next/dist/server/lib/start-server.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/web/spec-extension/revalidate.js +4 -3
- package/.next/standalone/node_modules/next/dist/server/web/spec-extension/unstable-cache.js +6 -2
- package/.next/standalone/node_modules/next/dist/shared/lib/errors/canary-only-config-error.js +1 -1
- package/.next/standalone/node_modules/next/dist/telemetry/anonymous-meta.js +1 -1
- package/.next/standalone/node_modules/next/dist/telemetry/events/swc-load-failure.js +1 -1
- package/.next/standalone/node_modules/next/dist/telemetry/events/version.js +2 -2
- package/.next/standalone/node_modules/next/package.json +15 -15
- package/.next/standalone/node_modules/react/cjs/react.development.js +1 -1
- package/.next/standalone/node_modules/react/cjs/react.production.js +1 -1
- package/.next/standalone/node_modules/react/package.json +1 -1
- package/.next/standalone/node_modules/react-dom/cjs/react-dom-server-legacy.browser.production.js +1 -1
- package/.next/standalone/node_modules/react-dom/cjs/react-dom-server-legacy.node.production.js +1 -1
- package/.next/standalone/node_modules/react-dom/cjs/react-dom-server.browser.production.js +3 -3
- package/.next/standalone/node_modules/react-dom/cjs/react-dom-server.edge.production.js +3 -3
- package/.next/standalone/node_modules/react-dom/cjs/react-dom-server.node.production.js +3 -3
- package/.next/standalone/node_modules/react-dom/cjs/react-dom.production.js +1 -1
- package/.next/standalone/node_modules/react-dom/package.json +2 -2
- package/.next/standalone/osv-scanner.toml +17 -0
- package/.next/standalone/package.json +8 -3
- package/.next/standalone/public/audit/fonts/bitcount-prop-single.woff2 +0 -0
- package/.next/standalone/public/icon.svg +1 -0
- package/.next/standalone/public/logo.svg +1 -0
- package/.next/standalone/server.js +1 -1
- package/.next/standalone/templates/bitcount-font/README.md +42 -0
- package/.next/standalone/templates/bitcount-font/bitcount-prop-single.woff2 +0 -0
- package/.next/standalone/templates/bitcount-font/bitcount.css +49 -0
- package/.next/standalone/templates/bitcount-font/fonts.ts.example +23 -0
- package/README.md +2 -1
- package/bin/failproofai.mjs +165 -144
- package/dist/cli.mjs +607 -1858
- package/lib/atomic-write.ts +67 -0
- package/lib/auth/api-server-client.ts +281 -0
- package/lib/auth/auth-store.ts +250 -0
- package/lib/client-telemetry.ts +2 -0
- package/lib/fetch-with-timeout.ts +42 -0
- package/lib/share-card.ts +120 -0
- package/lib/telemetry.ts +12 -7
- package/package.json +8 -3
- package/scripts/install-telemetry.mjs +4 -0
- package/src/audit/archetypes.ts +924 -0
- package/src/audit/cache.ts +21 -2
- package/src/audit/dashboard-cache.ts +111 -0
- package/src/audit/features.ts +268 -0
- package/src/audit/findings.ts +298 -0
- package/src/audit/index.ts +39 -21
- package/src/audit/replay.ts +29 -3
- package/src/audit/scoring.ts +174 -0
- package/src/audit/strengths.ts +138 -0
- package/src/audit/types.ts +24 -1
- package/src/auth/cli.ts +359 -0
- package/src/hooks/builtin-policies.ts +2 -1
- package/src/hooks/hook-telemetry.ts +2 -2
- package/src/hooks/policy-registry.ts +20 -0
- package/src/posthog-key.ts +9 -0
- package/.next/standalone/.next/server/app/icon.png/route/app-paths-manifest.json +0 -3
- package/.next/standalone/.next/server/app/icon.png/route.js +0 -7
- package/.next/standalone/.next/server/app/icon.png/route.js.nft.json +0 -1
- package/.next/standalone/.next/server/app/icon.png.body +0 -0
- package/.next/standalone/.next/server/app/icon.png.meta +0 -1
- package/.next/standalone/.next/server/chunks/[externals]_next_dist_0sqmaqd._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__06.arfm._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0__i0h0._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0fe7_q_._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0fw.e.h._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0pxn0e1._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0xv0jh2._.js +0 -3
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_icon_png_route_actions_12.gv.r.js +0 -3
- package/.next/standalone/.next/server/chunks/node_modules_next_dist_esm_build_templates_app-route_0bdfoky.js +0 -3
- package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_05pz9._._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__01as125._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0370~qj._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__09v.ljl._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0agrcb8._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0b7hkr~._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0ehh6vp._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0g8l0tu._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0j4l6hl._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0k5n2kz._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0lp08ll._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0n0yaqw._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0o21f.o._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0t8juvy._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0uylufv._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0ymlddl._.js +0 -223
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0~03grs._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/app_0cdqd9w._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/app_global-error_tsx_0xerkr6._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/app_policies_hooks-client_tsx_0q-m0y-._.js +0 -8
- package/.next/standalone/.next/server/chunks/ssr/app_projects_loading_tsx_13veom4._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/node_modules_0ttbz1~._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_06u0kr8._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0a_7sdg.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0ef3uwk.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0pbja1x.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0r6o0i2.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_11y81~_.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_12or2kf.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/node_modules_posthog-node_dist_entrypoints_index_node_mjs_0mebn66._.js +0 -3
- package/.next/standalone/.next/static/chunks/07kpqoo7kuckx.js +0 -6
- package/.next/standalone/.next/static/chunks/0azb~vy9ds_uy.js +0 -1
- package/.next/standalone/.next/static/chunks/0f5p9plm.aqlp.css +0 -2
- package/.next/standalone/.next/static/chunks/0ffvlbgzgnlw7.js +0 -2
- package/.next/standalone/.next/static/chunks/0spktq7xqab9h.js +0 -1
- package/.next/standalone/.next/static/chunks/118q3uljozd5z.js +0 -4
- package/.next/standalone/.next/static/chunks/12pt~2f.c1sha.js +0 -1
- package/.next/standalone/.next/static/media/4fa387ec64143e14-s.0.qu-9752pffj.woff2 +0 -0
- package/.next/standalone/.next/static/media/5ce348bf30bf5439-s.0ee55_hj9qcer.woff2 +0 -0
- package/.next/standalone/.next/static/media/6306c77e7c8268e4-s.0mao5jbfbduzp.woff2 +0 -0
- package/.next/standalone/.next/static/media/797e433ab948586e-s.p.09zddjkbdep5a.woff2 +0 -0
- package/.next/standalone/.next/static/media/7d817b4c03b0c5f1-s.0uzt.a6d44yda.woff2 +0 -0
- package/.next/standalone/.next/static/media/bbc41e54d2fcbd21-s.0mvwgmnhv29no.woff2 +0 -0
- package/.next/standalone/.next/static/media/icon.0a.gigb3_x5pd.png +0 -0
- package/.next/standalone/app/icon.png +0 -0
- package/src/audit/telemetry.ts +0 -113
- /package/.next/standalone/.next/server/app/{icon.png → api/audit/run}/route/build-manifest.json +0 -0
- /package/.next/standalone/.next/server/app/{icon.png → api/audit/run}/route.js.map +0 -0
- /package/.next/standalone/.next/static/chunks/{03~yq9q893hmn.js → 0cz1d0mv5g_q7.js} +0 -0
- /package/.next/standalone/.next/static/chunks/{0a40sy4tk8ioe.js → 0wwt5o04i4zwh.js} +0 -0
- /package/.next/standalone/.next/static/chunks/{0n1n67imq.udf.js → 1__i9af9g78vd.js} +0 -0
- /package/.next/standalone/.next/static/chunks/{0w6fzf.07a24u.js → 2so39wg7mjbi7.js} +0 -0
- /package/.next/standalone/.next/static/chunks/{0xbo5nl6w4lka.js → 2wbuxnsvux4di.js} +0 -0
- /package/.next/standalone/.next/static/chunks/{0_s0luks5tay-.js → 35fgpd_feci6x.js} +0 -0
- /package/.next/standalone/.next/static/chunks/{15fklyav5py5m.js → 3xpjn3cdgm-7m.js} +0 -0
- /package/.next/standalone/.next/static/chunks/{17.b3suj8zjjj.js → 4448_qq7bd963.js} +0 -0
- /package/.next/standalone/.next/static/{tGVQM5SE3NvbVu0gbAJm7 → wU3ot-EKa5ApKoh785wp8}/_buildManifest.js +0 -0
- /package/.next/standalone/.next/static/{tGVQM5SE3NvbVu0gbAJm7 → wU3ot-EKa5ApKoh785wp8}/_clientMiddlewareManifest.js +0 -0
- /package/.next/standalone/.next/static/{tGVQM5SE3NvbVu0gbAJm7 → wU3ot-EKa5ApKoh785wp8}/_ssgManifest.js +0 -0
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Derive the StrengthsSection rows from a live AuditResult.
|
|
3
|
+
*
|
|
4
|
+
* The reference (assets/audit/audit.jsx) ships 5 hand-curated strengths
|
|
5
|
+
* with placeholder numbers. Here we compute each one off the actual
|
|
6
|
+
* scanned data. Output shape mirrors the original.
|
|
7
|
+
*
|
|
8
|
+
* Most strengths are "absences" — the cleaner the agent, the more
|
|
9
|
+
* strengths we surface (e.g. "0 credential leaks" only counts as a
|
|
10
|
+
* strength when no sanitize-* policies fired).
|
|
11
|
+
*/
|
|
12
|
+
import type { AuditResult } from "./types";
|
|
13
|
+
|
|
14
|
+
export interface Strength {
|
|
15
|
+
metric: string;
|
|
16
|
+
unit: string;
|
|
17
|
+
headline: string;
|
|
18
|
+
detail: string;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
function shortName(name: string): string {
|
|
22
|
+
const slash = name.indexOf("/");
|
|
23
|
+
return slash >= 0 ? name.slice(slash + 1) : name;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
function hitsForShort(result: AuditResult, names: string[]): number {
|
|
27
|
+
const set = new Set(names);
|
|
28
|
+
let total = 0;
|
|
29
|
+
for (const r of result.results) {
|
|
30
|
+
if (set.has(shortName(r.name))) total += r.hits;
|
|
31
|
+
}
|
|
32
|
+
return total;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/** Pick up to 5 derived strengths. Each strength has a true-or-not test —
|
|
36
|
+
* only included when the agent actually demonstrates the behavior. */
|
|
37
|
+
export function deriveStrengths(result: AuditResult): Strength[] {
|
|
38
|
+
const out: Strength[] = [];
|
|
39
|
+
const events = result.eventsScanned ?? 0;
|
|
40
|
+
const totalHits = result.totals.hits;
|
|
41
|
+
const detectorsTriggered = result.results.filter((r) => r.source === "audit-detector").length;
|
|
42
|
+
const cleanRate = events > 0 ? Math.max(0, Math.min(100, Math.round(((events - totalHits) / events) * 100))) : 100;
|
|
43
|
+
|
|
44
|
+
// 1. Always show the "X tool calls, Y detectors triggered" headline.
|
|
45
|
+
if (events > 0) {
|
|
46
|
+
out.push({
|
|
47
|
+
metric: `${cleanRate}%`,
|
|
48
|
+
unit: "clean tool calls",
|
|
49
|
+
headline: `ran ${events.toLocaleString()} tool calls. ${detectorsTriggered} detector${detectorsTriggered === 1 ? "" : "s"} triggered.`,
|
|
50
|
+
detail: `${cleanRate}% of tool calls came back clean before today's audit.`,
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
// 2. Zero credential exposure to stdout — only when no sanitize-* and no
|
|
55
|
+
// block-env-files / block-secrets-write / block-read-outside-cwd hits.
|
|
56
|
+
const credentialPolicies = [
|
|
57
|
+
"sanitize-api-keys", "sanitize-jwt", "sanitize-connection-strings",
|
|
58
|
+
"sanitize-private-key-content", "sanitize-bearer-tokens",
|
|
59
|
+
"block-env-files", "block-secrets-write", "block-read-outside-cwd",
|
|
60
|
+
"protect-env-vars",
|
|
61
|
+
];
|
|
62
|
+
if (hitsForShort(result, credentialPolicies) === 0) {
|
|
63
|
+
out.push({
|
|
64
|
+
metric: "0",
|
|
65
|
+
unit: "credential leaks",
|
|
66
|
+
headline: "zero credential exposure to stdout.",
|
|
67
|
+
detail: "no env files, secret writes, or sanitize hits across the audit window.",
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
// 3. Average sessions task length — `events / sessions`. Faster than
|
|
72
|
+
// median (50) is celebrated; slower than it is mentioned in findings.
|
|
73
|
+
if (result.transcripts.scanned > 0 && events > 0) {
|
|
74
|
+
const avgTurns = Math.max(1, Math.round(events / result.transcripts.scanned));
|
|
75
|
+
if (avgTurns < 30) {
|
|
76
|
+
out.push({
|
|
77
|
+
metric: String(avgTurns),
|
|
78
|
+
unit: "avg turns / session",
|
|
79
|
+
headline: `sessions complete in ${avgTurns} turns on average.`,
|
|
80
|
+
detail: avgTurns < 15
|
|
81
|
+
? "faster than the median agent in this cohort."
|
|
82
|
+
: "comfortably within the typical session length envelope.",
|
|
83
|
+
});
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
// 4. No retry storms — `warn-repeated-tool-calls` + `sleep-polling-loop`
|
|
88
|
+
// are both quiet.
|
|
89
|
+
const retryHits = hitsForShort(result, ["warn-repeated-tool-calls", "sleep-polling-loop"]);
|
|
90
|
+
if (retryHits === 0) {
|
|
91
|
+
out.push({
|
|
92
|
+
metric: "0",
|
|
93
|
+
unit: "retry storms",
|
|
94
|
+
headline: "no retry storms or polling loops detected.",
|
|
95
|
+
detail: "failed calls were diagnosed or moved on from. no six-times-in-a-row spirals.",
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
// 5. No production-shape git mistakes.
|
|
100
|
+
const gitHits = hitsForShort(result, [
|
|
101
|
+
"block-push-master", "block-force-push", "block-work-on-main",
|
|
102
|
+
"git-commit-no-verify",
|
|
103
|
+
]);
|
|
104
|
+
if (gitHits === 0) {
|
|
105
|
+
out.push({
|
|
106
|
+
metric: "0",
|
|
107
|
+
unit: "push-to-main attempts",
|
|
108
|
+
headline: "kept changes off main without prompting.",
|
|
109
|
+
detail: "no direct pushes, force pushes, or hook bypasses across every session.",
|
|
110
|
+
});
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
// 6. No double-writes / re-reads — agent is efficient with edits.
|
|
114
|
+
const wastefulEdits = hitsForShort(result, [
|
|
115
|
+
"reread-after-edit", "prefer-edit-over-sed-awk", "prefer-write-over-heredoc",
|
|
116
|
+
]);
|
|
117
|
+
if (wastefulEdits === 0 && events > 0) {
|
|
118
|
+
out.push({
|
|
119
|
+
metric: "0",
|
|
120
|
+
unit: "double-writes",
|
|
121
|
+
headline: "no double-writes across production projects.",
|
|
122
|
+
detail: "the agent never re-read a file it had just edited, or rewrote via shell.",
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
// Cap to 5. If we somehow have <2 strengths, surface a generic "no
|
|
127
|
+
// findings in this category" so the section never looks empty.
|
|
128
|
+
if (out.length < 2) {
|
|
129
|
+
out.push({
|
|
130
|
+
metric: "—",
|
|
131
|
+
unit: "audit window",
|
|
132
|
+
headline: "audit complete.",
|
|
133
|
+
detail: `${result.transcripts.scanned} session${result.transcripts.scanned === 1 ? "" : "s"} scanned across ${result.totals.projectsWithHits} project${result.totals.projectsWithHits === 1 ? "" : "s"}.`,
|
|
134
|
+
});
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
return out.slice(0, 5);
|
|
138
|
+
}
|
package/src/audit/types.ts
CHANGED
|
@@ -127,6 +127,15 @@ export interface TranscriptAuditResult {
|
|
|
127
127
|
sessionId: string;
|
|
128
128
|
mtimeMs: number;
|
|
129
129
|
sizeBytes: number;
|
|
130
|
+
/** Cwd of the session (taken from the first event with a cwd field).
|
|
131
|
+
* Empty string when no events carried cwd. Surfaced up to `AuditResult.
|
|
132
|
+
* projectsScanned` so the dashboard's project filter can show every
|
|
133
|
+
* scanned project, not just those with examples. */
|
|
134
|
+
cwd?: string;
|
|
135
|
+
/** Total normalized tool-use events scanned in this transcript. Surfaced
|
|
136
|
+
* via `AuditResult.eventsScanned` so the report can show "X tool calls"
|
|
137
|
+
* across the whole audit. */
|
|
138
|
+
eventsScanned?: number;
|
|
130
139
|
/** Per-policy/detector hit count for this one transcript. */
|
|
131
140
|
hitsByName: Record<string, number>;
|
|
132
141
|
/** Up to 3 example commands per policy/detector (later coalesced upstream). */
|
|
@@ -137,7 +146,8 @@ export interface TranscriptAuditResult {
|
|
|
137
146
|
|
|
138
147
|
/** Top-level result of `runAudit()`. */
|
|
139
148
|
export interface AuditResult {
|
|
140
|
-
/** Schema version of this JSON shape. Increment on incompatible changes.
|
|
149
|
+
/** Schema version of this JSON shape. Increment on incompatible changes.
|
|
150
|
+
* v2: added `projectsScanned`. */
|
|
141
151
|
version: number;
|
|
142
152
|
scannedAt: string;
|
|
143
153
|
scope: {
|
|
@@ -156,6 +166,19 @@ export interface AuditResult {
|
|
|
156
166
|
hits: number;
|
|
157
167
|
projectsWithHits: number;
|
|
158
168
|
};
|
|
169
|
+
/** Sorted, deduped list of cwds across every transcript that was scanned
|
|
170
|
+
* (including those with zero hits). Drives the dashboard's project filter.
|
|
171
|
+
* Transcripts without a usable cwd are excluded. */
|
|
172
|
+
projectsScanned: string[];
|
|
173
|
+
/** Total normalized tool-use events the audit walked across every
|
|
174
|
+
* scanned transcript. The audit dashboard surfaces this as the
|
|
175
|
+
* "X tool calls" headline counter. */
|
|
176
|
+
eventsScanned: number;
|
|
177
|
+
/** Short names (without `failproofai/` namespace) of every builtin
|
|
178
|
+
* policy that was enabled in the user's merged config at scan time.
|
|
179
|
+
* Lets the dashboard answer "is this policy already on?" for
|
|
180
|
+
* detector-mapped policies that may not have hit during this audit. */
|
|
181
|
+
enabledBuiltinNames: string[];
|
|
159
182
|
}
|
|
160
183
|
|
|
161
184
|
/** CLI-supplied options for `runAudit()`. Set by `bin/failproofai.mjs`. */
|
package/src/auth/cli.ts
ADDED
|
@@ -0,0 +1,359 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `failproofai auth` CLI surface.
|
|
3
|
+
*
|
|
4
|
+
* failproofai auth login Email + OTP flow; writes ~/.failproofai/auth.json
|
|
5
|
+
* failproofai auth logout Wipe auth.json (best-effort server revoke)
|
|
6
|
+
* failproofai auth whoami Print the cached identity (or "not signed in")
|
|
7
|
+
* failproofai auth help Usage
|
|
8
|
+
*
|
|
9
|
+
* Source of truth is the local cache (~/.failproofai/auth.json). Server-side
|
|
10
|
+
* validation is intentionally avoided — once a token is on disk we trust it.
|
|
11
|
+
* That keeps `login`, `logout`, and `whoami` consistent with each other and
|
|
12
|
+
* with the dashboard, even when the api-server is unreachable.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import * as readline from "node:readline";
|
|
16
|
+
|
|
17
|
+
import {
|
|
18
|
+
AuthApiError,
|
|
19
|
+
getApiBase,
|
|
20
|
+
logoutSession,
|
|
21
|
+
requestLoginCode,
|
|
22
|
+
verifyLoginCode,
|
|
23
|
+
} from "../../lib/auth/api-server-client";
|
|
24
|
+
import {
|
|
25
|
+
authFromTokenResponse,
|
|
26
|
+
deleteAuth,
|
|
27
|
+
readAuth,
|
|
28
|
+
writeAuth,
|
|
29
|
+
} from "../../lib/auth/auth-store";
|
|
30
|
+
import { CliError } from "../cli-error";
|
|
31
|
+
import { trackHookEvent } from "../hooks/hook-telemetry";
|
|
32
|
+
import { getInstanceId } from "../../lib/telemetry-id";
|
|
33
|
+
|
|
34
|
+
interface AuthCliOptions {
|
|
35
|
+
mode: "login" | "logout" | "whoami" | "help";
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
const HELP = `
|
|
39
|
+
failproofai auth — sign in to FailproofAI from the CLI
|
|
40
|
+
|
|
41
|
+
USAGE
|
|
42
|
+
failproofai auth login Start the email + OTP login flow
|
|
43
|
+
failproofai auth logout Remove ~/.failproofai/auth.json
|
|
44
|
+
failproofai auth whoami Print the currently signed-in identity
|
|
45
|
+
failproofai auth help Show this help (also: --help, -h)
|
|
46
|
+
|
|
47
|
+
ENVIRONMENT
|
|
48
|
+
FAILPROOF_API_URL Override the api-server base URL
|
|
49
|
+
(default: https://api.befailproof.ai)
|
|
50
|
+
FAILPROOFAI_AUTH_DIR Override where auth.json is stored
|
|
51
|
+
(default: ~/.failproofai)
|
|
52
|
+
|
|
53
|
+
EXAMPLES
|
|
54
|
+
failproofai auth login
|
|
55
|
+
failproofai auth whoami
|
|
56
|
+
failproofai auth logout
|
|
57
|
+
`.trimStart();
|
|
58
|
+
|
|
59
|
+
/** Deprecated `--login` / `--logout` / `--whoami` flags map back to subcommands
|
|
60
|
+
* so shell history and older docs keep working silently. */
|
|
61
|
+
const LEGACY_FLAG_TO_SUB: Record<string, "login" | "logout" | "whoami"> = {
|
|
62
|
+
"--login": "login",
|
|
63
|
+
"--logout": "logout",
|
|
64
|
+
"--whoami": "whoami",
|
|
65
|
+
};
|
|
66
|
+
|
|
67
|
+
const SUBCOMMANDS = new Set(["login", "logout", "whoami", "help"]);
|
|
68
|
+
|
|
69
|
+
export function parseAuthArgs(args: string[]): AuthCliOptions {
|
|
70
|
+
if (args.includes("--help") || args.includes("-h")) return { mode: "help" };
|
|
71
|
+
|
|
72
|
+
const positional: string[] = [];
|
|
73
|
+
const legacy: ("login" | "logout" | "whoami")[] = [];
|
|
74
|
+
for (const a of args) {
|
|
75
|
+
if (a === "--help" || a === "-h") continue;
|
|
76
|
+
if (a in LEGACY_FLAG_TO_SUB) {
|
|
77
|
+
legacy.push(LEGACY_FLAG_TO_SUB[a]);
|
|
78
|
+
continue;
|
|
79
|
+
}
|
|
80
|
+
if (a.startsWith("-")) {
|
|
81
|
+
throw new CliError(
|
|
82
|
+
`Unknown flag for auth: ${a}\nRun \`failproofai auth help\` for usage.`,
|
|
83
|
+
);
|
|
84
|
+
}
|
|
85
|
+
positional.push(a);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
const subs = [...positional, ...legacy];
|
|
89
|
+
if (subs.length === 0) return { mode: "help" };
|
|
90
|
+
if (subs.length > 1) {
|
|
91
|
+
throw new CliError(
|
|
92
|
+
`Pick one of login, logout, whoami.\nRun \`failproofai auth help\` for usage.`,
|
|
93
|
+
);
|
|
94
|
+
}
|
|
95
|
+
const sub = subs[0];
|
|
96
|
+
if (!SUBCOMMANDS.has(sub)) {
|
|
97
|
+
throw new CliError(
|
|
98
|
+
`Unknown auth subcommand: ${sub}\nRun \`failproofai auth help\` for usage.`,
|
|
99
|
+
);
|
|
100
|
+
}
|
|
101
|
+
return { mode: sub as AuthCliOptions["mode"] };
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
function prompt(question: string, opts: { hidden?: boolean } = {}): Promise<string> {
|
|
105
|
+
const rl = readline.createInterface({ input: process.stdin, output: process.stdout });
|
|
106
|
+
if (opts.hidden && process.stdin.isTTY) {
|
|
107
|
+
const r = rl as unknown as {
|
|
108
|
+
_writeToOutput: (s: string) => void;
|
|
109
|
+
output: NodeJS.WritableStream;
|
|
110
|
+
};
|
|
111
|
+
const orig = r._writeToOutput.bind(rl);
|
|
112
|
+
r._writeToOutput = (s: string): void => {
|
|
113
|
+
if (s.length > 0 && s !== "\r\n" && s !== "\n") orig("*");
|
|
114
|
+
else orig(s);
|
|
115
|
+
};
|
|
116
|
+
}
|
|
117
|
+
return new Promise((resolve) => {
|
|
118
|
+
rl.question(question, (answer: string) => {
|
|
119
|
+
rl.close();
|
|
120
|
+
if (opts.hidden && process.stdin.isTTY) process.stdout.write("\n");
|
|
121
|
+
resolve(answer.trim());
|
|
122
|
+
});
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
const DIM = "\x1b[2m";
|
|
127
|
+
const RESET = "\x1b[0m";
|
|
128
|
+
const PINK = "\x1b[38;5;204m";
|
|
129
|
+
const GREEN = "\x1b[38;5;120m";
|
|
130
|
+
const RED = "\x1b[38;5;197m";
|
|
131
|
+
|
|
132
|
+
function emailLooksValid(email: string): boolean {
|
|
133
|
+
return /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(email);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
async function runLogin(): Promise<void> {
|
|
137
|
+
const existing = readAuth();
|
|
138
|
+
if (existing) {
|
|
139
|
+
// Treat the on-disk session as valid only when its refresh window hasn't
|
|
140
|
+
// already lapsed locally. We don't hit /me here (the file header explicitly
|
|
141
|
+
// avoids server validation so login/logout/whoami stay coherent offline),
|
|
142
|
+
// but the local exp claim is enough to recognise an obviously-stale file
|
|
143
|
+
// and let the user re-authenticate instead of bouncing them out.
|
|
144
|
+
const nowSecs = Math.floor(Date.now() / 1000);
|
|
145
|
+
const refreshUsable = existing.refresh_expires_at > nowSecs;
|
|
146
|
+
if (refreshUsable) {
|
|
147
|
+
void trackHookEvent(getInstanceId(), "audit_cli_auth_login_completed", {
|
|
148
|
+
source: "cli",
|
|
149
|
+
status: "already_signed_in",
|
|
150
|
+
user_id: existing.user.id,
|
|
151
|
+
});
|
|
152
|
+
process.stdout.write(
|
|
153
|
+
`${DIM}already signed in as${RESET} ${existing.user.email} ${DIM}(use \`failproofai auth logout\` to switch accounts)${RESET}\n`,
|
|
154
|
+
);
|
|
155
|
+
return;
|
|
156
|
+
}
|
|
157
|
+
process.stdout.write(
|
|
158
|
+
`${DIM}stored session for ${existing.user.email} has expired — re-authenticating.${RESET}\n`,
|
|
159
|
+
);
|
|
160
|
+
// Overwrite cleanly so a half-broken file doesn't survive next startup.
|
|
161
|
+
deleteAuth();
|
|
162
|
+
}
|
|
163
|
+
void trackHookEvent(getInstanceId(), "audit_cli_auth_login_started", {
|
|
164
|
+
source: "cli",
|
|
165
|
+
api_base: getApiBase(),
|
|
166
|
+
replaced_stale: existing !== null,
|
|
167
|
+
});
|
|
168
|
+
|
|
169
|
+
process.stdout.write(`${PINK}━━ failproofai auth ━━${RESET}\n`);
|
|
170
|
+
process.stdout.write(`${DIM}api: ${getApiBase()}${RESET}\n\n`);
|
|
171
|
+
|
|
172
|
+
let email = "";
|
|
173
|
+
for (let attempt = 0; attempt < 3; attempt++) {
|
|
174
|
+
email = await prompt("email: ");
|
|
175
|
+
if (emailLooksValid(email)) break;
|
|
176
|
+
process.stdout.write(`${RED}that doesn't look like an email — try again.${RESET}\n`);
|
|
177
|
+
email = "";
|
|
178
|
+
}
|
|
179
|
+
if (!email) {
|
|
180
|
+
void trackHookEvent(getInstanceId(), "audit_cli_auth_login_completed", {
|
|
181
|
+
source: "cli",
|
|
182
|
+
status: "aborted_invalid_email",
|
|
183
|
+
});
|
|
184
|
+
throw new CliError("Could not read a valid email after 3 attempts.");
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
try {
|
|
188
|
+
const r = await requestLoginCode(email);
|
|
189
|
+
void trackHookEvent(getInstanceId(), "audit_otp_requested", {
|
|
190
|
+
source: "cli",
|
|
191
|
+
status: "success",
|
|
192
|
+
expires_in: r.expires_in,
|
|
193
|
+
resend_available_in: r.resend_available_in,
|
|
194
|
+
});
|
|
195
|
+
process.stdout.write(
|
|
196
|
+
`\n${GREEN}code sent.${RESET} ${DIM}check ${email} — expires in ${r.expires_in}s.${RESET}\n`,
|
|
197
|
+
);
|
|
198
|
+
} catch (err) {
|
|
199
|
+
const isApi = err instanceof AuthApiError;
|
|
200
|
+
void trackHookEvent(getInstanceId(), "audit_otp_requested", {
|
|
201
|
+
source: "cli",
|
|
202
|
+
status: "failed",
|
|
203
|
+
error_code: isApi ? err.code : "upstream_unreachable",
|
|
204
|
+
http_status: isApi ? err.status : null,
|
|
205
|
+
});
|
|
206
|
+
if (isApi && err.code === "rate_limited") {
|
|
207
|
+
throw new CliError(
|
|
208
|
+
`Rate limited — try again in ${err.retryAfterSecs ?? "a few"} seconds.`,
|
|
209
|
+
);
|
|
210
|
+
}
|
|
211
|
+
if (isApi) {
|
|
212
|
+
throw new CliError(`Login request failed (${err.code}): ${err.message}`);
|
|
213
|
+
}
|
|
214
|
+
throw new CliError(
|
|
215
|
+
`Could not reach the api-server at ${getApiBase()}.\n` +
|
|
216
|
+
`Check your network, or set FAILPROOF_API_URL to point at a different host.`,
|
|
217
|
+
);
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
let tokenResp;
|
|
221
|
+
let verifyAttempts = 0;
|
|
222
|
+
for (let attempt = 0; attempt < 5; attempt++) {
|
|
223
|
+
const code = await prompt("code: ", { hidden: true });
|
|
224
|
+
if (!code) continue;
|
|
225
|
+
verifyAttempts += 1;
|
|
226
|
+
try {
|
|
227
|
+
tokenResp = await verifyLoginCode(email, code);
|
|
228
|
+
break;
|
|
229
|
+
} catch (err) {
|
|
230
|
+
const isApi = err instanceof AuthApiError;
|
|
231
|
+
void trackHookEvent(getInstanceId(), "audit_otp_verified", {
|
|
232
|
+
source: "cli",
|
|
233
|
+
status: "failed",
|
|
234
|
+
attempt: verifyAttempts,
|
|
235
|
+
error_code: isApi ? err.code : "upstream_unreachable",
|
|
236
|
+
http_status: isApi ? err.status : null,
|
|
237
|
+
});
|
|
238
|
+
if (isApi && err.status === 401) {
|
|
239
|
+
process.stdout.write(`${RED}code rejected — try again.${RESET}\n`);
|
|
240
|
+
continue;
|
|
241
|
+
}
|
|
242
|
+
if (isApi) {
|
|
243
|
+
throw new CliError(`Verify failed (${err.code}): ${err.message}`);
|
|
244
|
+
}
|
|
245
|
+
throw new CliError(
|
|
246
|
+
`Could not reach the api-server at ${getApiBase()}.`,
|
|
247
|
+
);
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
if (!tokenResp) {
|
|
251
|
+
void trackHookEvent(getInstanceId(), "audit_cli_auth_login_completed", {
|
|
252
|
+
source: "cli",
|
|
253
|
+
status: "exhausted_attempts",
|
|
254
|
+
attempts: verifyAttempts,
|
|
255
|
+
});
|
|
256
|
+
throw new CliError("Too many bad codes — start over.");
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
writeAuth(authFromTokenResponse(tokenResp));
|
|
260
|
+
void trackHookEvent(getInstanceId(), "audit_otp_verified", {
|
|
261
|
+
source: "cli",
|
|
262
|
+
status: "success",
|
|
263
|
+
attempt: verifyAttempts,
|
|
264
|
+
user_id: tokenResp.user.id,
|
|
265
|
+
email: tokenResp.user.email,
|
|
266
|
+
});
|
|
267
|
+
// Bridge the anonymous local instance ID to the server-issued user identity.
|
|
268
|
+
// PostHog can stitch together "anonymous machine X did Y" events emitted
|
|
269
|
+
// before sign-in with "user Z" events that follow, by joining on
|
|
270
|
+
// `local_random_id` (== this event's distinct_id). The verified email +
|
|
271
|
+
// `$set` persist the account onto the device person. The dashboard's
|
|
272
|
+
// /api/auth/login-verify emits the same event with
|
|
273
|
+
// `source: "audit_set_reminder_auth_dialog"`; this is the CLI sibling —
|
|
274
|
+
// without it, anyone who signs in via `failproofai auth login` stays
|
|
275
|
+
// unjoined to their pre-auth events.
|
|
276
|
+
void trackHookEvent(getInstanceId(), "audit_user_identity_linked", {
|
|
277
|
+
source: "cli",
|
|
278
|
+
user_id: tokenResp.user.id,
|
|
279
|
+
email: tokenResp.user.email,
|
|
280
|
+
local_random_id: getInstanceId(),
|
|
281
|
+
$set: { email: tokenResp.user.email, user_id: tokenResp.user.id },
|
|
282
|
+
});
|
|
283
|
+
void trackHookEvent(getInstanceId(), "audit_cli_auth_login_completed", {
|
|
284
|
+
source: "cli",
|
|
285
|
+
status: "success",
|
|
286
|
+
attempts: verifyAttempts,
|
|
287
|
+
user_id: tokenResp.user.id,
|
|
288
|
+
});
|
|
289
|
+
process.stdout.write(
|
|
290
|
+
`\n${GREEN}✓ signed in as ${tokenResp.user.email}${RESET}\n` +
|
|
291
|
+
`${DIM}session saved to ~/.failproofai/auth.json (mode 0600)${RESET}\n`,
|
|
292
|
+
);
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
async function runLogout(): Promise<void> {
|
|
296
|
+
const existing = readAuth();
|
|
297
|
+
if (!existing) {
|
|
298
|
+
void trackHookEvent(getInstanceId(), "audit_cli_auth_logout_completed", {
|
|
299
|
+
source: "cli",
|
|
300
|
+
had_session: false,
|
|
301
|
+
upstream: "noop",
|
|
302
|
+
});
|
|
303
|
+
process.stdout.write(`${DIM}not signed in. nothing to do.${RESET}\n`);
|
|
304
|
+
return;
|
|
305
|
+
}
|
|
306
|
+
// Best-effort server revoke — failure does not block the local wipe.
|
|
307
|
+
let upstream: "revoked" | "failed" = "revoked";
|
|
308
|
+
try {
|
|
309
|
+
await logoutSession(existing.access_token, existing.refresh_token);
|
|
310
|
+
} catch (err) {
|
|
311
|
+
if (err instanceof AuthApiError && err.status === 401) {
|
|
312
|
+
// already invalid server-side
|
|
313
|
+
} else {
|
|
314
|
+
upstream = "failed";
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
deleteAuth();
|
|
318
|
+
void trackHookEvent(getInstanceId(), "audit_cli_auth_logout_completed", {
|
|
319
|
+
source: "cli",
|
|
320
|
+
had_session: true,
|
|
321
|
+
upstream,
|
|
322
|
+
user_id: existing.user.id,
|
|
323
|
+
});
|
|
324
|
+
process.stdout.write(
|
|
325
|
+
`${GREEN}✓ signed out as ${existing.user.email}.${RESET}\n`,
|
|
326
|
+
);
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
function runWhoami(): void {
|
|
330
|
+
const existing = readAuth();
|
|
331
|
+
if (!existing) {
|
|
332
|
+
void trackHookEvent(getInstanceId(), "audit_cli_auth_whoami", {
|
|
333
|
+
source: "cli",
|
|
334
|
+
authenticated: false,
|
|
335
|
+
});
|
|
336
|
+
process.stdout.write(`${DIM}not signed in — run \`failproofai auth login\` to sign in.${RESET}\n`);
|
|
337
|
+
process.exitCode = 1;
|
|
338
|
+
return;
|
|
339
|
+
}
|
|
340
|
+
void trackHookEvent(getInstanceId(), "audit_cli_auth_whoami", {
|
|
341
|
+
source: "cli",
|
|
342
|
+
authenticated: true,
|
|
343
|
+
user_id: existing.user.id,
|
|
344
|
+
});
|
|
345
|
+
process.stdout.write(
|
|
346
|
+
`${GREEN}✓${RESET} ${existing.user.email} ${DIM}(${existing.user.id})${RESET}\n`,
|
|
347
|
+
);
|
|
348
|
+
}
|
|
349
|
+
|
|
350
|
+
export async function runAuthCli(args: string[]): Promise<void> {
|
|
351
|
+
const opts = parseAuthArgs(args);
|
|
352
|
+
if (opts.mode === "help") {
|
|
353
|
+
process.stdout.write(HELP);
|
|
354
|
+
return;
|
|
355
|
+
}
|
|
356
|
+
if (opts.mode === "login") return runLogin();
|
|
357
|
+
if (opts.mode === "logout") return runLogout();
|
|
358
|
+
return runWhoami();
|
|
359
|
+
}
|
|
@@ -1471,7 +1471,8 @@ function requireCiGreenBeforeStop(ctx: PolicyContext): PolicyResult {
|
|
|
1471
1471
|
r.status === "completed" &&
|
|
1472
1472
|
r.conclusion !== "success" &&
|
|
1473
1473
|
r.conclusion !== "skipped" &&
|
|
1474
|
-
r.conclusion !== "cancelled"
|
|
1474
|
+
r.conclusion !== "cancelled" &&
|
|
1475
|
+
r.conclusion !== "neutral",
|
|
1475
1476
|
);
|
|
1476
1477
|
if (failing.length > 0) {
|
|
1477
1478
|
const names = failing.map((r) => `"${r.name}"`).join(", ");
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
import { version } from "../../package.json";
|
|
9
|
-
import { POSTHOG_API_KEY } from "../posthog-key";
|
|
9
|
+
import { POSTHOG_API_KEY, POSTHOG_PRODUCT } from "../posthog-key";
|
|
10
10
|
|
|
11
11
|
const API_KEY = POSTHOG_API_KEY;
|
|
12
12
|
const CAPTURE_URL = "https://us.i.posthog.com/capture/";
|
|
@@ -22,7 +22,7 @@ export async function trackHookEvent(
|
|
|
22
22
|
api_key: process.env.FAILPROOFAI_POSTHOG_KEY ?? API_KEY,
|
|
23
23
|
event,
|
|
24
24
|
distinct_id: distinctId,
|
|
25
|
-
properties: { ...properties, $lib: "failproofai-hooks", failproofai_version: version },
|
|
25
|
+
properties: { ...properties, $lib: "failproofai-hooks", failproofai_version: version, product: POSTHOG_PRODUCT },
|
|
26
26
|
});
|
|
27
27
|
|
|
28
28
|
try {
|
|
@@ -105,3 +105,23 @@ export function clearPolicies(): void {
|
|
|
105
105
|
g[REGISTRY_KEY] = [];
|
|
106
106
|
setIndexCache(null);
|
|
107
107
|
}
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* Snapshot the current registry. Returns a shallow copy so callers can hold
|
|
111
|
+
* a stable reference while the registry is mutated by other code paths
|
|
112
|
+
* (notably the audit replay engine, which clears the registry to load only
|
|
113
|
+
* builtins).
|
|
114
|
+
*/
|
|
115
|
+
export function getAllPolicies(): RegisteredPolicy[] {
|
|
116
|
+
return [...getRegistry()];
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* Replace the registry wholesale. Pair with `getAllPolicies()` to take a
|
|
121
|
+
* snapshot before destructive operations and restore it afterwards.
|
|
122
|
+
*/
|
|
123
|
+
export function setAllPolicies(policies: RegisteredPolicy[]): void {
|
|
124
|
+
const g = globalThis as GlobalWithRegistry;
|
|
125
|
+
g[REGISTRY_KEY] = [...policies];
|
|
126
|
+
setIndexCache(null);
|
|
127
|
+
}
|
package/src/posthog-key.ts
CHANGED
|
@@ -3,3 +3,12 @@
|
|
|
3
3
|
* and the compiled hook binary telemetry. Write-only (safe to commit).
|
|
4
4
|
*/
|
|
5
5
|
export const POSTHOG_API_KEY = "phc_Ac1Ww1GqKc0z1SyrRWbmatEeQdlOQIsDEEdP8l8JRgX";
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Product identifier attached to the `product` property of every PostHog
|
|
9
|
+
* event, across all telemetry channels (hooks, web, server, install).
|
|
10
|
+
* Single source of truth so the value never drifts between channels.
|
|
11
|
+
* The standalone npm-lifecycle script (scripts/install-telemetry.mjs) can't
|
|
12
|
+
* import this TS module at install time, so it inlines the same literal.
|
|
13
|
+
*/
|
|
14
|
+
export const POSTHOG_PRODUCT = "failproofai-oss";
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
var R=require("../../chunks/[turbopack]_runtime.js")("server/app/icon.png/route.js")
|
|
2
|
-
R.c("server/chunks/[externals]_next_dist_0sqmaqd._.js")
|
|
3
|
-
R.c("server/chunks/[root-of-the-server]__0j8-xkl._.js")
|
|
4
|
-
R.c("server/chunks/node_modules_next_dist_esm_build_templates_app-route_0bdfoky.js")
|
|
5
|
-
R.c("server/chunks/_next-internal_server_app_icon_png_route_actions_12.gv.r.js")
|
|
6
|
-
R.m(15295)
|
|
7
|
-
module.exports=R.m(15295).exports
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":1,"files":["../../../../node_modules/@swc/helpers/cjs/_interop_require_default.cjs","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/next/dist/build/adapter/setup-node-env.external.js","../../../../node_modules/next/dist/client/components/app-router-headers.js","../../../../node_modules/next/dist/client/components/hooks-server-context.js","../../../../node_modules/next/dist/client/components/static-generation-bailout.js","../../../../node_modules/next/dist/client/lib/console.js","../../../../node_modules/next/dist/compiled/@opentelemetry/api/index.js","../../../../node_modules/next/dist/compiled/@opentelemetry/api/package.json","../../../../node_modules/next/dist/compiled/jsonwebtoken/index.js","../../../../node_modules/next/dist/compiled/jsonwebtoken/package.json","../../../../node_modules/next/dist/compiled/next-server/app-page-turbo.runtime.prod.js","../../../../node_modules/next/dist/compiled/next-server/app-route-turbo.runtime.prod.js","../../../../node_modules/next/dist/compiled/source-map/package.json","../../../../node_modules/next/dist/compiled/source-map/source-map.js","../../../../node_modules/next/dist/compiled/stacktrace-parser/package.json","../../../../node_modules/next/dist/compiled/stacktrace-parser/stack-trace-parser.cjs.js","../../../../node_modules/next/dist/compiled/ws/index.js","../../../../node_modules/next/dist/compiled/ws/package.json","../../../../node_modules/next/dist/lib/client-and-server-references.js","../../../../node_modules/next/dist/lib/constants.js","../../../../node_modules/next/dist/lib/framework/boundary-constants.js","../../../../node_modules/next/dist/lib/interop-default.js","../../../../node_modules/next/dist/lib/is-error.js","../../../../node_modules/next/dist/lib/picocolors.js","../../../../node_modules/next/dist/lib/scheduler.js","../../../../node_modules/next/dist/lib/semver-noop.js","../../../../node_modules/next/dist/server/app-render/action-async-storage-instance.js","../../../../node_modules/next/dist/server/app-render/action-async-storage.external.js","../../../../node_modules/next/dist/server/app-render/after-task-async-storage-instance.js","../../../../node_modules/next/dist/server/app-render/after-task-async-storage.external.js","../../../../node_modules/next/dist/server/app-render/async-local-storage.js","../../../../node_modules/next/dist/server/app-render/cache-signal.js","../../../../node_modules/next/dist/server/app-render/console-async-storage-instance.js","../../../../node_modules/next/dist/server/app-render/console-async-storage.external.js","../../../../node_modules/next/dist/server/app-render/dynamic-access-async-storage-instance.js","../../../../node_modules/next/dist/server/app-render/dynamic-access-async-storage.external.js","../../../../node_modules/next/dist/server/app-render/dynamic-rendering.js","../../../../node_modules/next/dist/server/app-render/instant-validation/boundary-constants.js","../../../../node_modules/next/dist/server/app-render/module-loading/track-module-loading.external.js","../../../../node_modules/next/dist/server/app-render/module-loading/track-module-loading.instance.js","../../../../node_modules/next/dist/server/app-render/staged-rendering.js","../../../../node_modules/next/dist/server/app-render/work-async-storage-instance.js","../../../../node_modules/next/dist/server/app-render/work-async-storage.external.js","../../../../node_modules/next/dist/server/app-render/work-unit-async-storage-instance.js","../../../../node_modules/next/dist/server/app-render/work-unit-async-storage.external.js","../../../../node_modules/next/dist/server/dev/browser-logs/file-logger.js","../../../../node_modules/next/dist/server/dynamic-rendering-utils.js","../../../../node_modules/next/dist/server/lib/incremental-cache/memory-cache.external.js","../../../../node_modules/next/dist/server/lib/incremental-cache/shared-cache-controls.external.js","../../../../node_modules/next/dist/server/lib/incremental-cache/tags-manifest.external.js","../../../../node_modules/next/dist/server/lib/lru-cache.js","../../../../node_modules/next/dist/server/lib/parse-stack.js","../../../../node_modules/next/dist/server/lib/router-utils/instrumentation-globals.external.js","../../../../node_modules/next/dist/server/lib/router-utils/instrumentation-node-extensions.js","../../../../node_modules/next/dist/server/lib/source-maps.js","../../../../node_modules/next/dist/server/lib/trace/constants.js","../../../../node_modules/next/dist/server/lib/trace/tracer.js","../../../../node_modules/next/dist/server/load-manifest.external.js","../../../../node_modules/next/dist/server/node-environment-baseline.js","../../../../node_modules/next/dist/server/node-environment-extensions/console-dim.external.js","../../../../node_modules/next/dist/server/node-environment-extensions/console-exit.js","../../../../node_modules/next/dist/server/node-environment-extensions/console-file.js","../../../../node_modules/next/dist/server/node-environment-extensions/date.js","../../../../node_modules/next/dist/server/node-environment-extensions/error-inspect.js","../../../../node_modules/next/dist/server/node-environment-extensions/fast-set-immediate.external.js","../../../../node_modules/next/dist/server/node-environment-extensions/io-utils.js","../../../../node_modules/next/dist/server/node-environment-extensions/node-crypto.js","../../../../node_modules/next/dist/server/node-environment-extensions/random.js","../../../../node_modules/next/dist/server/node-environment-extensions/unhandled-rejection.external.js","../../../../node_modules/next/dist/server/node-environment-extensions/web-crypto.js","../../../../node_modules/next/dist/server/node-environment.js","../../../../node_modules/next/dist/server/node-polyfill-crypto.js","../../../../node_modules/next/dist/server/patch-error-inspect.js","../../../../node_modules/next/dist/server/require-hook.js","../../../../node_modules/next/dist/server/response-cache/types.js","../../../../node_modules/next/dist/server/runtime-reacts.external.js","../../../../node_modules/next/dist/shared/lib/deep-freeze.js","../../../../node_modules/next/dist/shared/lib/invariant-error.js","../../../../node_modules/next/dist/shared/lib/is-plain-object.js","../../../../node_modules/next/dist/shared/lib/is-thenable.js","../../../../node_modules/next/dist/shared/lib/lazy-dynamic/bailout-to-csr.js","../../../../node_modules/next/dist/shared/lib/no-fallback-error.external.js","../../../../node_modules/next/dist/shared/lib/promise-with-resolvers.js","../../../../node_modules/next/dist/shared/lib/server-reference-info.js","../../../../node_modules/next/package.json","../../../../node_modules/react/cjs/react.development.js","../../../../node_modules/react/cjs/react.production.js","../../../../node_modules/react/index.js","../../../../node_modules/react/package.json","../../chunks/[externals]_next_dist_0sqmaqd._.js","../../chunks/[root-of-the-server]__0j8-xkl._.js","../../chunks/[turbopack]_runtime.js","../../chunks/_next-internal_server_app_icon_png_route_actions_12.gv.r.js","../../chunks/node_modules_next_dist_esm_build_templates_app-route_0bdfoky.js"]}
|
|
Binary file
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"status":200,"headers":{"cache-control":"public, max-age=0, must-revalidate","content-type":"image/png","x-next-cache-tags":"_N_T_/layout,_N_T_/icon.png/layout,_N_T_/icon.png/route,_N_T_/icon.png"}}
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
module.exports=[18622,(e,r,t)=>{r.exports=e.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},56704,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},24725,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},70406,(e,r,t)=>{r.exports=e.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},93695,(e,r,t)=>{r.exports=e.x("next/dist/shared/lib/no-fallback-error.external.js",()=>require("next/dist/shared/lib/no-fallback-error.external.js"))}];
|
|
2
|
-
|
|
3
|
-
//# sourceMappingURL=%5Bexternals%5D_next_dist_0sqmaqd._.js.map
|