summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-04-09 20:24:04 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-04-09 20:24:04 +0000
commitbb848f8fd2eedaddd22420fbaf37249d4a9ac27b (patch)
treece60ba06b19c81639217afd4da3604a965efa09a /src/modules
parentf94d5010fc8bdb4ee37694e6bb7e32cc7f9cade2 (diff)
The hmac stuff was slightly wrong, calculating the 2nd part
left a concatenation outside the bracket git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6787 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/m_spanningtree/treesocket1.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/modules/m_spanningtree/treesocket1.cpp b/src/modules/m_spanningtree/treesocket1.cpp
index 03fa69197..1dede8b31 100644
--- a/src/modules/m_spanningtree/treesocket1.cpp
+++ b/src/modules/m_spanningtree/treesocket1.cpp
@@ -143,11 +143,12 @@ std::string TreeSocket::MakePass(const std::string &password, const std::string
hmac2 += static_cast<char>(password[n] ^ 0x36);
}
+ hmac2 += challenge;
HashResetRequest(Utils->Creator, sha256).Send();
hmac2 = HashSumRequest(Utils->Creator, sha256, hmac2).Send();
HashResetRequest(Utils->Creator, sha256).Send();
- std::string hmac = hmac1 + hmac2 + challenge;
+ std::string hmac = hmac1 + hmac2;
hmac = HashSumRequest(Utils->Creator, sha256, hmac).Send();
return "HMAC-SHA256:"+ hmac;