{"success":true,"data":{"ext":"h","name":"H","description":"The .h header file format is a plain-text source file used in the C and C++ programming ecosystems, with conventions established by the language community and toolchain maintainers. It is used to declare functions, types, macros, and constants for inclusion in source files, supporting modular program design and reusable interfaces. Header files are generally safe, but they may contain preprocessor directives and code that affect compilation; older projects may use them as part of legacy codebases.","mime":["text/x-chdr"],"risk_level":"Safe","signatures":[{"hex":"23 69 66 6E 64 65 66 20","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"}]}],"related":["c","m"],"usage":{"python":"def is_h(file_path: str) -> bool:\n    \"\"\"Check if file is a valid H by magic bytes.\"\"\"\n    signature = bytes([0x23, 0x69, 0x66, 0x6E, 0x64, 0x65, 0x66, 0x20])\n    with open(file_path, \"rb\") as f:\n        return f.read(8) == signature","node":"function isH(buffer: Buffer): boolean {\n  const signature = Buffer.from([0x23, 0x69, 0x66, 0x6E, 0x64, 0x65, 0x66, 0x20]);\n  return buffer.subarray(0, 8).equals(signature);\n}","go":"func IsH(data []byte) bool {\n    signature := []byte{0x23, 0x69, 0x66, 0x6E, 0x64, 0x65, 0x66, 0x20}\n    if len(data) < 8 {\n        return false\n    }\n    return bytes.Equal(data[:8], signature)\n}"},"category":"Source Code"}}