GRI-1880: fix pre-upgrade blocklist check ignoring blocklist_applies_to_registered setting #112
No reviewers
Labels
No labels
Area/Backend
Area/Database
Area/Docs
Area/Frontend
Area/Infra
Area/Security
Area/Tests
Area/Tooling
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Lang/Python
Lang/Rust
Lang/Shell
Lang/SQL
Lang/TypeScript
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Routing
Auto
Routing
Hold
Routing
Human
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Grimoirix/grimoire-of-digital-signage!112
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/GRI-1880-blocklist-off-ignored-pre-upgrade"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
ws::upgraderefused a blocklisted registered device with 403 before the WebSocket upgrade, even when the server settingblocklist_applies_to_registeredwas off.Cause
The pre-upgrade check called
devices::load_admission_rules, which hardcodedblocklist_applies_to_registered: true. The real setting was applied only after the upgrade, inhandle_socket, so it never reached the early drop.Fix
Apply
state.blocklist_applies_to_registeredto the rules before the pre-upgradeblocklist_only_dropcheck, mirroring whathandle_socketalready does after the upgrade.Verification
ac_2_08_a_registered_device_on_the_blocklist_is_admitted_when_the_setting_is_off.cargo test -p server --test enrolment_acceptance_integration -- --include-ignoredagainst local Postgres: all 7 tests pass (AC-2-07 and AC-2-08 both green).cargo test -p server --lib: 112 passed, 1 ignored (unrelated)../scripts/local-gates.sh --rust-only: every gate passed.Closes #110