diff --git a/crypto/kdf/DerivedKeyConfig.h b/crypto/kdf/DerivedKeyConfig.h index 5e71aa8a..10c3a39b 100644 --- a/crypto/kdf/DerivedKeyConfig.h +++ b/crypto/kdf/DerivedKeyConfig.h @@ -60,6 +60,14 @@ namespace cpputils { uint32_t _p; }; + inline bool operator==(const DerivedKeyConfig &lhs, const DerivedKeyConfig &rhs) { + return lhs.salt() == rhs.salt() && lhs.N() == rhs.N() && lhs.r() == rhs.r() && lhs.p() == rhs.p(); + } + + inline bool operator!=(const DerivedKeyConfig &lhs, const DerivedKeyConfig &rhs) { + return !operator==(lhs, rhs); + } + } #endif