OLE

application/octet-stream

Safe

Magic Bytes

Offset: 0
4D 53 48 7C 5E 7E 5C 26 7C

The OLE Type Library (TLB) is a binary file format developed by Microsoft to provide machine-readable descriptions of Component Object Model (COM) interfaces. Development environments utilize these libraries to enable cross-language interoperability and automated interaction between disparate software components. Although considered a legacy technology in modern development, type libraries remain critical for backward compatibility within Windows, though they can be leveraged by malicious actors to exploit vulnerabilities in COM-aware applications.

Extension

.tlb

MIME Type

application/octet-stream

Byte Offset

0

Risk Level

Safe

Validation Code

How to validate .tlb files in Python

Python
def is_tlb(file_path: str) -> bool:
    """Check if file is a valid TLB by magic bytes."""
    signature = bytes([0x4D, 0x53, 0x48, 0x7C, 0x5E, 0x7E, 0x5C, 0x26, 0x7C])
    with open(file_path, "rb") as f:
        return f.read(9) == signature

How to validate .tlb files in Node.js

Node.js
function isTLB(buffer: Buffer): boolean {
  const signature = Buffer.from([0x4D, 0x53, 0x48, 0x7C, 0x5E, 0x7E, 0x5C, 0x26, 0x7C]);
  return buffer.subarray(0, 9).equals(signature);
}
Go
func IsTLB(data []byte) bool {
    signature := []byte{0x4D, 0x53, 0x48, 0x7C, 0x5E, 0x7E, 0x5C, 0x26, 0x7C}
    if len(data) < 9 {
        return false
    }
    return bytes.Equal(data[:9], signature)
}

API Endpoint

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

Related Formats