{"success":true,"data":{"ext":"cpx","name":"Microsoft Code Page Translation file","description":"A CPX file is a Microsoft Code Page Translation file used by Windows to define character set mappings for localized text handling and legacy applications. It is primarily used by the operating system and related tools to support code page conversion, font rendering, and multilingual compatibility. The format is a legacy Windows component and is generally considered safe, although its practical use has declined with modern Unicode-based systems.","mime":[],"risk_level":"Safe","signatures":[{"hex":"5B 57 69 6E 64 6F 77 73 20 4C 61 74 69 6E 20","offset":0,"sources":[{"name":"Gary Kessler","url":"https://www.garykessler.net/library/file_sigs_GCK_latest.html"}]}],"related":[],"usage":{"python":"def is_cpx(file_path: str) -> bool:\n    \"\"\"Check if file is a valid CPX by magic bytes.\"\"\"\n    signature = bytes([0x5B, 0x57, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x73, 0x20, 0x4C, 0x61, 0x74, 0x69, 0x6E, 0x20])\n    with open(file_path, \"rb\") as f:\n        return f.read(15) == signature","node":"function isCPX(buffer: Buffer): boolean {\n  const signature = Buffer.from([0x5B, 0x57, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x73, 0x20, 0x4C, 0x61, 0x74, 0x69, 0x6E, 0x20]);\n  return buffer.subarray(0, 15).equals(signature);\n}","go":"func IsCPX(data []byte) bool {\n    signature := []byte{0x5B, 0x57, 0x69, 0x6E, 0x64, 0x6F, 0x77, 0x73, 0x20, 0x4C, 0x61, 0x74, 0x69, 0x6E, 0x20}\n    if len(data) < 15 {\n        return false\n    }\n    return bytes.Equal(data[:15], signature)\n}"}}}