Add auth db connection function