[lug] deconstructing pdf of voted Boulder ballots

Neal McBurnett neal at bcn.boulder.co.us
Fri Dec 9 13:08:58 MST 2011


Thanks!  I assumed those were related to images, but hadn't succeeded in seeing any bits, so wasn't sure.  I also am very surprised to see so many images per page, since I'd expect just one.

Then I found this explanation:

 http://www.jpedal.org/PDFblog/2010/04/understanding-the-pdf-file-format-how-are-images-stored/

and this tool:

 http://en.wikipedia.org/wiki/Pdfimages

and discovered via "pdfimages" that the pdf has the images spliced up into strips each about 150 bits high.  Bizarre.  Sad....

Thanks again,

Neal McBurnett                 http://neal.mcburnett.org/

On Fri, Dec 09, 2011 at 06:02:46AM -0700, Kenneth D. Weinert wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> On 12/09/2011 12:17 AM, Neal McBurnett wrote:
> 
> > Can any of you pdf gurus help out?
> 
> I don't know if I'd classify myself as a guru, but all of those
> CCITFaxDecode objects are images.
> 
>  3824 0 obj<<
>     /BitsPerComponent 1
>     /DecodeParms<<
>       /Columns 1481
>       /K -1
>     >>
>     /Filter/CCITTFaxDecode
>     /Height 150
>     /ImageMask true
>     /Length 413
>     /Subtype/Image
>     /Type/XObject
>     /Width 1481
> >> stream
> 
> There's an example of an image object. It's object #3824, generation
> 0. The << indicates the start of a dictionary.
> BitsPerComponent of 1 says it's a black and white image.
> Columns is self-explanatory and I don't recall what K is off the top
> of my head, although it might be an indicator of whether or not the
> image is reversed (white/black or black/white.)
> 
> /Filter gives /CCITTFaxDecode, a very common encoding for B&W images.
> The /Subtype and /Type describe the type of object it is.
> 
> Then the object dictionary ends (the last >>) and the data attached to
> the object begins (the stream) and there will be an endstream at the
> end of the data (which is 413 bytes long.)
> 
> Does this help at all?
> 
> Ken
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.11 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
> 
> iQEcBAEBAgAGBQJO4gbtAAoJELwlFgJPb4vs6mwH/jeKpw99OhS/beSlqPBeSJtZ
> E0KjBNjRmbuNAQAiGv2j9LuMW+/B6d1cXMHlxSdH8S/VBnabReTdMcvEWOVerQlH
> uf7O39LDZODWX43cpb8xxX5WZJuXPhaZDvmfsX+cprmc+65AVFLIcXzkr3mduipc
> 35MfJfTqQPu1/ZwLJIXa3WoYYzy57ipjje2uQ1cRgi2gqD1RHpG4WaQNLOa/ry1g
> Y5VN2WSV5a4WyVxGbHziUI5zxA/mnpBX28c66Y841wWhQk+6zBKkUe4ZB8Dgx5fT
> K6h1i6WLW1OrVuQTa7i3cjmJZXHsdsBzfRyMJxkxvCC1nGzTnQfnqEy5dyx9DO8=
> =Fico
> -----END PGP SIGNATURE-----
> _______________________________________________
> Web Page:  http://lug.boulder.co.us
> Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> Join us on IRC: irc.hackingsociety.org port=6667 channel=#hackingsociety



More information about the LUG mailing list