-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4b2ab10
commit 2be0484
Showing
14 changed files
with
139 additions
and
64 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# Ban functionality | ||
|
||
This page outlines the various methods players can be banned. Currently, it's only possible to appeal | ||
a steam ban. The rest are considered effectively permanent. | ||
|
||
## Steam Bans | ||
|
||
The standard ban usecase, banning by steam ID. Note the 2 special options for `Include Friends` and `IP Evading Allowed`. | ||
|
||
If include friends is enabled, then all the ban recipients friends will also be banned. Friends do not receive a entry | ||
in the ban table however, and are automatically allowed back once the parents ban is completed. The list of friends is only | ||
updated periodically, so you may have to wait several hours for the changes to take effect and existing banned friends get | ||
flushed. | ||
|
||
IP evasion option allows users to connect from the same ip as a currently banned user. When not enabled, users | ||
are automatically banned for `evasion` and their ban lengths are changed to permanent. If you want a banned users "brother" | ||
to be able to play, then be sure to enable this. | ||
|
||
This type of ban is the only one that allows `muting` players. | ||
|
||
## CIDR bans | ||
|
||
Similar to steam bans, except they also match against a [cidr](https://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) range. | ||
|
||
For example, to ban a user and his entire network block, you could ban `50.60.70.0/24`. This would ban anyone connecting | ||
from `50.60.70.0 - 50.60.70.255`. | ||
|
||
## ASN Bans | ||
|
||
[ANS](https://en.wikipedia.org/wiki/Autonomous_system_(Internet)) bans are probably the least used option. They should | ||
be used with care as they can be too broad in what they ban if you are not careful. If a user connects with a range that | ||
the banned ASN owns, the user will be kicked. | ||
|
||
|
||
## Steam Group Bans | ||
|
||
Ban all members of a particular steam group from connecting. | ||
|
||
You can find a groups GID by opening the memberslist directly. You can achieve this by appending `/memberslistxml/?xml=1` | ||
to the url of the steam group. You should end up with something like: | ||
|
||
https://steamcommunity.com/groups/valve/memberslistxml/?xml=1 | ||
|
||
Inside here, at the top, you should see the group ID you can use for banning: | ||
|
||
```xml | ||
<groupID64>103582791429521412</groupID64> | ||
``` | ||
|
||
Similar to the friends list bans, these are also updated periodically. Any changes may take a few hours to flush | ||
through the system. | ||
|
||
Valve does not like hitting the memberslist endpoint that often without getting rate limited. Currently there is no | ||
protections for this, so its advised to not add too many entries for now. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Moderation | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# Sourcemod Plugin | ||
|
||
This covers functionality available through the gbans plugin as well as some recommended configuration options. | ||
|
||
## In-Game Commands | ||
|
||
| Command | Perms | Description | | ||
|------------|--------------|--------------------------------------------------------------------------------------------------------------------------------------------| | ||
| gb_mod | | Sends a notification to discord (if its enabled) to the users belonging to the group configured in the "mod ping role id" discord setting. | | ||
| gb_ban | ADMFLAG_BAN | Ban a user using in-game menu. | | ||
| gb_reload | ADMFLAG_ROOT | Reinitializes some parts of the plugin such as authentication password. | | ||
| gb_version | | Shows the current plugin version. | | ||
| report | | Report a user. | | ||
|
||
## Convars | ||
|
||
| convar | default value | Description | | ||
|----------------------|--------------------|---------------------------------------------------------| | ||
| gb_core_host | localhost | Address gbans is listening on | | ||
| gb_core_port | 6006 | Port gbans is listening on | | ||
| gb_core_server_key | '' | Password generated by gbans to authenticate the server. | | ||
| gb_disable_autoteam | 1 | Disallow the use of the autoteam command | | ||
| gb_hide_connections | 1 | Dont show the connect/disconnect message to users | | ||
| gb_stv_enable | 1 | Enable SourceTV | | ||
| gb_auto_record | 1 | Enable automatic recording | | ||
| gb_stv_minplayers | 1 | Minimum players on server to start recording | | ||
| gb_stv_ignorebots | 1 | Ignore bots in the player count | | ||
| gb_stv_timestart | -1 | Hour in the day to start recording (0-23, -1 disables) | | ||
| gb_stv_timestop | -1 | Hour in the day to stop recording (0-23, -1 disables) | | ||
| gb_stv_finishmap | 1 | If 1, continue recording until the map ends | | ||
| gb_stv_path | stv_demos/active | Path to store currently recording demos | | ||
| gb_stv_path_complete | stv_demos/complete | Path to store complete demos | | ||
|
||
## Creating a sourcemod database user | ||
|
||
It's recommended to create a secondary less-privileged user, especially when using servers remote of the | ||
gbans instance. Below is an example of creating a restricted user that only has access to the tables, and functions, required | ||
for operation. | ||
|
||
```postgresql | ||
CREATE ROLE sourcemod WITH LOGIN PASSWORD '<new-password>'; | ||
GRANT CONNECT ON DATABASE gbans TO sourcemod; | ||
GRANT USAGE ON SCHEMA public TO sourcemod ; | ||
GRANT SELECT ON | ||
sm_config, sm_overrides, sm_group_overrides, sm_group_immunity, sm_groups, | ||
sm_admins_groups, sm_admins TO sourcemod; | ||
GRANT SELECT, INSERT, UPDATE, DELETE ON sm_cookie_cache, sm_cookies TO sourcemod; | ||
GRANT EXECUTE ON FUNCTION check_ban TO sourcemod; | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# Stats Overview | ||
|
||
Stats are generated for many game events. They are summarized into atomic matches and stores in the database. The | ||
design goal is to have a cross between [logs.tf](https://logs.tf) | ||
and [hlstatsx:ce](https://github.com/A1mDev/hlstatsx-community-edition). | ||
|
||
## Compared with hlstatsx:ce | ||
|
||
- Simpler deployments, single monolithic binary. | ||
- Considerably better scaling performance | ||
- Matches are committed to the database in a single transaction instead of immediately upon incoming events | ||
- Long term tracking of who killed who is not available currently | ||
|
||
## General Info | ||
|
||
- Ignores showing stats from players in the match < 60 seconds | ||
- Matches that dont have a minimum amount of players are discarded | ||
- Matches are | ||
|
||
## How stats are generated (new, WIP) | ||
|
||
1. gbans checks for new demos. | ||
2. If a demo exists, download it locally or stop. | ||
3. Demo is uploaded to the [parsing service](https://github.com/leighmacdonald/tf2_demostats) (avail soon). | ||
4. Results are inserted into the database. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters