-
Notifications
You must be signed in to change notification settings - Fork 17
Allow passing None as FEC and hash device when formatting as VERITY #461
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
Allow passing None as FEC and hash device when formatting as VERITY #461
Conversation
WalkthroughMade Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes
Suggested reviewers
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🧰 Additional context used🧬 Code graph analysis (1)src/format.rs (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (38)
🔇 Additional comments (4)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
8d45f1b to
e6768d0
Compare
|
Congratulations! One of the builds has completed. 🍾 You can install the built RPMs by following these steps:
Please note that the RPMs should be used only in a testing environment. |
Add a small prototype to test passing FDs via varlink and opening them on the varlink server side. The varlink server then uses libcryptsetup-rs to create the dm-verity data for a given disk image that is passed in via varlink. Currently, a patched libcryptsetup-rs (with stratis-storage/libcryptsetup-rs#461 applied) is necessary for the dm-verity part to work. This is also useful to test the varlink server in a locked-down environment, as that's what we'll be working with as an actual sysupdate pull backend later. For a systemd-run command to lock down the server, see test_pull_server.rs.
jbaublitz
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.
This looks good to me! Please rebase and I'll merge.
Make the fec_device and the hash_device fields in the CryptParamsVerity struct an Option<>, so that it's possible to pass NULL in the C crypt_params_verity struct. For fec_device, passing NULL to libcryptsetup indicates that no FEC device should be created. Because currently this is impossible, an FEC device must be created when using libcryptsetup-rs. The hash_device option is not used by libcryptsetup when formatting a verity partition, so allow passing NULL there as well.
e6768d0 to
bba08ad
Compare
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
Make the fec_device and the hash_device fields in the CryptParamsVerity struct an Option<>, so that it's possible to pass NULL in the C crypt_params_verity struct.
For fec_device, passing NULL to libcryptsetup indicates that no FEC device should be created. Because currently this is impossible, an FEC device must be created when using libcryptsetup-rs.
The hash_device option is not used by libcryptsetup when formatting a verity partition, so allow passing NULL there as well.
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.