Add database-based authentication