Add new middleware to handle epitrax auth#1443
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1443 +/- ##
==========================================
+ Coverage 85.91% 90.11% +4.20%
==========================================
Files 259 180 -79
Lines 11705 6979 -4726
Branches 1378 1388 +10
==========================================
- Hits 10056 6289 -3767
+ Misses 1642 683 -959
Partials 7 7
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
I would prefer to unify this new middleware and withNbsAuth into something like withJwtAuth. We could change the cookie names and environment variable names to be more generic. I think it would be fine to remove the eCR ID from the URL when launching from NBS like EpiTrax wants and as for verifying the eCR ID in the token, we can just skip that if there isn't an ID in the token which would be the NBS flow. We would also take on the JWT authentication for |
PULL REQUEST
Hide ECR ID from URL for EpiTrax-authenticated sessions
Summary
EpiTrax-originated sessions on the /view-data page
and ECR ID in httpOnly cookies, and redirects to a clean URL with no ?id= in
the address bar
so the page receives the ECR ID without it ever appearing in the browser URL
Related Issue
Fixes #1438
Acceptance Criteria
from EpiTrax
Additional Information
Anything else the review team should know?
Checklist