CTF

A capture the flag (CTF) competition in cybersecurity is an event where participants solve various security-related challenges to find flags and earn points.

Flags

Flags are a piece of structured text that players need to get by exploiting vulnerabilities in CTF challenges. By knowing the flag of a challenge, the players can prove that they have exploited the challenge in some way and receive points for it. This is the anatomy of a flag:

The three main parts are the prefix, the content and optionally some high entropy data at the end.

Game Modes

There are two very popular CTF game modes: Jeopardy and Attack & Defense.

Jeopardy

A jeopardy CTF can be played individually or as a team, depending on the competition rules. All players and teams are given the exact same challenges that are hosted on the organisers infrastructure. The challenges are grouped into different categories:

Scoring

Most modern jeopardy CTF use dynamic scoring. This means that all challenges start at the same point value, regardless of difficulty, but the value of a challenge drops with each new solve. The challenge value then also applies to teams that have already solved the challenge.

This ensures that challenges that have many solves are worth less points than challenges with fewer solves, thus automatically balancing challenge value according to difficulty.

Attack & Defense

This format simulates a scenario where teams act as both attackers and defenders. The teams must defend their own systems while also attempting to exploit vulnerabilities in services of the other teams, where all teams need to host the same services. Each team has access to its own server that hosts vulnerable applications or services.

Scoring

Generally, scoring of Attack & Defense CTFs is performed in ticks. A tick occurs at a set interval, usually every few minutes (e.g., every 2-5 minutes), depending on the competition’s rules.

Getting Started

Playing CTFs is the best way to get started and prepare for future CTFs.

While this statement might sound funny at first, it is true. There really is no way around getting your hands dirty and trying to solve a CTF challenge. If you get stuck, thats part of the experience and is exactly where you will learn new things. If you weren’t able to solve a challenge during a CTF, you will almost certainly be able to find a writeup online on CTFTime.org after the CTF has ended.

If you are looking for a more guided learning experience, please check out SPARC! It is a free cyber security talent training program available to swiss citizens that also doubles as a first contact point with the military if you want to go into cyber security during your military service.

Finding CTFs to play

CTFTime.org again is a great resource in finding CTFs to play, be that as a single player or as a team. For convenience, use the buttons below to directly find upcoming events filtered by preferred game mode:

 Upcoming Jeopardy CTFs  Upcoming Attack & Defense CTFs

Do you want to check out challenges of previous Swiss Hacking Challenge events or want to prepare for the next big event? Look no further than the challenge library:

 Team /mnt/ain Challenge Library

The challenge library is available online, free and has no time limit, so you can train whenever you want to!