-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Add cipher seeding with Rust SDK encryption to enable cryptographically correct test data generation #6896
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
base: main
Are you sure you want to change the base?
Conversation
β¦ly correct test data generation
|
Claude finished @theMickster's task in 6m 10s ββ View job Code Review Summary (Re-Review)Reviewed PR: #6896 - Add cipher seeding with Rust SDK encryption to enable cryptographically correct test data generation Review Type: Re-review after commit Previous Review: Commit Changes Since Last Review
Analysis of New ChangesThe refactoring in commit
Review AssessmentNo new issues identified. The refactoring is a minor improvement that does not introduce security, correctness, or breaking change concerns. Existing Unresolved ThreadsThe PR has 4 unresolved discussion threads, all acknowledged for follow-up work:
These represent ongoing architectural discussions that are appropriately scoped for follow-up PRs. Result: Approved - no blocking issues Reviewed at commit 8203ee1 |
|
New Issues (6)Checkmarx found the following issues in this Pull Request
|
Codecov Reportβ
All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6896 +/- ##
==========================================
- Coverage 56.08% 56.06% -0.02%
==========================================
Files 1968 1969 +1
Lines 86974 87065 +91
Branches 7748 7755 +7
==========================================
+ Hits 48776 48810 +34
- Misses 36393 36447 +54
- Partials 1805 1808 +3 β View full report in Codecov by Sentry. π New features to boost your workflow:
|
|
This looks awesome and after a quick read makes sense to me, but @Hinton can perform something more thorough and so that you're aligned. |
Hinton
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A very high level review, hope to get back to reviewing this more in-depth by the end of the week.
SaintPatrck
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CLAUDE.md looks good. Just one question about the README based on other threads.
MGibson1
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seeding
I really like the data production stuff you put together, especially the consistent generation thinking.
What is unclear to me is, since you're accepting a seed rather than a deterministic Random instance, are you using the same value everywhere or somehow iterating it? It seems like everything accepting a required, shared Random and a deterministic usage order would produce predictable results while ensuring we aren't just using the same array index for everything.
SDK drift risk
What is the challenge this approach presents regarding drift between the SDK shim being used here, the shimless SDK used in clients, and the non-sdk client code?
I see where you're headed and I agree that the pseudorandom data points aren't perfect and I agree that the Rust SDK interface is rough and needs refactoring, but that's the point of this POC at this point. Get it working + show meaningful return on investment and iterate fast with byte sized PRs. For me, this is the first of 5-7 PRs that I want to churn through in the next 2 weeks. What I do not want (nor what I really ever do with POC work like this) is to have one PR continue on for weeks with many commits and code churn that ends up being impossible for human review. So big question for the team is whether or not we can accept the work as a feasible starting point knowing that we're going to idΓ©ate fast with many byte sized PRs in the next 2-3 weeks to get us just one Organization + Vault Recipe knowing that we've got a whole heck of a lot more planned beyond just this little thing here. |
Co-authored-by: Matt Gibson <mgibson@bitwarden.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see any comments by sonar cloud on this PR, can you link to the actual complaint? I don't see any issue with the pattern, isn't that generated by csbindgen, too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
|
|
||
| namespace Bit.Seeder.Factories; | ||
|
|
||
| public class OrganizationSeeder |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have an item added to the hit list to refactor this and the associated integration tests owned by admin console.
https://bitwarden.atlassian.net/browse/PM-31403



ποΈ Tracking
https://bitwarden.atlassian.net/browse/PM-31013
π Objective
Continue to build on the initial success of the Seeder with incremental progress towards a solid tool.
Please take a moment to read the
README.mdfiles, theCLAUDE.md, and a few of the TODOs in XML comments.Those will help guide you towards where we will be going with the work.
π€ Built with Claude Code