fusefrontend_reverse

package
v2.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 20, 2021 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type File

type File struct {
	// contains filtered or unexported fields
}

func (*File) Lseek

func (f *File) Lseek(ctx context.Context, off uint64, whence uint32) (uint64, syscall.Errno)

Lseek - FUSE call.

func (*File) Read

func (f *File) Read(ctx context.Context, buf []byte, ioff int64) (resultData fuse.ReadResult, errno syscall.Errno)

Read - FUSE call

func (*File) Release

func (f *File) Release(context.Context) syscall.Errno

Release - FUSE call, close file

type Node

type Node struct {
	fs.Inode
	// contains filtered or unexported fields
}

Node is a file or directory in the filesystem tree in a `gocryptfs -reverse` mount.

func (*Node) Getattr

func (n *Node) Getattr(ctx context.Context, f fs.FileHandle, out *fuse.AttrOut) (errno syscall.Errno)

GetAttr - FUSE call for stat()ing a file.

GetAttr is symlink-safe through use of openBackingDir() and Fstatat().

func (*Node) Lookup

func (n *Node) Lookup(ctx context.Context, cName string, out *fuse.EntryOut) (ch *fs.Inode, errno syscall.Errno)

Lookup - FUSE call for discovering a file.

func (*Node) Open

func (n *Node) Open(ctx context.Context, flags uint32) (fh fs.FileHandle, fuseFlags uint32, errno syscall.Errno)

Open - FUSE call. Open already-existing file.

Symlink-safe through Openat().

func (*Node) Path

func (n *Node) Path() string

Path returns the relative plaintext path of this node

func (*Node) Readdir

func (n *Node) Readdir(ctx context.Context) (stream fs.DirStream, errno syscall.Errno)

Readdir - FUSE call.

This function is symlink-safe through use of openBackingDir() and ReadDirIVAt().

func (n *Node) Readlink(ctx context.Context) (out []byte, errno syscall.Errno)

Readlink - FUSE call.

Symlink-safe through openBackingDir() + Readlinkat().

func (*Node) Statfs

func (n *Node) Statfs(ctx context.Context, out *fuse.StatfsOut) syscall.Errno

StatFs - FUSE call. Returns information about the filesystem.

Symlink-safe because the path is ignored.

type RootNode

type RootNode struct {
	Node
	// contains filtered or unexported fields
}

RootNode is the root directory in a `gocryptfs -reverse` mount

func NewRootNode

NewRootNode returns an encrypted FUSE overlay filesystem. In this case (reverse mode) the backing directory is plain-text and ReverseFS provides an encrypted view.

func (*RootNode) DecryptPath

func (rn *RootNode) DecryptPath(cipherPath string) (string, error)

DecryptPath implements ctlsock.Backend

func (*RootNode) EncryptPath

func (rn *RootNode) EncryptPath(plainPath string) (string, error)

EncryptPath implements ctlsock.Backend. This is used for the control socket and for the "-exclude" logic.

type VirtualConfFile

type VirtualConfFile struct {
	// contains filtered or unexported fields
}

func (*VirtualConfFile) Read

func (f *VirtualConfFile) Read(ctx context.Context, buf []byte, off int64) (res fuse.ReadResult, errno syscall.Errno)

func (*VirtualConfFile) Release

func (f *VirtualConfFile) Release(ctx context.Context) syscall.Errno

type VirtualConfNode

type VirtualConfNode struct {
	fs.Inode
	// contains filtered or unexported fields
}

func (*VirtualConfNode) Open

func (n *VirtualConfNode) Open(ctx context.Context, flags uint32) (fh fs.FileHandle, fuseFlags uint32, errno syscall.Errno)

type VirtualMemNode

type VirtualMemNode struct {
	fs.Inode
	// contains filtered or unexported fields
}

VirtualMemNode is an in-memory node that does not have a representation on disk.

func (*VirtualMemNode) Getattr

func (f *VirtualMemNode) Getattr(ctx context.Context, fh fs.FileHandle, out *fuse.AttrOut) syscall.Errno

GetAttr - FUSE call

func (*VirtualMemNode) Open

func (f *VirtualMemNode) Open(ctx context.Context, flags uint32) (fh fs.FileHandle, fuseFlags uint32, errno syscall.Errno)

Open - FUSE call

func (*VirtualMemNode) Read

func (f *VirtualMemNode) Read(ctx context.Context, fh fs.FileHandle, dest []byte, off int64) (fuse.ReadResult, syscall.Errno)

Read - FUSE call

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL