Discord CTF helper bot for CyberErudites

Overview

Eruditus - CTF helper bot


Logo

Eruditus - CTF helper bot

About

Eruditus is a Discord CTF helper bot built with Python, it was initially designed to be used internally within the CyberErudites CTF team in order to make team work as efficient as possible.
The bot implements a bunch of useful features and uses Discord's Slash commands to make its usage as intuitive as possible.

Features

Core functionalities

  • Manage channels and their permissions
  • Track CTFTime events and announce them on the server
  • Track CTFs progress
  • Track members' participation in challenges
  • Announcements upon solving a challenge
  • Automatic flag submission from within the Discord guild

Miscellaneous

  • Provides a utility to lookup system calls from a specific architecture
  • Provides a utility for basic encoding schemes
  • Provides a utility for classic ciphers

Usage

/ctf createctf <ctf_name>                                       (Create a new CTF)
/ctf renamectf <ctf_name>                                       (Rename a CTF)
/ctf archivectf <mode> [<ctf_name>]                             (Archive a CTF's channels)
/ctf deletectf [<ctf_name>]                                     (Delete a CTF as well as its channels)
/ctf join <ctf_name>                                            (Join a specific CTF channels)
/ctf leave                                                      (Leave a CTF)
/ctf addcreds <username> <password> <url>                       (Add credentials for the current CTF)
/ctf showcreds                                                  (Show credentials of the current CTF)
/ctf status [<ctf_name>]                                        (Show CTF(s) status)
/ctf workon <challenge_name>                                    (Access the private channel associated to the challenge)
/ctf unworkon [<challenge_name>]                                (Leave the challenge channel)
/ctf solve [<support_member>]...                                (Mark a challenge as solved)
/ctf unsolve                                                    (Mark a challenge as not solved)
/ctf createchallenge <challenge_name> <challenge_category>      (Create a new challenge)
/ctf renamechallenge <new_name> <new_category>                  (Rename a challenge)
/ctf deletechallenge [<challenge_name>]                         (Delete a challenge)
/ctf pull [<ctfd_url>]                                          (Pull unsolved challenges from the CTFd platform)
/ctf takenote <type> <note_format>                              (Copies the last message into the notes channel)
/ctf submit <flag> [<support_member>]...                        (Submits a flag to CTFd)

/syscalls show <arch> <syscall name/syscall id>                 (Show information for a specific syscall)

/ctftime upcoming [<limit>]                                     (Show upcoming CTF competitions)
/ctftime current                                                (Show ongoing CTF competitions)
/ctftime top [<year>]                                           (Show leaderboard for a specific year)

/cipher caesar <message> [<key>]                                (Caesar cipher)
/cipher rot13 <message>                                         (Rot13 cipher)
/cipher atbash <message>                                        (Atbash cipher)

/encoding base64 <encode/decode> <data>                         (Base64 encoding/decoding)
/encoding base32 <encode/decode> <data>                         (Base32 encoding/decoding)
/encoding binary <encode/decode> <data>                         (Binary encoding/decoding)
/encoding hex <encode/decode> <data>                            (Hex encoding/decoding)
/encoding url <encode/decode> <data>                            (URL encoding/decoding)

Installation (brief explanation)

This is a self hosted bot, just set your bot token config.py file and run docker-compose up -d --build.
In order to use Slash commands, the usual bot scope in the Discord developer portal is not sufficient, you must also grant the applications.commands scope.

Contribution Guidelines

More information on how to contribute to this project will be provided soon.

Contributors

Credits

This work was inspired from these amazing projects:

License

Distributed under the MIT License. See LICENSE for more information.

Comments
  • Auto account creation

    Auto account creation

    Because most ctfs use ctfd, I believe it is conceivable to have the bot establish an account for that ctf (assuming it uses ctfd).

    This will also necessitate the addition of configuration for the email address that will be used in the registration process, as well as any other information that may be required (depends on what the registration requires). 

    bug enhancement 
    opened by ouxs-19 2
  • Add a command to set the CTF reminder channel

    Add a command to set the CTF reminder channel

    Currently the bot sends CTF reminders to the channel defined as REMINDER_CHANNEL in the configuration variables, and if the variable is not set, it looks up a channel named #general or the first world-readable channel it can write to. It would be good to have a command to set the reminder channel manually.

    enhancement 
    opened by malikDaCoda 1
  • Fix several bugs and add new features

    Fix several bugs and add new features

    Bug fixes

    • /ctf takenote wasn't taking attachments into consideration (fixed in 6bd9cba)
    • /ctf status wasn't displaying all challenges because of Discord's fields limit of 25 per embed (fixed in 6bd9cba)
    • After adding a challenge, the command issuer shouldn't be able to see its channel automatically, otherwise it will cause a lot of pain if /ctf pull is run, as a lot of challenges will be added (fixed in 6bd9cba)
    • Periodic puller wasn't working properly (fixed in 6bd9cba)
    • Truncate event information (description and prizes) which can be larger than Discord's allowed field value length of 1024 (fixed in 54a2497)
    • /ctftime upcoming can be used in DM now (fixed in 23d9b01)

    Optimization

    • Session cookies are now cached (fixed in 70ccbbc)

    Features

    • Add /ctf scoreboard command to display the scoreboard at any time, in addition to posting the scoreboard periodically in its dedicated channel (introduced in 79f276c)
    • Add /request and /report commands to send a feature request or a bug report to the developer (introduced in 22f4755)
    • Post solves summary after archiving the CTF (introduced in 718c3a3)

    Enhancements

    • Add ability to feed a numerical ID into /ctf workon instead of going through the pain of typing a long challenge name (introduced in 7decf6e)
    • Format scoreboard to easily spot our team position (introduced in 5e22987)
    opened by hfz1337 0
  • Feature: Manage multiple guilds simultaneously

    Feature: Manage multiple guilds simultaneously

    1. Added the possibility to manage multiple guilds simultaneously, every guild has its own separate database.
    2. Updated installation instructions in README.md, there are 2 methods now, either by inviting the bot or self hosting it.
    3. Added a new slash command /config which enables setting per guild configuration variables easily.
    opened by hfz1337 0
  • Things that need to be done

    Things that need to be done

    • [x] Add docstrings according to the docstring convention in PEP 257
    • [x] Add CONTRIBUTING.md
    • [x] Revisit README.md (I've written it in hurry)
    • [x] Integrate Github workflows to check pull requests mergeability (check that they conform to our coding style)
    • [ ] Add a new cog for generating reverse shell payloads, shellcodes, gopher payloads, etc
    enhancement 
    opened by hfz1337 0
  • Migrated to the brand new Slash commands

    Migrated to the brand new Slash commands

    Major changes

    • Switched to Slash commands that Discord introduced in late 2020
    • Structured the project files

    Minor changes

    • Setup proper logging of errors
    • Moved the configuration from docker-compose.yml to config.py

    New features

    • Retrieve challenges from the CTFd platform periodically by invoking the ctf pull command, create the challenge and send a pinned message in its channel containing the challenge information (name, description, points, etc).
    • Announce an upcoming event when it approaches and enable voting using reactions.
    • If the announced event gets a certain amount of positive votes, the CTF is automatically created and members are given instructions on how to join.
    • When the CTF starts, a reminder will be sent in its general channel by mentioning the CTF role, also, the clock emoji in the category name will change to a red dot.
    • Announce added challenges in the CTF's announcements channel and a lot more features.
    opened by hfz1337 0
  • Add `/ctf intro` to act as a tutorial for new members

    Add `/ctf intro` to act as a tutorial for new members

    The bot lacks a key command, namely /ctf intro. This will be simple; once executed, the bot replies with a series of messages and images describing its usage (from joining a CTF, pulling challenges, solving challenges, etc). It will be useful for members who never used the bot before.

    enhancement good first issue 
    opened by hfz1337 0
Releases(v1.2)
  • v1.2(Jun 6, 2021)

    Bug fixes

    • /ctf takenote wasn't taking attachments into consideration (fixed in 6bd9cba)
    • /ctf status wasn't displaying all challenges because of Discord's fields limit of 25 per embed (fixed in 6bd9cba)
    • After adding a challenge, the command issuer shouldn't be able to see its channel automatically, otherwise it will cause a lot of pain if /ctf pull is run, as a lot of challenges will be added (fixed in 6bd9cba)
    • Periodic puller wasn't working properly (fixed in 6bd9cba)
    • Truncate event information (description and prizes) which can be larger than Discord's allowed field value length of 1024 (fixed in 54a2497)
    • /ctftime upcoming can be used in DM now (fixed in 23d9b01)

    Optimization

    • Session cookies are now cached (fixed in 70ccbbc)

    Features

    • Add /ctf scoreboard command to display the scoreboard at any time, in addition to posting the scoreboard periodically in its dedicated channel (introduced in 79f276c)
    • Add /request and /report commands to send a feature request or a bug report to the developer (introduced in 22f4755)
    • Post solves summary after archiving the CTF (introduced in 718c3a3)

    Enhancements

    • Add ability to feed a numerical ID into /ctf workon instead of going through the pain of typing a long challenge name (introduced in 7decf6e)
    • Format scoreboard to easily spot our team position (introduced in 5e22987)

    CI/CD

    • Add pre-commit hook and github workflow to check for code style using black and flake8
    Source code(tar.gz)
    Source code(zip)
  • v1.1(May 31, 2021)

Owner
Hafidh
Computer Science student at ESI | Cyber Security enthusiast | CTF player at Sudo_root
Hafidh
Discord bot ( discord.py ), uses pandas library from python for data-management.

Discord_bot A Best and the most easy-to-use Discord bot !! Some simple basic auto moderations, Chat functions. It includes a game similar to Casino, g

Jaitej 4 Aug 30, 2022
Instant messaging client in tkinter

Concord_client_tk Instant messaging client in tkinter Contributors : Ilade-s [https://github.com/Ilade-s] Doku [https://github.com/D0kuhebi] Descripti

Raphaël Merlet 2 Jun 15, 2022
Sakura: an powerfull Autofilter bot that can be used in your groups

Sakura AutoFilter This Bot May Look Like Mwk_AutofilterBot And Its Because I Like Its UI, That's All Sakura is an powerfull Autofilter bot that can be

PaulWalker 12 Oct 21, 2022
The best (and now open source) Discord selfbot.

React Selfbot Yes, for real Why am I making this open source? Because can't stop calling my product a rat, tokenlogger and what else not. But there is

30 Nov 13, 2022
FUD Keylogger That Reports To Discord

This python script will capture all of the keystrokes within a given time frame and report them to a Discord Server using Webhooks. Instead of the traditional

●┼Waseem Akram••✓⁩ 16 Dec 08, 2022
Online Marketplace API

Online Marketplace API Table of Contents Setup Instructions Documentation Setup instructions Make sure you have python installed Clone the repository

Kanat 3 Jul 13, 2022
A combination between python-flask, that fetch and send data from league client during champion select thanks to LCU

A combination between python-flask, that fetch data and send from league client during champion select thanks to LCU and compare picked champs to the gamesDataBase that we need to collect using my ot

Anas Hamrouni 1 Jan 19, 2022
Telegram Bot to learn English by words and more.. ( in Arabic )

Get the mp3 files Extract the mp3.rar on the same file that bot.py on install requirements pip install -r requirements.txt #Then enter you bot token

Plugin 10 Feb 19, 2022
Open Resource Calculator Module for Python

Calculator Module for Python By White Night Install #

White_Night_awa 4 Aug 22, 2022
C Y B Ξ R UserBot is a project that simplifies the use of Telegram.

C Y B Ξ R USΞRBOT 🇦🇿 C Y B Ξ R UserBot is a project that simplifies the use of Telegram. All rights reserved. Automatic Setup Android: open Termux p

FVREED 4 Dec 07, 2022
A file-based quote bot written in Python

Let's Write a Python Quote Bot! This repository will get you started with building a quote bot in Python. It's meant to be used along with the Learnin

1 Dec 07, 2021
Dodo - A graphical, hackable email client based on notmuch

Dodo Dodo is a graphical email client written in Python/PyQt5, based on the comm

Aleks Kissinger 44 Nov 12, 2022
The Social-Engineer Toolkit (SET) is specifically designed to perform advanced attacks against the human element.

The Social-Engineer Toolkit (SET) The Social-Engineer Toolkit (SET) is specifically designed to perform advanced attacks against the human element. SE

Professor 6 Nov 28, 2022
A discord bot for checking what linked profiles a user has to their Ubisoft account

ubisoft_discord_profiles A Discord bot for checking what linked profiles a user has to their Ubisoft account. This can be setup using an enviromental

Andrei 1 Dec 17, 2021
Модуль для создания скриптов для ВКонтакте | vk.com API wrapper

vk_api vk_api – Python модуль для создания скриптов для ВКонтакте (vk.com API wrapper) Документация Примеры Чат в Telegram Документация по методам API

Kirill 1.2k Jan 04, 2023
A Discord bot that allows you to rapidly deploy Minecraft servers seamlessly and painlessly from Discord.

Lyra - rapidly and painlessly deploy Minecraft servers from Discord Lyra lets you deploy Minecraft server instances via Docker with control through a

1 Dec 23, 2021
A discord self bot that replies to messages using cleverbot

cleverbot-discord-self A discord self bot that replies to messages using cleverbot Bot will respond to DMs and channels in the channels list. Need to

0 Jan 11, 2022
Ghostbuster - Eliminate dangling elastic IPs by performing analysis on your resources within all your AWS accounts

Table of Contents Table of Contents Ghostbuster The problem Project Features Ins

Assetnote 182 Dec 24, 2022
Robust and blazing fast open-redirect vulnerability scanner with ability of recursevely crawling all of web-forms, entry points, or links with data.

After Golismero project got dead there is no more any up to date open-source tool that can collect links with parametrs and web-forms and then test th

railway zeppelin 34 Aug 25, 2022
An all-purpose Discord bot written in Python featuring a diverse collection of practical utilities.

GlazeGlopBot Table of Contents About Setup Usage Commands Command Errors Cog Management Local Sound Files Cogs Mod QR RNG VC Weather Proposed Features

Edison Ye 0 May 12, 2022