We don’t allow questions seeking recommendations for software libraries, tutorials, tools, books, or other off-site resources. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(1)
continue
XOR is a very simple, but quite effective, solution to this problem.
In GML:
I have never used RPG Maker myself, but I imagine it wouldn't be too hard to write similar code for it.
A couple of notes, it doesn't guarantee security. One could decompile the Game Maker EXE and reveal the key, or the key can just straight-up be broken if it is insecure.
A good, secure key is long, because breaking the encryption relies on the key repeating itself. If the key is the over half the length of the data being encrypted, it is virtually impossible to break the encryption, except by a known-plaintext attack if the file's contents are predictable (for example, I could assume the file contains the player's name and score, so those could be used in a known-plaintext attack).
Overall, this won't guarantee security of the file, but for your purposes should be more than suitable.
Also, since you were asking for a possible PHP solution:
PS. I know this question is fairly old, but I was just randomly browsing Game Maker tags :p