Question

I am currently developping a windows application who test railroad equipments to find any defaults.

Utility A => OK
Utility B => NOK
...

This application will check the given equipment and generate a report. This report needs to be written once, and no further modifications are allowed since this file can be used as working proof for the equipment.

My first idea was ta use pdf files (haru lib looks great), but pdf can also be modified.

I told myself that I could obsfuscate the report, and implement a homemade reader inside my application, but whatever way I store it, the file would always be possibly accessed and modified right?

So I'm running out of ideas.

Sorry if my approach and my problem appear naive but it's an intership.

Thanks for any help.

Edit: I could also add checksums for files after I generated them, and keep a "checksums record file", and implement a checksums comparison tool for verification? just thought about this.

Was it helpful?

Solution

I believe the answer to your question is to use any format whatosever, and use a digital signature anybody can verify, e.g., create a gnupg, get that key signed by the people who require to check your documents, upload it to one of the key servers, and use it to sign the documents. You can publish the documents, and have a link to your public key available for verification; for critical cases someone verifying must be trust your signature (i.e., trust somebody who signed your key).

OTHER TIPS

People's lives depend on the state of train inspections. Therefore, I find it hard to believe that someone expects you to solve this problem only using free-as-in-beer components.

Adobe supports a strong digital signature model. If you buy into their technology base, you can create PDF's that are digitally signed, and are therefore tamper-evident, as the consumer can check for the signature.

You can, as someone else pointed out, use GNUpg, or for that matter OpenSSL, to implement your own signature scheme, but railroad regulators are somewhat less likely to figure out how to work with it.

I would store reports in an encrypted/protected datastore. When a user accesses a report (requests a copy, the original is of course always in the database and cannot be modified), it includes the text "Report #XXXXX". If you want to validate the report, retrive a new copy from the system using the Report ID.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top