1

I need to run a test which requires that I corrupt a specific .exe file. For security reasons I cannot upload this file to http://corrupt-a-file.net/. Is there a known tool for Windows that I can use, or a recommended technique?

5
  • Bit off-topic as your question is about corrupting files, not really about testing. May 16, 2015 at 22:28
  • Might be off topic, but... are you sure this external service is not injecting a virus?
    – dzieciou
    May 17, 2015 at 5:19
  • @NielsvanReijmersdal, not that off-topic, it looks like setting up test data. Still I'm curious what kind of test is that.
    – dzieciou
    May 17, 2015 at 7:56
  • @Niels thanks for your answer, the hex editor was the key.
    – dsu66uth
    May 19, 2015 at 3:08
  • @dzieciou - as for the test type, our software has some neat fail overs. I needed a quick way to corrupt an aspect of the software to trigger an event which in turn would replace the bad file(s). Greatly appreciate the help!
    – dsu66uth
    May 19, 2015 at 3:09

1 Answer 1

4

If we define corrupt as not being able to start the executable, just open it with a text editor (like notepad++) and change some text around and save. Some executables might be to large to open, but I think a good text-editor should be able to handle most. Open the executable, if it still works, change more text around :)

The smallest changes will often result in a broken application.

Maybe have a look at the file with a hexeditor and change some of the important bits.

1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.