CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl-labs/django-security-basics

Security essentials for Django — CSRF, CORS, security middleware, ALLOWED_HOSTS,

99

2.91x
Quality

99%

Does it follow best practices?

Impact

99%

2.91x

Average score across 2 eval scenarios

SecuritybySnyk

Passed

No known issues

Overview
Quality
Evals
Security
Files

task.mdevals/scenario-1/

Project Management REST API

Build a Django REST API for a project management tool. Use Django REST Framework.

Models

  • Project -- id, name, description, created_at, owner (FK to User)
  • Task -- id, title, description, status (todo/in_progress/done), priority (low/medium/high), project (FK to Project), assignee (FK to TeamMember), due_date
  • TeamMember -- id, user (FK to User), project (FK to Project), role (admin/member/viewer), joined_at

API Endpoints

  • GET/POST /api/projects/ -- list and create projects
  • GET/PUT/DELETE /api/projects/<id>/ -- retrieve, update, delete a project
  • GET/POST /api/projects/<id>/tasks/ -- list and create tasks for a project
  • GET/PUT/DELETE /api/tasks/<id>/ -- retrieve, update, delete a task
  • GET/POST /api/projects/<id>/members/ -- list and add team members
  • DELETE /api/members/<id>/ -- remove a team member

Output

Produce a Django project in a project_manager/ directory:

  • project_manager/settings.py -- Django settings configured for production deployment
  • project_manager/urls.py -- URL configuration
  • projects/models.py -- the models
  • projects/serializers.py -- DRF serializers
  • projects/views.py -- DRF viewsets or API views
  • projects/urls.py -- app URL patterns
  • requirements.txt -- Python dependencies

The code should be ready for production deployment. Do not include test files.

evals

scenario-1

criteria.json

task.md

tile.json