cryptohome: Add a new mount argument for migration

When this new argument is true, MountEx mounts the existing eCryptfs
vault to a temporary location, while setting up a dircrypto home
directory at the normal mount destination.

TEST=cryptohome --action=mount_ex --to_migrate_from_ecryptfs

Change-Id: I8081f8a0bc166fed3649b4577d36f92bab3a1778
Commit-Ready: Ryo Hashimoto <>
Tested-by: Ryo Hashimoto <>
Reviewed-by: Kazuhiro Inaba <>
diff --git a/dbus/cryptohome/rpc.proto b/dbus/cryptohome/rpc.proto
index be72ce1..30d8760 100644
--- a/dbus/cryptohome/rpc.proto
+++ b/dbus/cryptohome/rpc.proto
@@ -92,6 +92,9 @@
   // forces to use the new encryption. That is, makes it an error to mount
   // an existing home directory encrypted in the old way (ecryptfs).
   optional bool force_dircrypto_if_available = 3;
+  // If set to true, mounts the existing ecryptfs vault to a temporary location
+  // while setting up a new dircrypto directory.
+  optional bool to_migrate_from_ecryptfs = 4;
 // A BaseReply type is used for all cryptohomed responses. A shared base class