Delphi - change (ini) file but keep Checksum of crc16 equal

363 Views Asked by At

I am looking for a method to change an ini file but keep the checksum as it was before. I know I can try to change some bytes until the result fits. But I would like go an programmatical way. Any ideas are very appreciated.

Background: program checks the crc of the ini, if it does not fit, shows a messagebox and the user has to click "ok". The program is launched from a batch and quits automatically when its done. Very often, there is no user, so the programm can not do his job. Autoit or similar can not be installed.

The crc check is obsolete in the meantime. The Program is > 10 years old and we can not reach the developer and have no sources.

1

There are 1 best solutions below

0
On

Yes, it is relatively easy to modify data to get a chosen CRC, since CRCs are linear functions. My spoof program will do this for you. You choose what CRC you want and the bits in the message you will permit to be changed, and spoof will tell you which of those bits to invert.