strip out file header and footer

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Salim Zaabi
    New Member
    • Oct 2009
    • 25

    strip out file header and footer

    Hi All,
    My problem may sound irrelevant to this forum. I have been searching the web to find an answer for the following:
    how do I determine the header and the footer and their length in any type of file?.
    The purpose of it is that I'm trying to develop and a c# application to determine the data type without looking into the header nor the footer. But I need first to strip out the header and the footer to get precise result where unique characters and strings are going to be one of the determinants of the data type.
    Or, I'll be grateful if you could tell me about an available application that strip out header and footer automatically.
  • Rabbit
    Recognized Expert MVP
    • Jan 2007
    • 12517

    #2
    Header and footer of what? Data type of what? You need to share with us the definitions of the terms you're talking about because they can mean many many things.

    Comment

    • Salim Zaabi
      New Member
      • Oct 2009
      • 25

      #3
      Thanks Rabbit,,
      Any data type, such as pdf, docx, jpg.... But the question is the header length of any file type.
      to be precise, what is the header and the footer length of pdf, jpg, docx, mp3 files?.

      Comment

      • Rabbit
        Recognized Expert MVP
        • Jan 2007
        • 12517

        #4
        You can find those lengths by reading the white paper file specifications. You just need to google the file type with the phrase file spec and start reading how the files are laid out.

        Comment

        • Salim Zaabi
          New Member
          • Oct 2009
          • 25

          #5
          Thanks again Rabbit,
          I already did, but I found no answer. The specification information at most tells you how the file is arranged but does not go through bytes level and location.

          Comment

          • Rabbit
            Recognized Expert MVP
            • Jan 2007
            • 12517

            #6
            Are you sure you're looking at the right file? And are you sure you're reading carefully?

            It took me 5 minutes to find the JPEG "header". In JPEG, it's called a "start of frame segment" rather than a "header". And is 10-12 bytes long.

            Comment

            Working...