Small GZIP
Small GZIP is a GZIP Compressed Data sample generated for file format testing. It can be used to test downloads, parsers, previews, and file type detection.
small.txt.gzArchive
GZIP Compressed Data is a archive format commonly identified by .gz, .gzip. Use the listed signatures, MIME types, and structure notes to validate files beyond the extension.
1F 8B 08 ...SIGNATURE = bytes.fromhex("1f8b08")
OFFSET = 0
def is_gz(path: str) -> bool:
with open(path, "rb") as f:
f.seek(OFFSET)
head = f.read(len(SIGNATURE))
return head == SIGNATUREconst SIGNATURE = [0x1f, 0x8b, 0x08];
const OFFSET = 0;
// bytes: a Uint8Array / Buffer holding the start of the file
export function isGz(bytes) {
return SIGNATURE.every((byte, i) => bytes[OFFSET + i] === byte);
}package fileid
import "bytes"
var isgzSignature = []byte{0x1f, 0x8b, 0x08}
const isgzOffset = 0
func IsGz(b []byte) bool {
end := isgzOffset + len(isgzSignature)
if len(b) < end {
return false
}
return bytes.Equal(b[isgzOffset:end], isgzSignature)
}const SIGNATURE: &[u8] = &[0x1f, 0x8b, 0x08];
const OFFSET: usize = 0;
fn is_gz(bytes: &[u8]) -> bool {
bytes.get(OFFSET..OFFSET + SIGNATURE.len()) == Some(SIGNATURE)
}<?php
$signature = "\x1f\x8b\x08";
$offset = 0;
function is_gz(string $bytes): bool {
global $signature, $offset;
return substr($bytes, $offset, strlen($signature)) === $signature;
}GZIP Compressed Data is used for compression, extraction, backups, attachments, and multi-file inspection. Validate paths, file counts, compressed size, and extracted size before unpacking.
Archives can contain zip-slip paths, excessive expansion, hidden files, and double extensions. Normalize extraction paths and enforce file count and size limits.
11 samples help test leading-byte detection, parser errors, upload limits, and download behavior.
Small GZIP is a GZIP Compressed Data sample generated for file format testing. It can be used to test downloads, parsers, previews, and file type detection.
small.txt.gzEmpty GZIP is a GZIP Compressed Data sample generated for file format testing. It can be used to test downloads, parsers, previews, and file type detection.
empty.gzBlue Sky TXT.GZ is a GZIP Compressed Data sample based on Wikimedia Commons. It can be used to test downloads, parsers, previews, and file type detection.
01-blue-sky.txt.gzbd339e2f6ecde312ad681f2dbadacb5fa40f1272a989a46e48b6ae5412d3a86bFlower Garden TXT.GZ is a GZIP Compressed Data sample based on Wikimedia Commons. It can be used to test downloads, parsers, previews, and file type detection.
02-flower-garden.txt.gze347f058c65e3a70b8ebd7eec0df68eb345f88f13d96ff61c5ad4a6a0d3e3c14Navy Blue Sky TXT.GZ is a GZIP Compressed Data sample based on Wikimedia Commons. It can be used to test downloads, parsers, previews, and file type detection.
03-navy-blue-sky.txt.gzf0ffbb194ac00c32c155e2ae64f5b11125fd4ade8bf8405f9cc2df876936eb66Nature of the Sky TXT.GZ is a GZIP Compressed Data sample based on Wikimedia Commons. It can be used to test downloads, parsers, previews, and file type detection.
04-nature-sky.txt.gz26c4f012b0eb40487581dbbf95c2c6629a32b6a21aa83d47f2124794a548beb2Sky Landscape TXT.GZ is a GZIP Compressed Data sample based on Wikimedia Commons. It can be used to test downloads, parsers, previews, and file type detection.
05-sky-landscape.txt.gz6e7bb216870b8130a07481215de2dc4f3e442b2a1bc94254e3acfbbf86fef4baStarry Sky TXT.GZ is a GZIP Compressed Data sample based on Wikimedia Commons. It can be used to test downloads, parsers, previews, and file type detection.
06-starry-sky.txt.gz5def2c45c82871e416c64efa4e58e1367bb3b22fac3f882b0cad04eb5c83fce6Blue Night Sky TXT.GZ is a GZIP Compressed Data sample based on Wikimedia Commons. It can be used to test downloads, parsers, previews, and file type detection.
07-blue-night-sky.txt.gze944abd9432452504192795441c70d4d411d2fb2d157704957a6e435e9f4d6d0Hibiscus Flower TXT.GZ is a GZIP Compressed Data sample based on Wikimedia Commons. It can be used to test downloads, parsers, previews, and file type detection.
08-hibiscus-flower.txt.gze8d823308dd8f6c889030ff57aa5990f981864988e88b76436b08dc084bec84dNASA Blue Marble TXT.GZ is a GZIP Compressed Data sample based on NASA Image and Video Library. It can be used to test downloads, parsers, previews, and file type detection.
nasa-blue-marble-2012-east.txt.gz4a3d9989895a7d7cfb77d26c5369c6d539ad763fa942f4f3c16ee79910dfe7d1GZIP Compressed Data files begin with the byte signature 1F 8B 08 ("..."). Detect the format by reading these leading bytes rather than trusting the file extension alone.
The MIME type for GZIP Compressed Data is application/gzip.
GZIP Compressed Data files use the .gz, .gzip extension. The extension is a convention only and does not guarantee the file contents, so combine it with signature and structure checks.