📦 Package Pool
Contains the actual .deb
package files organized by package name
Ever wondered how APT repositories actually work under the hood? This page explains the technical details behind package management and how this repository is structured.
An APT repository (Advanced Package Tool) is a collection of software packages stored in a specific directory structure that Debian-based systems can understand and access. It’s essentially a organized warehouse of software that your system can automatically download and install.
📦 Package Pool
Contains the actual .deb
package files organized by package name
📋 Package Lists
Metadata files describing what packages are available
🔐 GPG Signatures
Cryptographic signatures ensuring package authenticity
🏗️ Repository Structure
Standardized directory layout that APT can navigate
Here’s how this repository is organized:
apt.fuabioo.com/├── dists/ # Distribution metadata│ └── stable/ # Release codename│ ├── InRelease # Signed release file│ ├── Release # Release information│ ├── Release.gpg # GPG signature│ └── main/ # Component (main, contrib, non-free)│ ├── binary-amd64/ # x86_64 packages│ ├── binary-arm64/ # ARM64 packages│ ├── binary-armhf/ # ARM hard-float packages│ ├── binary-armv6/ # ARMv6 packages│ ├── binary-armv7/ # ARMv7 packages│ │ ├── Packages # Package metadata│ │ └── Packages.gz # Compressed metadata│ └── [other architectures...]├── pool/ # Actual package files│ ├── buf-fmt-stdin/ # Package directory│ │ └── buf-fmt-stdin_0.0.0_amd64.deb│ ├── dontrm/│ │ └── dontrm_0.0.0_amd64.deb│ └── [other packages...]└── public.gpg # Public GPG key
When you add a repository to your system:
echo 'deb [arch=amd64 signed-by=/usr/share/keyrings/apt.fuabioo.gpg] https://apt.fuabioo.com stable main' | sudo tee /etc/apt/sources.list.d/apt.fuabioo.list
APT learns about:
https://apt.fuabioo.com
stable
main
amd64
(automatically detected)/usr/share/keyrings/apt.fuabioo.gpg
When you run sudo apt update
:
/dists/stable/InRelease
/dists/stable/main/binary-amd64/Packages
When you run sudo apt install dontrm
:
/pool/dontrm/dontrm_0.0.0_amd64.deb
Each package in the repository has detailed metadata. Here’s what’s stored:
Package: dontrmVersion: 0.0.0Architecture: amd64Maintainer: Fabio Mora <code@fabiomora.dev>Filename: pool/dontrm/dontrm_0.0.0_amd64.debSize: 964584MD5sum: 9a9199b5869c685b573702b2f8f1e950SHA1: 6a0a74efde8dc70fa5e477cb3e079608825f8c06SHA256: 7e9f4265f2023c1560a6ec2bc8202657154e84c6d2cb128ed4b7f06ca615fdbeSection: utilsPriority: optionalDescription: Subjective safe wheels for rm. Avoid messing up your system like a clown 🤡
This repository is built using standard Debian packaging tools:
Each software is packaged into .deb
format containing:
Tools like dpkg-scanpackages
and apt-ftparchive
generate:
The repository is served via HTTPS, allowing APT to:
.deb
files as needed/var/lib/apt/lists/
)apt-cache policy
Shows which repositories APT knows about
apt-cache show package-name
Displays detailed package information
apt list --upgradable
Shows available package updates
/var/log/apt/
/var/log/dpkg.log
/var/log/syslog
The verification process includes multiple layers of security and integrity checks:
1. Repository Metadata Signing
# Sign the Release file with repository GPG keygpg --default-key "$GPG_KEY_ID" --digest-algo SHA256 -abs -o dists/stable/Release.gpg dists/stable/Releasegpg --default-key "$GPG_KEY_ID" --digest-algo SHA256 --clearsign -o dists/stable/InRelease dists/stable/Release
2. APT’s Trust Verification Process
When APT runs apt update
, it performs these verification steps:
a) Fetch InRelease file from https://apt.fuabioo.com/dists/stable/InRelease
b) Verify GPG signature against trusted keyring /usr/share/keyrings/apt.fuabioo.gpg
c) Extract signed content - the Release file contents
d) Parse checksums for all Packages files listed in Release
3. Package List Integrity Verification The Release file contains SHA256 checksums for every Packages file:
SHA256: a1b2c3d4e5f6... 12345 main/binary-amd64/Packages f6e5d4c3b2a1... 6789 main/binary-amd64/Packages.gz
APT verifies:
4. Individual Package Verification Each package entry in the Packages file includes multiple checksums:
Package: dontrmMD5sum: 9a9199b5869c685b573702b2f8f1e950SHA1: 6a0a74efde8dc70fa5e477cb3e079608825f8c06SHA256: 7e9f4265f2023c1560a6ec2bc8202657154e84c6d2cb128ed4b7f06ca615fdbe
Before installation, APT:
The complete trust chain works as follows:
User Action: curl -fsSL https://apt.fuabioo.com/public.gpg | sudo tee /usr/share/keyrings/apt.fuabioo.gpg
Repository Trust: APT configuration references the trusted key
deb [signed-by=/usr/share/keyrings/apt.fuabioo.gpg] https://apt.fuabioo.com stable main
signed-by=
parameter tells APT which key to use for verificationMetadata Verification: On apt update
Package Verification: On apt install
This verification system protects against several attack vectors:
Man-in-the-Middle (MITM) Attacks:
Repository Compromise:
Package Tampering:
Replay Attacks:
This repository uses an innovative ephemeral Docker container approach for comprehensive testing. Every package is tested in a clean, isolated environment that mirrors production conditions.
For detailed information about the testing methodology, Docker container setup, and development workflow, see the Testing & Development page.
Understanding how APT repositories work helps you:
The beauty of APT is that it handles all this complexity automatically, but knowing what’s happening under the hood makes you a more effective system administrator!
Curious about the specific tools used to build this repository? Check out the repository source code for implementation details.