Bird
0
0

Which Flask extension is commonly used to add CSRF protection to forms?

easy📝 Conceptual Q2 of 15
Flask - Security Best Practices
Which Flask extension is commonly used to add CSRF protection to forms?
AFlask-Login
BFlask-WTF
CFlask-Migrate
DFlask-SQLAlchemy
Step-by-Step Solution
Solution:
  1. Step 1: Identify Flask extensions related to forms

    Flask-WTF is designed to handle forms and includes CSRF protection.
  2. Step 2: Match extension to CSRF feature

    Flask-WTF automatically adds CSRF tokens to forms.
  3. Final Answer:

    Flask-WTF -> Option B
  4. Quick Check:

    CSRF extension = Flask-WTF [OK]
Quick Trick: Flask-WTF handles forms and CSRF tokens [OK]
Common Mistakes:
MISTAKES
  • Choosing Flask-Login which manages user sessions
  • Confusing Flask-Migrate with database migrations
  • Selecting Flask-SQLAlchemy which manages databases

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Flask Quizzes