Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8363621
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T12:13:28+00:00 2026-06-09T12:13:28+00:00

According to the QPDF source I was reading it had this quote about pdfs:

  • 0

According to the QPDF source I was reading it had this quote about pdfs:

// PDF spec says %%EOF must be found within the last 1024 bytes of
// the file.  We add an extra 30 characters to leave room for the
// startxref stuff.

However, I cannot find any information regarding this in the PDF 1.7 specification. I found a couple places on the internet that also mentioned this though.

My question is: is this true and if so, where is this specified that %%EOF will be in the last 1024 bytes?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T12:13:29+00:00Added an answer on June 9, 2026 at 12:13 pm

    The source code does indeed say that, in libqpdf/QPDF.cc, but ISO 32000-1:2008 (the PDF 1.7 one) has this to say about the file trailer:

    7.5.5. File Trailer

    The trailer of a PDF file enables a conforming reader to quickly find the cross-reference table and certain special objects. Conforming readers should read a PDF file from its end. The last line of the file shall contain only the end-of-file marker, %%EOF.

    So, if you’re following the standard, it’s even more restrictive than you state.


    Back in the Adobe 1.3 specification, in Appendix H (Implementation notes), you’ll find this little snippet about the properties of the Acrobat viewer (not the file format):

    3.4.4, “File Trailer”

    Acrobat viewers require only that the %%EOF marker appear somewhere within the last 1024 bytes of the file.

    In other words, it’s saying that the viewer (Adobe’s implementation) is a little more relaxed in what it will accept. The specification itself, however, still maintains that the %%EOF has to be on its own, on the last line.

    That note still exists in Adobe’s version of the file format document up to 1.7. However, it was removed from the ISO version since, rightly so, ISO don’t care one little bit about specific implementations of a product, as long as they conform to the standard as written.

    Adobe’s documents can be found here, they also have the right to distribute a (slightly modified) version of the ISO 32000 standard here.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

According to this discussion , the iphone agreement says that it doesn't allow loading
According to this SO post: How to check the TEMPLATE_DEBUG flag in a django
According to this post , IDEA uses Osmorc to run OSGi frameworks. It, in
According this article , generic JPA DAO(Data Access Object) is a pretty nice pattern.
According to this post in Recursive Descent vs. LALR , any LALR(k) can be
According to Steffen's post this is an efficient way to generate random BOOL s
According to Microsoft , you must sign your ClickOnce application. But it seems to
According to JavaScript Patterns book (p. 79), this should work: var ob = {
according to my knowledge, this feature already exists in PHP. lets look at the
According to the annotated source, the Coffee Script grammar delimits the arguments to a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.