Banning players with MP object

Discussion and feedback on Construct 2

Post » Sun May 15, 2016 4:39 am

AFAIK wile using the multiplayer object, issuing a ban on a specific peer/IP is impossible? It seems like a pretty important feature that's missing, since this means a cheating player could keep rejoining even if they were kicked.

I feel like we should be able to get the IP of a specific peer for this reason at the very least.
B
79
S
13
G
8
Posts: 1,977
Reputation: 9,947

Post » Sun May 15, 2016 4:51 am

Might that be done at the signaling server?
Image ImageImage
B
172
S
50
G
182
Posts: 8,432
Reputation: 115,083

Post » Sun May 15, 2016 5:07 am

You can create something for that in your game logic.


i.e.
The peer receives a ban command from the host.
The peer then fires off an Ajax call to a dedicated page.
This page processes the request, catching the IP of the user calling the page.
This info is then processed and applied to the firewall rules.

Voila IP blocked on server :)



Another approach could be that if the player receives a bann messages, certain values get stored in the local storage preventing him or her to reconnect.
This could be undone by reinstalling the game or something, but could become tedious after several bans.
Who dares wins
B
57
S
17
G
21
Posts: 1,878
Reputation: 19,592

Post » Sun May 15, 2016 5:19 am

@lennaert

For obvious reasons banning players shouldn't rely on info from the person being banned though. Ideally there should be a way for the host to get the IP of a player before they're banned (i assume this info is already known by the host in establishing a connection), store it, and check if a connecting player has an IP in the ban-list.

really a get peer IP expression is all that's needed, however im uncertain of how feasible this is since I don't know much about using WebRTC.
Last edited by QuaziGNRLnose on Sun May 15, 2016 5:24 am, edited 1 time in total.
B
79
S
13
G
8
Posts: 1,977
Reputation: 9,947

Post » Sun May 15, 2016 5:23 am

QuaziGNRLnose wrote:@lennaert

For obvious reasons banning players shouldn't rely on info from the person being banned though. Ideally there should be a way for the host to get the IP of a player before they're banned (i assume this info is already known by the host in establishing a connection), store it, and check if a connecting player has an IP in the ban-list.



If the signalling server does not allow the connection ..... he or she will not connect.
Who dares wins
B
57
S
17
G
21
Posts: 1,878
Reputation: 19,592

Post » Sun May 15, 2016 5:24 am

@lennaert

I'm not looking for a way to ban players permanently from a signalling server, just from a specific host's room. The host should be able to find the IP's of the peers considering it's communicating with them, but the multiplayer object offers no expression to retrieve it. Banning a player game-wide isn't the issue, i just want players to be able to permanently kick an annoying/spammy/fake/cheating user in their room.
B
79
S
13
G
8
Posts: 1,977
Reputation: 9,947

Post » Sun May 15, 2016 5:29 am

Atm, the mp object does not have such function, but you can build something similar with the method mentioned above.

Upon connecting An ajax call is made, which relays back the IP address which gets stored in a peer/user's local storage.
When connecting to a game, the stored IP address gets transmitted and compared by the host to some list it has stored somewhere.
Who dares wins
B
57
S
17
G
21
Posts: 1,878
Reputation: 19,592


Return to Construct 2 General

Who is online

Users browsing this forum: Yahoo [Bot] and 6 guests