Why the plugin exists

A quick introduction to what CTFd-chall-manager is and why it should be used.

Why Chall-Manager exists?

Originally, CTFer.io used Pulumi in Go to deploy CTFd in a Kubernetes cluster due to our expertise in software development. One of Chall-Manager’s target capabilities was that “anything deployable by Pulumi could be deployable by Chall-Manager”. This promise would have been difficult to achieve if we had used only Python, as it required many dependencies and would force each plugin user to rebuild the CTFd Docker image.

Additionally, we aimed for an Offline-First model, and using Golang made it easier to achieve this goal because we could compile the program and deploy it in a Docker image.

However, executing Pulumi with Go inside CTFd proved to be difficult. We wanted to build a reusable component without vendor lock-in and without hard coupling between technical objects with different goals. Therefore, a dedicated component was a good choice.

In summary, each component has its own scope:

  • Chall-Manager: Exposed an API to manage challenges using infrastructure-as-code.
  • CTFd: Handled player authentication, the scoreboard, challenges, and the web interface.
  • CTFd-chall-manager: Acted as the bridge between the two components.

How CTFd-chall-manager works with CTFd and Chall-Manager?

CTFd-chall-manager is a CTFd plugin designed to enhance CTFd’s core functionalities. Chall-Manager allowed the execution of any Pulumi project as long as it adhered to the syntax required by the SDK.

The CTFd-chall-manager plugin served as a user interface for the Chall-Manager system, making it accessible and user-friendly for a broader audience. The plugin exposed an API within CTFd, performing necessary checks before forwarding requests to Chall-Manager.