db: implement password-check method
db: implement password-check method

Takes the password, username and the table (admins or players)
and checks the password using bcrypt hash. Returns
the ID of the user if the user is authenticated, otherwise
returns None.

Signed-off-by: Ilija Hadzic <47a09d4a4430975766160361f65fc72633be50b6@gmail.com>

ihadzic/jim,ihadzic/jim,ihadzic/jim