1b6cee71dSXin LI 2b6cee71dSXin LI#------------------------------------------------------------------------------ 3*48c779cdSXin LI# $File: intel,v 1.17 2018/08/01 10:34:03 christos Exp $ 4b6cee71dSXin LI# intel: file(1) magic for x86 Unix 5b6cee71dSXin LI# 6b6cee71dSXin LI# Various flavors of x86 UNIX executable/object (other than Xenix, which 7b6cee71dSXin LI# is in "microsoft"). DOS is in "msdos"; the ambitious soul can do 8b6cee71dSXin LI# Windows as well. 9b6cee71dSXin LI# 10b6cee71dSXin LI# Windows NT belongs elsewhere, as you need x86 and MIPS and Alpha and 11b6cee71dSXin LI# whatever comes next (HP-PA Hummingbird?). OS/2 may also go elsewhere 12b6cee71dSXin LI# as well, if, as, and when IBM makes it portable. 13b6cee71dSXin LI# 14b6cee71dSXin LI# The `versions' should be un-commented if they work for you. 15b6cee71dSXin LI# (Was the problem just one of endianness?) 16b6cee71dSXin LI# 17b6cee71dSXin LI0 leshort 0502 basic-16 executable 18b6cee71dSXin LI>12 lelong >0 not stripped 19b6cee71dSXin LI#>22 leshort >0 - version %d 20b6cee71dSXin LI0 leshort 0503 basic-16 executable (TV) 21b6cee71dSXin LI>12 lelong >0 not stripped 22b6cee71dSXin LI#>22 leshort >0 - version %d 23b6cee71dSXin LI0 leshort 0510 x86 executable 24b6cee71dSXin LI>12 lelong >0 not stripped 25b6cee71dSXin LI0 leshort 0511 x86 executable (TV) 26b6cee71dSXin LI>12 lelong >0 not stripped 27b6cee71dSXin LI0 leshort =0512 iAPX 286 executable small model (COFF) 28b6cee71dSXin LI>12 lelong >0 not stripped 29b6cee71dSXin LI#>22 leshort >0 - version %d 30b6cee71dSXin LI0 leshort =0522 iAPX 286 executable large model (COFF) 31b6cee71dSXin LI>12 lelong >0 not stripped 32b6cee71dSXin LI#>22 leshort >0 - version %d 333e41d09dSXin LI# updated by Joerg Jenderek at Oct 2015 343e41d09dSXin LI# https://de.wikipedia.org/wiki/Common_Object_File_Format 353e41d09dSXin LI# http://www.delorie.com/djgpp/doc/coff/filhdr.html 363e41d09dSXin LI# ./msdos (version 5.25) labeled the next entry as "MS Windows COFF Intel 80386 object file" 373e41d09dSXin LI# ./intel (version 5.25) label labeled the next entry as "80386 COFF executable" 38b6cee71dSXin LI# SGI labeled the next entry as "iAPX 386 executable" --Dan Quinlan 393e41d09dSXin LI0 leshort =0514 403e41d09dSXin LI# use subroutine to display name+flags+variables for common object formated files 413e41d09dSXin LI>0 use display-coff 423e41d09dSXin LI#>12 lelong >0 not stripped 433e41d09dSXin LI# no hint found, that at offset 22 is version 443e41d09dSXin LI#>22 leshort >0 - version %d 45*48c779cdSXin LI0 leshort 0x0200 46*48c779cdSXin LI>0 use display-coff 47*48c779cdSXin LI0 leshort 0x8664 48*48c779cdSXin LI>0 use display-coff 49b6cee71dSXin LI 50b6cee71dSXin LI# rom: file(1) magic for BIOS ROM Extensions found in intel machines 51b6cee71dSXin LI# mapped into memory between 0xC0000 and 0xFFFFF 5258a0f0d0SEitan Adler# From: Alex Myczko <alex@aiei.ch> 533e41d09dSXin LI# updated by Joerg Jenderek 543e41d09dSXin LI# https://en.wikipedia.org/wiki/Option_ROM 55b6cee71dSXin LI0 beshort 0x55AA BIOS (ia32) ROM Ext. 563e41d09dSXin LI!:mime application/octet-stream 573e41d09dSXin LI!:ext rom/bin 58b6cee71dSXin LI>5 string USB USB 59b6cee71dSXin LI>7 string LDR UNDI image 60b6cee71dSXin LI>30 string IBM IBM comp. Video 61b6cee71dSXin LI>26 string Adaptec Adaptec 62b6cee71dSXin LI>28 string Adaptec Adaptec 63b6cee71dSXin LI>42 string PROMISE Promise 64b6cee71dSXin LI>2 byte x (%d*512) 65b6cee71dSXin LI 66b6cee71dSXin LI# Flash descriptors for Intel SPI flash roms. 67b6cee71dSXin LI# From Dr. Jesus <j@hug.gs> 68b6cee71dSXin LI0 lelong 0x0ff0a55a Intel serial flash for ICH/PCH ROM <= 5 or 3400 series A-step 69b6cee71dSXin LI16 lelong 0x0ff0a55a Intel serial flash for PCH ROM 70