diff options
author | Gustav Simonsson <gustav.simonsson@gmail.com> | 2016-09-24 03:42:29 +0800 |
---|---|---|
committer | Gustav Simonsson <gustav.simonsson@gmail.com> | 2016-09-28 01:07:33 +0800 |
commit | 7cc6b801e0967e5ebfa26b9f670675acea6e3a20 (patch) | |
tree | 4f27977539b92569659c67751c4d4a209d6af95f /accounts/key_store_test.go | |
parent | 863d166c7b0250cf2e99c8aad69578cdd144d386 (diff) | |
download | go-tangerine-7cc6b801e0967e5ebfa26b9f670675acea6e3a20.tar go-tangerine-7cc6b801e0967e5ebfa26b9f670675acea6e3a20.tar.gz go-tangerine-7cc6b801e0967e5ebfa26b9f670675acea6e3a20.tar.bz2 go-tangerine-7cc6b801e0967e5ebfa26b9f670675acea6e3a20.tar.lz go-tangerine-7cc6b801e0967e5ebfa26b9f670675acea6e3a20.tar.xz go-tangerine-7cc6b801e0967e5ebfa26b9f670675acea6e3a20.tar.zst go-tangerine-7cc6b801e0967e5ebfa26b9f670675acea6e3a20.zip |
accounts: left pad keybytes-to-encrypt, add 30/31 byte keys tests
Diffstat (limited to 'accounts/key_store_test.go')
-rw-r--r-- | accounts/key_store_test.go | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/accounts/key_store_test.go b/accounts/key_store_test.go index b0417c87e..d0713caa0 100644 --- a/accounts/key_store_test.go +++ b/accounts/key_store_test.go @@ -239,3 +239,15 @@ func TestKeyForDirectICAP(t *testing.T) { t.Errorf("Expected first address byte to be zero, have: %s", key.Address.Hex()) } } + +func TestV3_31_Byte_Key(t *testing.T) { + t.Parallel() + tests := loadKeyStoreTestV3("testdata/v3_test_vector.json", t) + testDecryptV3(tests["31_byte_key"], t) +} + +func TestV3_30_Byte_Key(t *testing.T) { + t.Parallel() + tests := loadKeyStoreTestV3("testdata/v3_test_vector.json", t) + testDecryptV3(tests["30_byte_key"], t) +} |