aboutsummaryrefslogtreecommitdiff
path: root/internal/fusefrontend_reverse/ctlsock_interface.go
diff options
context:
space:
mode:
authorJakob Unterwurzacher2016-11-10 00:27:08 +0100
committerJakob Unterwurzacher2016-11-10 00:27:08 +0100
commit75ebb28a625bc16d145f5acd9e0cc1d305716afe (patch)
tree6e4c654c67b93933a2575857883777b3f05fc5d3 /internal/fusefrontend_reverse/ctlsock_interface.go
parentdf28fc5a11f5e52897f45cc299ab62a2a2cbaf4c (diff)
ctlsock: add initial limited implementation
At the moment, in forward mode you can only encrypt paths and in reverse mode you can only decrypt paths.
Diffstat (limited to 'internal/fusefrontend_reverse/ctlsock_interface.go')
-rw-r--r--internal/fusefrontend_reverse/ctlsock_interface.go19
1 files changed, 19 insertions, 0 deletions
diff --git a/internal/fusefrontend_reverse/ctlsock_interface.go b/internal/fusefrontend_reverse/ctlsock_interface.go
new file mode 100644
index 0000000..448663f
--- /dev/null
+++ b/internal/fusefrontend_reverse/ctlsock_interface.go
@@ -0,0 +1,19 @@
+package fusefrontend_reverse
+
+import (
+ "errors"
+
+ "github.com/rfjakob/gocryptfs/internal/ctlsock"
+)
+
+var _ ctlsock.Interface = &reverseFS{} // Verify that interface is implemented.
+
+// EncryptPath implements ctlsock.Backend
+func (rfs *reverseFS) EncryptPath(plainPath string) (string, error) {
+ return "", errors.New("Not implemented")
+}
+
+// DecryptPath implements ctlsock.Backend
+func (rfs *reverseFS) DecryptPath(plainPath string) (string, error) {
+ return rfs.decryptPath(plainPath)
+}