XSL (.xsl)
.xsl file signature | application/xml
Magic Bytes
Offset 0
3C 3F 78 6D 6C
Sources: Apache Tika
All Known Signatures
6 signature variants are documented for .xsl files across multiple sources.
| Hex Signature | Offset | Sources |
|---|---|---|
| 3C 3F 78 6D 6C | 0 | Apache Tika |
| 3C 3F 58 4D 4C | 0 | Apache Tika |
| EF BB BF 3C 3F 78 6D 6C | 0 | Apache Tika |
| FF FE 3C 00 3F 00 78 00 6D 00 6C 00 | 0 | Apache Tika |
| FE FF 00 3C 00 3F 00 78 00 6D 00 6C | 0 | Apache Tika |
| 3C 21 2D 2D | 0 | Apache Tika |
Extension
.xsl
MIME Type
application/xml
Byte Offset
0
Risk Level
Safe
Validation Code
How to validate .xsl files in Python
def is_xsl(file_path: str) -> bool:
"""Check if file is a valid XSL by magic bytes."""
signature = bytes([0x3C, 0x3F, 0x78, 0x6D, 0x6C])
with open(file_path, "rb") as f:
return f.read(5) == signature
How to validate .xsl files in Node.js
function isXSL(buffer: Buffer): boolean {
const signature = Buffer.from([0x3C, 0x3F, 0x78, 0x6D, 0x6C]);
return buffer.subarray(0, 5).equals(signature);
}
How to validate .xsl files in Go
func IsXSL(data []byte) bool {
signature := []byte{0x3C, 0x3F, 0x78, 0x6D, 0x6C}
if len(data) < 5 {
return false
}
return bytes.Equal(data[:5], signature)
}
API Endpoint
/api/v1/xsl
curl https://filesignature.org/api/v1/xsl
See the full API documentation for all endpoints and parameters.
Frequently Asked Questions
What is a .xsl file?
A .xsl file is a XSL file.
What are the magic bytes for .xsl files?
The magic bytes for XSL files are 3C 3F 78 6D 6C at byte offset 0. These bytes uniquely identify the file format regardless of the file extension.
How do I validate a .xsl file?
To validate a .xsl file, read the first bytes of the file and compare them against the known magic bytes (3C 3F 78 6D 6C) at offset 0. This is more reliable than checking the file extension alone, as extensions can be renamed.
What is the MIME type for .xsl files?
The primary MIME type for .xsl files is application/xml.
Is it safe to open .xsl files?
XSL (.xsl) files are generally safe to open. They are classified as low risk because they primarily contain data rather than executable code. However, always ensure files come from a trusted source.