From 5229b8f5f5ef8d3e91fe2ab1f415131337161577 Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Sun, 4 Oct 2015 11:03:40 +0200 Subject: Add BlockNoPlainOff() and BlockNoCipherOff() + test Also, fix key, it is now []byte, not [16]byte --- cryptfs/names_test.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'cryptfs/names_test.go') diff --git a/cryptfs/names_test.go b/cryptfs/names_test.go index 30ecfb9..7e20690 100644 --- a/cryptfs/names_test.go +++ b/cryptfs/names_test.go @@ -11,7 +11,7 @@ func TestTranslatePath(t *testing.T) { s = append(s, "foo12312312312312312313123123123") s = append(s, "123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890") - var key [16]byte + key := make([]byte, 16) fs := NewCryptFS(key, true) for _, n := range(s) { @@ -32,8 +32,10 @@ func TestPad16(t *testing.T) { s = append(s, []byte("foo")) s = append(s, []byte("12345678901234567")) s = append(s, []byte("12345678901234567abcdefg")) - var key [16]byte + + key := make([]byte, 16) fs := NewCryptFS(key, true) + for i := range(s) { orig := s[i] padded := fs.pad16(orig) -- cgit v1.2.3