<feed xmlns='http://www.w3.org/2005/Atom'>
<title>fscrypt.git/filesystem/mountpoint.go, branch 0.2.1</title>
<subtitle>Go tool for managing Linux filesystem encryption
</subtitle>
<link rel='alternate' type='text/html' href='https://git.hodgden.net/cgit.cgi/fscrypt.git/'/>
<entry>
<title>filesystem: libblkid -&gt; search /dev/disk/by-uuid</title>
<updated>2017-08-31T21:05:29+00:00</updated>
<author>
<name>Joe Richey</name>
<email>joerichey@google.com</email>
</author>
<published>2017-08-31T21:05:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.hodgden.net/cgit.cgi/fscrypt.git/commit/?id=0fcb6601ca66b9e4c2349392663fe9baa30dbbc7'/>
<id>0fcb6601ca66b9e4c2349392663fe9baa30dbbc7</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>actions: error handling and API changed</title>
<updated>2017-06-28T22:15:15+00:00</updated>
<author>
<name>Joe Richey joerichey@google.com</name>
<email>joerichey@google.com</email>
</author>
<published>2017-06-21T17:03:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.hodgden.net/cgit.cgi/fscrypt.git/commit/?id=93415b198a3ef427c02893b8fdf036aa75ffe50f'/>
<id>93415b198a3ef427c02893b8fdf036aa75ffe50f</id>
<content type='text'>
This commit changes the error handling for the actions package to use
the error handling library github.com/pkg/errors. This means replacing
"errors" with "github.com/pkg/errors", reworking some of the error
values, and wrapping some errors with additional context.

This commit also changes the Protector/Policy API, moving most of the
package functionality into Protector or Policy methods. These types are
now "locked" when they are queried from the filesystem, and Unlock()
must be used to get their corresponding keys. Note that only certain
operations will require unlocking the keys. Certain unnecessary
functions and methods are also removed.

This CL also fixes two bugs reported by Tyler Hicks in CreateConfigFile.
CPU time is used instead of wall time, and kiB is used instead of kB.

Change-Id: I88f45659e9fe4938d148843e3289e7b6d5b698d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit changes the error handling for the actions package to use
the error handling library github.com/pkg/errors. This means replacing
"errors" with "github.com/pkg/errors", reworking some of the error
values, and wrapping some errors with additional context.

This commit also changes the Protector/Policy API, moving most of the
package functionality into Protector or Policy methods. These types are
now "locked" when they are queried from the filesystem, and Unlock()
must be used to get their corresponding keys. Note that only certain
operations will require unlocking the keys. Certain unnecessary
functions and methods are also removed.

This CL also fixes two bugs reported by Tyler Hicks in CreateConfigFile.
CPU time is used instead of wall time, and kiB is used instead of kB.

Change-Id: I88f45659e9fe4938d148843e3289e7b6d5b698d8
</pre>
</div>
</content>
</entry>
<entry>
<title>Change error handling to new package</title>
<updated>2017-06-28T21:06:52+00:00</updated>
<author>
<name>Joe Richey joerichey@google.com</name>
<email>joerichey@google.com</email>
</author>
<published>2017-06-21T16:52:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.hodgden.net/cgit.cgi/fscrypt.git/commit/?id=77b226a90ef70b77ca556830528c013a23b01e57'/>
<id>77b226a90ef70b77ca556830528c013a23b01e57</id>
<content type='text'>
This commit changes the error handing for the crypto, filesystem,
metadata, pam, and util packages to use the error handling library
github.com/pkg/errors. This means elimination of the FSError type, an
increased use of wrapping errors (as opposed to logging), switching
on the Cause() of an error (as opposed to its value), and improving our
integration tests involving TEST_FILESYSTEM_ROOT.

This commit also fixes a few bugs with the keyring code to ensure that
our {Find|Remove|Insert}PolicyKey functions are always operating on the
same keyring. The check for filesystem support has been moved from the
filesystem package to the metadata package. Finally, the API for the
filesystem package has been slightly modified:
	* filesystem.AllFilesystems() now returns all the filesystems in
	  sorted order
	* certain path methods are now public

O_SYNC is also removed for writing the metadata. We don't get that much
from syncing the metadata, as the actual file data could also be
corrupted by and IO error. The sync operation is also occasionally very
slow (~3 seconds) and can be unfriendly to battery life.

Change-Id: I392c2655141714b16dfdbc84ac09780072be2cf0
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit changes the error handing for the crypto, filesystem,
metadata, pam, and util packages to use the error handling library
github.com/pkg/errors. This means elimination of the FSError type, an
increased use of wrapping errors (as opposed to logging), switching
on the Cause() of an error (as opposed to its value), and improving our
integration tests involving TEST_FILESYSTEM_ROOT.

This commit also fixes a few bugs with the keyring code to ensure that
our {Find|Remove|Insert}PolicyKey functions are always operating on the
same keyring. The check for filesystem support has been moved from the
filesystem package to the metadata package. Finally, the API for the
filesystem package has been slightly modified:
	* filesystem.AllFilesystems() now returns all the filesystems in
	  sorted order
	* certain path methods are now public

O_SYNC is also removed for writing the metadata. We don't get that much
from syncing the metadata, as the actual file data could also be
corrupted by and IO error. The sync operation is also occasionally very
slow (~3 seconds) and can be unfriendly to battery life.

Change-Id: I392c2655141714b16dfdbc84ac09780072be2cf0
</pre>
</div>
</content>
</entry>
<entry>
<title>filesystem: change support detection and bug-fixes</title>
<updated>2017-06-16T05:32:35+00:00</updated>
<author>
<name>Joe Richey joerichey@google.com</name>
<email>joerichey@google.com</email>
</author>
<published>2017-06-01T00:52:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.hodgden.net/cgit.cgi/fscrypt.git/commit/?id=67879f7a69e2040f2266d81ba239324534e24405'/>
<id>67879f7a69e2040f2266d81ba239324534e24405</id>
<content type='text'>
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
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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
</pre>
</div>
</content>
</entry>
<entry>
<title>pam: checking a user's login passphrase</title>
<updated>2017-06-16T05:31:35+00:00</updated>
<author>
<name>Joe Richey joerichey@google.com</name>
<email>joerichey@google.com</email>
</author>
<published>2017-05-31T19:49:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.hodgden.net/cgit.cgi/fscrypt.git/commit/?id=d4160e07cfc1942844160fdb8e6c9525da0bd2c8'/>
<id>d4160e07cfc1942844160fdb8e6c9525da0bd2c8</id>
<content type='text'>
This commit adds in the fscrypt/pam package. This package will hold all
functionality related to Linux Pluggable Authentication Modules (PAM).
Right now this package uses cgo to mock a PAM conversation, allowing the
function to check if a provided passphrase actually belongs to a user.

Due to the nature of cgo callbacks, global state of the key to check is
necessary for this function. This commit also addresses some issues
about building the cgo components. Now, only the minimal linking flags
are included in the go files. Additional linker flags may now be
necessary to build a static binary of fscrypt. This is addressed in the
Makefile and README.

Finally, this commit fixes a bug where the tests would not run correctly
due to shared global state on the testing filesystem. Fixed, by having
all the tests run sequentially.

Change-Id: Ia43636801da984b505d2f43dd14127b7cfbf2c48
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit adds in the fscrypt/pam package. This package will hold all
functionality related to Linux Pluggable Authentication Modules (PAM).
Right now this package uses cgo to mock a PAM conversation, allowing the
function to check if a provided passphrase actually belongs to a user.

Due to the nature of cgo callbacks, global state of the key to check is
necessary for this function. This commit also addresses some issues
about building the cgo components. Now, only the minimal linking flags
are included in the go files. Additional linker flags may now be
necessary to build a static binary of fscrypt. This is addressed in the
Makefile and README.

Finally, this commit fixes a bug where the tests would not run correctly
due to shared global state on the testing filesystem. Fixed, by having
all the tests run sequentially.

Change-Id: Ia43636801da984b505d2f43dd14127b7cfbf2c48
</pre>
</div>
</content>
</entry>
<entry>
<title>filesystem: creating the directories and files</title>
<updated>2017-05-31T19:40:13+00:00</updated>
<author>
<name>Joe Richey joerichey@google.com</name>
<email>joerichey@google.com</email>
</author>
<published>2017-05-24T01:45:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.hodgden.net/cgit.cgi/fscrypt.git/commit/?id=f4f4f606718497a2f660cdb737b812e035f55311'/>
<id>f4f4f606718497a2f660cdb737b812e035f55311</id>
<content type='text'>
This commit adds in the filesystem subpackage. The goal of this package
is to provide and interface for adding to and removing from the metadata
storage for a given filesystem. This is primarily done in filesystem.go.
To facilitate this functionality, mountpoint.go exposes an interface for
querying the system about the current mounted filesystems and their
information. Note that this operation is done with a lazy loading
mechanism.

To refer to other filesystems, we use link files that can be parsed by
libblkid. The README is also updated to account for this new dependancy.

This package uses the FSError type under the hood so that error messages
will include the filesystem name, but callers can still check for
specific error instances.

Change-Id: I74fe4e84b8e3a5b73f1337c35307ffe0bf7cdea9
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit adds in the filesystem subpackage. The goal of this package
is to provide and interface for adding to and removing from the metadata
storage for a given filesystem. This is primarily done in filesystem.go.
To facilitate this functionality, mountpoint.go exposes an interface for
querying the system about the current mounted filesystems and their
information. Note that this operation is done with a lazy loading
mechanism.

To refer to other filesystems, we use link files that can be parsed by
libblkid. The README is also updated to account for this new dependancy.

This package uses the FSError type under the hood so that error messages
will include the filesystem name, but callers can still check for
specific error instances.

Change-Id: I74fe4e84b8e3a5b73f1337c35307ffe0bf7cdea9
</pre>
</div>
</content>
</entry>
</feed>
