courses

Environment Configuration

REMnux is a Linux toolkit for reverse-engineering and analyzing malicious software, maintained by Lenny Zeltser. It is distributed as a pre-built Ubuntu-based VM with a curated collection of malware analysis tools already installed and configured. This is our primary analysis environment for this course.

Getting REMnux

The simplest way that works everywhere is to follow these instructions.

On an Apple Silicon Mac this will not work as written: REMnux is x86-64-only. See Running x86-64 Linux on Apple Silicon first.

System Configuration

First, make sure REMnux is up to date:

$ sudo apt update
$ sudo apt upgrade -y

Install Additional Tools

REMnux comes with many malware analysis tools pre-installed. The supplemental tools and the pre-configured shell environment used in this course are installed by an Ansible playbook, malware-env.

Run it on the VM itself, against the machine it is running from. Ansible is in the Ubuntu archive, so installing it is one apt line:

$ sudo apt update
$ sudo apt install -y ansible
$ git clone https://gitlab.cecs.pdx.edu/dmcgrath/malware-env.git
$ cd malware-env
$ ansible-playbook -i localhost, -c local setup.yml -K

The trailing comma in -i localhost, is not a typo — it is how Ansible takes an inline host list instead of an inventory file. -c local runs the tasks directly instead of connecting over SSH to the machine you are already on, and -K prompts for the sudo password the playbook needs to install packages. Run it as your normal account, not under sudo — it configures the account that runs it, and refuses to start as root. You will be prompted for your git name and email.

This replaces the setup.sh script used in previous terms, which no longer works: two of the package names it installed were removed in Ubuntu 24.04, and because apt fails an entire transaction on a single unknown name, the script installed nothing at all. The playbook asks the target what it actually carries instead. See Lab Setup for the tags, and the repository README for the full list.

This will take a while. When it’s done, reboot your VM to ensure everything is set up correctly, then log back in and launch a terminal.

Important: VM Snapshots

Before you begin any malware analysis, take a VM snapshot. This allows you to revert to a clean state at any time. In VirtualBox:

  1. Go to Machine > Take Snapshot
  2. Give it a descriptive name (e.g., “Clean baseline - post setup”)
  3. Before each assignment, revert to this snapshot or take a new one

Never execute malware outside your VM. If in doubt, revert to a clean snapshot.