aboutsummaryrefslogtreecommitdiff
path: root/internal/nametransform
diff options
context:
space:
mode:
authorJakob Unterwurzacher2021-06-21 11:53:33 +0200
committerJakob Unterwurzacher2021-06-21 11:53:33 +0200
commit2efef1e270a0e374c479326ab2c296b5e9fdc34d (patch)
tree62a0d4dc10e949d71510b5c7f7b8731e044b9221 /internal/nametransform
parente244b514913a31293eac1dc728f5b1026ab84b98 (diff)
nametransform: delete NameTransformer interface
Useless layer of indirection.
Diffstat (limited to 'internal/nametransform')
-rw-r--r--internal/nametransform/names.go17
1 files changed, 0 insertions, 17 deletions
diff --git a/internal/nametransform/names.go b/internal/nametransform/names.go
index afc0f5d..2ee52e4 100644
--- a/internal/nametransform/names.go
+++ b/internal/nametransform/names.go
@@ -19,23 +19,6 @@ const (
BadNameFlag = " GOCRYPTFS_BAD_NAME"
)
-// NameTransformer is an interface used to transform filenames.
-type NameTransformer interface {
- DecryptName(cipherName string, iv []byte) (string, error)
- EncryptName(plainName string, iv []byte) (string, error)
- EncryptAndHashName(name string, iv []byte) (string, error)
- EncryptAndHashBadName(name string, iv []byte, dirfd int) (string, error)
- // HashLongName - take the hash of a long string "name" and return
- // "gocryptfs.longname.[sha256]"
- //
- // This function does not do any I/O.
- HashLongName(name string) string
- HaveBadnamePatterns() bool
- WriteLongNameAt(dirfd int, hashName string, plainName string) error
- B64EncodeToString(src []byte) string
- B64DecodeString(s string) ([]byte, error)
-}
-
// NameTransform is used to transform filenames.
type NameTransform struct {
emeCipher *eme.EMECipher