|
-
Dec 19th, 2010, 12:50 PM
#1
UDP Socket communication on my website
Hi,
I was in the process of building an ASP.NET website that communicates with a gameserver. This communication happens via UDP and I am using a Socket object to connect and send / receive messages.
When I run (debug) my website locally, everything works fine, but after I deploy it to my webserver, it no longer works. Whenever a communication with the gameserver occurs, the website simply does not load anymore. For example, I click a button that should retrieve the name of the server (it does that by sending a "sv_hostname" command and waiting for the response). The website posts back (cause I clicked the button) but then it simply keeps loading forever. The loading bar stays completely empty, I've waited minutes, but nothing happens.
I'm finding it hard to diagnose any exact problem, but it seems likely that the webserver blocks the UDP communication, a firewall issue probably. I guess I can still send commands, but that the response is blocked, and since I am not using async response (doesn't seem like there is a point using async connection for a website) it just blocks the entire website from loading.
I contacted my webhost and asked them whether it was possible to open UDP ports 3000 to 4000 (those are the ports this game uses for its servers). They responded that it was possible for them to open ports, but they charge 25 bucks PER PORT! If I wanted to support all possible ports that would be 25.000 bucks... Yeah, no.
The reason they don't like opening ports is that the servers are shared. I'm not sure what that means, but probably that more websites are run on one single webserver (isn't that usually the case? I can't imagine small websites to all have their own server), so that opening ports is a security risk not only for me but also for the other sites. Or something.
Anyway, I was wondering if I have any alternatives. I am completely new to this UDP and socket communication, so there may be no other way except to open the ports (which I'm not going to do obviously), but if there is a way I'd like to know!
Thanks for any help
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|