Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Securely Connect MySQL via PHP in ActionScript 3 using AMFPHP framework

My Flash movie would like communicate with MySQL server to fetch and save data between MySQL and SWF. I know AMFPHP can help with the communication, but is there a secure way to encrypt the texts sending between 2 sides (other than hashing password in MD5)? As far as I know, by default, AMFPHP sends out data in plain text.

Also, I heard that the CPU usage during network requests in Flash is quite high. Any lightweight framework suggestion?

like image 324
Raptor Avatar asked Mar 24 '26 23:03

Raptor


1 Answers

I don't actually know much about AMFPHP but in general you should never send SQL queries from a client directly. No matter how good your encryption, someone can break it and then they can do whatever they want to your server.

You should create an API in PHP that the client can use to perform certain pre-defined safe actions on the DB, so if someone reverse-engineers your encryption (which, by the way, is extremely easy to do by decompiling your swf), they can only do things to the database that are allowed.

like image 99
Jay Paroline Avatar answered Mar 27 '26 12:03

Jay Paroline



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!