Agent skill · security · affaan-m

django-security

Django security best practices, authentication, authorization, CSRF protection, SQL injection prevention, XSS prevention, and secure deployment configurations.

Why this skill is useful

Provides specific security configurations and practices for Django applications that the AI wouldn't reliably generate on its own.

What it needs

About 6k tokens when loaded. Last updated 2026-08-06. 238,342 stars on the source repository.

What this skill does

Django Security Best Practices Comprehensive security guidelines for Django applications to protect against common vulnerabilities. When to Activate Setting up Django authentication and authorization Implementing user permissions and roles Configuring production security settings Reviewing Django application for security issues Deploying Django applications to production Core Security Settings Production Settings Configuration Authentication Custom User Model Password Hashing Session Management Authorization Permissions Custom Permissions Role-Based Access Control (RBAC) SQL Injection Prevention Django ORM Protection Extra Security with raw() XSS Prevention Template Escaping Safe String Handling HTTP Headers CSRF Protection Default CSRF Protection Exempting Views (Use Carefully) File Upload Security File Validation Secure File Storage API Security Rate Limiting Authentication for APIs Security Headers Content Security Policy Environment Variables Managing Secrets Logging Security Events Quick Security Checklist Check Description ------- ------------- DEBUG = False Never run with DEBUG in production HTTPS only Force SSL, secure cookies Strong secrets Use environment variables for SECRETKEY Password validation Enable all password validators CSRF protection Enabled by default, don't disable XSS prevention Django auto-escapes, don't use |safe with user input SQL injection Use ORM, never concatenate strings in queries File uploads Validate file type and size Rate limiting Throttle API endpoints Security headers CSP, X-Frame-Options, HSTS Logging Log security events Updates Keep Django and dependencies updated Remember: Security is a process, not a product. Regularly review and update your security practices.

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills affaan-m/django-security--b73751

View the source on GitHub

Browse the @skills marketplace