diff --git a/Docs/Separation/Audit.md b/Docs/Separation/Audit.md index 8ea9d1b7..1d5d94f2 100644 --- a/Docs/Separation/Audit.md +++ b/Docs/Separation/Audit.md @@ -65,7 +65,8 @@ public pages and is omitted. Public brand assets have a versioned provenance man Read-only public HTML/browser checks found no analytics/tracking script, advertising cookie or search-engine verification meta tag in the public layout. Source contains -no Google/Bing verification file. Public privacy copy says no analytics/tracking +no Google/Bing verification file. Read-only DNS inspection found an existing search +verification TXT record on the unchanged apex; that verification remains in place. Public privacy copy says no analytics/tracking cookies. Preserve any independent live Nginx verification location discovered during administrator cutover preflight; restricted receipt access cannot inspect arbitrary root-owned Nginx files, so do not silently replace the live vhost with a template. @@ -98,6 +99,25 @@ No copy or design expansion is included. | Infrastructure | Existing app retains service/port/releases/config/uploads/SQL/keys and signed compressed deploy process. Website gets independent identities, keys, port 5004 in Production, port 5051 in Development, release root and receipts. | | Email/AI/background integrations | Support mailboxes/sender domain remain plotdirector.com. Do not change SMTP keys, held email/background workers, external-processing flags, acceptance fence or egress restrictions. Review pending old-host links before owner approval. | +The application HelpService preserves file-source fallback and additionally hot-reloads +an explicitly configured, independently installed approved content publication. Both +services keep separate artifact stores; neither reads the other's store/process. + `Evidence/domain-references.json` records concrete hard-coded origin locations. Dynamic URLs also depend on request/proxy host; a string search alone is insufficient. No application projects, assemblies, namespaces, users, subscriptions or data are renamed. + +## Development operations findings + +The installed routine code-only baseline still pointed at 9b1770d9 although the +running, already-qualified release was 9dcd29d4 with a complete 338-entry Development +history. Reconciled only the protected baseline files after verifying the existing +signed package, installed manifest/DLL/current pointer and complete live schema/history +under the deployment lock. Previous baseline retained; no SQL, backup/restore or +service operation occurred. Evidence: development-baseline-refresh.json. This restores +the routine guarded command rather than bypassing its schema fence. + +`/srv` has about 1.1 GiB available after removing only this task's failed temporary +build outputs. Clean qualification builds now use the system volume under +`~/.local/share/plotdirector-development/worktrees`, with ample measured free space. +No unrelated checkouts, releases, backups or user files were deleted. diff --git a/Docs/Separation/Cutover.md b/Docs/Separation/Cutover.md index cb533404..7f7ceca8 100644 --- a/Docs/Separation/Cutover.md +++ b/Docs/Separation/Cutover.md @@ -53,7 +53,12 @@ unchanged comparison. Do not modify that site, port 5002, reserved 5003 or any o unrelated service. Verify port 5004 is free. The application stays on port 5001 with its existing service, runtime identity, environment file, uploads, secrets, database, key ring/discriminator and acceptance/egress/worker controls. Never rotate or copy -Data Protection material into the website. +Data Protection material into the website. Merge the prepared non-secret +`application-origin.env.example` values into the existing application configuration: +`Site__WebsiteBaseUrl=https://plotdirector.com` and an explicit AllowedHosts list for +app.plotdirector.com, the legacy apex bridge and loopback health. Set `HelpContent__Path=/srv/plotdirector/shared/help/current` after installing the +same approved Production help artifact into the application's own protected store. +Keep all other application environment values intact; do not replace its environment file. ## Independent website provisioning (web1) @@ -142,7 +147,9 @@ on app.plotdirector.com. Do not redirect every missing URL to a homepage. Review new attribute routes against the compatibility template before activation. Legacy `/api`, `/hubs`, `/native-companion`, `/word-companion` and `/uploads` traffic -is explicitly proxied to the existing application backend. Preserve request bodies, +is explicitly proxied to the existing application backend. The taskpane-specific +JavaScript, notification CSS/JavaScript and legacy manifest icons are also proxied +explicitly, so the bridged taskpane does not lose its scripts or styling. Preserve request bodies, Authorization/Stripe signatures, queries and websocket upgrade semantics. These protocol clients cannot safely rely on ordinary browser redirects. The temporary bridge preserves endpoint availability, not a promise to migrate origin-bound cookie, diff --git a/Docs/Separation/Evidence/application-browser.json b/Docs/Separation/Evidence/application-browser.json new file mode 100644 index 00000000..660f55d5 --- /dev/null +++ b/Docs/Separation/Evidence/application-browser.json @@ -0,0 +1,39 @@ +{ + "passed": true, + "checks": [ + "unauthenticated root challenges with Projects return", + "branded /Account/Login", + "branded /Account/Register", + "branded /Account/ForgotPassword", + "branded /Account/ResendVerificationEmail", + "branded /Account/VerifyEmailConfirmation", + "branded /Account/ResetPassword", + "branded /Account/VerifyEmail", + "branded /Account/AccessDenied", + "branded /Account/Login", + "normal login returns requested Projects", + "authenticated root lands on Projects", + "authenticated sign-in honors safe deep link", + "external return URL rejected", + "persisted theme plotdirector", + "persisted theme warm-light", + "persisted theme warm-dark", + "persisted theme modern-light", + "persisted theme modern-dark", + "persisted theme rose-pink", + "persisted theme baby-blue", + "existing synthetic project", + "existing synthetic book/manuscript workspace", + "real authenticated Context Workspace", + "real SignalR connection established", + "Word taskpane route (browser only)", + "existing subscription page; no payment initiated", + "application-owned Projects PWA manifest", + "logout returns branded application sign-in", + "unauthenticated deep-link login returns requested project" + ], + "errors": [], + "physicalWordTested": false, + "externalPaymentsTested": false, + "realEmailDeliveryTested": false +} \ No newline at end of file diff --git a/Docs/Separation/Evidence/application-context.png b/Docs/Separation/Evidence/application-context.png new file mode 100644 index 00000000..7d1488bb Binary files /dev/null and b/Docs/Separation/Evidence/application-context.png differ diff --git a/Docs/Separation/Evidence/application-deploy-isolation.json b/Docs/Separation/Evidence/application-deploy-isolation.json new file mode 100644 index 00000000..0e5ea904 --- /dev/null +++ b/Docs/Separation/Evidence/application-deploy-isolation.json @@ -0,0 +1,6 @@ +{ + "passed": true, + "websitePidBefore": "984560", + "websitePidAfter": "984560", + "applicationSourceCommit": "43ff8f15132f03e3abc36c943bfc3916da3a14da" +} diff --git a/Docs/Separation/Evidence/application-deployment.json b/Docs/Separation/Evidence/application-deployment.json new file mode 100644 index 00000000..de269ed8 --- /dev/null +++ b/Docs/Separation/Evidence/application-deployment.json @@ -0,0 +1 @@ +{"availability":{"confirmed_inactive_to_health_ready_seconds":6.693927165004425,"definition":"Monotonic intervals include stop/start commands; observed public outage measured separately on Atlas.","service_stop_to_start_seconds":3.339812299993355,"stop_request_to_health_ready_seconds":6.912828799977433,"stop_request_to_start_command_complete_seconds":3.5587169509963132},"checks":{"activation":true,"application":{"database":"PlotDirector_Development","environment":"Development","healthy":true,"sourceCommit":"43ff8f15132f03e3abc36c943bfc3916da3a14da","version":"1.0.0"},"binary_identity":true,"database":{"complete_history":true,"healthy":true,"history":{"baselined":317,"executed":21,"expected":338,"latest_successful_release":{"activated_utc":"2026-11-27T20:12:54.5785343Z","activation_kind":"Deploy","application_version":"1.0.0","deployment_identifier":"20261127T201227Z-0cb5cdeff9f9","manifest_sha256":"0a20855b684d19e331c8e54c06d6a7745f9de56b87b743625f60b0ef395cda12","package_sha256":"0e3a92cfdd0108a306743c9a285ea41992ee3e2975b92bd4d5a16c9dfb6ef8e0","recorded":true,"release_identifier":"development-context-navigation-9dcd29d423b2-20261127T201127Z","source_commit":"9dcd29d423b20e373e49fb28180d993c40aa165d"},"recorded":338,"successful_release_count":23},"history_verification_seconds":0.1346329},"http_login":true,"http_root":true},"completed_utc":"2026-11-27T21:20:50.667+00:00","database_backup":{"options":["COPY_ONLY","CHECKSUM","VERIFYONLY"],"path":"/sql/mssql/backup/PlotDirector_Development-predeploy-20261127T212026Z-7da587c8951a.bak","verified":true},"deployment_id":"20261127T212026Z-7da587c8951a","failures":[],"format":1,"migration_history":{"complete":true,"database_bytes":2097152000,"history":{"baselined":317,"executed":21,"expected":338,"latest_successful_release":{"activated_utc":"2026-11-27T20:12:54.5785343Z","activation_kind":"Deploy","application_version":"1.0.0","deployment_identifier":"20261127T201227Z-0cb5cdeff9f9","manifest_sha256":"0a20855b684d19e331c8e54c06d6a7745f9de56b87b743625f60b0ef395cda12","package_sha256":"0e3a92cfdd0108a306743c9a285ea41992ee3e2975b92bd4d5a16c9dfb6ef8e0","recorded":true,"release_identifier":"development-context-navigation-9dcd29d423b2-20261127T201127Z","source_commit":"9dcd29d423b20e373e49fb28180d993c40aa165d"},"recorded":338,"successful_release_count":23},"history_verification_seconds":0.2583421,"schema":"3d6e163f7cb8fff6bd17834ae8097dcf68be03894ce644844621dc191336cb7a"},"migrations":{"baselined":0,"committed":[],"committed_list_truncated":false,"executed":0,"schema":"3d6e163f7cb8fff6bd17834ae8097dcf68be03894ce644844621dc191336cb7a"},"operation":"activate","origin":"web1","phases":[{"completed_utc":"2026-11-27T21:20:28.637+00:00","exclusive_seconds":1.738749,"name":"package_validation","outcome":"passed","parent":null,"seconds":1.738749,"started_utc":"2026-11-27T21:20:26.898+00:00"},{"completed_utc":"2026-11-27T21:20:32.440+00:00","exclusive_seconds":3.802962,"name":"package_validation","outcome":"passed","parent":null,"seconds":3.802962,"started_utc":"2026-11-27T21:20:28.637+00:00"},{"completed_utc":"2026-11-27T21:20:34.189+00:00","exclusive_seconds":0.72328,"name":"database_state_verification","outcome":"passed","parent":null,"seconds":0.981622,"started_utc":"2026-11-27T21:20:33.207+00:00"},{"clock":"SQL worker Stopwatch; measured duration, UTC endpoints unavailable","completed_utc":null,"exclusive_seconds":0.258342,"name":"migration_history_verification","outcome":"passed","parent":"database_state_verification","seconds":0.258342,"started_utc":null},{"completed_utc":"2026-11-27T21:20:43.481+00:00","exclusive_seconds":9.268891,"name":"database_backup","outcome":"passed","parent":null,"seconds":9.268891,"started_utc":"2026-11-27T21:20:34.212+00:00"},{"completed_utc":"2026-11-27T21:20:43.725+00:00","exclusive_seconds":0.218798,"name":"service_stop","outcome":"passed","parent":null,"seconds":0.218798,"started_utc":"2026-11-27T21:20:43.506+00:00"},{"completed_utc":"2026-11-27T21:20:44.822+00:00","exclusive_seconds":1.080939,"name":"migration_execution","outcome":"passed","parent":null,"seconds":1.080939,"started_utc":"2026-11-27T21:20:43.741+00:00"},{"completed_utc":"2026-11-27T21:20:47.034+00:00","exclusive_seconds":2.203944,"name":"release_installation","outcome":"passed","parent":null,"seconds":2.203944,"started_utc":"2026-11-27T21:20:44.830+00:00"},{"completed_utc":"2026-11-27T21:20:47.041+00:00","exclusive_seconds":0.001521,"name":"release_activation","outcome":"passed","parent":null,"seconds":0.001521,"started_utc":"2026-11-27T21:20:47.039+00:00"},{"completed_utc":"2026-11-27T21:20:47.065+00:00","exclusive_seconds":0.023552,"name":"service_start","outcome":"passed","parent":null,"seconds":0.023552,"started_utc":"2026-11-27T21:20:47.041+00:00"},{"completed_utc":"2026-11-27T21:20:50.418+00:00","exclusive_seconds":0.532236,"name":"postactivation_verification","outcome":"passed","parent":"application_health_readiness","seconds":0.666869,"started_utc":"2026-11-27T21:20:49.752+00:00"},{"clock":"SQL worker Stopwatch; measured duration, UTC endpoints unavailable","completed_utc":null,"exclusive_seconds":0.134633,"name":"migration_history_verification","outcome":"passed","parent":"postactivation_verification","seconds":0.134633,"started_utc":null},{"completed_utc":"2026-11-27T21:20:50.419+00:00","exclusive_seconds":2.687195,"name":"application_health_readiness","outcome":"passed","parent":null,"seconds":3.354064,"started_utc":"2026-11-27T21:20:47.065+00:00"},{"completed_utc":"2026-11-27T21:20:50.477+00:00","exclusive_seconds":0.049059,"name":"postactivation_verification","outcome":"passed","parent":null,"seconds":0.049059,"started_utc":"2026-11-27T21:20:50.428+00:00"},{"completed_utc":"2026-11-27T21:20:50.667+00:00","exclusive_seconds":0.016329,"name":"receipt_generation","outcome":"passed","parent":null,"seconds":0.016329,"started_utc":"2026-11-27T21:20:50.651+00:00"}],"previous_release":{"deployment":"20261127T201227Z-0cb5cdeff9f9","package_sha256":"0e3a92cfdd0108a306743c9a285ea41992ee3e2975b92bd4d5a16c9dfb6ef8e0","release":"development-context-navigation-9dcd29d423b2-20261127T201127Z","source_commit":"9dcd29d423b20e373e49fb28180d993c40aa165d","version":"1.0.0"},"protected_evidence_reference":"/opt/plotdirector-dev/deployment-evidence/20261127T212026Z-7da587c8951a.jsonl","recovery":"No automatic database restore or application rollback. Review protected attempt evidence on failure.","release":{"application_sha256":"f18351be6f093f4cf74e3a4f281b141c3e748a15634c13e8a76a829d68041282","dll_sha256":"e02741c3416850bbed132beb00025f17fcf79ca51d549aedadbffb15b31d680b","id":"development-43ff8f15132f-20261127T211739Z","manifest_sha256":"b6a99fb28cfb1caa7ce695971db596cfd880c77e7ad12916b074507df5a6ee6c","package_sha256":"fee88d65546dfb5f020d9314d2def8dd35fe1eb7f8ea9074b171784bb545f95c","source_commit":"43ff8f15132f03e3abc36c943bfc3916da3a14da","version":"1.0.0"},"release_history":{"activated_utc":"2026-11-27T21:20:50.4569986Z","activation_kind":"Deploy","application_version":"1.0.0","deployment_identifier":"20261127T212026Z-7da587c8951a","manifest_sha256":"b6a99fb28cfb1caa7ce695971db596cfd880c77e7ad12916b074507df5a6ee6c","package_sha256":"fee88d65546dfb5f020d9314d2def8dd35fe1eb7f8ea9074b171784bb545f95c","recorded":true,"release_identifier":"development-43ff8f15132f-20261127T211739Z","source_commit":"43ff8f15132f03e3abc36c943bfc3916da3a14da"},"started_utc":"2026-11-27T21:20:26.824+00:00","status":"activated","timing":{"clock":"monotonic; UTC timestamps for correlation only","measured_top_level_seconds":22.74043,"total_seconds":23.842826,"unattributed_seconds":1.102396},"transport":{"compression_ratio":1.0,"method":"none","original_bytes":555724800,"original_sha256":"fee88d65546dfb5f020d9314d2def8dd35fe1eb7f8ea9074b171784bb545f95c","transferred_bytes":555724800,"transferred_sha256":"fee88d65546dfb5f020d9314d2def8dd35fe1eb7f8ea9074b171784bb545f95c"},"unperformed_phases":["release_preparation","production_validation","remote_activation","receipt_retrieval","scope_verification","build","packaging_signing","compression","transfer","decompression","public_acceptance"],"warnings":["upload-metrics-unavailable; sender receipt may provide transfer measurements"]} diff --git a/Docs/Separation/Evidence/application-installed-pwa.png b/Docs/Separation/Evidence/application-installed-pwa.png new file mode 100644 index 00000000..cec3e8bb Binary files /dev/null and b/Docs/Separation/Evidence/application-installed-pwa.png differ diff --git a/Docs/Separation/Evidence/application-mfa.json b/Docs/Separation/Evidence/application-mfa.json new file mode 100644 index 00000000..0f1d5bbc --- /dev/null +++ b/Docs/Separation/Evidence/application-mfa.json @@ -0,0 +1,13 @@ +{ + "passed": true, + "checks": [ + "enabled MFA on dedicated synthetic account", + "real pending MFA challenge uses public brand", + "real recovery challenge uses public brand", + "real TOTP verification returns requested protected deep link", + "original disabled MFA state restored" + ], + "fixtureMfaRestored": true, + "failedStep": null, + "noSecretsOrRecoveryCodesRecorded": true +} \ No newline at end of file diff --git a/Docs/Separation/Evidence/application-modern-dark.png b/Docs/Separation/Evidence/application-modern-dark.png new file mode 100644 index 00000000..d4fea834 Binary files /dev/null and b/Docs/Separation/Evidence/application-modern-dark.png differ diff --git a/Docs/Separation/Evidence/application-pwa.json b/Docs/Separation/Evidence/application-pwa.json new file mode 100644 index 00000000..5cc8d89a --- /dev/null +++ b/Docs/Separation/Evidence/application-pwa.json @@ -0,0 +1,13 @@ +{ + "passed": true, + "installedChromium": true, + "checks": [ + "real installed PWA launches authenticated Projects by default", + "all authenticated themes retained", + "offline requests fail honestly; no cached authenticated response", + "installed signed-out authentication keeps public brand", + "installed sign-in returns Projects" + ], + "ownerPwaMigrated": false, + "physicalWordTested": false +} \ No newline at end of file diff --git a/Docs/Separation/Evidence/application-restoration.json b/Docs/Separation/Evidence/application-restoration.json new file mode 100644 index 00000000..526b35b3 --- /dev/null +++ b/Docs/Separation/Evidence/application-restoration.json @@ -0,0 +1 @@ +{"availability":{"confirmed_inactive_to_health_ready_seconds":5.840198758000042,"definition":"Monotonic intervals include stop/start commands; observed public outage measured separately on Atlas.","service_stop_to_start_seconds":2.3100903729791753,"stop_request_to_health_ready_seconds":6.004454798006918,"stop_request_to_start_command_complete_seconds":2.474349909054581},"checks":{"activation":true,"application":{"database":"PlotDirector_Development","environment":"Development","healthy":true,"sourceCommit":"43ff8f15132f03e3abc36c943bfc3916da3a14da","version":"1.0.0"},"binary_identity":true,"database":{"complete_history":true,"healthy":true,"history":{"baselined":317,"executed":21,"expected":338,"latest_successful_release":{"activated_utc":"2026-11-27T21:24:56.9858981Z","activation_kind":"Rollback","application_version":"1.0.0","deployment_identifier":"20261127T212436Z-82253877aca4","manifest_sha256":"922069e6e99cfd711f56b950436fe47498531f89edac645a6d3255479ae0913a","package_sha256":"d4c7c879697d5c6f21dc51b2162b05b5b6f313966b53b84de92b21c0c0a72e81","recorded":true,"release_identifier":"development-separation-rollback-9dcd29d4-20261127","source_commit":"9dcd29d423b20e373e49fb28180d993c40aa165d"},"recorded":338,"successful_release_count":25},"history_verification_seconds":0.2698475},"http_login":true,"http_root":true},"completed_utc":"2026-11-27T21:25:18.795+00:00","database_backup":{"options":["COPY_ONLY","CHECKSUM","VERIFYONLY"],"path":"/sql/mssql/backup/PlotDirector_Development-predeploy-20261127T212457Z-d71e05af54c6.bak","verified":true},"deployment_id":"20261127T212457Z-d71e05af54c6","failures":[],"format":1,"migration_history":{"complete":true,"database_bytes":2097152000,"history":{"baselined":317,"executed":21,"expected":338,"latest_successful_release":{"activated_utc":"2026-11-27T21:24:56.9858981Z","activation_kind":"Rollback","application_version":"1.0.0","deployment_identifier":"20261127T212436Z-82253877aca4","manifest_sha256":"922069e6e99cfd711f56b950436fe47498531f89edac645a6d3255479ae0913a","package_sha256":"d4c7c879697d5c6f21dc51b2162b05b5b6f313966b53b84de92b21c0c0a72e81","recorded":true,"release_identifier":"development-separation-rollback-9dcd29d4-20261127","source_commit":"9dcd29d423b20e373e49fb28180d993c40aa165d"},"recorded":338,"successful_release_count":25},"history_verification_seconds":0.2725061,"schema":"3d6e163f7cb8fff6bd17834ae8097dcf68be03894ce644844621dc191336cb7a"},"migrations":{"baselined":0,"committed":[],"committed_list_truncated":false,"executed":0,"schema":"3d6e163f7cb8fff6bd17834ae8097dcf68be03894ce644844621dc191336cb7a"},"operation":"activate","origin":"web1","phases":[{"completed_utc":"2026-11-27T21:24:58.385+00:00","exclusive_seconds":0.998231,"name":"package_validation","outcome":"passed","parent":null,"seconds":0.998231,"started_utc":"2026-11-27T21:24:57.387+00:00"},{"completed_utc":"2026-11-27T21:24:59.466+00:00","exclusive_seconds":1.080746,"name":"decompression","outcome":"passed","parent":null,"seconds":1.080746,"started_utc":"2026-11-27T21:24:58.386+00:00"},{"completed_utc":"2026-11-27T21:25:01.312+00:00","exclusive_seconds":1.846027,"name":"package_validation","outcome":"passed","parent":null,"seconds":1.846027,"started_utc":"2026-11-27T21:24:59.466+00:00"},{"completed_utc":"2026-11-27T21:25:03.810+00:00","exclusive_seconds":0.759381,"name":"database_state_verification","outcome":"passed","parent":null,"seconds":1.031887,"started_utc":"2026-11-27T21:25:02.778+00:00"},{"clock":"SQL worker Stopwatch; measured duration, UTC endpoints unavailable","completed_utc":null,"exclusive_seconds":0.272506,"name":"migration_history_verification","outcome":"passed","parent":"database_state_verification","seconds":0.272506,"started_utc":null},{"completed_utc":"2026-11-27T21:25:12.453+00:00","exclusive_seconds":8.621474,"name":"database_backup","outcome":"passed","parent":null,"seconds":8.621474,"started_utc":"2026-11-27T21:25:03.832+00:00"},{"completed_utc":"2026-11-27T21:25:12.650+00:00","exclusive_seconds":0.16415,"name":"service_stop","outcome":"passed","parent":null,"seconds":0.16415,"started_utc":"2026-11-27T21:25:12.485+00:00"},{"completed_utc":"2026-11-27T21:25:13.894+00:00","exclusive_seconds":1.231982,"name":"migration_execution","outcome":"passed","parent":null,"seconds":1.231982,"started_utc":"2026-11-27T21:25:12.662+00:00"},{"completed_utc":"2026-11-27T21:25:14.450+00:00","exclusive_seconds":0.547519,"name":"release_installation","outcome":"passed","parent":null,"seconds":0.547519,"started_utc":"2026-11-27T21:25:13.902+00:00"},{"completed_utc":"2026-11-27T21:25:14.938+00:00","exclusive_seconds":0.206027,"name":"release_activation","outcome":"passed","parent":null,"seconds":0.206027,"started_utc":"2026-11-27T21:25:14.732+00:00"},{"completed_utc":"2026-11-27T21:25:14.960+00:00","exclusive_seconds":0.02138,"name":"service_start","outcome":"passed","parent":null,"seconds":0.02138,"started_utc":"2026-11-27T21:25:14.938+00:00"},{"completed_utc":"2026-11-27T21:25:18.490+00:00","exclusive_seconds":0.560515,"name":"postactivation_verification","outcome":"passed","parent":"application_health_readiness","seconds":0.830363,"started_utc":"2026-11-27T21:25:17.659+00:00"},{"clock":"SQL worker Stopwatch; measured duration, UTC endpoints unavailable","completed_utc":null,"exclusive_seconds":0.269848,"name":"migration_history_verification","outcome":"passed","parent":"postactivation_verification","seconds":0.269848,"started_utc":null},{"completed_utc":"2026-11-27T21:25:18.490+00:00","exclusive_seconds":2.699682,"name":"application_health_readiness","outcome":"passed","parent":null,"seconds":3.530045,"started_utc":"2026-11-27T21:25:14.960+00:00"},{"completed_utc":"2026-11-27T21:25:18.550+00:00","exclusive_seconds":0.050608,"name":"postactivation_verification","outcome":"passed","parent":null,"seconds":0.050608,"started_utc":"2026-11-27T21:25:18.499+00:00"},{"completed_utc":"2026-11-27T21:25:18.795+00:00","exclusive_seconds":0.017374,"name":"receipt_generation","outcome":"passed","parent":null,"seconds":0.017374,"started_utc":"2026-11-27T21:25:18.777+00:00"}],"previous_release":{"deployment":"20261127T212436Z-82253877aca4","package_sha256":"d4c7c879697d5c6f21dc51b2162b05b5b6f313966b53b84de92b21c0c0a72e81","release":"development-separation-rollback-9dcd29d4-20261127","source_commit":"9dcd29d423b20e373e49fb28180d993c40aa165d","version":"1.0.0"},"protected_evidence_reference":"/opt/plotdirector-dev/deployment-evidence/20261127T212457Z-d71e05af54c6.jsonl","recovery":"No automatic database restore or application rollback. Review protected attempt evidence on failure.","release":{"application_sha256":"f18351be6f093f4cf74e3a4f281b141c3e748a15634c13e8a76a829d68041282","dll_sha256":"e02741c3416850bbed132beb00025f17fcf79ca51d549aedadbffb15b31d680b","id":"development-separation-restore-43ff8f15-20261127","manifest_sha256":"9df8ffb1c6e6d9e9364a39bea3dd25fea84f9fcc3ea48da0f4ba745b8b4b50b3","package_sha256":"ee7af5bc346112db5eb88af046468b25eae9ff1787ff7ad87ad56900ebcbd2fe","source_commit":"43ff8f15132f03e3abc36c943bfc3916da3a14da","version":"1.0.0"},"release_history":{"activated_utc":"2026-11-27T21:25:18.5215306Z","activation_kind":"Deploy","application_version":"1.0.0","deployment_identifier":"20261127T212457Z-d71e05af54c6","manifest_sha256":"9df8ffb1c6e6d9e9364a39bea3dd25fea84f9fcc3ea48da0f4ba745b8b4b50b3","package_sha256":"ee7af5bc346112db5eb88af046468b25eae9ff1787ff7ad87ad56900ebcbd2fe","recorded":true,"release_identifier":"development-separation-restore-43ff8f15-20261127","source_commit":"43ff8f15132f03e3abc36c943bfc3916da3a14da"},"started_utc":"2026-11-27T21:24:57.309+00:00","status":"activated","timing":{"clock":"monotonic; UTC timestamps for correlation only","measured_top_level_seconds":19.34745,"total_seconds":21.486394,"unattributed_seconds":2.138944},"transport":{"compression_ratio":0.298588,"compression_seconds_atlas":2.1182439870317467,"method":"zstd","original_bytes":555724800,"original_sha256":"ee7af5bc346112db5eb88af046468b25eae9ff1787ff7ad87ad56900ebcbd2fe","settings":{"level":6,"threads":4},"transferred_bytes":165932869,"transferred_sha256":"e808177a602280f194a96603f522ef5a6b4fbd7f1e414e206c971ccfd1d06d6a"},"unperformed_phases":["release_preparation","production_validation","remote_activation","receipt_retrieval","scope_verification","build","packaging_signing","compression","transfer","public_acceptance"],"warnings":["upload-metrics-unavailable; sender receipt may provide transfer measurements"]} diff --git a/Docs/Separation/Evidence/application-rollback-isolation.json b/Docs/Separation/Evidence/application-rollback-isolation.json new file mode 100644 index 00000000..370b2a52 --- /dev/null +++ b/Docs/Separation/Evidence/application-rollback-isolation.json @@ -0,0 +1,9 @@ +{ + "passed": true, + "websitePidBefore": "984560", + "websitePidAfter": "984560", + "applicationRollbackSource": "9dcd29d423b20e373e49fb28180d993c40aa165d", + "applicationRestoredSource": "43ff8f15132f03e3abc36c943bfc3916da3a14da", + "signedCompressedPackages": true, + "sqlExecuted": 0 +} diff --git a/Docs/Separation/Evidence/application-rollback.json b/Docs/Separation/Evidence/application-rollback.json new file mode 100644 index 00000000..cd2652e3 --- /dev/null +++ b/Docs/Separation/Evidence/application-rollback.json @@ -0,0 +1 @@ +{"availability":{"confirmed_inactive_to_health_ready_seconds":5.588434814999346,"definition":"Monotonic intervals include stop/start commands; observed public outage measured separately on Atlas.","service_stop_to_start_seconds":2.1945657380274497,"stop_request_to_health_ready_seconds":5.736365418008063,"stop_request_to_start_command_complete_seconds":2.342501761042513},"checks":{"activation":true,"application":{"database":"PlotDirector_Development","environment":"Development","healthy":true,"sourceCommit":"9dcd29d423b20e373e49fb28180d993c40aa165d","version":"1.0.0"},"binary_identity":true,"database":{"complete_history":true,"healthy":true,"history":{"baselined":317,"executed":21,"expected":338,"latest_successful_release":{"activated_utc":"2026-11-27T21:20:50.4569986Z","activation_kind":"Deploy","application_version":"1.0.0","deployment_identifier":"20261127T212026Z-7da587c8951a","manifest_sha256":"b6a99fb28cfb1caa7ce695971db596cfd880c77e7ad12916b074507df5a6ee6c","package_sha256":"fee88d65546dfb5f020d9314d2def8dd35fe1eb7f8ea9074b171784bb545f95c","recorded":true,"release_identifier":"development-43ff8f15132f-20261127T211739Z","source_commit":"43ff8f15132f03e3abc36c943bfc3916da3a14da"},"recorded":338,"successful_release_count":24},"history_verification_seconds":0.179227},"http_login":true,"http_root":true},"completed_utc":"2026-11-27T21:24:57.218+00:00","database_backup":{"options":["COPY_ONLY","CHECKSUM","VERIFYONLY"],"path":"/sql/mssql/backup/PlotDirector_Development-predeploy-20261127T212436Z-82253877aca4.bak","verified":true},"deployment_id":"20261127T212436Z-82253877aca4","failures":[],"format":1,"migration_history":{"complete":true,"database_bytes":2097152000,"history":{"baselined":317,"executed":21,"expected":338,"latest_successful_release":{"activated_utc":"2026-11-27T21:20:50.4569986Z","activation_kind":"Deploy","application_version":"1.0.0","deployment_identifier":"20261127T212026Z-7da587c8951a","manifest_sha256":"b6a99fb28cfb1caa7ce695971db596cfd880c77e7ad12916b074507df5a6ee6c","package_sha256":"fee88d65546dfb5f020d9314d2def8dd35fe1eb7f8ea9074b171784bb545f95c","recorded":true,"release_identifier":"development-43ff8f15132f-20261127T211739Z","source_commit":"43ff8f15132f03e3abc36c943bfc3916da3a14da"},"recorded":338,"successful_release_count":24},"history_verification_seconds":0.253517,"schema":"3d6e163f7cb8fff6bd17834ae8097dcf68be03894ce644844621dc191336cb7a"},"migrations":{"baselined":0,"committed":[],"committed_list_truncated":false,"executed":0,"schema":"3d6e163f7cb8fff6bd17834ae8097dcf68be03894ce644844621dc191336cb7a"},"operation":"rollback","origin":"web1","phases":[{"completed_utc":"2026-11-27T21:24:37.081+00:00","exclusive_seconds":0.477547,"name":"package_validation","outcome":"passed","parent":null,"seconds":0.477547,"started_utc":"2026-11-27T21:24:36.604+00:00"},{"completed_utc":"2026-11-27T21:24:38.315+00:00","exclusive_seconds":1.233742,"name":"decompression","outcome":"passed","parent":null,"seconds":1.233742,"started_utc":"2026-11-27T21:24:37.081+00:00"},{"completed_utc":"2026-11-27T21:24:40.131+00:00","exclusive_seconds":1.815534,"name":"package_validation","outcome":"passed","parent":null,"seconds":1.815534,"started_utc":"2026-11-27T21:24:38.315+00:00"},{"completed_utc":"2026-11-27T21:24:42.507+00:00","exclusive_seconds":0.751484,"name":"database_state_verification","outcome":"passed","parent":null,"seconds":1.005001,"started_utc":"2026-11-27T21:24:41.502+00:00"},{"clock":"SQL worker Stopwatch; measured duration, UTC endpoints unavailable","completed_utc":null,"exclusive_seconds":0.253517,"name":"migration_history_verification","outcome":"passed","parent":"database_state_verification","seconds":0.253517,"started_utc":null},{"completed_utc":"2026-11-27T21:24:51.185+00:00","exclusive_seconds":8.655203,"name":"database_backup","outcome":"passed","parent":null,"seconds":8.655203,"started_utc":"2026-11-27T21:24:42.530+00:00"},{"completed_utc":"2026-11-27T21:24:51.362+00:00","exclusive_seconds":0.147841,"name":"service_stop","outcome":"passed","parent":null,"seconds":0.147841,"started_utc":"2026-11-27T21:24:51.214+00:00"},{"completed_utc":"2026-11-27T21:24:52.669+00:00","exclusive_seconds":1.290414,"name":"migration_execution","outcome":"passed","parent":null,"seconds":1.290414,"started_utc":"2026-11-27T21:24:51.379+00:00"},{"completed_utc":"2026-11-27T21:24:53.240+00:00","exclusive_seconds":0.562564,"name":"release_installation","outcome":"passed","parent":null,"seconds":0.562564,"started_utc":"2026-11-27T21:24:52.678+00:00"},{"completed_utc":"2026-11-27T21:24:53.534+00:00","exclusive_seconds":0.187274,"name":"release_activation","outcome":"passed","parent":null,"seconds":0.187274,"started_utc":"2026-11-27T21:24:53.347+00:00"},{"completed_utc":"2026-11-27T21:24:53.556+00:00","exclusive_seconds":0.021814,"name":"service_start","outcome":"passed","parent":null,"seconds":0.021814,"started_utc":"2026-11-27T21:24:53.535+00:00"},{"completed_utc":"2026-11-27T21:24:56.950+00:00","exclusive_seconds":0.56751,"name":"postactivation_verification","outcome":"passed","parent":"application_health_readiness","seconds":0.746737,"started_utc":"2026-11-27T21:24:56.203+00:00"},{"clock":"SQL worker Stopwatch; measured duration, UTC endpoints unavailable","completed_utc":null,"exclusive_seconds":0.179227,"name":"migration_history_verification","outcome":"passed","parent":"postactivation_verification","seconds":0.179227,"started_utc":null},{"completed_utc":"2026-11-27T21:24:56.950+00:00","exclusive_seconds":2.647068,"name":"application_health_readiness","outcome":"passed","parent":null,"seconds":3.393805,"started_utc":"2026-11-27T21:24:53.556+00:00"},{"completed_utc":"2026-11-27T21:24:57.011+00:00","exclusive_seconds":0.050976,"name":"postactivation_verification","outcome":"passed","parent":null,"seconds":0.050976,"started_utc":"2026-11-27T21:24:56.960+00:00"},{"completed_utc":"2026-11-27T21:24:57.218+00:00","exclusive_seconds":0.018179,"name":"receipt_generation","outcome":"passed","parent":null,"seconds":0.018179,"started_utc":"2026-11-27T21:24:57.200+00:00"}],"previous_release":{"deployment":"20261127T212026Z-7da587c8951a","package_sha256":"fee88d65546dfb5f020d9314d2def8dd35fe1eb7f8ea9074b171784bb545f95c","release":"development-43ff8f15132f-20261127T211739Z","source_commit":"43ff8f15132f03e3abc36c943bfc3916da3a14da","version":"1.0.0"},"protected_evidence_reference":"/opt/plotdirector-dev/deployment-evidence/20261127T212436Z-82253877aca4.jsonl","recovery":"No automatic database restore or application rollback. Review protected attempt evidence on failure.","release":{"application_sha256":"9d1aaf9cc2b945e11b25b70a24d00679da086af6df6ea03f10d7d569472e02a9","dll_sha256":"7fc84cb642bba8ddd9726acdcc5fed9566544b4adcff3a4ec09f37d47df3aa29","id":"development-separation-rollback-9dcd29d4-20261127","manifest_sha256":"922069e6e99cfd711f56b950436fe47498531f89edac645a6d3255479ae0913a","package_sha256":"d4c7c879697d5c6f21dc51b2162b05b5b6f313966b53b84de92b21c0c0a72e81","source_commit":"9dcd29d423b20e373e49fb28180d993c40aa165d","version":"1.0.0"},"release_history":{"activated_utc":"2026-11-27T21:24:56.9858981Z","activation_kind":"Rollback","application_version":"1.0.0","deployment_identifier":"20261127T212436Z-82253877aca4","manifest_sha256":"922069e6e99cfd711f56b950436fe47498531f89edac645a6d3255479ae0913a","package_sha256":"d4c7c879697d5c6f21dc51b2162b05b5b6f313966b53b84de92b21c0c0a72e81","recorded":true,"release_identifier":"development-separation-rollback-9dcd29d4-20261127","source_commit":"9dcd29d423b20e373e49fb28180d993c40aa165d"},"started_utc":"2026-11-27T21:24:36.518+00:00","status":"activated","timing":{"clock":"monotonic; UTC timestamps for correlation only","measured_top_level_seconds":18.859894,"total_seconds":20.700321,"unattributed_seconds":1.840427},"transport":{"compression_ratio":0.298584,"compression_seconds_atlas":2.0760917220031843,"method":"zstd","original_bytes":555735040,"original_sha256":"d4c7c879697d5c6f21dc51b2162b05b5b6f313966b53b84de92b21c0c0a72e81","settings":{"level":6,"threads":4},"transferred_bytes":165933765,"transferred_sha256":"08604ed9f353a74d143209ee7850000ee247e1fdced7e9858621e38db92b1631"},"unperformed_phases":["release_preparation","production_validation","remote_activation","receipt_retrieval","scope_verification","build","packaging_signing","compression","transfer","public_acceptance"],"warnings":["upload-metrics-unavailable; sender receipt may provide transfer measurements"]} diff --git a/Docs/Separation/Evidence/brand-compatibility.json b/Docs/Separation/Evidence/brand-compatibility.json new file mode 100644 index 00000000..cdf32767 --- /dev/null +++ b/Docs/Separation/Evidence/brand-compatibility.json @@ -0,0 +1,7 @@ +{ + "passed": true, + "version": "public-brand-v1", + "websiteSourceCommit": "376b0bfab9dd5244d695f3fc3108d9e577a7b807", + "sharedFiles": 114, + "applicationSourceContentMatches": true +} diff --git a/Docs/Separation/Evidence/development-baseline-refresh.json b/Docs/Separation/Evidence/development-baseline-refresh.json new file mode 100644 index 00000000..32e32b32 --- /dev/null +++ b/Docs/Separation/Evidence/development-baseline-refresh.json @@ -0,0 +1 @@ +{"completeLiveHistory":true,"databaseWrites":false,"historyEntries":338,"passed":true,"previousBaselineRetained":"/var/lib/plotdirector-dev-deployment/baseline-before-separation-20261127T211501Z","previousSource":"9b1770d96d17b7b2cc4f42efb936d822d20fe31e","schema":"3d6e163f7cb8fff6bd17834ae8097dcf68be03894ce644844621dc191336cb7a","serviceRestarted":false,"signedPackageVerified":true,"sourceCommit":"9dcd29d423b20e373e49fb28180d993c40aa165d"} diff --git a/Docs/Separation/Evidence/development-help-consumption.json b/Docs/Separation/Evidence/development-help-consumption.json new file mode 100644 index 00000000..ad739dda --- /dev/null +++ b/Docs/Separation/Evidence/development-help-consumption.json @@ -0,0 +1,8 @@ +{ + "channel": "Development", + "version": "2026.11.27-separation-development", + "manifestSha256": "de91a5e48252e3b0ababecac84d84758554de9686dddd7da8860fe1b46b8772e", + "articles": 409, + "sourceCommit": "43ff8f15132f03e3abc36c943bfc3916da3a14da", + "serviceRestarted": false +} diff --git a/Docs/Separation/Evidence/dns-observation.json b/Docs/Separation/Evidence/dns-observation.json new file mode 100644 index 00000000..dfd0fcb3 --- /dev/null +++ b/Docs/Separation/Evidence/dns-observation.json @@ -0,0 +1,14 @@ +{ + "plotdirector.com": [ + "85.190.124.132" + ], + "app.plotdirector.com": [ + "plotdirector.com.", + "85.190.124.132" + ], + "dev.plotdirector.com": [ + "77.104.168.236" + ], + "website-dev.plotdirector.com": [], + "apexVerificationTxtPresent": true +} diff --git a/Docs/Separation/Evidence/help-publication.json b/Docs/Separation/Evidence/help-publication.json new file mode 100644 index 00000000..8b0a5445 --- /dev/null +++ b/Docs/Separation/Evidence/help-publication.json @@ -0,0 +1,16 @@ +{ + "passed": true, + "developmentPublicationConsumed": true, + "wrongProductionChannelRejected": true, + "articleIdentifiersPreserved": true, + "hotReloadVerified": true, + "previousPublicationRestored": true, + "servicePidsBefore": { + "plotdirector-dev": "963308", + "plotdirector-website-dev": "984560" + }, + "servicePidsAfter": { + "plotdirector-dev": "963308", + "plotdirector-website-dev": "984560" + } +} diff --git a/Docs/Separation/Evidence/nginx-compatibility.json b/Docs/Separation/Evidence/nginx-compatibility.json new file mode 100644 index 00000000..e1602a21 --- /dev/null +++ b/Docs/Separation/Evidence/nginx-compatibility.json @@ -0,0 +1,17 @@ +{ + "passed": true, + "sandboxOnly": true, + "checks": [ + "both prepared vhosts pass nginx -t", + "public root goes to independent website", + "legacy browser path/query /Projects/Details/123", + "legacy browser path/query /Account/ResetPassword", + "legacy browser path/query /problem-solver/workspace/characters", + "legacy browser path/query /admin/writing-solver", + "legacy browser path/query /onboarding", + "legacy API preserves POST body query and bearer header", + "legacy websocket upgrade reaches application", + "application host and noindex isolated", + "health endpoint denied on both public hosts" + ] +} diff --git a/Docs/Separation/Evidence/public-content-comparison.json b/Docs/Separation/Evidence/public-content-comparison.json index 8beb7a6b..c43febde 100644 --- a/Docs/Separation/Evidence/public-content-comparison.json +++ b/Docs/Separation/Evidence/public-content-comparison.json @@ -1,5 +1,5 @@ { - "passed": false, + "passed": true, "pages": [ { "path": "/", @@ -15,15 +15,15 @@ }, { "path": "/pricing", - "samePublicText": false, + "samePublicText": true, "oldCharacters": 3661, - "newCharacters": 3662 + "newCharacters": 3661 }, { "path": "/help", - "samePublicText": false, + "samePublicText": true, "oldCharacters": 1897, - "newCharacters": 1895 + "newCharacters": 1897 }, { "path": "/about", diff --git a/Docs/Separation/Evidence/public-urls.json b/Docs/Separation/Evidence/public-urls.json index 99f4f26e..cbe11bd0 100644 --- a/Docs/Separation/Evidence/public-urls.json +++ b/Docs/Separation/Evidence/public-urls.json @@ -538,7 +538,9 @@ "GET /Help/Article/{contextKey}", "* /writing-problems/{**path} => 308 /problem-solver/{**path}", "POST /problem-solver/answer", - "GET /problem-solver?state={protectedHistory}" + "GET /problem-solver?state={protectedHistory}", + "GET /HelpDrawer/Article?key={publishedContextKey}", + "GET /HelpDrawer/Image?file={publishedAsset}" ], "crawlerFiles": [ "/robots.txt", diff --git a/Docs/Separation/Evidence/website-browser.json b/Docs/Separation/Evidence/website-browser.json new file mode 100644 index 00000000..7d2ebe6b --- /dev/null +++ b/Docs/Separation/Evidence/website-browser.json @@ -0,0 +1,34 @@ +{ + "passed": true, + "origin": "http://192.168.10.10:5051", + "checks": [ + "1440 /", + "1440 /features", + "1440 /pricing", + "1440 /problem-solver", + "1440 /problem-solver/browse", + "1440 /help", + "1440 /about", + "1440 /contact", + "1440 /privacy", + "1440 /terms", + "390 /", + "390 /features", + "390 /pricing", + "390 /problem-solver", + "390 /problem-solver/browse", + "390 /help", + "390 /about", + "390 /contact", + "390 /privacy", + "390 /terms", + "mobile navigation", + "server-rendered help search", + "published help article", + "Problem Solver completed 5 answers", + "no website PWA installation", + "application account links" + ], + "errors": [], + "failed": [] +} \ No newline at end of file diff --git a/Docs/Separation/Evidence/website-deployment.json b/Docs/Separation/Evidence/website-deployment.json new file mode 100644 index 00000000..41bdd43d --- /dev/null +++ b/Docs/Separation/Evidence/website-deployment.json @@ -0,0 +1 @@ +{"operation": "6fa8d162-8bea-4cbf-bc6d-2b2d4c51bfe4", "release": "website-separation-dev-2", "kind": "deploy", "startedUtc": "2026-11-27T21:14:11Z", "status": "activated", "sourceCommit": "376b0bfab9dd5244d695f3fc3108d9e577a7b807", "packageSha256": "0778827a54a8a4150e793e0c74400831031d588036a84d69ecccd21ca5759775", "manifestSha256": "2ffe8b12c95e0cb3f72d5d935b6ba6996f1bcee7269d3e706cff7dec5116997a", "previous": "/opt/plotdirector-website-dev/releases/website-separation-dev-1/app", "health": {"healthy": true, "product": "PlotDirector.Website", "sourceCommit": "376b0bfab9dd5244d695f3fc3108d9e577a7b807"}, "completedUtc": "2026-11-27T21:14:12Z"} diff --git a/Docs/Separation/Evidence/website-desktop-home.png b/Docs/Separation/Evidence/website-desktop-home.png new file mode 100644 index 00000000..3d4517af Binary files /dev/null and b/Docs/Separation/Evidence/website-desktop-home.png differ diff --git a/Docs/Separation/Evidence/website-http.json b/Docs/Separation/Evidence/website-http.json new file mode 100644 index 00000000..e5079fd2 --- /dev/null +++ b/Docs/Separation/Evidence/website-http.json @@ -0,0 +1,10 @@ +{ + "origin": "http://192.168.10.10:5051", + "productionPolicy": false, + "baselineUrls": 449, + "renderedPages": 527, + "internalPaths": 554, + "assets": 42, + "errors": [], + "passed": true +} diff --git a/Docs/Separation/Evidence/website-mobile-home.png b/Docs/Separation/Evidence/website-mobile-home.png new file mode 100644 index 00000000..20892f13 Binary files /dev/null and b/Docs/Separation/Evidence/website-mobile-home.png differ diff --git a/Docs/Separation/Evidence/website-problem-solver.png b/Docs/Separation/Evidence/website-problem-solver.png new file mode 100644 index 00000000..58322413 Binary files /dev/null and b/Docs/Separation/Evidence/website-problem-solver.png differ diff --git a/Docs/Separation/Evidence/website-production-policy.json b/Docs/Separation/Evidence/website-production-policy.json new file mode 100644 index 00000000..43dfe5bf --- /dev/null +++ b/Docs/Separation/Evidence/website-production-policy.json @@ -0,0 +1,10 @@ +{ + "origin": "http://127.0.0.1:5053", + "productionPolicy": true, + "baselineUrls": 449, + "renderedPages": 527, + "internalPaths": 554, + "assets": 42, + "errors": [], + "passed": true +} diff --git a/Docs/Separation/Evidence/website-restoration.json b/Docs/Separation/Evidence/website-restoration.json new file mode 100644 index 00000000..8fededb1 --- /dev/null +++ b/Docs/Separation/Evidence/website-restoration.json @@ -0,0 +1 @@ +{"operation": "f7f6e2a4-e08e-4f29-bc95-e6c521766d0b", "release": "website-separation-dev-2", "kind": "rollback", "startedUtc": "2026-11-27T21:14:14Z", "status": "activated", "sourceCommit": "376b0bfab9dd5244d695f3fc3108d9e577a7b807", "packageSha256": "0778827a54a8a4150e793e0c74400831031d588036a84d69ecccd21ca5759775", "manifestSha256": "2ffe8b12c95e0cb3f72d5d935b6ba6996f1bcee7269d3e706cff7dec5116997a", "previous": "/opt/plotdirector-website-dev/releases/website-separation-dev-1/app", "health": {"healthy": true, "product": "PlotDirector.Website", "sourceCommit": "376b0bfab9dd5244d695f3fc3108d9e577a7b807"}, "completedUtc": "2026-11-27T21:14:15Z"} diff --git a/Docs/Separation/Evidence/website-rollback.json b/Docs/Separation/Evidence/website-rollback.json new file mode 100644 index 00000000..b91ec13d --- /dev/null +++ b/Docs/Separation/Evidence/website-rollback.json @@ -0,0 +1 @@ +{"operation": "80264e72-3ba3-4ee7-8080-188237d0deb7", "release": "website-separation-dev-1", "kind": "rollback", "startedUtc": "2026-11-27T21:14:12Z", "status": "activated", "sourceCommit": "72a384af8839b7685e99cf50f7ac2824790caaf6", "packageSha256": "d7ffce7500180be5e60126050f94684ffacaa76cb1525b69fec00a2682785fb1", "manifestSha256": "8984124423051e2021fff0c429e842f5a7d74afef9af86b15c2677b6c523b288", "previous": "/opt/plotdirector-website-dev/releases/website-separation-dev-2/app", "health": {"healthy": true, "product": "PlotDirector.Website", "sourceCommit": "72a384af8839b7685e99cf50f7ac2824790caaf6"}, "completedUtc": "2026-11-27T21:14:13Z"} diff --git a/Docs/Separation/Evidence/website-with-application-stopped.json b/Docs/Separation/Evidence/website-with-application-stopped.json new file mode 100644 index 00000000..fbb4fa04 --- /dev/null +++ b/Docs/Separation/Evidence/website-with-application-stopped.json @@ -0,0 +1,41 @@ +{ + "passed": true, + "checks": [ + { + "route": "/", + "status": 200, + "bytes": 33802, + "applicationBefore": "inactive", + "applicationAfter": "inactive" + }, + { + "route": "/pricing", + "status": 200, + "bytes": 19821, + "applicationBefore": "inactive", + "applicationAfter": "inactive" + }, + { + "route": "/help", + "status": 200, + "bytes": 15605, + "applicationBefore": "inactive", + "applicationAfter": "inactive" + }, + { + "route": "/problem-solver", + "status": 200, + "bytes": 10868, + "applicationBefore": "inactive", + "applicationAfter": "inactive" + }, + { + "route": "/sitemap.xml", + "status": 200, + "bytes": 87342, + "applicationBefore": "inactive", + "applicationAfter": "inactive" + } + ], + "method": "Observed guarded Development application activation while its service was stopped" +} diff --git a/PlotLine.Tests/ApplicationDomainBoundaryTests.cs b/PlotLine.Tests/ApplicationDomainBoundaryTests.cs index 12fe036d..59d02743 100644 --- a/PlotLine.Tests/ApplicationDomainBoundaryTests.cs +++ b/PlotLine.Tests/ApplicationDomainBoundaryTests.cs @@ -28,7 +28,41 @@ internal static class ApplicationDomainBoundaryTests Check(controller.Login() is RedirectToActionResult {ControllerName:"Projects"},"Authenticated sign in opens Projects"); Check(controller.Login("/Books/Details/123") is LocalRedirectResult {Url:"/Books/Details/123"},"Safe deep link survives"); foreach(var url in new[]{"https://example.com/","//example.com/","/\\example.com/"})Check(controller.Login(url) is RedirectToActionResult {ControllerName:"Projects"},"Reject open redirect"); + var publication = Path.Combine(Path.GetTempPath(), "pd-help-publication-" + Guid.NewGuid().ToString("N")); + Directory.CreateDirectory(publication); + try + { + File.WriteAllText(Path.Combine(publication, "manifest.json"), "{\"version\":\"first\"}"); + var article = new PlotLine.Models.HelpArticle { Title="Approved help",Category="Projects",CategorySlug="projects",Slug="overview",ContextKey="projects.overview",MarkdownContent="# Approved" }; + File.WriteAllText(Path.Combine(publication,"articles.json"),System.Text.Json.JsonSerializer.Serialize(new[]{article})); + var contentConfig=new ConfigurationBuilder().AddInMemoryCollection(new Dictionary { ["HelpContent:Path"]=publication }).Build(); + var help=new HelpService(null!,contentConfig); + Check(help.GetByContextKey("projects.overview")?.Title=="Approved help", "Application consumes approved help artifact"); + article.Title="Updated approved help"; + File.WriteAllText(Path.Combine(publication,"articles.json"),System.Text.Json.JsonSerializer.Serialize(new[]{article})); + File.WriteAllText(Path.Combine(publication,"manifest.json"),"{\"version\":\"second\"}"); + Check(help.GetBySlugs("projects","overview")?.Title=="Updated approved help", "Application help publication hot reload preserves identifiers"); + } + finally { Directory.Delete(publication,true); } + var queue = new EmailCapture(); + http.Request.Host = new HostString("app.plotdirector.com"); + var email = new EmailService(Microsoft.Extensions.Options.Options.Create(new PlotLine.Models.EmailSettings()), + services.GetRequiredService(), queue, new HttpContextAccessor { HttpContext = http }, + Microsoft.Extensions.Logging.Abstractions.NullLogger.Instance); + email.SendVerificationEmailAsync("domain-fixture@example.invalid", "Synthetic", Guid.NewGuid()).GetAwaiter().GetResult(); + email.SendPasswordResetEmailAsync("domain-fixture@example.invalid", "Synthetic", Guid.NewGuid()).GetAwaiter().GetResult(); + Check(queue.Items.Count == 2 && queue.Items[0].PlainTextBody!.Contains("https://app.plotdirector.com/Account/VerifyEmail?") + && queue.Items[1].PlainTextBody!.Contains("https://app.plotdirector.com/Account/ResetPassword?"), "Verification/reset emails use app origin"); Console.WriteLine("PASS Application domain boundary, Projects landing, authenticated sign in and safe deep links"); } + private sealed class EmailCapture : PlotLine.Data.IEmailQueueRepository + { + public List Items {get;}=[]; + public Task CreateAsync(PlotLine.Models.EmailQueueItem item){Items.Add(item);return Task.FromResult((long)Items.Count);} + public Task> DequeueBatchAsync(int size)=>throw new NotSupportedException(); + public Task MarkSentAsync(long id)=>throw new NotSupportedException(); + public Task MarkFailedAsync(long id,string error)=>throw new NotSupportedException(); + public Task ResetStuckSendingAsync()=>throw new NotSupportedException(); + } private static void Check(bool ok,string message){if(!ok)throw new InvalidOperationException(message);} } diff --git a/PlotLine.Tests/Browser/application-domain-development.cjs b/PlotLine.Tests/Browser/application-domain-development.cjs new file mode 100644 index 00000000..a5f15e0b --- /dev/null +++ b/PlotLine.Tests/Browser/application-domain-development.cjs @@ -0,0 +1,31 @@ +// Normal Development login with an existing dedicated synthetic identity; no owner credentials. +const {chromium}=require('playwright'),fs=require('node:fs'),assert=require('node:assert/strict'); +const file=process.argv[2];assert(file?.startsWith('/tmp/pd-dev-browser-'));const identity=JSON.parse(fs.readFileSync(file));assert.equal(identity.Database,'PlotDirector_Development');assert(identity.Email.startsWith('pwa-browser-')); +const base='https://dev.plotdirector.com',out=process.env.DOMAIN_EVIDENCE_DIR||'/tmp/plotdirector-app-domain-browser';fs.mkdirSync(out,{recursive:true}); +(async()=>{const browser=await chromium.launch();const checks=[],errors=[];let page,originalTheme;const login=async()=>{await page.locator('#Email').fill(identity.Email);await page.locator('#Password').fill(identity.Password);await Promise.all([page.waitForNavigation(),page.locator('form button[type=submit]').click()]);}; +try{const context=await browser.newContext({viewport:{width:1440,height:1000}});page=await context.newPage();await page.addInitScript(()=>document.addEventListener('context-connection-ready',()=>window.__qualificationSignalRConnected=true,true));page.on('pageerror',e=>errors.push(e.message)); + await page.goto(base+'/');assert.equal(new URL(page.url()).pathname,'/Account/Login');assert(new URL(page.url()).searchParams.get('ReturnUrl')?.toLowerCase().startsWith('/projects')||new URL(page.url()).searchParams.get('returnUrl')?.toLowerCase().startsWith('/projects'));checks.push('unauthenticated root challenges with Projects return'); + for(const route of ['/Account/Login','/Account/Register','/Account/ForgotPassword','/Account/ResendVerificationEmail','/Account/VerifyEmailConfirmation','/Account/ResetPassword?token=00000000-0000-0000-0000-000000000000','/Account/VerifyEmail?token=00000000-0000-0000-0000-000000000000','/Account/AccessDenied','/Account/Login?companion=true&returnUrl=/word-companion']){ + const r=await page.goto(base+route);assert(r.status()<500,route);assert.equal(await page.locator('html').getAttribute('data-site-theme'),'public',route);assert.equal(await page.locator('html').getAttribute('data-theme'),'light',route);checks.push('branded '+route.split('?')[0]); + } + await page.goto(base+'/Projects');await login();assert.equal(new URL(page.url()).pathname,'/Projects');checks.push('normal login returns requested Projects'); + await page.goto(base+'/');assert.equal(new URL(page.url()).pathname,'/Projects');checks.push('authenticated root lands on Projects'); + const projectLink=await page.locator('a[href^="/Projects/Details/"]').first().getAttribute('href');assert(projectLink);const project=Number(projectLink.split('/').pop()); + await page.goto(base+'/Account/Login?returnUrl='+encodeURIComponent(projectLink));assert.equal(new URL(page.url()).pathname,projectLink);checks.push('authenticated sign-in honors safe deep link'); + await page.goto(base+'/Account/Login?returnUrl=https://example.invalid/');assert.equal(new URL(page.url()).pathname,'/Projects');checks.push('external return URL rejected'); + originalTheme=await page.locator('html').getAttribute('data-app-theme');assert(originalTheme); + const setTheme=async theme=>{const token=await page.locator('[data-appearance-form] input[name="__RequestVerificationToken"]').inputValue();const r=await page.request.post(base+'/Appearance/Theme',{form:{themeKey:theme,__RequestVerificationToken:token}});assert.equal(r.status(),200);await page.reload();assert.equal(await page.locator('html').getAttribute('data-app-theme'),theme);}; + for(const theme of ['plotdirector','warm-light','warm-dark','modern-light','modern-dark','rose-pink','baby-blue']){await setTheme(theme);checks.push('persisted theme '+theme);if(['modern-dark','warm-light'].includes(theme))await page.screenshot({path:out+'/projects-'+theme+'.png',fullPage:true});} + await setTheme(originalTheme);originalTheme=null; + await page.goto(base+projectLink);assert((await page.locator('main').innerText()).length>50);checks.push('existing synthetic project'); + const bookLink=await page.locator('a[href^="/Books/Details/"]').first().getAttribute('href');assert(bookLink,'fixture book required');const book=Number(bookLink.split('/').pop());await page.goto(base+bookLink);assert((await page.locator('main').innerText()).length>50);checks.push('existing synthetic book/manuscript workspace'); + const hub=[];page.on('request',r=>{if(r.url().includes('/hubs/'))hub.push(r.url().split('?')[0]);}); + await page.goto(base+`/Writing/Context?projectId=${project}&bookId=${book}`);await page.locator('[data-context-workspace]').waitFor();await page.waitForFunction(()=>window.__qualificationSignalRConnected===true,null,{timeout:20000});await page.screenshot({path:out+'/context-workspace.png',fullPage:true});checks.push('real authenticated Context Workspace');assert(hub.length>0,'real SignalR negotiation');checks.push('real SignalR connection established'); + await page.goto(base+'/word-companion');assert.equal(new URL(page.url()).pathname,'/word-companion');checks.push('Word taskpane route (browser only)'); + await page.goto(base+'/ManageAccount/Subscription');assert.equal(new URL(page.url()).pathname,'/ManageAccount/Subscription');assert((await page.locator('main').innerText()).length>50);checks.push('existing subscription page; no payment initiated'); + const manifest=await (await page.request.get(base+'/site.webmanifest')).json();assert.equal(manifest.start_url,'/Projects');assert.equal(manifest.scope,'/');assert.equal(manifest.id,'/Projects');checks.push('application-owned Projects PWA manifest'); + const logout=page.locator('form[action="/Account/Logout"]').first();await Promise.all([page.waitForNavigation(),logout.evaluate(f=>f.requestSubmit())]);assert.equal(new URL(page.url()).pathname,'/Account/Login');assert.equal(await page.locator('html').getAttribute('data-site-theme'),'public');checks.push('logout returns branded application sign-in'); + await page.goto(base+projectLink);assert.equal(new URL(page.url()).pathname,'/Account/Login');await login();assert.equal(new URL(page.url()).pathname,projectLink);checks.push('unauthenticated deep-link login returns requested project'); + assert.deepEqual(errors,[]);fs.writeFileSync(out+'/results.json',JSON.stringify({passed:true,checks,errors,physicalWordTested:false,externalPaymentsTested:false,realEmailDeliveryTested:false},null,2));console.log(JSON.stringify({passed:true,checks:checks.length,out})); +}catch(e){fs.writeFileSync(out+'/results.json',JSON.stringify({passed:false,checks,errors,error:String(e)},null,2));throw e;} +finally{if(originalTheme&&page){try{const token=await page.locator('[data-appearance-form] input[name="__RequestVerificationToken"]').inputValue();await page.request.post(base+'/Appearance/Theme',{form:{themeKey:originalTheme,__RequestVerificationToken:token}});}catch{}}await browser.close();}})().catch(e=>{console.error(e);process.exitCode=1;}); diff --git a/PlotLine.Tests/Browser/application-domain-mfa-development.cjs b/PlotLine.Tests/Browser/application-domain-mfa-development.cjs new file mode 100644 index 00000000..de16b87d --- /dev/null +++ b/PlotLine.Tests/Browser/application-domain-mfa-development.cjs @@ -0,0 +1,11 @@ +// Dedicated synthetic account only. Restore its initially-disabled MFA in finally. +const {chromium}=require('playwright'),fs=require('node:fs'),crypto=require('node:crypto'),assert=require('node:assert/strict');const file=process.argv[2];assert(file?.startsWith('/tmp/pd-dev-browser-'));const i=JSON.parse(fs.readFileSync(file));assert.equal(i.Database,'PlotDirector_Development');assert(i.Email.startsWith('pwa-browser-'));const base='https://dev.plotdirector.com',out='/tmp/plotdirector-app-domain-mfa';fs.mkdirSync(out,{recursive:true}); +function totp(secret,stepOffset=0){let bits='';for(const c of secret.replace(/[=\s]/g,'').toUpperCase()){const n='ABCDEFGHIJKLMNOPQRSTUVWXYZ234567'.indexOf(c);assert(n>=0);bits+=n.toString(2).padStart(5,'0');}const bytes=[];for(let n=0;n+8<=bits.length;n+=8)bytes.push(parseInt(bits.slice(n,n+8),2));const counter=Buffer.alloc(8);counter.writeBigUInt64BE(BigInt(Math.floor(Date.now()/30000)+stepOffset));const hash=crypto.createHmac('sha1',Buffer.from(bytes)).update(counter).digest(),offset=hash.at(-1)&15;return ((hash.readUInt32BE(offset)&0x7fffffff)%1000000).toString().padStart(6,'0');} +(async()=>{const b=await chromium.launch();let admin,enabled=false,step='initial login';const checks=[];const login=async p=>{await p.locator('#Email').fill(i.Email);await p.locator('#Password').fill(i.Password);await Promise.all([p.waitForNavigation(),p.locator('form button[type=submit]').click()]);};try{ + admin=await (await b.newContext()).newPage();await admin.goto(base+'/Account/Login');await login(admin);assert.equal(new URL(admin.url()).pathname,'/Projects','fixture MFA must initially be disabled'); + const deep=await admin.locator('a[href^="/Projects/Details/"]').first().getAttribute('href');assert(deep);step='enable synthetic MFA';await admin.goto(base+'/ManageAccount/EnableTwoFactor');const secret=await admin.locator('#SecretKey').inputValue();await admin.locator('#Code').fill(totp(secret));enabled=true;await Promise.all([admin.waitForNavigation(),admin.locator('form[action="/ManageAccount/EnableTwoFactor"] button[type=submit]').click()]);assert(['/ManageAccount/RecoveryCodes','/Account/Login'].includes(new URL(admin.url()).pathname));checks.push('enabled MFA on dedicated synthetic account'); + const p=await (await b.newContext()).newPage();await p.goto(base+'/Account/Login?returnUrl='+encodeURIComponent(deep));step='password then MFA challenge';await login(p);assert.equal(new URL(p.url()).pathname,'/Account/TwoFactor');assert.equal(await p.locator('html').getAttribute('data-site-theme'),'public');checks.push('real pending MFA challenge uses public brand'); + await p.goto(base+'/Account/TwoFactorRecovery?returnUrl='+encodeURIComponent(deep));assert.equal(new URL(p.url()).pathname,'/Account/TwoFactorRecovery');assert.equal(await p.locator('html').getAttribute('data-site-theme'),'public');checks.push('real recovery challenge uses public brand'); + await p.goto(base+'/Account/TwoFactor?returnUrl='+encodeURIComponent(deep));step='verify authenticator and deep link';const code=totp(secret,1);const returned=p.waitForURL('**'+deep);for(let n=0;n<6;n++)await p.locator('[data-two-factor-digit]').nth(n).fill(code[n]);await returned;assert.equal(new URL(p.url()).pathname,deep);checks.push('real TOTP verification returns requested protected deep link');admin=p; + }catch(e){console.log(JSON.stringify({errorType:e.name,step,path:admin?new URL(admin.url()).pathname:null}));process.exitCode=1;} + finally{if(enabled&&admin){try{await admin.goto(base+'/ManageAccount/DisableTwoFactor');await admin.locator('#CurrentPassword').fill(i.Password);await Promise.all([admin.waitForNavigation(),admin.locator('form[action="/ManageAccount/DisableTwoFactor"] button[type=submit]').click()]);assert.notEqual(new URL(admin.url()).pathname,'/ManageAccount/DisableTwoFactor');enabled=false;checks.push('original disabled MFA state restored');}catch(e){console.log(JSON.stringify({errorType:e.name,step,path:admin?new URL(admin.url()).pathname:null}));process.exitCode=1;}}fs.writeFileSync(out+'/results.json',JSON.stringify({passed:!process.exitCode,checks,fixtureMfaRestored:!enabled,failedStep:process.exitCode?step:null,noSecretsOrRecoveryCodesRecorded:true},null,2));await b.close();console.log(JSON.stringify({passed:!process.exitCode,checks:checks.length,fixtureMfaRestored:!enabled}));}})().catch(()=>{console.error('MFA acceptance failed; no credentials recorded.');process.exitCode=1;}); diff --git a/PlotLine.Tests/Browser/application-domain-pwa-development.cjs b/PlotLine.Tests/Browser/application-domain-pwa-development.cjs new file mode 100644 index 00000000..6852eaeb --- /dev/null +++ b/PlotLine.Tests/Browser/application-domain-pwa-development.cjs @@ -0,0 +1,14 @@ +// Real installed Chromium PWA against Development, with only a dedicated synthetic account. +const {chromium}=require('playwright'),fs=require('node:fs'),assert=require('node:assert/strict');const file=process.argv[2];assert(file?.startsWith('/tmp/pd-dev-browser-'));const i=JSON.parse(fs.readFileSync(file));assert.equal(i.Database,'PlotDirector_Development');assert(i.Email.startsWith('pwa-browser-')); +const base='https://dev.plotdirector.com',out=process.env.DOMAIN_EVIDENCE_DIR||'/tmp/plotdirector-app-domain-pwa';fs.mkdirSync(out,{recursive:true}); +(async()=>{const profile=fs.mkdtempSync('/tmp/pd-domain-pwa-');const context=await chromium.launchPersistentContext(profile,{headless:false,viewport:{width:1440,height:1000}}),cdp=await context.browser().newBrowserCDPSession(),manifestId=base+'/Projects';const checks=[];let installed=false;try{ + const tab=context.pages()[0];await tab.goto(base+'/Projects');await tab.locator('#Email').fill(i.Email);await tab.locator('#Password').fill(i.Password);await Promise.all([tab.waitForNavigation(),tab.locator('form button[type=submit]').click()]);assert.equal(new URL(tab.url()).pathname,'/Projects'); + await cdp.send('PWA.install',{manifestId,installUrlOrBundleUrl:base+'/Projects'});installed=true;await cdp.send('PWA.changeAppUserSettings',{manifestId,displayMode:'standalone'}); + const opened=context.waitForEvent('page');await cdp.send('PWA.launch',{manifestId});const app=await opened;await app.waitForLoadState();assert.equal(new URL(app.url()).pathname,'/Projects');assert(await app.evaluate(()=>matchMedia('(display-mode: standalone)').matches));checks.push('real installed PWA launches authenticated Projects by default'); + assert.equal(await app.locator('[data-app-theme-choice]').count(),7);checks.push('all authenticated themes retained');await app.screenshot({path:out+'/installed-projects.png',fullPage:true}); + await context.setOffline(true);const offline=await app.evaluate(async()=>{try{await fetch('/Projects?offline-acceptance=1',{cache:'no-store'});return false;}catch{return true;}});assert(offline,'no authenticated offline cached response');await context.setOffline(false);checks.push('offline requests fail honestly; no cached authenticated response'); + const logout=app.locator('form[action="/Account/Logout"]').first();await Promise.all([app.waitForNavigation(),logout.evaluate(f=>f.requestSubmit())]);assert.equal(new URL(app.url()).pathname,'/Account/Login');assert.equal(await app.locator('html').getAttribute('data-site-theme'),'public');assert.equal(await app.locator('html').getAttribute('data-theme'),'light');checks.push('installed signed-out authentication keeps public brand'); + await app.locator('#Email').fill(i.Email);await app.locator('#Password').fill(i.Password);await Promise.all([app.waitForNavigation(),app.locator('form button[type=submit]').click()]);assert.equal(new URL(app.url()).pathname,'/Projects');checks.push('installed sign-in returns Projects'); + fs.writeFileSync(out+'/results.json',JSON.stringify({passed:true,installedChromium:true,checks,ownerPwaMigrated:false,physicalWordTested:false},null,2));console.log(JSON.stringify({passed:true,checks:checks.length,out})); + }catch(e){fs.writeFileSync(out+'/results.json',JSON.stringify({passed:false,checks,error:String(e)},null,2));throw e;} + finally{await context.setOffline(false).catch(()=>{});if(installed)await cdp.send('PWA.uninstall',{manifestId}).catch(()=>{});await context.close();fs.rmSync(profile,{recursive:true,force:true});}})().catch(e=>{console.error(e);process.exitCode=1;}); diff --git a/PlotLine/Services/HelpService.cs b/PlotLine/Services/HelpService.cs index 755ce8ab..3ca0c9af 100644 --- a/PlotLine/Services/HelpService.cs +++ b/PlotLine/Services/HelpService.cs @@ -20,13 +20,31 @@ public interface IHelpService IReadOnlyList GetCoverage(); } -public sealed class HelpService(IWebHostEnvironment environment) : IHelpService +public sealed class HelpService(IWebHostEnvironment environment, IConfiguration? configuration = null) : IHelpService { private readonly object cacheLock = new(); private IReadOnlyList? cachedArticles; + private string? publishedIdentity; public IReadOnlyList GetAllArticles() { + if (configuration?["HelpContent:Path"] is { Length: > 0 } publishedRoot) + { + var directory = new DirectoryInfo(publishedRoot); + var root = directory.LinkTarget is null ? publishedRoot : directory.ResolveLinkTarget(true)!.FullName; + var identity = File.ReadAllText(Path.Combine(root, "manifest.json")); + lock (cacheLock) + { + if (cachedArticles is null || identity != publishedIdentity) + { + cachedArticles = System.Text.Json.JsonSerializer.Deserialize>( + File.ReadAllText(Path.Combine(root, "articles.json"))) + ?? throw new InvalidDataException("Empty approved help publication."); + publishedIdentity = identity; + } + return cachedArticles; + } + } if (cachedArticles is not null) { return cachedArticles; diff --git a/Tools/PublicContent/README.md b/Tools/PublicContent/README.md index 6ceb6a25..cb6449d0 100644 --- a/Tools/PublicContent/README.md +++ b/Tools/PublicContent/README.md @@ -26,4 +26,6 @@ digest with release evidence, and transfer that artifact for consumption by PlotDirector.Website/Tools/consume_help.py. Full operator procedures are in that repository's Docs/Content.md. Publication and atomic content activation do not deploy or restart the application. Website renders from its local immutable publication; -application contextual help keeps its current source/renderer and needs no website. +application contextual help keeps its current renderer and needs no website. Both +products can independently consume the same publication into their own content store, +selected by HelpContent__Path, with manifest-driven hot reload and no restart.