Our Authentication & Quality Assurance Procedure For Creating Fedora Installation Media

Below is our authentication & quality assurance procedure for creating Fedora installation media:

# Download Fedora

wget https://download.fedoraproject.org/pub/fedora/linux/releases/37/Workstat...

2023-02-13 17:53:38 (14.6 MB/s) - ‘Fedora-Workstation-Live-x86_64-37-1.7.iso’ saved [2037372928/2037372928]

# First, import Fedora's GPG key(s)

curl -O https://getfedora.org/static/fedora.gpg

# Download the Fedora x86_64 (iso) CHECKSUM

wget https://getfedora.org/static/checksums/37/iso/Fedora-Workstation-37-1.7-...

# Now, verify that the CHECKSUM file is valid

gpgv --keyring ./fedora.gpg *-CHECKSUM

gpgv: Signature made Thu 10 Nov 2022 02:56:12 PM EST
gpgv: using RSA key ACB5EE4E831C74BB7C168D27F55AD3FB5323552A
gpgv: Good signature from "Fedora (37) "

Note: The important bit to look for is that it says it's got a good signature from the Fedora developers

# Lastly, check that your download's checksum matches:

sha256sum -c *-CHECKSUM

# If all went well you should get a line that says OK next to the file name of the ISO image

Fedora-Workstation-Live-x86_64-37-1.7.iso: OK

# Plug in a USB flash drive and unmount any auto-mounted partitions to ensure reliability of written image
# At a minimum make sure the size of the flash drive matches what you inserted to avoid accidentally
# overwriting important data

sudo fdisk -l

Disk /dev/sda: 59.75 GiB, 64160400896 bytes, 125313283 sectors
Disk model: Flash Drive
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x00000000

Device Boot Start End Sectors Size Id Type
/dev/sda1 128 125313250 125313123 59.8G 7 HPFS/NTFS/exFAT

# So we're going to run the follow commands as the flash drive above we are using has mounted partitions

sudo umount /dev/sda1

# Write the Fedora ISO image to disk

sudo dd if=Fedora-Workstation-Live-x86_64-37-1.7.iso of=/dev/sda bs=16M oflag=direct status=progress

# Run the sync command to flush any data to disk and make sure it's written


# Identify the size of the ISO image using the stat command

stat -c '%s' Fedora-Workstation-Live-x86_64-37-1.7.iso


# Along with the above number output use the head command to check the portion of the disk we've written
# the ISO to Prior to running this command it isn't a bad idea to unplug the USB drive and connect it again

sudo head -c 2037372928 /dev/sda | sha256sum

# Make sure the output above matches what is in the Fedora-Workstation-x-x.x-x86_64-CHECKSUM file we downloaded earlier

cat *-CHECKSUM | grep SHA256

SHA256 (Fedora-Workstation-Live-x86_64-37-1.7.iso) = 9c69005baafdba6e4ff04c1cf4779121b7fc9aacab80b4633394576da336a515

# In this case the above matches so we can conclude that the ISO image is fully and properly written to disk-