mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 13:37:00 +00:00
[8450] Prevented using of plaintext passwords in sql queries
This commit is contained in:
parent
c8b717ab7d
commit
9c5f85d309
7 changed files with 62 additions and 28 deletions
|
|
@ -865,13 +865,10 @@ int WorldSocket::HandleAuthSession (WorldPacket& recvPacket)
|
|||
|
||||
// Re-check account ban (same check as in realmd)
|
||||
QueryResult *banresult =
|
||||
loginDatabase.PQuery ("SELECT "
|
||||
"bandate, "
|
||||
"unbandate "
|
||||
"FROM account_banned "
|
||||
"WHERE id = '%u' "
|
||||
"AND active = 1",
|
||||
id);
|
||||
loginDatabase.PQuery ("SELECT 1 FROM account_banned WHERE id = %u AND active = 1 "
|
||||
"UNION "
|
||||
"SELECT 1 FROM ip_banned WHERE ip = '%s'",
|
||||
id, GetRemoteAddress().c_str());
|
||||
|
||||
if (banresult) // if account banned
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue