-
Notifications
You must be signed in to change notification settings - Fork 101
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
fsync set policy ioctls #359
Conversation
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
95f1347
to
ae7dded
Compare
Remove if google/fscrypt#359 gets accepted
Split policyIoctl into setPolicyIoctl and getPolicyIoctl. Add a os.Sync() call to setPolicyIoctl. Policy ioctls are not necessary durable on return. For example, on ext4 (ref: fs/ext4/crypto.c: ext4_set_context) they are not. This may lead to a filesystem containing fscrypt metadata (in .fscrypt), but without the policy applied on an encrypted directory. Example: Snapshotting a mounted ext4 filesystem on Ceph RBD right after setting the policy. While subject to timing, with high probability the snapshot will not have the policy set. Calling fsync fixes this. Signed-off-by: Marcel Lauhoff <[email protected]>
ae7dded
to
e3746be
Compare
Remove if google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
The failure in "Run command-line interface tests" is unrelated and will be fixed by #362. So it looks like you just need to sign the CLA. (Or make sure that you've done everything for the CLA to be recognized, if your company already has it on file.) |
There is already a company CLA, I'm waiting to get added. |
Remove if google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
CLA is now signed |
Merged, thanks! |
Revert once our google/fscrypt dependency is upgraded to a version that includes google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
Revert once our google/fscrypt dependency is upgraded to a version that includes google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
Revert once our google/fscrypt dependency is upgraded to a version that includes google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
Revert once our google/fscrypt dependency is upgraded to a version that includes google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
Revert once our google/fscrypt dependency is upgraded to a version that includes google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
Revert once our google/fscrypt dependency is upgraded to a version that includes google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
Revert once our google/fscrypt dependency is upgraded to a version that includes google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
Revert once our google/fscrypt dependency is upgraded to a version that includes google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
Revert once our google/fscrypt dependency is upgraded to a version that includes google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
Revert once our google/fscrypt dependency is upgraded to a version that includes google/fscrypt#359 gets accepted Signed-off-by: Marcel Lauhoff <[email protected]>
Split policyIoctl into setPolicyIoctl and getPolicyIoctl. Add a
os.Sync() call to setPolicyIoctl.
Policy ioctls are not necessary durable on return. For example, on
ext4 (ref: fs/ext4/crypto.c: ext4_set_context) they are not. This may
lead to a filesystem containing fscrypt metadata (in .fscrypt), but
without the policy applied on an encrypted directory.
Example:
Snapshotting a mounted ext4 filesystem on Ceph RBD right after
setting the policy. While subject to timing, with high probability the
snapshot will not have the policy set. Calling fsync fixes this.
Signed-off-by: Marcel Lauhoff [email protected]