ovflowd / yupi

:game_die: open source gaming emulator for flash based games
MIT License
30 stars 15 forks source link

Problem with TCP proxy #84

Closed Killua99x closed 8 years ago

Killua99x commented 8 years ago

With a Proxy TCP I can have only one user, using the proxy because they all have the same IP ie the IP of the proxy, how can I fix? or ensure that IP connections are unlimited? @sant0ro

ovflowd commented 8 years ago

The problem with Proxy is every end-user IP is the same of the Proxy Server IP.

Yupi uses IP Address (END-Point) as Client Identification, and i will not change this as a security issue.

If @TheDoct0r11 knows any other way to make it work, feel free to ask him.

Killua99x commented 8 years ago

okay I'll try to solve my problem, thanks @TheDoct0r11 Excuse me, could you tell me if you know another way out of this problem?

ah still @sant0ro you could tell me if when I have placed this issue, please, if you could come back on my server to test the bugs I have seen and put on post #78 ?

TheDoct0r11 commented 8 years ago

@sant0ro That isn't entirely correct. Yupi only uses the IP Address as Identification, not the local endpoint.

We're living in a world with NAT resulting in having multiple computers residing behind the same public IP Address.

It usually makes sense to allow only a few connections from the same network, but to limit it to one per network doesn't make sense, since other players in the same network would have the same IP.

This would prevent users from accessing Yupi with their family members, from public WiFi and maybe even from Mobile Networks (not really sure about those though)

I'm currently refactoring the Sockets System, and once that's done we might consider adding a config option for Reverse TCP Proxies.

Killua99x commented 8 years ago

I was thinking this, my friend with his laptop he wanted to connect to my retro server but became a spectator could not move or else after entering it the navigator worked. It is a bad thing for an IP user for me.. and i cant use a proxy for security issue

ovflowd commented 8 years ago

Yes Doctoro you're right. But Yupi doesn't uses only the IP Address as Identification. Literally uses the End-Point <=> IP Convertion that results into IPv4 + Some Hashes

You can see if you try login. So these Hashes are designed for different machine.

So login into different machine in same network isn't a problem.

The problem is using proxy. since the proxy redirects entirely data for the same machine. The proxy machine. So the hash isn't different ;)

TheDoct0r11 commented 8 years ago

As far as I can see only the IP Address is being used:

Add to ClientManager

Override existing in ClientManager

IP Address to String Conversion

Mono implementation of System.Net.IPAddress#ToString()

Killua99x commented 8 years ago

boh I have noticed some problems with two different machines .. I do not know