Unbreak hyperlinks broken by go mod v2 conversion

Commit

  69d88505fd go mod: declare module version v2

translated all instances of "github.com/rfjakob/gocryptfs/" to
"github.com/rfjakob/gocryptfs/v2/".

Unfortunately, this included hyperlinks.

Unbreak the hyperlinks like this:

  find . -name \*.go | xargs sed -i s%https://github.com/rfjakob/gocryptfs/v2/%https://github.com/rfjakob/gocryptfs/v2/%
This commit is contained in:
Jakob Unterwurzacher 2021-08-30 11:31:01 +02:00
parent 17fe50ef74
commit 34d8a498c4
29 changed files with 51 additions and 51 deletions

View File

@ -1,6 +1,6 @@
/*
Small tool to try to debug unix.Getdents problems on CIFS mounts
( https://github.com/rfjakob/gocryptfs/v2/issues/483 )
( https://github.com/rfjakob/gocryptfs/issues/483 )
Example output:

View File

@ -1,6 +1,6 @@
/*
Small tool to try to debug unix.Getdents problems on CIFS mounts
( https://github.com/rfjakob/gocryptfs/v2/issues/483 )
( https://github.com/rfjakob/gocryptfs/issues/483 )
Example output:

View File

@ -276,7 +276,7 @@ func (cf *ConfFile) WriteFile() error {
err = fd.Sync()
if err != nil {
// This can happen on network drives: FRITZ.NAS mounted on MacOS returns
// "operation not supported": https://github.com/rfjakob/gocryptfs/v2/issues/390
// "operation not supported": https://github.com/rfjakob/gocryptfs/issues/390
tlog.Warn.Printf("Warning: fsync failed: %v", err)
// Try sync instead
syscall.Sync()

View File

@ -167,7 +167,7 @@ func (be *ContentEnc) DecryptBlock(ciphertext []byte, blockNo uint64, fileID []b
nonce := ciphertext[:be.cryptoCore.IVLen]
if bytes.Equal(nonce, be.allZeroNonce) {
// Bug in tmpfs?
// https://github.com/rfjakob/gocryptfs/v2/issues/56
// https://github.com/rfjakob/gocryptfs/issues/56
// http://www.spinics.net/lists/kernel/msg2370127.html
return nil, errors.New("all-zero nonce")
}

View File

@ -25,7 +25,7 @@
// l-wx------. 1 jakob jakob 64 Jan 5 15:54 3 -> /dev/null
// lrwx------. 1 jakob jakob 64 Jan 5 15:54 4 -> 'anon_inode:[eventpoll]'
//
// See https://github.com/rfjakob/gocryptfs/v2/issues/320 for details.
// See https://github.com/rfjakob/gocryptfs/issues/320 for details.
package ensurefds012
import (

View File

@ -40,7 +40,7 @@ type Args struct {
// Suid is true if the filesystem has been mounted with the "-suid" flag.
// If it is false, we can ignore the GETXATTR "security.capability" calls,
// which are a performance problem for writes. See
// https://github.com/rfjakob/gocryptfs/v2/issues/515 for details.
// https://github.com/rfjakob/gocryptfs/issues/515 for details.
Suid bool
// Enable the FUSE kernel_cache option
KernelCache bool

View File

@ -24,7 +24,7 @@ var xattrNameIV = []byte("xattr_name_iv_xx")
var xattrStorePrefix = "user.gocryptfs."
// We get one read of this xattr for each write -
// see https://github.com/rfjakob/gocryptfs/v2/issues/515 for details.
// see https://github.com/rfjakob/gocryptfs/issues/515 for details.
var xattrCapability = "security.capability"
// isAcl returns true if the attribute name is for storing ACLs
@ -41,7 +41,7 @@ func (n *Node) Getxattr(ctx context.Context, attr string, dest []byte) (uint32,
rn := n.rootNode()
// If we are not mounted with -suid, reading the capability xattr does not
// make a lot of sense, so reject the request and gain a massive speedup.
// See https://github.com/rfjakob/gocryptfs/v2/issues/515 .
// See https://github.com/rfjakob/gocryptfs/issues/515 .
if !rn.args.Suid && attr == xattrCapability {
// Returning EOPNOTSUPP is what we did till
// ca9e912a28b901387e1dbb85f6c531119f2d5ef2 "fusefrontend: drop xattr user namespace restriction"

View File

@ -68,7 +68,7 @@ func WriteDirIVAt(dirfd int) error {
iv := cryptocore.RandBytes(DirIVLen)
// 0400 permissions: gocryptfs.diriv should never be modified after creation.
// Don't use "ioutil.WriteFile", it causes trouble on NFS:
// https://github.com/rfjakob/gocryptfs/v2/commit/7d38f80a78644c8ec4900cc990bfb894387112ed
// https://github.com/rfjakob/gocryptfs/commit/7d38f80a78644c8ec4900cc990bfb894387112ed
fd, err := syscallcompat.Openat(dirfd, DirIVFilename, os.O_WRONLY|os.O_CREATE|os.O_EXCL, dirivPerms)
if err != nil {
tlog.Warn.Printf("WriteDirIV: Openat: %v", err)

View File

@ -6,14 +6,14 @@ const (
// never chmod'ed or chown'ed.
//
// Group-readable so the FS can be mounted by several users in the same group
// (see https://github.com/rfjakob/gocryptfs/v2/issues/387 ).
// (see https://github.com/rfjakob/gocryptfs/issues/387 ).
//
// Note that gocryptfs.conf is still created with 0400 permissions so the
// owner must explicitly chmod it to permit access.
//
// World-readable so an encrypted directory can be copied by the non-root
// owner when gocryptfs is running as root
// ( https://github.com/rfjakob/gocryptfs/v2/issues/539 ).
// ( https://github.com/rfjakob/gocryptfs/issues/539 ).
dirivPerms = 0444
// Permissions for gocryptfs.longname.[sha256].name files.

View File

@ -14,7 +14,7 @@ import (
// 2) Is ARM64 && has AES instructions && Go is v1.11 or higher
// (commit https://github.com/golang/go/commit/4f1f503373cda7160392be94e3849b0c9b9ebbda)
//
// See https://github.com/rfjakob/gocryptfs/v2/wiki/CPU-Benchmarks
// See https://github.com/rfjakob/gocryptfs/wiki/CPU-Benchmarks
// for benchmarks.
func PreferOpenSSL() bool {
if BuiltWithoutOpenssl {
@ -26,7 +26,7 @@ func PreferOpenSSL() bool {
return false
}
// On the Apple M1, Go stdlib is faster than OpenSSL, despite cpu.ARM64.HasAES
// reading false: https://github.com/rfjakob/gocryptfs/v2/issues/556#issuecomment-848079309
// reading false: https://github.com/rfjakob/gocryptfs/issues/556#issuecomment-848079309
if runtime.GOOS == "darwin" && runtime.GOARCH == "arm64" {
return false
}

View File

@ -12,7 +12,7 @@ import (
// https://github.com/golang/go/blob/d2a80f3fb5b44450e0b304ac5a718f99c053d82a/src/os/file_posix.go#L243
//
// This is needed because CIFS throws lots of EINTR errors:
// https://github.com/rfjakob/gocryptfs/v2/issues/483
// https://github.com/rfjakob/gocryptfs/issues/483
//
// Don't use retryEINTR() with syscall.Close()!
// See https://code.google.com/p/chromium/issues/detail?id=269623 .

View File

@ -23,7 +23,7 @@ const sizeofDirent = int(unsafe.Sizeof(unix.Dirent{}))
// maxReclen sanity check: Reclen should never be larger than this.
// Due to padding between entries, it is 280 even on 32-bit architectures.
// See https://github.com/rfjakob/gocryptfs/v2/issues/197 for details.
// See https://github.com/rfjakob/gocryptfs/issues/197 for details.
const maxReclen = 280
// getdents wraps unix.Getdents and converts the result to []fuse.DirEntry.
@ -43,7 +43,7 @@ func getdents(fd int) (entries []fuse.DirEntry, entriesSpecial []fuse.DirEntry,
continue
} else if err != nil {
if smartBuf.Len() > 0 {
tlog.Warn.Printf("warning: unix.Getdents returned errno %d in the middle of data ( https://github.com/rfjakob/gocryptfs/v2/issues/483 )", err.(syscall.Errno))
tlog.Warn.Printf("warning: unix.Getdents returned errno %d in the middle of data ( https://github.com/rfjakob/gocryptfs/issues/483 )", err.(syscall.Errno))
return nil, nil, syscall.EIO
}
return nil, nil, err
@ -145,7 +145,7 @@ func dtUnknownWarn(dirfd int) {
if err == nil && buf.Type == XFS_SUPER_MAGIC {
// Old XFS filesystems always return DT_UNKNOWN. Downgrade the message
// to "info" level if we are on XFS.
// https://github.com/rfjakob/gocryptfs/v2/issues/267
// https://github.com/rfjakob/gocryptfs/issues/267
tlog.Info.Printf("Getdents: convertDType: received DT_UNKNOWN, fstype=xfs, falling back to stat")
} else {
tlog.Warn.Printf("Getdents: convertDType: received DT_UNKNOWN, fstype=%#x, falling back to stat",

View File

@ -27,7 +27,7 @@ func TestGetdents(t *testing.T) {
// skipOnGccGo skips the emulateGetdents test when we are
// running linux and were compiled with gccgo. The test is known to fail
// (https://github.com/rfjakob/gocryptfs/v2/issues/201), but getdents emulation
// (https://github.com/rfjakob/gocryptfs/issues/201), but getdents emulation
// is not used on linux, so let's skip the test and ignore the failure.
func skipOnGccGo(t *testing.T) {
if !emulate || runtime.GOOS != "linux" {

View File

@ -6,12 +6,12 @@ import (
const (
// QuirkBrokenFalloc means the falloc is broken.
// Preallocation on Btrfs is broken ( https://github.com/rfjakob/gocryptfs/v2/issues/395 )
// and slow ( https://github.com/rfjakob/gocryptfs/v2/issues/63 ).
// Preallocation on Btrfs is broken ( https://github.com/rfjakob/gocryptfs/issues/395 )
// and slow ( https://github.com/rfjakob/gocryptfs/issues/63 ).
QuirkBrokenFalloc = uint64(1 << iota)
// QuirkDuplicateIno1 means that we have duplicate inode numbers.
// On MacOS ExFAT, all empty files share inode number 1:
// https://github.com/rfjakob/gocryptfs/v2/issues/585
// https://github.com/rfjakob/gocryptfs/issues/585
QuirkDuplicateIno1
)

View File

@ -8,7 +8,7 @@ import (
func DetectQuirks(cipherdir string) (q uint64) {
const (
// From https://github.com/rfjakob/gocryptfs/v2/issues/585#issuecomment-887370065
// From https://github.com/rfjakob/gocryptfs/issues/585#issuecomment-887370065
FstypenameExfat = "exfat"
)
@ -31,9 +31,9 @@ func DetectQuirks(cipherdir string) (q uint64) {
tlog.Debug.Printf("DetectQuirks: Fstypename=%q\n", fstypename)
// On MacOS ExFAT, all empty files share inode number 1:
// https://github.com/rfjakob/gocryptfs/v2/issues/585
// https://github.com/rfjakob/gocryptfs/issues/585
if fstypename == FstypenameExfat {
logQuirk("ExFAT detected, disabling hard links. See https://github.com/rfjakob/gocryptfs/v2/issues/585 for why.")
logQuirk("ExFAT detected, disabling hard links. See https://github.com/rfjakob/gocryptfs/issues/585 for why.")
q |= QuirkDuplicateIno1
}

View File

@ -18,12 +18,12 @@ func DetectQuirks(cipherdir string) (q uint64) {
return 0
}
// Preallocation on Btrfs is broken ( https://github.com/rfjakob/gocryptfs/v2/issues/395 )
// and slow ( https://github.com/rfjakob/gocryptfs/v2/issues/63 ).
// Preallocation on Btrfs is broken ( https://github.com/rfjakob/gocryptfs/issues/395 )
// and slow ( https://github.com/rfjakob/gocryptfs/issues/63 ).
//
// Cast to uint32 avoids compile error on arm: "constant 2435016766 overflows int32"
if uint32(st.Type) == unix.BTRFS_SUPER_MAGIC {
logQuirk("Btrfs detected, forcing -noprealloc. See https://github.com/rfjakob/gocryptfs/v2/issues/395 for why.")
logQuirk("Btrfs detected, forcing -noprealloc. See https://github.com/rfjakob/gocryptfs/issues/395 for why.")
q |= QuirkBrokenFalloc
}

View File

@ -59,7 +59,7 @@ func setattrlist(path *byte, list unsafe.Pointer, buf unsafe.Pointer, size uintp
// Sorry, fallocate is not available on OSX at all and
// fcntl F_PREALLOCATE is not accessible from Go.
// See https://github.com/rfjakob/gocryptfs/v2/issues/18 if you want to help.
// See https://github.com/rfjakob/gocryptfs/issues/18 if you want to help.
func EnospcPrealloc(fd int, off int64, len int64) error {
return nil
}

View File

@ -48,7 +48,7 @@ func EnospcPrealloc(fd int, off int64, len int64) (err error) {
}
if err == syscall.EOPNOTSUPP {
// ZFS and ext3 do not support fallocate. Warn but continue anyway.
// https://github.com/rfjakob/gocryptfs/v2/issues/22
// https://github.com/rfjakob/gocryptfs/issues/22
preallocWarn.Do(func() {
tlog.Warn.Printf("Warning: The underlying filesystem " +
"does not support fallocate(2). gocryptfs will continue working " +

View File

@ -1,5 +1,5 @@
// gocryptfs is an encrypted overlay filesystem written in Go.
// See README.md ( https://github.com/rfjakob/gocryptfs/v2/blob/master/README.md )
// See README.md ( https://github.com/rfjakob/gocryptfs/blob/master/README.md )
// and the official website ( https://nuetzlich.net/gocryptfs/ ) for details.
package main

View File

@ -75,7 +75,7 @@ func doMount(args *argContainer) {
// and `drop_privileges` in `man mount.fuse3` for background.
} else {
err = isEmptyDir(args.mountpoint)
// OSXFuse will create the mountpoint for us ( https://github.com/rfjakob/gocryptfs/v2/issues/194 )
// OSXFuse will create the mountpoint for us ( https://github.com/rfjakob/gocryptfs/issues/194 )
if runtime.GOOS == "darwin" && os.IsNotExist(err) {
tlog.Info.Printf("Mountpoint %q does not exist, but should be created by OSXFuse",
args.mountpoint)

View File

@ -60,9 +60,9 @@ func TestInitFilePerms(t *testing.T) {
syscall.Stat(dir+"/gocryptfs.diriv", &st)
perms = st.Mode & 0777
// From v1.7.1, these are created with 0440 permissions, see
// https://github.com/rfjakob/gocryptfs/v2/issues/387 .
// https://github.com/rfjakob/gocryptfs/issues/387 .
// From v2.0, created with 0444 perms, see
// https://github.com/rfjakob/gocryptfs/v2/issues/539 .
// https://github.com/rfjakob/gocryptfs/issues/539 .
if perms != 0444 {
t.Errorf("Wrong permissions for gocryptfs.diriv: %#o", perms)
}
@ -441,7 +441,7 @@ func TestPasswdPasswordIncorrect(t *testing.T) {
// Check that we correctly background on mount and close stderr and stdout.
// Something like
// gocryptfs a b | cat
// must not hang ( https://github.com/rfjakob/gocryptfs/v2/issues/130 ).
// must not hang ( https://github.com/rfjakob/gocryptfs/issues/130 ).
func TestMountBackground(t *testing.T) {
dir := test_helpers.InitFS(t)
mnt := dir + ".mnt"
@ -557,7 +557,7 @@ func TestExcludeForward(t *testing.T) {
}
// Check that the config file can be read from a named pipe.
// Make sure bug https://github.com/rfjakob/gocryptfs/v2/issues/258 does not come
// Make sure bug https://github.com/rfjakob/gocryptfs/issues/258 does not come
// back.
func TestConfigPipe(t *testing.T) {
dir := test_helpers.InitFS(t)
@ -580,7 +580,7 @@ func TestConfigPipe(t *testing.T) {
}
// Ciphertext dir and mountpoint contains a comma
// https://github.com/rfjakob/gocryptfs/v2/issues/262
// https://github.com/rfjakob/gocryptfs/issues/262
func TestComma(t *testing.T) {
dir0 := test_helpers.InitFS(t)
dir := dir0 + ",foo,bar"
@ -625,7 +625,7 @@ func TestIdle(t *testing.T) {
}
// Mount with idle timeout of 100ms read something every 10ms. The fs should
// NOT get unmounted. Regression test for https://github.com/rfjakob/gocryptfs/v2/issues/421
// NOT get unmounted. Regression test for https://github.com/rfjakob/gocryptfs/issues/421
func TestNotIdle(t *testing.T) {
dir := test_helpers.InitFS(t)
mnt := dir + ".mnt"
@ -663,7 +663,7 @@ func TestNotIdle(t *testing.T) {
// TestSymlinkedCipherdir checks that if CIPHERDIR itself is a symlink, it is
// followed.
// https://github.com/rfjakob/gocryptfs/v2/issues/450
// https://github.com/rfjakob/gocryptfs/issues/450
func TestSymlinkedCipherdir(t *testing.T) {
dir := test_helpers.InitFS(t)
dirSymlink := dir + ".symlink"
@ -909,7 +909,7 @@ func TestPassfileX2(t *testing.T) {
}
// TestInitNotEmpty checks that `gocryptfs -init` returns the right error code
// if CIPHERDIR is not empty. See https://github.com/rfjakob/gocryptfs/v2/pull/503
// if CIPHERDIR is not empty. See https://github.com/rfjakob/gocryptfs/pull/503
func TestInitNotEmpty(t *testing.T) {
dir := test_helpers.TmpDir + "/" + t.Name()
if err := os.Mkdir(dir, 0700); err != nil {

View File

@ -17,7 +17,7 @@ import (
"github.com/rfjakob/gocryptfs/v2/tests/test_helpers"
)
// https://github.com/rfjakob/gocryptfs/v2/issues/543
// https://github.com/rfjakob/gocryptfs/issues/543
func TestCpA(t *testing.T) {
fn1 := filepath.Join(test_helpers.TmpDir, t.Name())
fn2 := filepath.Join(test_helpers.DefaultPlainDir, t.Name())
@ -77,7 +77,7 @@ func getfacl(fn string) (string, error) {
return string(out), err
}
// https://github.com/rfjakob/gocryptfs/v2/issues/543
// https://github.com/rfjakob/gocryptfs/issues/543
func TestAcl543(t *testing.T) {
fn1 := test_helpers.TmpDir + "/TestAcl543"
fn2 := test_helpers.DefaultPlainDir + "/TestAcl543"

View File

@ -239,7 +239,7 @@ func TestMvWarningSymlink(t *testing.T) {
if err != nil {
t.Log(string(out))
if runtime.GOOS == "darwin" {
t.Skip("mv on darwin chokes on broken symlinks, see https://github.com/rfjakob/gocryptfs/v2/issues/349")
t.Skip("mv on darwin chokes on broken symlinks, see https://github.com/rfjakob/gocryptfs/issues/349")
}
t.Fatal(err)
}

View File

@ -12,7 +12,7 @@ import (
"github.com/rfjakob/gocryptfs/v2/tests/test_helpers"
)
// https://github.com/rfjakob/gocryptfs/v2/issues/363
// https://github.com/rfjakob/gocryptfs/issues/363
//
// Note: this test calls log.Fatal() instead of t.Fatal() because apparently,
// calling t.Fatal() from a goroutine hangs the test.
@ -73,7 +73,7 @@ func TestConcurrentReadWrite(t *testing.T) {
wg.Wait()
}
// https://github.com/rfjakob/gocryptfs/v2/issues/363
// https://github.com/rfjakob/gocryptfs/issues/363
//
// Note: this test calls log.Fatal() instead of t.Fatal() because apparently,
// calling t.Fatal() from a goroutine hangs the test.

View File

@ -34,7 +34,7 @@ func TestDirOverwrite(t *testing.T) {
}
// Test that we can create and remove a directory regardless of the permission it has
// https://github.com/rfjakob/gocryptfs/v2/issues/354
// https://github.com/rfjakob/gocryptfs/issues/354
func TestRmdirPerms(t *testing.T) {
for _, perm := range []uint32{0000, 0100, 0200, 0300, 0400, 0500, 0600, 0700} {
dir := fmt.Sprintf("TestRmdir%#o", perm)

View File

@ -149,7 +149,7 @@ func TestFallocate(t *testing.T) {
}
}
// We used to allocate 18 bytes too much:
// https://github.com/rfjakob/gocryptfs/v2/issues/311
// https://github.com/rfjakob/gocryptfs/issues/311
//
// 8110 bytes of plaintext should get us exactly 8192 bytes of ciphertext.
err = file.Truncate(0)

View File

@ -774,7 +774,7 @@ func TestMkfifo(t *testing.T) {
}
// TestMagicNames verifies that "magic" names are handled correctly
// https://github.com/rfjakob/gocryptfs/v2/issues/174
// https://github.com/rfjakob/gocryptfs/issues/174
func TestMagicNames(t *testing.T) {
names := []string{"warmup1", "warmup2", "gocryptfs.longname.QhUr5d9FHerwEs--muUs6_80cy6JRp89c1otLwp92Cs", "gocryptfs.diriv"}
for _, n := range names {
@ -891,7 +891,7 @@ func TestStatfs(t *testing.T) {
}
// gocryptfs 2.0 reported the ciphertext size on symlink creation, causing
// confusion: https://github.com/rfjakob/gocryptfs/v2/issues/574
// confusion: https://github.com/rfjakob/gocryptfs/issues/574
func TestSymlinkSize(t *testing.T) {
p := filepath.Join(test_helpers.DefaultPlainDir, t.Name())
// SYMLINK reports the size to the kernel
@ -911,7 +911,7 @@ func TestSymlinkSize(t *testing.T) {
// TestPwd check that /usr/bin/pwd works inside gocryptfs.
//
// This was broken in gocryptfs v2.0 with -sharedstorage:
// https://github.com/rfjakob/gocryptfs/v2/issues/584
// https://github.com/rfjakob/gocryptfs/issues/584
func TestPwd(t *testing.T) {
dir := test_helpers.DefaultPlainDir
for i := 0; i < 3; i++ {

View File

@ -185,7 +185,7 @@ func TestEnoent(t *testing.T) {
// If the symlink target gets too long due to base64 encoding, we should
// return ENAMETOOLONG instead of having the kernel reject the data and
// returning an I/O error to the user.
// https://github.com/rfjakob/gocryptfs/v2/issues/167
// https://github.com/rfjakob/gocryptfs/issues/167
func TestTooLongSymlink(t *testing.T) {
var err error
var l int

View File

@ -128,7 +128,7 @@ func TestExcludeTestFs(t *testing.T) {
}
// Exclude everything using "/*", then selectively include only dir1 using "!/dir1"
// https://github.com/rfjakob/gocryptfs/v2/issues/588
// https://github.com/rfjakob/gocryptfs/issues/588
func TestExcludeAllOnlyDir1(t *testing.T) {
// --exclude-wildcard patterns, gitignore syntax
patterns := []string{