From 9a15dfa494c76b5fcadcd32e2e46cbee84218a87 Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Mon, 25 Jun 2018 22:27:15 +0200 Subject: trezor: add TrezorPayload TrezorPayload stores 32 random bytes used for unlocking the master key using a Trezor security module. The randomness makes sure that a unique unlock value is used for each gocryptfs filesystem. --- tests/trezor/trezor_test.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'tests/trezor/trezor_test.go') diff --git a/tests/trezor/trezor_test.go b/tests/trezor/trezor_test.go index 5db56e2..59e10cb 100644 --- a/tests/trezor/trezor_test.go +++ b/tests/trezor/trezor_test.go @@ -42,6 +42,9 @@ func TestInitTrezor(t *testing.T) { if !c.IsFeatureFlagSet(configfile.FlagTrezor) { t.Error("Trezor flag should be set but is not") } + if len(c.TrezorPayload) != 32 { + t.Errorf("TrezorPayload has wrong length: %d", len(c.TrezorPayload)) + } } // Test using -trezor together with -extpass. Should fail with code 1 (usage error). -- cgit v1.2.3