MCPcopy Create free account
hub / github.com/ddnet/ddnet / UpdateKeyHash

Method UpdateKeyHash

src/engine/server/authmanager.cpp:177–186  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

175}
176
177void CAuthManager::UpdateKeyHash(int Slot, MD5_DIGEST Hash, const unsigned char *pSalt, const char *pRoleName)
178{
179 if(Slot < 0 || Slot >= (int)m_vKeys.size())
180 return;
181
182 CKey *pKey = &m_vKeys[Slot];
183 pKey->m_Pw = Hash;
184 mem_copy(pKey->m_aSalt, pSalt, SALT_BYTES);
185 pKey->m_pRole = FindRole(pRoleName);
186}
187
188void CAuthManager::UpdateKey(int Slot, const char *pPw, const char *pRoleName)
189{

Callers 1

ConAuthUpdateHashedMethod · 0.80

Calls 1

mem_copyFunction · 0.85

Tested by

no test coverage detected