0

I do have an android application that downloads PDF files for display in a magazine app.

To secure the data I am already setting a user password. I was additionally thinking of removing the last 100 bytes of each file when stored on the device and adding them during run-time.

This at least would render the PDF not readable anymore.

Does anyone have a suggestion on how to achieve this with moderate effort and at the same time keeping the calulcating overhead low?

Thanks for any advice here.

idplanter
  • 160
  • 2
  • 9
  • If your pdfs use the old-fashioned xref tables, those last 100 bytes often only contain the file trailer and some part of the xref table. Many pdfs can be repaired with those bytes missing... – mkl Apr 08 '13 at 22:09

1 Answers1

0

encryption seems to be the best approach for you.

https://developer.android.com/reference/javax/crypto/package-summary.html

How to encrypt and decrypt file in Android?

Community
  • 1
  • 1
Budius
  • 39,391
  • 16
  • 102
  • 144
  • I already tried with encryption, but this causes few seconds delay each time the PDF is opened. Thus Im looking for another way to render the PDF useless by removing some data from the end. – idplanter Apr 08 '13 at 18:15