<feed xmlns='http://www.w3.org/2005/Atom'>
<title>gocryptfs, branch LockSharedStorage_rebase2</title>
<subtitle>Mirror of gocryptfs source code on Github</subtitle>
<id>http://nuetzlich.net/cgit/gocryptfs/atom?h=LockSharedStorage_rebase2</id>
<link rel='self' href='http://nuetzlich.net/cgit/gocryptfs/atom?h=LockSharedStorage_rebase2'/>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/'/>
<updated>2026-07-16T19:20:29+00:00</updated>
<entry>
<title>sharedstorage: fix darwin &amp; freebsd build failure</title>
<updated>2026-07-16T19:20:29+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2026-07-16T19:16:45+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=835cd40733d63bce9a4bd843482766c246495044'/>
<id>urn:sha1:835cd40733d63bce9a4bd843482766c246495044</id>
<content type='text'>
</content>
</entry>
<entry>
<title>fusefrontend: sharedstorage: truncate: error out on failed file lock</title>
<updated>2026-07-16T19:12:20+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2026-07-16T19:10:14+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=9efd5ec6c5e290a24a413dbcdbabc14e34d3177d'/>
<id>urn:sha1:9efd5ec6c5e290a24a413dbcdbabc14e34d3177d</id>
<content type='text'>
</content>
</entry>
<entry>
<title>tests/cluster: fix possible fd exhaustion</title>
<updated>2026-07-16T19:01:01+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2026-07-16T19:01:01+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=6a098702f11f1c2c9f5a3d102c56c3b9232719eb'/>
<id>urn:sha1:6a098702f11f1c2c9f5a3d102c56c3b9232719eb</id>
<content type='text'>
...and one typo.
</content>
</entry>
<entry>
<title>fusefrontend: LockSharedStorage: loop on EINTR, add debug output</title>
<updated>2026-07-16T19:00:08+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2026-07-16T18:47:57+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=c3f386d511094362ad5bb28c3a5c6c4f52a77236'/>
<id>urn:sha1:c3f386d511094362ad5bb28c3a5c6c4f52a77236</id>
<content type='text'>
</content>
</entry>
<entry>
<title>fusefrontend: sharedstorage: add two missing unlocks</title>
<updated>2026-07-16T18:34:50+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2026-07-16T18:34:11+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=833103864f18a4e2f514d50d5816bdc2c03ab1e0'/>
<id>urn:sha1:833103864f18a4e2f514d50d5816bdc2c03ab1e0</id>
<content type='text'>
</content>
</entry>
<entry>
<title>fusefrontend: sharedstorage: introduce UnlockSharedStorage helper</title>
<updated>2026-07-16T18:34:45+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2026-07-16T18:32:51+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=a244f1ae9e5a67c1bc2fedb80e82bb646993d936'/>
<id>urn:sha1:a244f1ae9e5a67c1bc2fedb80e82bb646993d936</id>
<content type='text'>
</content>
</entry>
<entry>
<title>fusefrontend: sharedstorage: lock truncate agains concurrent access</title>
<updated>2026-07-16T18:10:19+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2024-12-30T11:08:41+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=0acbbc0913a3a7069984c8e52f64e302d7f52df4'/>
<id>urn:sha1:0acbbc0913a3a7069984c8e52f64e302d7f52df4</id>
<content type='text'>
Prevent reads and writes concurrent with the truncate operation. It's
racy on tmpfs and ext4 ( https://lore.kernel.org/all/18e9fa0f-ec31-9107-459c-ae1694503f87@gmail.com/t/ )
as evident by TestOpenTruncate test failures:

  === RUN   TestOpenTruncate
      cluster_test.go:209: POSIX compliance issue: non-exlusive create failed with err=file exists
  doRead 16384215: corrupt block #0: cipher: message authentication failed
  ino16384215 fh8: RMW read failed: errno=5
      cluster_test.go:214: iteration 1: WriteAt: write /tmp/gocryptfs-test-parent-1026/1358464214/TestOpenTruncate.1788296708.mnt2/foo: input/output error
  --- FAIL: TestOpenTruncate (0.06s)
  FAIL
  exit status 1
  FAIL	github.com/rfjakob/gocryptfs/v2/tests/cluster	7.880s

Relates-to: https://github.com/rfjakob/gocryptfs/issues/56
</content>
</entry>
<entry>
<title>fusefrontend: sharedstorage: add warnings for lock failure</title>
<updated>2026-07-16T18:10:19+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2023-06-19T11:35:29+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=c12811349ec04a10e4090dc1becbf92380693f62'/>
<id>urn:sha1:c12811349ec04a10e4090dc1becbf92380693f62</id>
<content type='text'>
Complain loudly when the underlying storage does not support
byte-range locks.

https://github.com/rfjakob/gocryptfs/issues/754
</content>
</entry>
<entry>
<title>fusefrontend: sharedstorage: retry read-path on EIO error</title>
<updated>2026-07-16T18:10:19+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2023-06-19T11:26:44+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=781f1b8be16c1ce4d5f9648641c28a13b258b2e9'/>
<id>urn:sha1:781f1b8be16c1ce4d5f9648641c28a13b258b2e9</id>
<content type='text'>
With -sharedstorage, when we get a decryption error, we lock the
byte range and try again.

This makes concurrent R/W safe agains torn writes.

https://github.com/rfjakob/gocryptfs/issues/754
</content>
</entry>
<entry>
<title>tests/cluster: enable TestClusterConcurrentRW per default</title>
<updated>2026-07-16T18:10:19+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2023-06-09T12:35:04+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=a00736332c836dbb6b87f6132513f1cac5407e0b'/>
<id>urn:sha1:a00736332c836dbb6b87f6132513f1cac5407e0b</id>
<content type='text'>
Add the -sharedstorage flag to the mounts and make it more
severe by adjusting the I/O and file sizes to arbitrary unaligned
values.

It passes *most of the time*.

If it fails, it's like this, and the reason is that there is no
fcntl locks in the READ path yet.

gocryptfs/tests/cluster$ go test -run TestClusterConcurrentRW -v
=== RUN   TestClusterConcurrentRW
doRead 2895433: corrupt block #0: cipher: message authentication failed
doRead 2895433: corrupt block #0: cipher: message authentication failed
doRead 2895433: corrupt block #0: cipher: message authentication failed
    cluster_test.go:98: readThread iteration 9165: ReadAt failed: read /var/tmp/gocryptfs-test-parent-1026/3021427391/TestClusterConcurrentRW.366469887.mnt1/foo: input/output error
 --- FAIL: TestClusterConcurrentRW (0.40s)
FAIL
exit status 1
FAIL	github.com/rfjakob/gocryptfs/v2/tests/cluster	0.406s
</content>
</entry>
</feed>
