abs0lut3pwn4g3 / RTB-CTF-Framework

A fast, efficient and lightweight (~100 KB) Capture The Flag framework inspired by the HackTheBox platform. Built with Flask.
https://rtbctfframework.up.railway.app/
GNU Affero General Public License v3.0
108 stars 55 forks source link

Adding UserMachineModel #58

Closed svensevenslow closed 4 years ago

svensevenslow commented 4 years ago

Closes: #17

Changes Made

  1. Added UserMachine Model
  2. Made relevant changes for when a new user registers or new machine is created
  3. Updated the create_db files
  4. Made changes for the comments left in src/FlaskRTBCTF/ctf/routes.py

Other Information

  1. Running flake8 src/ --max-line-length=88 --show-source --statistics is throwing errors for src/FlaskRTBCTF/utils/init.py, which I assume can be ignored
  2. There is a typo in flake8 src/ --max-line-length=88 --show-source --statistics in CONTRIBUTING.md, I have corrected it for this branch atleast
  3. I have not utilised the get_all method in Machine class but have instead used query.all() directly wherever I need it. If the get_all method is preferred then I will use that and also add it to User class since it is required.

Let me know what you think @Eshaan7