Skip to content

Latest commit

 

History

History
397 lines (283 loc) · 9.53 KB

File metadata and controls

397 lines (283 loc) · 9.53 KB

VMware Ubuntu Desktop/Server Lab Setup Guide

Date: 2026-05-25

Purpose: build an Ubuntu firmware-analysis VM on a Windows VMware host. This supports both downloaded ISOs:

ubuntu-24.04.4-desktop-amd64.iso      -> manual GUI install
ubuntu-24.04.4-live-server-amd64.iso  -> automated NoCloud/autoinstall path

The Ubuntu VM is a manual-analysis workbench and no-EMBA backup path. Kali remains the preferred EMBA box if EMBA/Docker works there.

If Kali/EMBA works smoothly, you do not need Ubuntu for the interview assignment. Build Ubuntu only when you want a backup path, a clean manual lab, or repeatable LTS automation.

Important: Desktop ISO vs Server ISO

You downloaded:

ubuntu-24.04.4-desktop-amd64.iso

That is the Desktop ISO.

For this guide's autoinstall flow, use the Ubuntu Server ISO, not the Desktop ISO:

ubuntu-24.04.4-live-server-amd64.iso

Why:

  • Ubuntu Server uses the Subiquity autoinstall flow directly.
  • The user-data / meta-data NoCloud seed method is designed for that installer path.
  • The Desktop ISO is better for a normal manual GUI install.

Decision:

Want easiest path with the ISO you already downloaded?
  -> Use Desktop ISO and install manually in VMware.

Want automated install?
  -> Download Ubuntu Server ISO and use this guide.

For your hardware and workflow, the Server autoinstall is still the better long-term repeatable lab option because IDA/Ghidra GUI can run on Windows, and the VM can stay lean. The Desktop ISO is still completely valid when you want the lowest-friction manual setup.

If you want a GUI later:

sudo apt update
sudo apt install -y ubuntu-desktop-minimal
sudo reboot

But do not install a desktop unless you actually need it inside the VM.

Windows Host + WSL2 Workflow

Your host is Windows and has WSL2. Use WSL2 only to create the seed ISO.

High-level:

Windows:
  download Ubuntu Server ISO
  run VMware Workstation Pro

WSL2:
  edit user-data
  generate password hash
  build seed.iso

VMware:
  attach Ubuntu Server ISO as CD/DVD 1
  attach seed.iso as CD/DVD 2
  boot installer

Paths:

Windows repo path:
C:\ai-assisted-vulnerability-reserach

WSL2 repo path:
/mnt/c/ai-assisted-vulnerability-reserach

You do not need to move the whole workflow into WSL2.

Files

docs/lab-setup/vmware-ubuntu-autoinstall/
  user-data          actual NoCloud autoinstall config
  meta-data          NoCloud instance metadata
  autoinstall.yaml   readable copy of the same config

Use user-data + meta-data to create a small seed ISO named seed.iso.

Why Server ISO?

Use Ubuntu Server ISO for automation.

Reasons:

  • Ubuntu Server uses Subiquity autoinstall cleanly.
  • You do not need a full desktop inside the VM if IDA/Ghidra GUI runs on Windows.
  • A lean server VM is better on weak hardware.
  • You can install a desktop later if needed.

If you want a GUI inside the VM, install it after the base VM works.

Before Use

Edit:

docs/lab-setup/vmware-ubuntu-autoinstall/user-data

Replace:

$6$REPLACE_WITH_REAL_SHA512_CRYPT_HASH

Generate a password hash on Linux/WSL:

openssl passwd -6

Paste the resulting hash into identity.password.

Optional but recommended: add your SSH public key:

ssh:
  install-server: true
  allow-pw: false
  authorized-keys:
    - ssh-ed25519 AAAA... your-key-comment

Build seed.iso

From Linux/WSL:

cd /mnt/c/ai-assisted-vulnerability-reserach/docs/lab-setup/vmware-ubuntu-autoinstall
sudo apt update
sudo apt install -y cloud-image-utils
cloud-localds seed.iso user-data meta-data

Alternative if cloud-localds is unavailable:

sudo apt install -y genisoimage
genisoimage -output seed.iso -volid cidata -joliet -rock user-data meta-data

Expected result:

docs/lab-setup/vmware-ubuntu-autoinstall/seed.iso

VMware Wizard

Create the VM manually once, but let Ubuntu install itself.

  1. File -> New Virtual Machine.
  2. Choose Custom (advanced).
  3. Hardware compatibility: newest available.
  4. Choose I will install the operating system later.
  5. Guest OS:
    • Linux
    • Ubuntu 64-bit
  6. VM name:
iot-lab-ubuntu-24.04.4
  1. Firmware:
    • UEFI
    • Secure Boot disabled
  2. CPU:
    • strong host: 8 vCPU
    • 4-logical-core host: 2 vCPU
  3. RAM:
    • strong host: 16-24 GB
    • weak host: 6-12 GB depending on host RAM
  4. Network:
  • NAT
  1. Disk:
  • 80-120 GB thin-provisioned
  • single file if stored on a local NTFS/ReFS disk
  1. Customize Hardware:
  • CD/DVD 1: attach Ubuntu Server ISO
  • CD/DVD 2: attach seed.iso
  • Shared folders: disabled
  • Printer: removed
  • Clipboard/drag-drop: disabled for unknown firmware work
  1. Finish.

If You Keep The Desktop ISO

If you only have:

ubuntu-24.04.4-desktop-amd64.iso

then skip autoinstall and do a normal manual install.

VMware wizard:

  1. File -> New Virtual Machine.
  2. Choose Custom (advanced).
  3. Choose I will install the operating system later.
  4. Guest OS:
    • Linux
    • Ubuntu 64-bit
  5. Firmware:
    • UEFI
    • Secure Boot disabled
  6. CPU/RAM:
    • weak 4-logical-core host: 2 vCPU, 6-12 GB RAM
    • stronger host: 8 vCPU, 16-24 GB RAM
  7. Disk:
    • 80-120 GB thin-provisioned
  8. Network:
    • NAT
  9. Customize Hardware:
    • attach ubuntu-24.04.4-desktop-amd64.iso
    • shared folders disabled
    • printer removed
    • clipboard/drag-drop disabled for unknown firmware work
  10. Boot and install Ubuntu normally.

After first boot:

sudo apt update
sudo apt install -y open-vm-tools open-vm-tools-desktop
sudo reboot

After reboot, install the no-EMBA manual firmware tool stack from this repository:

cd /path/to/ai-assisted-vulnerability-reserach
chmod +x scripts/bootstrap_ubuntu_iot_backup_lab.sh
./scripts/bootstrap_ubuntu_iot_backup_lab.sh

Optional for a fresh disposable VM only:

sudo apt upgrade -y
sudo reboot

This is OS hygiene, not a requirement for firmware analysis.

Snapshot:

ubuntu-24.04.4-desktop-manual-tools

This path is fine. It is just less automated than the Server NoCloud path.

Boot Command

Boot the VM from the Ubuntu Server ISO.

If the installer does not automatically detect the seed ISO, edit the GRUB boot line:

  1. At the Ubuntu boot menu, highlight Try or Install Ubuntu Server.
  2. Press e.
  3. Find the line starting with linux.
  4. Add this before the final ---:
autoinstall ds=nocloud\;s=/cdrom/
  1. Press Ctrl+x or F10 to boot.

If that does not work, the seed ISO may be mounted somewhere else. Use the HTTP seed method below.

HTTP Seed Fallback

From Linux/WSL, serve the autoinstall directory:

cd /mnt/c/ai-assisted-vulnerability-reserach/docs/lab-setup/vmware-ubuntu-autoinstall
python3 -m http.server 8000

Find your host IP reachable from the VM, then add this to the Ubuntu boot line:

autoinstall ds=nocloud-net\;s=http://HOST_IP:8000/

The URL must expose:

http://HOST_IP:8000/user-data
http://HOST_IP:8000/meta-data

After Install

Login as:

user: analyst
password: the password whose hash you generated

Check:

ip addr
ssh localhost
qemu-mipsel-static --version
ls ~/iot-fw-lab

Tool Split With Kali/EMBA

The Ubuntu autoinstall is now intentionally a manual-analysis companion VM, not a second EMBA box.

Use the split this way:

VM Main job Installed by default
Kali EMBA VM EMBA classic Docker scans, broad automated firmware triage, EMBA reports EMBA installer manages Docker/container-heavy tooling
Ubuntu lab VM manual extraction, grep, QEMU/GDB experiments, scripts, packet capture, report evidence lean CLI tools: binwalk, squashfs/cpio/xz/zstd, ripgrep, Python, qemu, gdb-multiarch, strace/ltrace, nmap, tcpdump
Windows host GUI RE when useful IDA/Ghidra/Binary Ninja if installed

This avoids installing Docker twice by default. The overlap that remains is deliberate: tools like binwalk, qemu-user-static, gdb-multiarch, strace, ripgrep, and tcpdump are useful for manual verification even if EMBA also has similar tools inside its container.

Only add Docker to Ubuntu if you decide Ubuntu will be your fallback EMBA host or you need containerized tools outside Kali:

sudo apt update
sudo apt install -y docker.io docker-compose-v2
sudo systemctl enable --now docker
sudo usermod -aG docker "$USER"
newgrp docker
docker run --rm hello-world

Take snapshot:

ubuntu-24.04.4-autoinstall-clean

Then install anything missing for the assignment.

When Not To Use Autoinstall

Use the manual installer if:

  • you are not comfortable editing boot parameters
  • you need disk encryption during install
  • VMware cannot see the seed ISO and HTTP seed is inconvenient
  • you only need to create one VM and are short on time

Autoinstall saves time after the first successful setup. The first run can take some debugging.

If Server autoinstall fails, do not spend the whole day debugging NoCloud. Install Ubuntu Server manually with the same CPU/RAM/disk/network settings, then run:

cd /path/to/ai-assisted-vulnerability-reserach
chmod +x scripts/bootstrap_ubuntu_iot_backup_lab.sh
./scripts/bootstrap_ubuntu_iot_backup_lab.sh

That gives you the same no-EMBA manual tool stack as the Desktop path.

Sources