Skip to main content
This project demonstrates real cybersecurity concepts including reverse shells and persistence mechanisms. Use it only in a controlled virtual machine or isolated lab environment. Never run it on production systems or against unauthorized targets.

What is Virus Hunter: Code Defender?

Virus Hunter: Code Defender is a Python-based 2D arcade game built with Pygame that teaches cybersecurity concepts through hands-on gameplay. Players control an Antivirus Avatar navigating a cyber-themed environment, progressing through four levels that mirror real-world attack and defense scenarios. The game isn’t just entertainment — each level demonstrates a genuine security technique: dependency verification, reverse shell communication, persistence mechanisms, and system cleanup. By playing through the game, students and security enthusiasts gain practical exposure to concepts typically confined to textbooks.

How it works

Level 1: System Scan

Automatic dependency verification simulates the first step of any secure system: ensuring all required components are present and authenticated.

Level 2: Network Node

Real-time TCP reverse shell communication with a listener process demonstrates how remote access tools establish and maintain connections.

Level 3: Persistence

Cross-platform persistence simulation shows how malware survives reboots using Windows Registry, Linux crontab, and macOS LaunchAgents.

Level 4: Final Cleanup

System restoration and secure exit teaches the remediation phase — how to remove persistence artifacts and restore a clean state.

Key features

  • Educational gameplay — Four progressive levels mapping to real attack phases
  • Real reverse shell — Functional TCP socket shell on port 5050, not a simulation
  • Cross-platform persistence — Works on Windows, Linux, and macOS
  • Consent-first design — Requires explicit user acknowledgment before any cybersecurity features activate
  • Cleanup tool — Removes all artifacts created during the session
  • Listener CLI — Full command interface with file download, directory navigation, and heartbeat monitoring

Who is this for?

Security students

Learn attack techniques in a safe, controlled environment with immediate visual feedback.

Educators

Use as a classroom demonstration tool for concepts like persistence and reverse shells.

CTF participants

Practice recognizing and understanding common attacker techniques in an interactive format.

Developers

Study the Python implementation of network sockets, threading, and OS-level persistence APIs.

Quick navigation

Installation

Get Python, install dependencies, and run the game in minutes.

Quickstart

Start the listener, launch the game, and complete your first session.

Gameplay guide

Understand the controls, objectives, and how each level works.

Safety guide

Set up a safe lab environment before running the game.

Build docs developers (and LLMs) love