diff options
| author | Joe Richey joerichey@google.com <joerichey@google.com> | 2017-05-31 17:52:15 -0700 |
|---|---|---|
| committer | Joe Richey joerichey@google.com <joerichey@google.com> | 2017-06-15 22:32:35 -0700 |
| commit | 67879f7a69e2040f2266d81ba239324534e24405 (patch) | |
| tree | 7b2a6725daec02f4868fa8c835ba18acd913a160 /util/errors.go | |
| parent | d4160e07cfc1942844160fdb8e6c9525da0bd2c8 (diff) | |
filesystem: change support detection and bug-fixes
Instead of checking if the filesystem type is correct, we now detect if
a filesystem supports encryption by trying to read a policy on its root
directory. The error returned tells us if there is support or not.
This commit also fixes a bug in the use libblkid. Throughout all of
fscrypt, cannonicalizePath() is used before any path comparison or
lookup. However, the canonical device path in the blkid cache may differ
from our idea of a canonical path. Additional blkid functions are needed
to perform the necessary translation. This is noted in the documentation
of makeLink().
Finally, this commit makes a few API changes. AllSupporedFilesystems()
now returns an error, and a GetProtector() method now replaces the
GetLinkedProtector() and GetEitherProtector() methods. A PathSorter has
also been added so Mounts can be sorted in a reliable order.
Change-Id: I664f46fafd1483ebecb743c061b03d708b3233a4
Diffstat (limited to 'util/errors.go')
0 files changed, 0 insertions, 0 deletions