DominicTurner02 / SimpleIPBan

Adds the ability to blacklist certain IPs from joining your Server.
GNU General Public License v3.0
0 stars 3 forks source link

OMGGGGGGGGG #4

Open RainOfPain125 opened 5 years ago

RainOfPain125 commented 5 years ago

Ok, this plugin is amazing and great and all, but could you look at Global Bans ( https://harbor.rocketmod.net/plugins/global-ban/ ) and try to combine the two? The pros of Global Bans is that it uses MySQL to sync bans, but the con is that bans don't have timers nor reasons (and of course it isn't an IP ban)

This would be the ULTIMATE ebic plugin if you could do this. I'm currently using global bans but players often just avoid the ban obviously.

DominicTurner02 commented 5 years ago

Once I am confident in creating plugins with MySQL compatibility I will look into adding MySQL support for this plugin, and maybe some of my others.

RainOfPain125 commented 5 years ago

Once I am confident in creating plugins with MySQL compatibility I will look into adding MySQL support for this plugin, and maybe some of my others.

Thanks for thinking about it. I'll make sure to switch my franchise over to your plugin if you do one day decide to do it. ^w^

DominicTurner02 commented 5 years ago

No problem. If you want, add me on Discord and I’ll let you know when I update the plugin, and you can also give me feedback. Discord: Mr.Kwabs#9751

mattmentrup commented 5 years ago

Question, how does this plugin detects the user's IP when they're routed through a Steam Server (This acts like a VPN)? I made my own implementation a while back and I dropped it because if you banned one person, half the server population has been banned because the users would be routed through the same Steam Server.

DominicTurner02 commented 5 years ago

Question, how does this plugin detects the user's IP when they're routed through a Steam Server (This acts like a VPN)? I made my own implementation a while back and I dropped it because if you banned one person, half the server population has been banned because the users would be routed through the same Steam Server.

It uses the following from the UnturnedPlayer class in Rocket.Unturned.Player:

P2PSessionState_t pConnectionState;
SteamGameServerNetworking.GetP2PSessionState(this.CSteamID, out pConnectionState);
return Parser.getIPFromUInt32(pConnectionState.m_nRemoteIP);

It seems like this gets their individual IP instead by directly asking Steam. As far as I am aware there haven't been any issues of more than the intended person being banned.

mattmentrup commented 5 years ago

Ah, I just opened up my plugin and I swore I just used the ip of the UnturnedPlayer object. Turns out I used the Steam one instead. If you want, I can send you my DB class and you should be able to easily modify it to work with GlobalBans.

If this is of interest, shoot me a message on discord. My handler is Blobby#2142

RainOfPain125 commented 5 years ago

<3