IEC

application/octet-stream

Safe

Magic Bytes

Offset: 0
4D 5A

The IEC file format is a legacy binary structure, essentially a renamed Windows Dynamic Link Library (DLL), historically utilized by Microsoft Office and specific Intel software tools. These files function as internal converter modules or plugins, enabling applications to import data from external sources or interpret specialized text encodings seamlessly. Although generally considered safe and obsolete in modern computing, the underlying executable architecture technically contains program code rather than passive data.

Extension

.iec

MIME Type

application/octet-stream

Byte Offset

0

Risk Level

Safe

Validation Code

How to validate .iec files in Python

Python
def is_iec(file_path: str) -> bool:
    """Check if file is a valid IEC by magic bytes."""
    signature = bytes([0x4D, 0x5A])
    with open(file_path, "rb") as f:
        return f.read(2) == signature

How to validate .iec files in Node.js

Node.js
function isIEC(buffer: Buffer): boolean {
  const signature = Buffer.from([0x4D, 0x5A]);
  return buffer.subarray(0, 2).equals(signature);
}
Go
func IsIEC(data []byte) bool {
    signature := []byte{0x4D, 0x5A}
    if len(data) < 2 {
        return false
    }
    return bytes.Equal(data[:2], signature)
}

API Endpoint

GET /api/v1/iec
curl https://filesignature.org/api/v1/iec

Related Formats