How do you calculate the crc32 checksum of a file by hand? - checksum

I'm using fsum to generate crc32 checksums of various files. I'd like to validate it's checksums by hand to ensure that they are being calculated correctly, but I don't know how to do this.
I do realize there are programs out there that will check these things for me, but then I'd also have to validate THOSE programs.
Can someone help me figure out how to calculate the crc32 checksums of a file by hand? For the sake of being on the same page, let's use this txt file: http://www.filedropper.com/file_210
I apologize for the vague-ness of this post as I'm a bit confused as to where I should even start. I've been trying to figure out how to do this for hours and have come up incredibly short.

Related

How can I parse a progressive JPG

I am writing a 'clean-room' program that requires parsing/unparsing of jpegs. I have found all the information I need to parse/unparse baseline jpegs, but I cannot find the information that I need to parse/unparse progressive jpegs.
I need to be able to convert the compressed data to macroblocks and back, so most available frameworks are too high level. I also want to understand what is going on, hence the 'clean room' approach.
Can anybody help me please? A specification of the SOF1 header would be useful, as would be the layout of the compressed data in the scan segment.
Thanks in advance.
If you want to figure this out, I'd get this book:
https://www.amazon.com/Compressed-Image-File-Formats-JPEG/dp/0201604434/ref=sr_1_5?ie=UTF8&qid=1486949641&sr=8-5&keywords=jpeg
It explains it all in easy-to-understand terms. The author has source code at
http://colosseumbuilders.com/sourcecode/imagelib403.zip
that is designed to be easy to understand.
The SOF1 header is the same as all other SOF headers. You need to have a copy of the JPEG standard (as obtuse as it is). The other sources above will help you get through it.

What is checksum and where is used?

I have a project with topic what is checksum, I would like to explain where to be focused on, and to make more attractive from others colleagues.
What checksum?
Where is used and how can I explain it with a short term?
Checksum is a digit representing the sum of the correct digits in a piece of stored or transmitted digital data, against which later comparisons can be made to detect errors in the data.
You can refer below links for more detail:
1. http://www.online-tech-tips.com/cool-websites/what-is-checksum/
http://www.thegeekstuff.com/2012/05/ip-header-checksum
Hope it will help you.

Connect to Acrobat's IAC (interapplication communication)

I am trying to automate some non-trivial task* with Adobe's Acrobat XI.
I think the way to go is using Acrobat's IAC, which seems to be well-documented, eg. here.
However, I could not figure out how to access the application object, eg. from within an HTA. I mean: How do I get the app object mentioned in the API documentation?
It feels like I am missing something very obvious. However, I have been searching and trying unsuccessfully for quite a while now.
Alternatively, any other suggestion how to perform complicated stuff (see footnote) in Acrobat is appreciated.
*The task is concatenating 1 to n JPG files into a PDF/A document (like, tens of thousands of times). The mapping is given through a TSV file or something alike. The requirement of generating PDF/A which pass Adobe's validation forces me to use Acrobat, at least for this last step.
Are you using .net? Are you missing a reference to IAC?
try: SET gApp = CreateObject("AcroExch.App")

Compile the same program but get different binaries in Delphi XE [duplicate]

For the purposes of binary / source code verification, i'd like to be able to make two compiles on the same computer 2 weeks apart and have the binaries be identical and thus pass some checksum test.
So far I've found that most likely the timestamp will be written by the compiler into the binary. I can work around this by doing the compare on the dumpbin /rawdata results per this msdn article.
http://support.microsoft.com/kb/164151
However the dumpbin results still differ in a about a dozen places and the difference still appears to be some kind of timestamp (changing from A1 73 to C4 76) for example.
I assume this is the timestamp that the delphi compiler is putting into the code/data sections but i can't find where this is happening or how to turn it off. Fiddling with the various compiler/linker options has not changed this behavior.
Any help would be greatly appreciated.
We researched this question a few years ago, and as I recall the answer was simply that the people at Borland/Codegear/Embarcadero do not subscribe to the notion that the compiler should produce exactly the same output given exactly the same input (given that the current date-time is not acceptable to consider as input).
This is disappointing, but given that Delphi is upmteen major versions old, it probably will not change.
Based on your comment in the question, I think you are searching for the answer to this question:
How can I verify that a certain binary is created by a certain set of source files
One way is to have an automated built process that:
Inserts a unique verififcation tag in the source code (might be as simple as a GUID string or something else in an include file)
Compiles the binaries using that verification tag
Packs the resulting binary and source code in a delivery directory tree
You must make sure that your sourcecode actually uses that verification tag (for instance by showing in an about box, or something similar).
I use FinalBuilder to automate build processes like this.
--jeroen
Unfortunately I haven't heard of any answer to this problem.
It's not just timestamps but there are places where a few bytes of random garbage out of memory ends up in the result.

Trap and translate ESC/P2 printer output

Old days are catching up and old stuff isn't as good as new. Have tons of data stored in a system that only supports printing to ESC/P2 printer language, and even if that isn't completely unsupported, I want to be able to convert the printouts.
The datastorage is a properitary file. I have decoded some of the fileformat, but still there is too many blanks to successfully recreating the stored data.
The software is written in Forth. Tried to debug it, but it's too timeconsuming without a better decompiler. Any pointers...?
At last, the easy way out is to grab the printout stream and decode it into bitmaps and then create a PDF or something. Even if ESC/P2 is older I havent found a good library for it. Any pointers?
If anyone has suggestions to what path to walk I'd be very happy. Oh, and any software I write to solve this will be written in C#. :)

Resources