Running your own server and doing socket connections in flash?
Then you need a flash-policy server. I tried the one on adobe devnet but it seems to require python 2.5
I found this one that runs fine on centos 5.2
http://www.devco.net/pubwiki/FlashPolicyd