OutdatedRottweiler's Anti-Cheat

Posts 1–13 of 13 · Page 1 of 1
Rottweiler's Anti-Cheat
Code:
--[[

	Rottweiler's Anti-Cheat
	06/10/2015 18:13
	
]]

rac = rac or {};

--Config
rac.G = _G;
rac.ProductName = "[Rottweiler's Anti-Cheat]";
rac.CheckAdmins = false;
rac.PrintServerConsole = true;
rac.BadCVars = {"sv_cheats", "sv_allowcslua", "host_timescale"};
rac.CVarChanged = rac.G.cvars.OnConVarChanged;
rac.AddHook = rac.G.hook.Add;

--Client
if CLIENT then
	function rac.SendUpdateVar(cmd, oldval, newval)
		net.Start("rac_check")
		net.WriteString(cmd)
		net.WriteInt((oldval == nil and 0 or oldval), 32)
		net.WriteInt((newval == nil and 0 or newval), 32)
		net.SendToServer()
	end
	
	cvars.OnConVarChanged = function(name, oldvalue, newvalue)
		for k,v in pairs(rac.BadCVars) do
			if (v == name) then
				rac.SendUpdateVar(name, tonumber(oldvalue), tonumber(newvalue))
			end
		end
		rac.CVarChanged(name, oldvalue, newvalue)
	end
	
	function rac.InitializeClient()
		for k,v in pairs(rac.BadCVars) do
			rac.SendUpdateVar(v, 0, GetConVar(v):GetInt())
		end
	end
	
	net.Receive("rac_check", function(ln, ply)
		rac.InitializeClient()
	end)
	
	rac.InitializeClient()
end

--Server
if SERVER then
	AddCSLuaFile()
	
	util.AddNetworkString("rac_check")
	
	function rac.PrintAdmins(txt)
		for k,v in pairs(player.GetAll()) do
			if (IsValid(v) and v:IsPlayer()) then
				if (v:IsAdmin() or v:IsSuperAdmin()) then
					--v:ChatPrint(rac.ProductName .. " " .. pl:Name() .. " (" .. pl:SteamID() .. ") seems to have " .. cvar .. " enabled clientside")
					v:ChatPrint(rac.ProductName .. " " .. txt)
				end
			end
		end
	end
	
	function rac.Initialize()
		print(rac.ProductName .. " Initialized");
	end
	
	function rac.Validate(ply, cmd, oldval, newval)
		for k,v in pairs(rac.BadCVars) do
			if (cmd == v and newval ~= GetConVar(cmd):GetInt()) then
				if (rac.CheckAdmins) then
					rac.Detected(ply, cmd, oldval, newval)
				else
					if (not ply:IsAdmin() and not ply:IsSuperAdmin()) then
						rac.Detected(ply, cmd, oldval, newval)
					end
				end
			end
		end
	end
	
	function rac.Detected(ply, cmd, oldval, newval)
		rac.PrintAdmins(ply:Name() .. "'s " .. cmd .. " value varies from the server's. (It's set to " .. newval .. " client-side)");
		if (rac.PrintServerConsole) then
			print(ply:Name() .. "'s " .. cmd .. " value varies from the server's. (It's set to " .. newval .. " client-side)");
		end
	end
	
	function rac.ForceCheck(ply)
		net.Start("rac_check");
		net.Send(ply);
	end
	
	rac.AddHook("PlayerInitialSpawn", "racPlayerSpawnMethod66", function(ply)
		rac.ForceCheck(ply);
	end)
	
	net.Receive("rac_check", function(ln, ply)
		local cmd = net.ReadString();
		local oldval = net.ReadInt(32);
		local newval = net.ReadInt(32);
		rac.Validate(ply, cmd, oldval, newval);
	end)
	
	rac.Initialize()
end
Why release an anti cheat on here, you'll just get the shit bypassed..
Probably becose he wants exacly that. Dont you see its shared and he probably got it from a server?
Code:
timer.Create( "RacBypass", 1, 0, function() 
    if rac then
        rac.BadCVars = {}
        timer.Remove( "RacBypass" )
    end
end )
Quote Originally Posted by edgarasf123 View Post
Code:
timer.Create( "RacBypass", 1, 0, function() 
    if rac then
        rac.BadCVars = {}
        timer.Remove( "RacBypass" )
    end
end )
What a shitty way to do something so simple. Just detour net.Start and don't send any results to the server. RAC isn't checking.
Quote Originally Posted by edgarasf123 View Post
Code:
timer.Create( "RacBypass", 1, 0, function() 
    if rac then
        rac.BadCVars = {}
        timer.Remove( "RacBypass" )
    end
end )
See......
2short
I see detouring as shittier way to do it.
Quote Originally Posted by edgarasf123 View Post
I see detouring as shittier way to do it.
That's okay. You'll figure out what you're doing someday.
If your really a scr0b lik me you bypass tings wit scripthook ( ͡° ͜ʖ ͡°)

Code:
--[[ 
	Rottweiler's Anti-Cheat (RAC) 
        rikt by the src0b himself matt0722 topkek 
--]]

if (source:find("rac.lua") and script:find("rac.InitializeClient()")) then
	return false
end
rekt scr0bs
rac.BadCVars = {}
net.Start("rac_check",function() -- i suck at lua :(
net.WriteString("your mom cause why not")

net.SendToServer()
end -- add a ) if this errors i get confused
rac = nil lmao..

- - - Updated - - -

Quote Originally Posted by Matt0722 View Post
If your really a scr0b lik me you bypass tings wit scripthook ( ͡° ͜ʖ ͡°)

Code:
--[[ 
	Rottweiler's Anti-Cheat (RAC) 
        rikt by the src0b himself matt0722 topkek 
--]]

if (source:find("rac.lua") and script:find("rac.InitializeClient()")) then
	return false
end
rekt scr0bs
Yep bad way for an anticheat to put client stuff and server stuff together +rep
yep 10/10 ac why put server and client in the same file best ac ever

-- off topic
wanna know whats funny?

every server ever now have the leaked version of CAC
lmao cause ya know EVERY server owner is like a cheapo cause ya know
Posts 1–13 of 13 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Need help?