{"success":true,"data":{"ext":"ogg","name":"Ogg Vorbis Codec compressed Multimedia file","description":"Ogg is a free, open multimedia container format developed and maintained by the Xiph.Org Foundation. It is commonly used to store compressed audio, especially Vorbis and Opus streams, and is supported by many media players, web browsers, and streaming applications. The format is generally considered safe to open, though—as with any media file—malformed or corrupted files can occasionally trigger parsing issues in vulnerable software.","mime":["audio/ogg","audio/vorbis"],"risk_level":"Safe","signatures":[{"hex":"4F 67 67 53 00 02 00 00 00 00 00 00 00 00","offset":0,"sources":[{"name":"Gary Kessler","url":"https://www.garykessler.net/library/file_sigs_GCK_latest.html"},{"name":"Neil Harvey FileSignatures","url":"https://raw.githubusercontent.com/neilharvey/FileSignatures/master/src/FileSignatures/Formats/Ogg.cs"}]},{"hex":"4F 67 67 53 00 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 01 76 6F 72 62 69 73","offset":0,"sources":[{"name":"Apache Tika","url":"https://raw.githubusercontent.com/apache/tika/main/tika-core/src/main/resources/org/apache/tika/mime/tika-mimetypes.xml"}]},{"hex":"4F 67 67 53","offset":0,"sources":[{"name":"Wikipedia","url":"https://en.wikipedia.org/wiki/List_of_file_signatures"}]}],"related":["oga","opus","spx","flac","m4a","aac"],"usage":{"python":"def is_ogg(file_path: str) -> bool:\n    \"\"\"Check if file is a valid OGG by magic bytes.\"\"\"\n    signature = bytes([0x4F, 0x67, 0x67, 0x53, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00])\n    with open(file_path, \"rb\") as f:\n        return f.read(14) == signature","node":"function isOGG(buffer: Buffer): boolean {\n  const signature = Buffer.from([0x4F, 0x67, 0x67, 0x53, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]);\n  return buffer.subarray(0, 14).equals(signature);\n}","go":"func IsOGG(data []byte) bool {\n    signature := []byte{0x4F, 0x67, 0x67, 0x53, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}\n    if len(data) < 14 {\n        return false\n    }\n    return bytes.Equal(data[:14], signature)\n}"},"category":"Audio"}}