0x4248 wiki

A collection of guides and tutorials for various topics that I have written.

View the Project on GitHub 0x4248/wiki

View all pages

View homepage

Patching an ISO

In this guide I will show you how to patch an ISO file. Since ISO files are not writable, we will have to mount the ISO, modify the contents, and then create a new ISO file using the modified contents.

Prerequisites

Installing genisoimage

Debian-based systems

To install genisoimage on debian-based systems, run the following command:

sudo apt-get install genisoimage

Arch-based systems

To install genisoimage on arch-based systems, run the following command:

sudo pacman -S cdrtools

Fedora-based systems

To install genisoimage on fedora-based systems, run the following command:

sudo dnf install genisoimage

Steps

  1. Create a directory to mount the ISO file:
mkdir /mnt/iso
  1. Mount the ISO file:
sudo mount -o loop file.iso /mnt/iso
  1. Modify the contents of the mounted ISO file as needed.

  2. Create a new ISO file with the modified contents:

genisoimage -o newfile.iso -r -J /mnt/iso
  1. Unmount the ISO file:
sudo umount /mnt/iso

Now you have successfully patched an ISO file.