WK2
application/vnd.lotus-1-2-3;version=2
Magic Bytes
Offset: 0
00 00 02 00 06 04 06 00 08 00
The WK2 file format is a legacy spreadsheet document associated with Release 2 of the Lotus 1-2-3 software suite, originally developed by Lotus Development Corporation. These files were primarily used for financial modeling, data tabulation, and business calculations on DOS-based systems during the late 1980s. As a strictly binary format for numerical data storage, it is considered safe by modern standards, though modern spreadsheet software may require specific legacy import filters to access the archived data.
Validation Code
How to validate .wk2 files in Python
Python
def is_wk2(file_path: str) -> bool:
"""Check if file is a valid WK2 by magic bytes."""
signature = bytes([0x00, 0x00, 0x02, 0x00, 0x06, 0x04, 0x06, 0x00, 0x08, 0x00])
with open(file_path, "rb") as f:
return f.read(10) == signature
How to validate .wk2 files in Node.js
Node.js
function isWK2(buffer: Buffer): boolean {
const signature = Buffer.from([0x00, 0x00, 0x02, 0x00, 0x06, 0x04, 0x06, 0x00, 0x08, 0x00]);
return buffer.subarray(0, 10).equals(signature);
}
Go
func IsWK2(data []byte) bool {
signature := []byte{0x00, 0x00, 0x02, 0x00, 0x06, 0x04, 0x06, 0x00, 0x08, 0x00}
if len(data) < 10 {
return false
}
return bytes.Equal(data[:10], signature)
}
API Endpoint
GET
/api/v1/wk2
curl https://filesignature.org/api/v1/wk2