Flask-Security is a Flask extension which adds basic security and authentication features to your Flask apps quickly and easily. It additionally bootstraps your application with various views for handling its configured features to get you up and running as quick as possible.
Questions tagged [flask-security]
319 questions
3
votes
1 answer
Best method to integrate Nuxt frontend with Flask backend
I am trying to integrate a front-end dashboard built with nuxt with an API back-end built with Flask. Both the front and the back must run on the same local server on the client's closed network. The client wishes to use Flask-Security in order to…

yg1
- 33
- 1
- 3
3
votes
2 answers
SECURITY_PASSWORD_SALT must not be None - flask security
This question is related to: Unique Salt per User using Flask-Security, but I'm more concerned with removing this error message.
The linked question established that flask-security uses per-user salts, which is good since a global salt is…

thosphor
- 2,493
- 7
- 26
- 42
3
votes
1 answer
Flask-Security override register view
Is there some convenient way to override register view in Flask-Security? I'm pretty happy with the built-in view for registration, but I need it to be accessible only after authentication and by certain roles.
I tried to override it like this (with…

drahoja9
- 81
- 7
3
votes
1 answer
Flask security incredibly slowing all https traffic
I am using Flask Security for creating a secure API.
I recently discovered that using @auth_token_required makes each one of my calls to the back end take approximately 50 times longer. Https call time is increased from 100ms per request to 5+…

TacoEater
- 2,115
- 20
- 22
3
votes
3 answers
How to pass in a user attribute to a python function/route -- Flask
So I'm creating a simple website in flask that allows two types of users. Admin and regular users. I have a class called "User" which has an attribute "isUser". I then have a route call "addMovie" which takes in a parameter "isUser" to check to see…

humbleCoder
- 463
- 1
- 5
- 18
3
votes
1 answer
Flask-Security email confirmation (Flask-Mail) Fails to send without modifying flask_security/utils.py
I'm experimenting with Flask-Security and was having some trouble getting the confirmation email to send. I eventually fixed it by removing a line in flask_security/utils.py. I removed line 387, forcing flask-mail to use the app.config's mail…

John Robinson
- 315
- 4
- 16
3
votes
1 answer
Flask multiple login from same computer
I currently have a flask application that uses Flask-Security to handle user login and registration. I'm trying to test a chatroom I made so I want to login to two different accounts in different windows to check if it works. However I can't do that…

Scragglez
- 123
- 1
- 11
3
votes
1 answer
How to secure Flask-Admin if my only user is going to be the Admin?
I have seen plenty of solutions online, however all of them addressed more complex apps which allow external users to create accounts. In my case the only user will be the admin. How do I secure the /admin routes created by Flask-Admin in an…

Vlad Lazar
- 377
- 1
- 3
- 13
3
votes
1 answer
How to limit number of active logins in Flask
I'm trying to write a basic Flask app that limits the number of active logins a user can have, a la Netflix. I'm using the following strategy for now:
Using Flask_Security
store a active_login_count field for my User class.
every time a successful…

lip
- 114
- 1
- 11
3
votes
3 answers
How can I prevent the usage of old flask-jwt token when I change the password
I'm new using JWT and flask-jwt. I implemented flast-jwt in my project. The access token received from flask-jwt is not expired even after I changed the user password. Then how can prevent usage of old flask-jwt token.

Savad KP
- 1,625
- 3
- 28
- 40
3
votes
1 answer
How is the return value of Flask-Security's context processor used?
I am trying to customize my register view for flask-security as specified in the documentation.
@security.register_context_processor
def security_register_processor():
return dict(hello="world")
I don't know what return dict(hello="world")…

Dan Rubio
- 4,709
- 10
- 49
- 106
3
votes
1 answer
How to get auth_token_required in Flask_Security working?
I'm trying to build a token based backend (API) for an app using Flask in which I'm trying to use Flask_Security. Since I'm using the Peewee ORM, I've followed this guide to build the basic setup and I now have to build the views which should login…

kramer65
- 50,427
- 120
- 308
- 488
3
votes
1 answer
KeyError: 'security' in Flask_security?
I'm building a website using Flask in which I'm now trying to use Flask_Security for token based authentication. I now want to get an auth_token from the user, for which I use the get_auth_token() method. Unfortunately I get the stacktrace below…

kramer65
- 50,427
- 120
- 308
- 488
3
votes
1 answer
Installed bcrypt on windows for python and passlib--still have MissingBackendError
Trying to get bcrypt working on windows has been a challenge. I finally found a reddit thread pointing to a windows distribution of bcrypt (http://www.reddit.com/r/flask/comments/15q5xj/anyone_have_a_working_version_of_flaskbcrypt_for/), and it…

Chockomonkey
- 3,895
- 7
- 38
- 55
3
votes
0 answers
Flask: how to authenticate user on subdomain?
A user logins in through mydomain.com. How can I make it so that when they visit their own server at subdomain.mydomain.com, that they won't have to relogin? Alternatively, if a user logs in through subdomain.mydomain.com, they should find…

KJW
- 15,035
- 47
- 137
- 243