refactored to use flask-security