KeyDerivation does sha256 twice to password.
(password []byte, salt []byte)
| 36 | |
| 37 | // KeyDerivation does sha256 twice to password. |
| 38 | func KeyDerivation(password []byte, salt []byte) (out []byte) { |
| 39 | return hash.DoubleHashB(append(password, salt...)) |
| 40 | } |
| 41 | |
| 42 | // EncryptWithPassword encrypts data with given password, iv will be placed |
| 43 | // at head of cipher data. |
no test coverage detected