apple 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524
  1. #------------------------------------------------------------------------------
  2. # $File: apple,v 1.43 2019/04/19 00:42:27 christos Exp $
  3. # apple: file(1) magic for Apple file formats
  4. #
  5. 0 search/1/t FiLeStArTfIlEsTaRt binscii (apple ][) text
  6. 0 string \x0aGL Binary II (apple ][) data
  7. 0 string \x76\xff Squeezed (apple ][) data
  8. 0 string NuFile NuFile archive (apple ][) data
  9. 0 string N\xf5F\xe9l\xe5 NuFile archive (apple ][) data
  10. 0 belong 0x00051600 AppleSingle encoded Macintosh file
  11. 0 belong 0x00051607 AppleDouble encoded Macintosh file
  12. # Type: Apple Emulator WOZ format
  13. # From: Greg Wildman <greg@apple2.org.za>
  14. # Ref: https://applesaucefdc.com/woz/reference/
  15. # Ref: https://applesaucefdc.com/woz/reference2/
  16. #
  17. # Note: The following test are mostly identical. I would rather not
  18. # use a regex to identify the WOZ format number.
  19. 0 string WOZ1
  20. >4 string \xFF\x0A\x0D\x0A Apple ][ WOZ 1.0 Disk Image
  21. >12 string INFO
  22. >>21 byte 01 \b, 5.25 inch
  23. >>21 byte 02 \b, 3.5 inch
  24. >>22 byte 01 \b, write protected
  25. >>23 byte 01 \b, cross track synchronized
  26. >>25 string/T x \b, %.32s
  27. 0 string WOZ2
  28. >4 string \xFF\x0A\x0D\x0A Apple ][ WOZ 2.0 Disk Image
  29. >12 string INFO
  30. >>21 byte 01 \b, 5.25 inch
  31. >>21 byte 02 \b, 3.5 inch
  32. >>22 byte 01 \b, write protected
  33. >>23 byte 01 \b, cross track synchronized
  34. >>25 string/T x \b, %.32s
  35. # Type: Apple Emulator disk images
  36. # From: Greg Wildman <greg@apple2.org.za>
  37. # ProDOS boot loader?
  38. 0 string \x01\x38\xB0\x03\x4C Apple ProDOS Image
  39. # Detect Volume Directory block ($02)
  40. >0x400 string \x00\x00\x03\x00
  41. >>0x404 byte &0xF0
  42. >>>0x405 string x \b, Volume /%s
  43. >>>0x429 leshort x \b, %u Blocks
  44. # ProDOS ordered ?
  45. >0xb00 string \x00\x00\x03\x00
  46. >>0xb04 byte &0xF0
  47. >>>0xb05 string x \b, Volume /%s
  48. >>>0xb29 leshort x \b, %u Blocks
  49. #
  50. # DOS3.3 boot loader?
  51. 0 string \x01\xA5\x27\xC9\x09\xD0\x18\xA5\x2B
  52. >0x11001 string \x11\x0F\x03 Apple DOS 3.3 Image
  53. >>0x11006 byte x \b, Volume %u
  54. >>0x11034 byte x \b, %u Tracks
  55. >>0x11035 byte x \b, %u Sectors
  56. >>0x11036 leshort x \b, %u bytes per sector
  57. # DOS3.2 ?
  58. >0x11001 string \x11\x0C\x02 Apple DOS 3.2 Image
  59. >>0x11006 byte x \b, Volume %u
  60. >>0x11034 byte x \b, %u Tracks
  61. >>0x11035 byte x \b, %u Sectors
  62. >>0x11036 leshort x \b, %u bytes per sector
  63. # DOS3.1 ?
  64. >0x11001 string \x11\x0C\x01
  65. >>0x11c00 string \x00\x11\x0B Apple DOS 3.1 Image
  66. #
  67. # Pascal boot loader?
  68. 0 string \x01\xE0\x60\xF0\x03\x4C\xE3\x08\xAD
  69. >0xd6 pstring SYSTEM.APPLE
  70. >>0xb00 leshort 0x0000
  71. >>>0xb04 leshort 0x0000 Apple Pascal Image
  72. >>>>0xb06 pstring x \b, Volume %s:
  73. >>>>0xb0e leshort x \b, %u Blocks
  74. >>>>0xb10 leshort x \b, %u Files
  75. # Type: Apple Emulator 2IMG format
  76. # From: Radek Vokal <rvokal@redhat.com>
  77. # Update: Greg Wildman <greg@apple2.org.za>
  78. 0 string 2IMG Apple ][ 2IMG Disk Image
  79. >4 clear x
  80. >4 string XGS! \b, XGS
  81. >4 string CTKG \b, Catakig
  82. >4 string ShIm \b, Sheppy's ImageMaker
  83. >4 string SHEP \b, Sheppy's ImageMaker
  84. >4 string WOOF \b, Sweet 16
  85. >4 string B2TR \b, Bernie ][ the Rescue
  86. >4 string \!nfc \b, ASIMOV2
  87. >4 string \>BD\< \b, Brutal Deluxe's Cadius
  88. >4 string CdrP \b, CiderPress
  89. >4 string Vi][ \b, Virtual ][
  90. >4 string PRFS \b, ProFUSE
  91. >4 string FISH \b, FishWings
  92. >4 string RVLW \b, Revival for Windows
  93. >4 default x
  94. >>4 string x \b, Creator tag "%-4.4s"
  95. >0xc byte 00 \b, DOS 3.3 sector order
  96. >>0x10 byte 00 \b, Volume 254
  97. >>0x10 byte&0x7f x \b, Volume %u
  98. >0xc byte 01 \b, ProDOS sector order
  99. >>0x14 short x \b, %u Blocks
  100. >0xc byte 02 \b, NIB data
  101. # magic for Newton PDA package formats
  102. # from Ruda Moura <ruda@helllabs.org>
  103. 0 string package0 Newton package, NOS 1.x,
  104. >12 belong &0x80000000 AutoRemove,
  105. >12 belong &0x40000000 CopyProtect,
  106. >12 belong &0x10000000 NoCompression,
  107. >12 belong &0x04000000 Relocation,
  108. >12 belong &0x02000000 UseFasterCompression,
  109. >16 belong x version %d
  110. 0 string package1 Newton package, NOS 2.x,
  111. >12 belong &0x80000000 AutoRemove,
  112. >12 belong &0x40000000 CopyProtect,
  113. >12 belong &0x10000000 NoCompression,
  114. >12 belong &0x04000000 Relocation,
  115. >12 belong &0x02000000 UseFasterCompression,
  116. >16 belong x version %d
  117. 0 string package4 Newton package,
  118. >8 byte 8 NOS 1.x,
  119. >8 byte 9 NOS 2.x,
  120. >12 belong &0x80000000 AutoRemove,
  121. >12 belong &0x40000000 CopyProtect,
  122. >12 belong &0x10000000 NoCompression,
  123. # The following entries for the Apple II are for files that have
  124. # been transferred as raw binary data from an Apple, without having
  125. # been encapsulated by any of the above archivers.
  126. #
  127. # In general, Apple II formats are hard to identify because Apple DOS
  128. # and especially Apple ProDOS have strong typing in the file system and
  129. # therefore programmers never felt much need to include type information
  130. # in the files themselves.
  131. #
  132. # Eric Fischer <enf@pobox.com>
  133. # AppleWorks word processor:
  134. # URL: https://en.wikipedia.org/wiki/AppleWorks
  135. # Reference: http://www.gno.org/pub/apple2/doc/apple/filetypes/ftn.1a.xxxx
  136. # Update: Joerg Jenderek
  137. # NOTE:
  138. # The "O" is really the magic number, but that's so common that it's
  139. # necessary to check the tab stops that follow it to avoid false positives.
  140. # and/or look for unused bits of booleans bytes like zoom, paginated, mail merge
  141. # the newer AppleWorks is from claris with extension CWK
  142. 4 string O
  143. # test for unused bits of zoom- , paginated-boolean bytes
  144. >84 ubequad ^0x00Fe00000000Fe00
  145. # look for tabstop definitions "=" no tab, "|" no tab
  146. # "<" left tab,"^" center tab,">" right tab, "." decimal tab,
  147. # unofficial "!" other , "\x8a" other
  148. # official only if SFMinVers is nonzero
  149. >>5 regex/s [=.<>|!^\x8a]{79} AppleWorks Word Processor
  150. # AppleWorks Word Processor File (Apple II)
  151. # ./apple (version 5.25) labeled the entry as "AppleWorks word processor data"
  152. # application/x-appleworks is mime type for claris version with cwk extension
  153. !:mime application/x-appleworks3
  154. # http://home.earthlink.net/~hughhood/appleiiworksenvoy/
  155. # ('p' + 1-byte ProDOS File Type + 2-byte ProDOS Aux Type')
  156. # $70 $1A $F8 $FF is this the apple type ?
  157. #:apple pdosp^Z\xf8\xff
  158. !:ext awp
  159. # minimum version needed to read this files. SFMinVers (0 , 30~3.0 )
  160. >>>183 ubyte 30 3.0
  161. >>>183 ubyte !30
  162. >>>>183 ubyte !0 0x%x
  163. # usual tabstop start sequence "=====<"
  164. >>>5 string x \b, tabstop ruler "%6.6s"
  165. # tabstop ruler
  166. #>>>5 string >\0 \b, tabstops "%-79s"
  167. # zoom switch
  168. >>>85 byte&0x01 >0 \b, zoomed
  169. # whether paginated
  170. >>>90 byte&0x01 >0 \b, paginated
  171. # contains any mail-merge commands
  172. >>>92 byte&0x01 >0 \b, with mail merge
  173. # left margin in 1/10 inches ( normally 0 or 10 )
  174. >>>91 ubyte >0
  175. >>>>91 ubyte x \b, %d/10 inch left margin
  176. # AppleWorks database:
  177. #
  178. # This isn't really a magic number, but it's the closest thing to one
  179. # that I could find. The 1 and 2 really mean "order in which you defined
  180. # categories" and "left to right, top to bottom," respectively; the D and R
  181. # mean that the cursor should move either down or right when you press Return.
  182. #30 string \x01D AppleWorks database data
  183. #30 string \x02D AppleWorks database data
  184. #30 string \x01R AppleWorks database data
  185. #30 string \x02R AppleWorks database data
  186. # AppleWorks spreadsheet:
  187. #
  188. # Likewise, this isn't really meant as a magic number. The R or C means
  189. # row- or column-order recalculation; the A or M means automatic or manual
  190. # recalculation.
  191. #131 string RA AppleWorks spreadsheet data
  192. #131 string RM AppleWorks spreadsheet data
  193. #131 string CA AppleWorks spreadsheet data
  194. #131 string CM AppleWorks spreadsheet data
  195. # Applesoft BASIC:
  196. #
  197. # This is incredibly sloppy, but will be true if the program was
  198. # written at its usual memory location of 2048 and its first line
  199. # number is less than 256. Yuck.
  200. # update by Joerg Jenderek at Feb 2013
  201. # GRR: this test is still too general as it catches also Gujin BOOT144.SYS (0xfa080000)
  202. #0 belong&0xff00ff 0x80000 Applesoft BASIC program data
  203. 0 belong&0x00ff00ff 0x00080000
  204. # assuming that line number must be positive
  205. >2 leshort >0 Applesoft BASIC program data, first line number %d
  206. #>2 leshort x \b, first line number %d
  207. # ORCA/EZ assembler:
  208. #
  209. # This will not identify ORCA/M source files, since those have
  210. # some sort of date code instead of the two zero bytes at 6 and 7
  211. # XXX Conflicts with ELF
  212. #4 belong&0xff00ffff 0x01000000 ORCA/EZ assembler source data
  213. #>5 byte x \b, build number %d
  214. # Broderbund Fantavision
  215. #
  216. # I don't know what these values really mean, but they seem to recur.
  217. # Will they cause too many conflicts?
  218. # Probably :-)
  219. #2 belong&0xFF00FF 0x040008 Fantavision movie data
  220. # Some attempts at images.
  221. #
  222. # These are actually just bit-for-bit dumps of the frame buffer, so
  223. # there's really no reasonably way to distinguish them except for their
  224. # address (if preserved) -- 8192 or 16384 -- and their length -- 8192
  225. # or, occasionally, 8184.
  226. #
  227. # Nevertheless this will manage to catch a lot of images that happen
  228. # to have a solid-colored line at the bottom of the screen.
  229. # GRR: Magic too weak
  230. #8144 string \x7F\x7F\x7F\x7F\x7F\x7F\x7F\x7F Apple II image with white background
  231. #8144 string \x55\x2A\x55\x2A\x55\x2A\x55\x2A Apple II image with purple background
  232. #8144 string \x2A\x55\x2A\x55\x2A\x55\x2A\x55 Apple II image with green background
  233. #8144 string \xD5\xAA\xD5\xAA\xD5\xAA\xD5\xAA Apple II image with blue background
  234. #8144 string \xAA\xD5\xAA\xD5\xAA\xD5\xAA\xD5 Apple II image with orange background
  235. # Beagle Bros. Apple Mechanic fonts
  236. 0 belong&0xFF00FFFF 0x6400D000 Apple Mechanic font
  237. # Apple Universal Disk Image Format (UDIF) - dmg files.
  238. # From Johan Gade.
  239. # These entries are disabled for now until we fix the following issues.
  240. #
  241. # Note there might be some problems with the "VAX COFF executable"
  242. # entry. Note this entry should be placed before the mac filesystem section,
  243. # particularly the "Apple Partition data" entry.
  244. #
  245. # The intended meaning of these tests is, that the file is only of the
  246. # specified type if both of the lines are correct - i.e. if the first
  247. # line matches and the second doesn't then it is not of that type.
  248. #
  249. #0 long 0x7801730d
  250. #>4 long 0x62626060 UDIF read-only zlib-compressed image (UDZO)
  251. #
  252. # Note that this entry is recognized correctly by the "Apple Partition
  253. # data" entry - however since this entry is more specific - this
  254. # information seems to be more useful.
  255. #0 long 0x45520200
  256. #>0x410 string disk\ image UDIF read/write image (UDRW)
  257. # From: Toby Peterson <toby@apple.com>
  258. 0 string bplist00 Apple binary property list
  259. # Apple binary property list (bplist)
  260. # Assumes version bytes are hex.
  261. # Provides content hints for version 0 files. Assumes that the root
  262. # object is the first object (true for CoreFoundation implementation).
  263. # From: David Remahl <dremahl@apple.com>
  264. 0 string bplist
  265. >6 byte x \bCoreFoundation binary property list data, version 0x%c
  266. >>7 byte x \b%c
  267. >6 string 00 \b
  268. >>8 byte&0xF0 0x00 \b
  269. >>>8 byte&0x0F 0x00 \b, root type: null
  270. >>>8 byte&0x0F 0x08 \b, root type: false boolean
  271. >>>8 byte&0x0F 0x09 \b, root type: true boolean
  272. >>8 byte&0xF0 0x10 \b, root type: integer
  273. >>8 byte&0xF0 0x20 \b, root type: real
  274. >>8 byte&0xF0 0x30 \b, root type: date
  275. >>8 byte&0xF0 0x40 \b, root type: data
  276. >>8 byte&0xF0 0x50 \b, root type: ascii string
  277. >>8 byte&0xF0 0x60 \b, root type: unicode string
  278. >>8 byte&0xF0 0x80 \b, root type: uid (CORRUPT)
  279. >>8 byte&0xF0 0xa0 \b, root type: array
  280. >>8 byte&0xF0 0xd0 \b, root type: dictionary
  281. # Apple/NeXT typedstream data
  282. # Serialization format used by NeXT and Apple for various
  283. # purposes in YellowStep/Cocoa, including some nib files.
  284. # From: David Remahl <dremahl@apple.com>
  285. 2 string typedstream NeXT/Apple typedstream data, big endian
  286. >0 byte x \b, version %d
  287. >0 byte <5 \b
  288. >>13 byte 0x81 \b
  289. >>>14 ubeshort x \b, system %d
  290. 2 string streamtyped NeXT/Apple typedstream data, little endian
  291. >0 byte x \b, version %d
  292. >0 byte <5 \b
  293. >>13 byte 0x81 \b
  294. >>>14 uleshort x \b, system %d
  295. #------------------------------------------------------------------------------
  296. # CAF: Apple CoreAudio File Format
  297. #
  298. # Container format for high-end audio purposes.
  299. # From: David Remahl <dremahl@apple.com>
  300. #
  301. 0 string caff CoreAudio Format audio file
  302. >4 beshort <10 version %d
  303. >6 beshort x
  304. #------------------------------------------------------------------------------
  305. # Keychain database files
  306. 0 string kych Mac OS X Keychain File
  307. #------------------------------------------------------------------------------
  308. # Code Signing related file types
  309. 0 belong 0xfade0c00 Mac OS X Code Requirement
  310. >8 belong 1 (opExpr)
  311. >4 belong x - %d bytes
  312. 0 belong 0xfade0c01 Mac OS X Code Requirement Set
  313. >8 belong >1 containing %d items
  314. >4 belong x - %d bytes
  315. 0 belong 0xfade0c02 Mac OS X Code Directory
  316. >8 belong x version %x
  317. >12 belong >0 flags 0x%x
  318. >4 belong x - %d bytes
  319. 0 belong 0xfade0cc0 Mac OS X Detached Code Signature (non-executable)
  320. >4 belong x - %d bytes
  321. 0 belong 0xfade0cc1 Mac OS X Detached Code Signature
  322. >8 belong >1 (%d elements)
  323. >4 belong x - %d bytes
  324. # From: "Nelson A. de Oliveira" <naoliv@gmail.com>
  325. # .vdi
  326. 4 string innotek\ VirtualBox\ Disk\ Image %s
  327. # Apple disk partition stuff
  328. # URL: https://en.wikipedia.org/wiki/Apple_Partition_Map
  329. # Reference: https://ftp.netbsd.org/pub/NetBSD/NetBSD-current/src/sys/sys/bootblock.h
  330. # Update: Joerg Jenderek
  331. # "ER" is APPLE_DRVR_MAP_MAGIC signature
  332. 0 beshort 0x4552
  333. # display Apple Driver Map (strength=50) after Syslinux bootloader (71)
  334. #!:strength +0
  335. # strengthen the magic by looking for used blocksizes 512 2048
  336. >2 ubeshort&0xf1FF 0 Apple Driver Map
  337. # last 6 bytes for padding found are 0 or end with 55AAh marker for MBR hybrid
  338. #>>504 ubequad&0x0000FFffFFff0000 0
  339. !:mime application/x-apple-diskimage
  340. !:apple ????devr
  341. # https://en.wikipedia.org/wiki/Apple_Disk_Image
  342. !:ext dmg/iso
  343. # sbBlkSize for driver descriptor map 512 2048
  344. >>2 beshort x \b, blocksize %d
  345. # sbBlkCount sometimes garbish like
  346. # 0xb0200000 for unzlibed install_flash_player_19.0.0.245_osx.dmg
  347. # 0xf2720100 for bunziped Firefox 48.0-2.dmg
  348. # 0xeb02ffff for super_grub2_disk_hybrid_2.02s3.iso
  349. # 0x00009090 by syslinux-6.03/utils/isohybrid.c
  350. >>4 ubelong x \b, blockcount %u
  351. # following device/driver information not very useful
  352. # device type 0 1 (37008 garbage for super_grub2_disk_hybrid_2.02s3.iso)
  353. >>8 ubeshort x \b, devtype %u
  354. # device id 0 1 (37008 garbage for super_grub2_disk_hybrid_2.02s3.iso)
  355. >>10 ubeshort x \b, devid %u
  356. # driver data 0 (2425393296 garbage for super_grub2_disk_hybrid_2.02s3.iso)
  357. >>12 ubelong >0
  358. >>>12 ubelong x \b, driver data %u
  359. # number of driver descriptors sbDrvrCount <= 61
  360. # (37008 garbage for super_grub2_disk_hybrid_2.02s3.iso)
  361. >>16 ubeshort x \b, driver count %u
  362. # 61 * apple_drvr_descriptor[8]. information not very useful or same as in partition map
  363. # >>18 use apple-driver-map
  364. # >>26 use apple-driver-map
  365. # # ...
  366. # >>500 use apple-driver-map
  367. # number of partitions is always same in every partition (map block count)
  368. #>>0x0204 ubelong x \b, %u partitions
  369. >>0x0204 ubelong >0 \b, contains[@0x200]:
  370. >>>0x0200 use apple-apm
  371. >>0x0204 ubelong >1 \b, contains[@0x400]:
  372. >>>0x0400 use apple-apm
  373. >>0x0204 ubelong >2 \b, contains[@0x600]:
  374. >>>0x0600 use apple-apm
  375. >>0x0204 ubelong >3 \b, contains[@0x800]:
  376. >>>0x0800 use apple-apm
  377. >>0x0204 ubelong >4 \b, contains[@0xA00]:
  378. >>>0x0A00 use apple-apm
  379. >>0x0204 ubelong >5 \b, contains[@0xC00]:
  380. >>>0x0C00 use apple-apm
  381. >>0x0204 ubelong >6 \b, contains[@0xE00]:
  382. >>>0x0E00 use apple-apm
  383. >>0x0204 ubelong >7 \b, contains[@0x1000]:
  384. >>>0x1000 use apple-apm
  385. # display apple driver descriptor map (start-block, # blocks in sbBlkSize sizes, type)
  386. 0 name apple-driver-map
  387. >0 ubequad !0
  388. # descBlock first block of driver
  389. >>0 ubelong x \b, driver start block %u
  390. # descSize driver size in blocks
  391. >>4 ubeshort x \b, size %u
  392. # descType driver system type 1 701h F8FFh FFFFh
  393. >>6 ubeshort x \b, type 0x%x
  394. # URL: https://en.wikipedia.org/wiki/Apple_Partition_Map
  395. # Reference: https://opensource.apple.com/source/IOStorageFamily/IOStorageFamily-116/IOApplePartitionScheme.h
  396. # Update: Joerg Jenderek
  397. # Yes, the 3rd and 4th bytes pmSigPad are reserved, but we use them to make the
  398. # magic stronger.
  399. # for apple partition map stored as a single file
  400. 0 belong 0x504d0000
  401. # to display Apple Partition Map (strength=70) after Syslinux bootloader (71)
  402. #!:strength +0
  403. >0 use apple-apm
  404. # magic/Magdir/apple14.test, 365: Warning: Current entry does not yet have a description for adding a EXTENSION type
  405. # file: could not find any valid magic files!
  406. #!:ext bin
  407. # display apple partition map. Normally called after Apple driver map
  408. 0 name apple-apm
  409. >0 belong 0x504d0000 Apple Partition Map
  410. # number of partitions
  411. >>4 ubelong x \b, map block count %u
  412. # logical block (512 bytes) start of partition
  413. >>8 ubelong x \b, start block %u
  414. >>12 ubelong x \b, block count %u
  415. >>16 string >0 \b, name %s
  416. >>48 string >0 \b, type %s
  417. # processor type dpme_process_id[16] e.g. "68000" "68020"
  418. >>120 string >0 \b, processor %s
  419. # A/UX boot arguments BootArgs[128]
  420. >>136 string >0 \b, boot arguments %s
  421. # status of partition dpme_flags
  422. >>88 belong & 1 \b, valid
  423. >>88 belong & 2 \b, allocated
  424. >>88 belong & 4 \b, in use
  425. >>88 belong & 8 \b, has boot info
  426. >>88 belong & 16 \b, readable
  427. >>88 belong & 32 \b, writable
  428. >>88 belong & 64 \b, pic boot code
  429. >>88 belong & 128 \b, chain compatible driver
  430. >>88 belong & 256 \b, real driver
  431. >>88 belong & 512 \b, chain driver
  432. # mount automatically at startup APPLE_PS_AUTO_MOUNT
  433. >>88 ubelong &0x40000000 \b, mount at startup
  434. # is the startup partition APPLE_PS_STARTUP
  435. >>88 ubelong &0x80000000 \b, is the startup partition
  436. #https://wiki.mozilla.org/DS_Store_File_Format
  437. #https://en.wikipedia.org/wiki/.DS_Store
  438. 0 string \0\0\0\1Bud1\0 Apple Desktop Services Store
  439. # HFS/HFS+ Resource fork files (andrew.roazen@nau.edu Apr 13 2015)
  440. # Usually not in separate files, but have either filename rsrc with
  441. # no extension, or a filename corresponding to another file, with
  442. # extensions rsr/rsrc
  443. 0 string \000\000\001\000
  444. >4 leshort 0
  445. >>16 lelong 0 Apple HFS/HFS+ resource fork
  446. #https://en.wikipedia.org/wiki/AppleScript
  447. 0 string FasdUAS AppleScript compiled
  448. # AppleWorks/ClarisWorks
  449. # https://github.com/joshenders/appleworks_format
  450. # http://fileformats.archiveteam.org/wiki/AppleWorks
  451. 0 name appleworks
  452. >0 belong&0x00ffffff 0x07e100 AppleWorks CWK Document
  453. >0 belong&0x00ffffff 0x008803 ClarisWorks CWK Document
  454. >0 default x
  455. >>0 belong x AppleWorks/ClarisWorks CWK Document
  456. >0 byte x \b, version %d
  457. >30 beshort x \b, %d
  458. >32 beshort x \bx%d
  459. !:ext cwk
  460. 4 string BOBO
  461. >0 byte >4
  462. >>12 belong 0
  463. >>>26 belong 0
  464. >>>>0 use appleworks
  465. >0 belong 0x0481ad00
  466. >>0 use appleworks
  467. # magic for Apple File System (APFS)
  468. # from Alex Myczko <alex@aiei.ch>
  469. 32 string NXSB Apple File System (APFS)
  470. >36 ulelong x \b, blocksize %u
  471. # iTunes cover art (versions 1 and 2)
  472. 4 string itch
  473. >24 string artw
  474. >>0x1e8 string data iTunes cover art
  475. >>>0x1ed string PNG (PNG)
  476. >>>0x1ec beshort 0xffd8 (JPEG)
  477. # MacPaint image
  478. 65 string PNTGMPNT MacPaint image data
  479. #0 belong 2 MacPaint image data