diff options
-rw-r--r-- | src/modules/m_bcrypt.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/modules/m_bcrypt.cpp b/src/modules/m_bcrypt.cpp index a8de729d2..a9a1ef2ae 100644 --- a/src/modules/m_bcrypt.cpp +++ b/src/modules/m_bcrypt.cpp @@ -56,6 +56,11 @@ class BCryptProvider : public HashProvider return Generate(data, Salt()); } + bool Compare(const std::string& input, const std::string& hash) CXX11_OVERRIDE + { + return InspIRCd::TimingSafeCompare(Generate(input, hash), hash); + } + std::string ToPrintable(const std::string& raw) CXX11_OVERRIDE { return raw; |