pdf 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. #------------------------------------------------------------------------------
  2. # $File: pdf,v 1.18 2023/07/17 15:57:18 christos Exp $
  3. # pdf: file(1) magic for Portable Document Format
  4. #
  5. 0 name pdf
  6. >8 search /Count
  7. >>&0 regex [0-9]+ \b, %s page(s)
  8. >8 search/512 /Filter/FlateDecode/ (zip deflate encoded)
  9. 0 string %PDF- PDF document
  10. !:mime application/pdf
  11. !:strength +60
  12. !:ext pdf
  13. >5 byte x \b, version %c
  14. >7 byte x \b.%c
  15. >0 use pdf
  16. 0 string \012%PDF- PDF document
  17. !:mime application/pdf
  18. !:strength +60
  19. !:ext pdf
  20. >6 byte x \b, version %c
  21. >8 byte x \b.%c
  22. >0 use pdf
  23. 0 string \xef\xbb\xbf%PDF- PDF document (UTF-8)
  24. !:mime application/pdf
  25. !:strength +60
  26. !:ext pdf
  27. >6 byte x \b, version %c
  28. >8 byte x \b.%c
  29. >0 use pdf
  30. # From: Nick Schmalenberger <nick@schmalenberger.us>
  31. # Forms Data Format
  32. 0 string %FDF- FDF document
  33. !:mime application/vnd.fdf
  34. !:strength +60
  35. !:ext pdf
  36. >5 byte x \b, version %c
  37. >7 byte x \b.%c
  38. 0 search/1024 %PDF- PDF document
  39. !:mime application/pdf
  40. !:strength +60
  41. !:ext pdf
  42. >&0 byte x \b, version %c
  43. >&2 byte x \b.%c
  44. >0 use pdf