Free DEB test files and sample generator

Software package format for Debian, Ubuntu and derivatives. Installed via dpkg/apt.

Generate a .deb file →

What is a .deb file?

DEB: Debian Package. A .deb is a Debian or Ubuntu package: an `ar` archive holding control metadata and the payload to install. Package tooling reads the control data before unpacking anything.

Why generate a test DEB file?

How a .deb file is identified

Every .deb file begins with 21 3C 61 72 63 68 3E, "!<arch>", a Unix ar archive. That is what a validator inspecting content rather than the file name looks for.

How the size lands on the exact byte

A trailing `_padding` member absorbs the remainder. dpkg reads the members it knows and ignores the rest.

Negative testing with broken DEB files

Which failure to reach for, and what to assert for each, is covered in how to make a corrupted file for testing. For upload limits and type checks see testing file upload validation.

Sample DEB content

[Package], control + data archives, dpkg installable.

This shows the shape of the file. Your download is generated fresh at the size you choose, so the values will differ.

How to open and verify the file

Inspect with `dpkg-deb -I file.deb` (info) and `dpkg-deb -c file.deb` (contents).

Media type application/vnd.debian.binary-package · extension .deb · category Scripts & OS

Generate a .deb file → · questions about sizes, privacy or cost are answered on the site FAQ.

Frequently asked questions about DEB files

What identifies a .deb file?

A .deb file begins with the bytes 21 3C 61 72 63 68 3E, "!<arch>", a Unix ar archive. Those bytes are what a content-sniffing validator looks for, and what the Corrupted condition destroys.

How can a .deb file be an exact number of bytes?

A trailing `_padding` member absorbs the remainder. dpkg reads the members it knows and ignores the rest.

Can I download several broken DEB files at once?

Yes, select more than one File Condition and you get one ZIP containing a .deb per condition, each named after its condition.

Can the DEB file use UTF-16 or a byte-order mark?

No, and deliberately. A .deb file is a container rather than plain text, so rewriting its bytes as UTF-16 would not produce a UTF-16 document. It would produce a broken file. Use a text format such as CSV, JSON or XML for encoding tests.

How do I open or verify the DEB file?

Inspect with dpkg-deb -I file.deb (info) and dpkg-deb -c file.deb (contents).

Related Scripts & OS formats

SH · BAT · PS1 · VBS · RPM · PKG · APK · AAB

Browse all file formats →