Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix device keys incorrectly being treated as strings #564

Merged
merged 4 commits into from
Jan 31, 2024

Conversation

Hinton
Copy link
Member

@Hinton Hinton commented Jan 30, 2024

Type of change

- [x] Bug fix
- [ ] New feature development
- [ ] Tech debt (refactoring, code cleanup, dependency upgrades, etc)
- [ ] Build/deploy pipeline (DevOps)
- [ ] Other

Objective

Device keys are generated from random u8 vectors. We incorrectly attempted to parse these as strings when decrypting them in the last trust device step.

Added a complete test which confirms the whole device approval process.

Before you submit

  • Please add unit tests where it makes sense to do so

@Hinton Hinton requested a review from dani-garcia January 30, 2024 20:19
@Hinton Hinton marked this pull request as ready for review January 30, 2024 20:20
Copy link

codecov bot commented Jan 30, 2024

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (3064ac5) 51.65% compared to head (7217e70) 52.11%.

Files Patch % Lines
crates/bitwarden/src/auth/auth_request.rs 98.61% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #564      +/-   ##
==========================================
+ Coverage   51.65%   52.11%   +0.45%     
==========================================
  Files         163      163              
  Lines        8202     8267      +65     
==========================================
+ Hits         4237     4308      +71     
+ Misses       3965     3959       -6     

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

@bitwarden-bot
Copy link

bitwarden-bot commented Jan 31, 2024

Logo
Checkmarx One – Scan Summary & Details9186ef63-676d-4302-8092-42405bf2cf7e

No New Or Fixed Issues Found

@Hinton Hinton changed the title Fix device keys not being strings Fix device keys incorrectly being treated as strings Jan 31, 2024
@Hinton Hinton merged commit 8b468ec into main Jan 31, 2024
59 checks passed
@Hinton Hinton deleted the ps/fix-device-encryption branch January 31, 2024 13:20
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.

3 participants