I want to make a setting file (*.stt) to be read by my PHP application. May I know how to encrypt it and decrypt to read by my application?
The setting file is written in XML format and the size may reached 1MB. Any effective way to do this?
I want to make a setting file (*.stt) to be read by my PHP application. May I know how to encrypt it and decrypt to read by my application?
The setting file is written in XML format and the size may reached 1MB. Any effective way to do this?
You can use the mcrypt extension. However, if you really expect to have 1MB of data, I think you'd be better off using a database solution if possible, rather than the processing needed to read that size of a file into memory and presumably parse it with [man]simplexml[/man] or such, let alone decrypting it.
NogDog wrote:You can use the mcrypt extension. However, if you really expect to have 1MB of data, I think you'd be better off using a database solution if possible, rather than the processing needed to read that size of a file into memory and presumably parse it with [man]simplexml[/man] or such, let alone decrypting it.
Thank you for your suggestion. I'll try out and see..