A CTF leaderboard for the submission of flags during a CTF challenge. Built using Django.

Related tags

Djangoctf-leaderboard
Overview

🚩 CTF Leaderboard

The goal of this project is to provide a simple web page to allow the participants of an CTF to enter their found flags. Also the live overview over all found flags gives a more competitive feeling to the game.

This app is written using Python 3 and the Django web framework.

Screenshot

Features

  • Participants can submit flags found during the CTF challenge
  • Live reload on the leaderboard overview
  • Simple administration through the Django admin UI (at /admin)
  • Custom landing page through the Content-model in the DB for instructions, links and screenshots

Getting started

Create and activate a virtual environment for the app:

$ python3 -m venv venv
$ source venv/bin/activate

Install all the necessary dependencies:

$ python3 -m pip install -r requirements.txt

Copy the .env.dist file to a .env file and make suitable adjustments (SECRET_KEY is important).

Create the database through migration and create a superuser for the admin UI (at /admin):

$ python3 manage.py migrate
$ python3 manage.py createsuperuser
$ python3 manage.py collectstatic

Run the server:

$ python3 manage.py runserver

Participant-Name-Format (name e.g. "Group B" in the screenshot): max. 20 chars
Name-Format (custom_name e.g. "Maurice, Gabriel" in the screenshot): max. 40 chars [a-zA-Z0-9_ ,]*
Flag-Format (secret): max. 200 chars [a-zA-Z0-9_]+

Feature ideas

This is a list of features some users requested but still need to be implemented. Feel free to implement one of them and submit a pull request. Thank you! Hint: we are roughly following the PEP 8 guideline using autopep8.

  • Crown the winner of the CTF who first found all the flags
  • Allow the creation of multiple pages (not only one homepage)
  • Enable multiple simultaneous CTFs through a list of available CTFs or unique URLs
Comments
  • Bump django from 4.0.7 to 4.0.8

    Bump django from 4.0.7 to 4.0.8

    Bumps django from 4.0.7 to 4.0.8.

    Commits
    • 7d5cb49 [4.0.x] Bumped version for 4.0.8 release.
    • 23f0093 [4.0.x] Fixed CVE-2022-41323 -- Prevented locales being interpreted as regula...
    • 4a30e0d [4.0.x] Set date and added stub notes for 4.0.8 and 3.2.16 releases.
    • 898f0aa [4.0.x] Added CVE-2022-36359 to security archive.
    • 60e6bae [4.0.x] Post-release version bump.
    • See full diff in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
  • Bump django from 4.0.6 to 4.0.7

    Bump django from 4.0.6 to 4.0.7

    Bumps django from 4.0.6 to 4.0.7.

    Commits
    • e9e9729 [4.0.x] Bumped version for 4.0.7 release.
    • b7d9529 [4.0.x] Fixed CVE-2022-36359 -- Escaped filename in Content-Disposition header.
    • 2eb7ded [4.0.x] Adjusted version 4.0.7 release notes.
    • baeffe8 [4.0.x] Ignored 080359c4c5242ef69ac8c58c92f240e71121ffd7 formatting changes i...
    • 080359c [4.0.x] Fixed warnings per flake8 5.0.0.
    • 1a9f079 [4.0.x] Fixed collation tests on MySQL 8.0.30+.
    • b8b449f [4.0.x] Adjusted release notes for 4.0.7 and 3.2.15.
    • 2c2b748 [4.0.x] Added release date and stub release notes for 4.0.7 and 3.2.15 releases.
    • f78b18f [4.0.x] Fixed #33820 -- Doc'd "true"/"false"/"null" caveat for JSONField key ...
    • 48501c8 [4.0.x] Fixed RelatedGeoModelTest.test08_defer_only() on MySQL 8+ with MyISAM...
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
  • Bump django from 4.0.4 to 4.0.6

    Bump django from 4.0.4 to 4.0.6

    Bumps django from 4.0.4 to 4.0.6.

    Commits
    • caad462 [4.0.x] Bumped version for 4.0.6 release.
    • c732152 [4.0.x] Updated man page for Django 4.0.6.
    • 0dc9c01 [4.0.x] Fixed CVE-2022-34265 -- Protected Trunc(kind)/Extract(lookup_name) ag...
    • a2b88d7 [4.0.x] Fixed typo in docs/topics/signals.txt.
    • 2b901c1 [4.0.x] Fixed GEOSTest.test_emptyCollections() on GEOS 3.8.0.
    • 4d20d2f [4.0.x] Fixed docs build with sphinxcontrib-spelling 7.5.0+.
    • 8a294ee [4.0.x] Added stub release notes and release date for 4.0.6 and 3.2.14.
    • 1c28443 [4.0.x] Fixed CoveringIndexTests.test_covering_partial_index() when DEFAULT_I...
    • 0f3b250 [4.0.x] Fixed #33789 -- Doc'd changes in quoting table/column names on Oracle...
    • 6661c48 [4.0.x] Updated OWASP Top 10 link in security topic.
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
  • Bump django from 4.0.2 to 4.0.4

    Bump django from 4.0.2 to 4.0.4

    Bumps django from 4.0.2 to 4.0.4.

    Commits
    • 89807fb [4.0.x] Bumped version for 4.0.4 release.
    • 00b0fc5 [4.0.x] Fixed CVE-2022-28347 -- Protected QuerySet.explain(**options) against...
    • 8008288 [4.0.x] Fixed CVE-2022-28346 -- Protected QuerySet.annotate(), aggregate(), a...
    • 78e553b [4.0.x] Fixed #33628 -- Ignored directories with empty names in autoreloader ...
    • 7700084 [4.0.x] Added stub release notes and release date for 4.0.4, 3.2.13, and 2.2.28.
    • 5137416 [4.0.x] Fixed #32129 -- Adjusted the docs for session expiry helpers.
    • 7d540d6 [4.0.x] Fixed #33598 -- Reverted "Removed unnecessary reuse_with_filtered_rel...
    • f62816b [4.0.x] Updated Oracle docs links to Oracle 21c.
    • 0da9053 [4.0.x] Updated various links to HTTPS and new locations.
    • 7f69c0d [4.0.x] Corrected models.FileField signature in docs.
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
  • Bump django from 4.0 to 4.0.2

    Bump django from 4.0 to 4.0.2

    Bumps django from 4.0 to 4.0.2.

    Commits
    • b12be7a [4.0.x] Bumped version for 4.0.2 release.
    • f9c7d48 [4.0.x] Fixed CVE-2022-23833 -- Fixed DoS possiblity in file uploads.
    • 0142204 [4.0.x] Fixed CVE-2022-22818 -- Fixed possible XSS via {% debug %} template tag.
    • 6928227 [4.0.x] Fixed #33480 -- Fixed makemigrations crash when renaming field of ren...
    • aff79be [4.0.x] Fixed #33468 -- Fixed QuerySet.aggregate() after annotate() crash on ...
    • 7a1c653 [4.0.x] Updated translations from Transifex.
    • 9a9c5b4 [4.0.x] Fixed #33459 -- Clarified index type in full text search docs.
    • 7c2d4d9 [4.0.x] Fixed #33462 -- Fixed migration crash when altering type of primary k...
    • f4de870 [4.0.x] Fixed #33048 -- Doc'd that DEBUG static files requests don't use midd...
    • f82ca84 [4.0.x] Fixed #33407 -- Fixed .radiolist admin CSS.
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
Releases(v1.0.0)
  • v1.0.0(Dec 23, 2021)

    🚩 CTF Leaderboard

    The goal of this project is to provide a simple web page to allow the participants of an CTF to enter their found flags. Also the live overview over all found flags gives a more competitive feeling to the game.

    This app is written using Python 3 and the Django web framework.

    Features

    • Participants can submit flags found during the CTF challenge
    • Live reload on the leaderboard overview
    • Simple administration through the Django admin UI
    • Custom landing page through the Content-model in the DB for instructions, links and screenshots
    Source code(tar.gz)
    Source code(zip)
Owner
Maurice Bauer
Student of Applied Computer Science at the Corporate State University Baden Württemberg
Maurice Bauer
Custom Django field for using enumerations of named constants

django-enumfield Provides an enumeration Django model field (using IntegerField) with reusable enums and transition validation. Installation Currently

5 Monkeys 195 Dec 20, 2022
Faker is a Python package that generates fake data for you.

Faker is a Python package that generates fake data for you. Whether you need to bootstrap your database, create good-looking XML documents, fill-in yo

Daniele Faraglia 15.2k Jan 01, 2023
A fresh approach to autocomplete implementations, specially for Django. Status: v3 stable, 2.x.x stable, 1.x.x deprecated. Please DO regularely ping us with your link at #yourlabs IRC channel

Features Python 2.7, 3.4, Django 2.0+ support (Django 1.11 (LTS), is supported until django-autocomplete-light-3.2.10), Django (multiple) choice suppo

YourLabs 1.7k Jan 01, 2023
📝 Sticky Notes in Django admin

django-admin-sticky-notes Share notes between superusers. Installation Install via pip: pip install django_admin_sticky_notes Put django_admin_sticky_

Dariusz Choruży 7 Oct 06, 2021
Learn Python and the Django Framework by building a e-commerce website

The Django-Ecommerce is an open-source project initiative and tutorial series built with Python and the Django Framework.

Very Academy 275 Jan 08, 2023
PostgreSQL with Docker + Portainer + pgAdmin + Django local

django-postgresql-docker Running PostgreSQL with Docker + Portainer + pgAdmin + Django local for development. This project was done with: Python 3.9.8

Regis Santos 4 Jun 12, 2022
Django React Flight Rezervation

Django Intro & Installation python -m venv venv source ./venv/Scripts/activate pip install Django pip install djangorestframework pip install python-d

HILMI SARIOGLU 2 May 26, 2022
Python CSS/Javascript minifier

Squeezeit - Python CSS and Javascript minifier Copyright (C) 2011 Sam Rudge This program is free software: you can redistribute it and/or modify it un

Smudge 152 Apr 03, 2022
Realworld - Realworld using Django and HTMX

Realworld - Realworld using Django and HTMX

Dan Jacob 53 Jan 05, 2023
Code coverage measurement for Python

Coverage.py Code coverage testing for Python. Coverage.py measures code coverage, typically during test execution. It uses the code analysis tools and

Ned Batchelder 2.3k Jan 05, 2023
Django Serverless Cron - Run cron jobs easily in a serverless environment

Django Serverless Cron - Run cron jobs easily in a serverless environment

Paul Onteri 41 Dec 16, 2022
AUES Student Management System Developed for laboratory works №9 Purpose using Python (Django).

AUES Student Management System (L M S ) AUES Student Management System Developed for laboratory works №9 Purpose using Python (Django). I've created t

ANAS NABIL 2 Dec 06, 2021
A starter template for building a backend with Django and django-rest-framework using docker with PostgreSQL as the primary DB.

Django-Rest-Template! This is a basic starter template for a backend project with Django as the server and PostgreSQL as the database. About the templ

Akshat Sharma 11 Dec 06, 2022
An app that allows you to add recipes from the dashboard made using DJango, JQuery, JScript and HTMl.

An app that allows you to add recipes from the dashboard. Then visitors filter based on different categories also each ingredient has a unique page with their related recipes.

Pablo Sagredo 1 Jan 31, 2022
It's the assignment 1 from the Python 2 course, that requires a ToDoApp with authentication using Django

It's the assignment 1 from the Python 2 course, that requires a ToDoApp with authentication using Django

0 Jan 20, 2022
Streamlining Django forms to provide all the wins of single-page-applications without the pain.

nango Streamlining Django forms to provide all the wins of single-page-applications without the pain. Key features Available to all Django deployments

Nick Farrell 107 Dec 12, 2022
Bringing together django, django rest framework, and htmx

This is Just an Idea There is no code, this README just represents an idea for a minimal library that, as of now, does not exist. django-htmx-rest A l

Jack DeVries 5 Nov 24, 2022
An insecure login and registration website with Django.

An insecure login and registration website with Django.

Luis Quiñones Requelme 1 Dec 05, 2021
Inject an ID into every log message from a Django request. ASGI compatible, integrates with Sentry, and works with Celery

Django GUID Now with ASGI support! Django GUID attaches a unique correlation ID/request ID to all your log outputs for every request. In other words,

snok 300 Dec 29, 2022
Per object permissions for Django

django-guardian django-guardian is an implementation of per object permissions [1] on top of Django's authorization backend Documentation Online docum

3.3k Jan 04, 2023