Skip to content

Enforce Device Binding in Session Validation - #147

Merged
mckaragoz merged 2 commits into
CodeBeamOrg:devfrom
mckaragoz:DeviceRejectHardening
Nov 7, 2026
Merged

mckaragoz merged 2 commits into
CodeBeamOrg:devfrom
mckaragoz:DeviceRejectHardening

Conversation

@mckaragoz

Copy link
Copy Markdown
Contributor

Summary

Strengthens device-bound session validation by enforcing the configured DeviceMismatchBehavior when device identifiers are missing or mismatched.

Changes

  • Reject missing or mismatched device identifiers when DeviceMismatchBehavior is Reject.
  • Preserve existing Allow and AllowAndRebind behavior without introducing automatic rebinding.
  • Forward the resolved Device ID during Resource API remote session validation.
  • Add focused regression tests for local and remote session validation.

Compatibility

  • No public API or authentication mode changes.
  • Existing session, chain, root, and tenant validation rules remain unchanged.
  • Browser navigation and Resource API authentication flows must remain functional.

@codecov

codecov Bot commented Nov 7, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 87.20%. Comparing base (95d75d4) to head (e398fd9).
⚠️ Report is 1 commits behind head on dev.

Additional details and impacted files
@@            Coverage Diff             @@
##              dev     #147      +/-   ##
==========================================
+ Coverage   87.17%   87.20%   +0.02%     
==========================================
  Files         580      580              
  Lines       18890    18891       +1     
  Branches     2227     2227              
==========================================
+ Hits        16468    16474       +6     
+ Misses       1620     1615       -5     
  Partials      802      802              
Flag Coverage Δ
framework 87.20% <100.00%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@mckaragoz
mckaragoz merged commit dfc17fc into CodeBeamOrg:dev Nov 7, 2026
14 checks passed
mckaragoz added a commit that referenced this pull request Nov 7, 2026
* feat(docs): showcase Identity Lab and enhance landing page experience (#143)

* Add GitHub Actions workflow for JavaScript tests

* Enhance JavaScript tests workflow with change detection

Updated workflow to include permissions and detect changes step.

* Merge commit from fork

* advisory-fix-1

* Fix Reviewed Issues

* Fix Conflicts & Tests

* test: Add CSRF regression coverage and update endpoint classification (#144)

* test: Add CSRF regression coverage and update endpoint classification

* Fix TrustedOrigin in Request Client and Client Bootstrapper

* Fix UAuthUrlBuilder when Tenant Specified (#145)

* Fix UAuthUrlBuilder when Tenant Specified

* Fix Flaky Logout Test

* More Fixes

* More Fixes

* Modernize Dependencies, Test Infrastructure and CI Workflows (#146)

* Update Dependencies & Identity Lab Arrangements

* test: propagate xUnit v3 cancellation tokens

Pass the current xUnit test cancellation token to ordinary asynchronous test
operations in unit, integration, and Identity Lab tests. Keep exact token
matching in the snapshot factory mock and qualify the xUnit context where
bUnit also defines TestContext.

Preserve explicit cancellation sources and non-cancellable operations. Leave
the two transaction cleanup rollbacks uncancellable, with explanatory comments.

Validation: xUnit1051 decreases from 2,403 to 2 intentional cleanup exceptions.

* ci: migrate .NET 10 tests to Microsoft.Testing.Platform

* build: centralize supported frameworks and derive CI compatibility matrix

* ci: standardize workflow checks and conditional PR validation

* Some Additional Changes

* Enforce Device Binding in Session Validation (#147)

* Enforce Device Binding in Session Validation

* Fix Antiforgery Behavior on Device Hardening

* Fix External Hub Antiforgery Cookies and Strengthen CSRF Regression Tests (#148)

* Improve Identity Lab Login UX and Sidebar Footer (#149)

* Improve Identity Lab Login UX and Sidebar Footer

* Completed Implementations

* Update 0.2.0-preview.2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant