{"success":true,"data":{"ext":"fits","name":"Flexible Image Transport System","description":"Flexible Image Transport System (FITS) is a scientific file format developed by the International Astronomical Union and maintained through community standards for storing astronomy data. It is used for images, spectra, and other observational data in telescopes, research archives, and analysis software. FITS is a long-standing standard rather than a legacy format, and it is generally safe, though malformed files can still trigger parser issues in older tools.","mime":["application/fits"],"risk_level":"Safe","signatures":[{"hex":"53 49 4D 50 4C 45 20 20 3D 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 54","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"},{"name":"Gary Kessler","url":"https://www.garykessler.net/library/file_sigs_GCK_latest.html"}]},{"hex":"53 49 4D 50 4C 45 20 20 3D 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 54","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":"53 49 4D 50 4C 45 20 20","offset":0,"sources":[{"name":"Wikipedia","url":"https://en.wikipedia.org/wiki/List_of_file_signatures"}]},{"hex":"3D 20 20 20 20 20 20 20","offset":0,"sources":[{"name":"Wikipedia","url":"https://en.wikipedia.org/wiki/List_of_file_signatures"}]},{"hex":"20 20 20 20 20 20 20 20","offset":0,"sources":[{"name":"Wikipedia","url":"https://en.wikipedia.org/wiki/List_of_file_signatures"}]},{"hex":"20 20 20 20 20 54","offset":0,"sources":[{"name":"Wikipedia","url":"https://en.wikipedia.org/wiki/List_of_file_signatures"}]}],"related":["fit","fts"],"usage":{"python":"def is_fits(file_path: str) -> bool:\n    \"\"\"Check if file is a valid FITS by magic bytes.\"\"\"\n    signature = bytes([0x53, 0x49, 0x4D, 0x50, 0x4C, 0x45, 0x20, 0x20, 0x3D, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x54])\n    with open(file_path, \"rb\") as f:\n        return f.read(30) == signature","node":"function isFITS(buffer: Buffer): boolean {\n  const signature = Buffer.from([0x53, 0x49, 0x4D, 0x50, 0x4C, 0x45, 0x20, 0x20, 0x3D, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x54]);\n  return buffer.subarray(0, 30).equals(signature);\n}","go":"func IsFITS(data []byte) bool {\n    signature := []byte{0x53, 0x49, 0x4D, 0x50, 0x4C, 0x45, 0x20, 0x20, 0x3D, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x54}\n    if len(data) < 30 {\n        return false\n    }\n    return bytes.Equal(data[:30], signature)\n}"}}}