Git Product home page Git Product logo

c0nw0nk / garrys-mod-family-sharing Goto Github PK

View Code? Open in Web Editor NEW
34.0 8.0 12.0 53 KB

Prevent players bypassing existing bans on Garrys Mod Servers via steam family sharing / shared accounts or buying a new GMod. Banned messages and banning lengths configurable with lots of extra useful custom features such as a ban tracker / tracking. This script is guaranteed to make players regret receiving a ban from your server in GarrysMod / GarryMod / Garry'sMod / Garry's Mod / G Mod / G-Mod familysharing alts / alternative are a thing of the past. familysharing / familyshared checks / checker / checked / checking. lua script addon addons

Home Page: http://www.networkflare.com/

License: Other

Lua 100.00%
family-sharing familysharing ban bypass steam garrysmod ulx garrys-mod free ulysses

garrys-mod-family-sharing's Introduction

garrys-mod-family-sharing's People

Contributors

c0nw0nk avatar matt-compsci avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

garrys-mod-family-sharing's Issues

Lua error

[ERROR] lua/autorun/familysharing.lua:264: FamilySharing: Invalid Steam API response for 0 | steamid

  1. error - [C]:-1
  2. onsuccess - lua/autorun/familysharing.lua:264
    3. unknown - lua/includes/modules/http.lua:35

TODO : IP Address Unban compatibility

Posting this as a todo issue for myself for another time.

Based of my following solution that allows both family shared and the account that is the owner of that shared accounts games to be unbanned at the same time. #2 (comment)

When IP Ban setting is enabled, To allow IP addresses to be unbanned add / modify the offence on banhook via

RunConsoleCommand("ulx", "banid", lenderSteamID, time, offence .. "| IP:1.2.3.4")

Do regex check $ for end of offence reason where matched | IP:.*$

And on unban hook get the IP if exists from offence reason to unban their IP too.

if ply:query(string.lower(commandName)) and string.lower(commandName) == "ulx unban" then
--do stuff if global ipban setting enabled then allow users to also have their ip's removed from banlist if found
--pull the IP from the ban reason on the matching STEAMID
RunConsoleCommand("removeip 1.2.3.4")
RunConsoleCommand("writeip")
end

Not working

Is this right?
[ERROR] lua/autorun/familysharing.lua:166: FamilySharing: Failed API call for
(Error: unsuccessful)

  1. error - [C]:-1
  2. onfailure - lua/autorun/familysharing.lua:166
    3. unknown - lua/includes/modules/http.lua:42

I have seen users with shared account that has been banned on their main.

enormous security flaw

Hey so some guy on my friends list just sent this to me for unrelated reasons and I noticed that it's a shared file, and you're asking the server owner to put their steam API key near the top of the file.

This means that anyone who connects to the server will download a copy of the file containing the steam API key, so they can simply open the file, and find the API key.
You should really put this in a different file which is serverside only.

Also you should probably stop making all the config variables global, because if some other mod happens to make global variables with the same name, it'll break your entire addon (See #6 )

Banip is overriding the ban messages and another thing

So, the ban script works pretty well, but I've had to disable the banIP setting because of a glaring issue. When a user is banned from the game, whether that be a day ban or a permanent, it always says the same message: "Disconnect: added to the banned list". I don't know if that was intentional but I do not want that to be the ban screen of all users that are banned because it isn't very informative and most importantly, it doesn't give the link to our website in case if their ban was false and they need to dispute it. I understand that that reason "added to the banned list" is what happens when you get IP banned but is there a way you could delay it so first it bans the acc/ID so the ban screen we made for them can be viewed then the IP ban is taken into effect because I do want the IP ban setting on, it helps with keeping the alts away but I don't want it at the cost of the custom ban screen.

Also, I'd just like some clarification on how the unbanning of an account when IP ban is enabled because sometimes I have to unban the IP too since it doesn't unban immediately when I run ulx unban (id).

Thanks for reading.

[bug] Invalid Steam API Response

Getting this error in console when players join the server:

[anti_family_sharing] addons/anti_family_sharing/lua/autorun/server/sv_familysharing.lua:146: FamilySharing: Invalid Steam API response for rat when it sees sugar reward: | STEAM_0:1:30918607
  1. error - [C]:-1
   2. onsuccess - addons/anti_family_sharing/lua/autorun/server/sv_familysharing.lua:146
    3. unknown - lua/includes/modules/http.lua:29
[anti_family_sharing] addons/anti_family_sharing/lua/autorun/server/sv_familysharing.lua:146: FamilySharing: Invalid Steam API response for rat when it sees sugar reward: | STEAM_0:1:30918607
  1. error - [C]:-1
   2. onsuccess - addons/anti_family_sharing/lua/autorun/server/sv_familysharing.lua:146
    3. unknown - lua/includes/modules/http.lua:29

I am using the most recent version of the addon (installed yesterday). Here are my config settings:

SteamFamilySharing.APIKey = "<redacted (double checked)>"

SteamFamilySharing.kickmessage = "The account that lent you Garry's Mod is banned on this server"

SteamFamilySharing.banbypass = true

SteamFamilySharing.banlength = 0

SteamFamilySharing.banreason = "attempting to bypass a current/existing ban."

SteamFamilySharing.banip = true

SteamFamilySharing.blockfamilysharing = true

SteamFamilySharing.blockfamilysharingmessage = "Please connect to the server by a account that own's Garry's Mod."

SteamFamilySharing.extra_ban_checks = true

SteamFamilySharing.informative_ban_message = true

SteamFamilySharing.custom_ban_message = "You're banned!"

SteamFamilySharing.storage_path = "materials/"
SteamFamilySharing.file_type = ".vtf"
SteamFamilySharing.file_name = "car_as14"

local ban_tracker = true

Logs

Where can i find the logs of
--Log to server console who has been detected family sharing.
print(string.format("FamilySharing: %s | %s has been lent Garry's Mod by %s",
I can't find it in ulx-logs
I did not have logs enabled in commandline.

Question

Wouldn't having all the setting variables be global cause issues?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.