CTFNote
CTFNote copied to clipboard
Frontend fails to render when invalid date in CTF
Bug
If there is a CTF entry with a invalid date in the database the frontend bug out. You can keep using CTFNote by directly opening the ctf pages if you know their ID and name. The page for the bugged entry will not open using this trick however
In the pictures above you see what normally happens when using the website.
However if you "invalid date" you see that the graphql does send the data over but the site does not render properly. In the last image you see what happens when you directly go to the http://localhost:8088/#/ctf/2-ads/info
page.
Proposal
This bug can be quite harmful because you will have to manually edit the database (or craft a GraphQL query) to get your instance working again. To fix this issue I have 2 proposed fixes.
- Make sure server side that invalid dates can never occur.
- Capture invalid dates client side and show an error.
- Make sure you cannot set these dates in the create CTF menu.