From cf9759f3b4c987eb9567df267fe911240007b800 Mon Sep 17 00:00:00 2001 From: Dimitri Sokolyuk Date: Wed, 19 Apr 2017 20:20:28 +0200 Subject: Rounds --- keys.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'keys.go') diff --git a/keys.go b/keys.go index 08c3ff4..c0429b5 100644 --- a/keys.go +++ b/keys.go @@ -105,6 +105,10 @@ func (e *EncKey) Kdf(pass string, rounds int) { e.KDFRounds = uint32(rounds) } +func (e *EncKey) Rounds() int { + return int(e.KDFRounds) +} + func Unmarshal(b []byte, v interface{}) error { buf := bytes.NewReader(b) if err := binary.Read(buf, binary.BigEndian, v); err != nil { -- cgit v1.2.3