CAH2 - Connor Anti-Hack 2.0!

Differences from the last version:
Whitelists!
Hook check!
Detour checks!
DIY plugins!

Features:



	Anti-NoSpread (SeedTrick)
	Anti-CVar Forcer
	Anti-CheatGlobals
	Anti-CheatCVars
	Anti-CheatHooks
	Anti-Detours
	Anti-CheatEngine
	Anti-AntiAim
	FileStealer


Installation:



1. First, make sure you are admin or superadmin.
2. Download CAH2, rename CAH2-master to CAH2, put it in the server's garrysmod/addons folder
3. Set sv_allowcslua to 1, then type this into the console:
  4. lua_run_cl for k,v in pairs(hook.GetTable()["Think"]) do print(tostring(k)) end

5. Open up cl_cah.lua

6. Find CAH_THooks, add everything you saw in console to that table.
  Example:
  
    local CAH_THooks = {
      "stuff",
      "in",
      "console",
    }
    

7. Repeat steps 3-6, replace step 4 hook.GetTable()["Think"] with hook.GetTable()["CreateMove"], add the hooks you see to CAH_CMHooks
8. Repeat steps 3-6, replace step 4 hook.GetTable()["Think"] with hook.GetTable()["HUDPaint"], add the hooks you see to CAH_HPHooks
9. Repeat steps 3-6, replace step 4 hook.GetTable()["Think"] with concommand.GetTable(), add the concommands you see to CAH_W_CMD
10. You're done, congratulations! Make SURE you did steps 7 and 8! If you didn't, everyone will be banned 15 seconds after joining!


Media:

Downloads:
GitHub - Main
GitHub - Compatibility Version (DarkRP, Pointshop, Pointshop 2, etc.)

This should not be used with DarkRP as it may ban innocent people.

If you find a bug, a way to bypass this, feature requests, or just want to comment, just say it!

All this again? :suicide:

It’s redone, check it out.

What makes your anti-cheat better then say LAC or CAC?

Well in his defence, It doesn’t need to be better as it’s free.
Not everyone are willing to pay $10 for LAC or $30 for CAC

https://github.com/cdriza/CAH2/blob/master/lua/cl_cah.lua#L125
now detecting all of the darkrp servers and sandbox servers, which trust their clients.

LAC is $7 and CAC is $14.

You should network the server’s values for the convars clientside and just check if they’re mismatched instead of assuming a value

QAC
[lua]function qac.scan_func()
local s = {}
for i = 0, 1/0, 1 do
local dbg = qac.debug.getinfo(i)
if (dbg) then
s[dbg.short_src] = true
else
break
end
end

for src, _ in qac.pairs(s) do
	if table.HasValue(qac.sources, src) then
		return
	elseif (!(qac.scans[src])) then
		qac.scans[src] = true
		local crc = qac.util.CRC(qac.file.Read(src, "game") or "0") // Currently doesnt work. Send for debug
		qac.validate_src(src, crc)
	end
end

end
[/lua]

CAH2
[lua]local function CAH_CheckSRCS()
local srcs = {}

for i = 0, 1/0, 1 do
	local src = debug.getinfo(i)
	
	if src then
		srcs[src.short_src] = true
	else
		break
	end
end

for src,_ in pairs(srcs) do
	if src == "[C]" or src == "LuaCmd" then
		return
	elseif !CAH_SRC[src] then
		CAH_SRC[src] = "checked"
		net.Start("CAH_CheckSRC")
		net.WriteString(src)
		net.SendToServer()
	end
end

end
[/lua]

Seems like you just copied QAC, then threw in some extra ConVar checking.

What is up with the creators of every single anti-cheat always copying code from other anticheats?

  1. that’s not pasted from qac
  2. this has a bit more than just cvar checking
  3. i love you

I’ll do this in 2.1, thanks for the recommendation!

[editline]May 14th, 7:19 PM[/editline]
Nobodies commented on the UniqueKey amazing things?

[editline]15th May 2015[/editline]

  1. You can’t compare it to a completely serverside anticheat
  2. I never said it’s better than CAC, that’s paid anway.

Then where did you get the variable name short_src?

Please stop releasing things

I didn’t.

It’s debug.getinfo(func/num).short_src

Try it, PrintTable(debug.getinfo(print))

It’s a predefined variable in debug.getinfo

I guess i could use .source

Does this make you feel better?

Those two pieces of code obviously are 100% unique. Not like they both match this exact pattern.



for i = 0, 1/0, 1 do
	local ... = debug.getinfo(i)

	if ... then
		...[X.short_src] = true
	else
		break
	end
end

for src, _ in ...(srcs) do
	if anticheat developer is too lazy to test this file name then
		return
	elseif !...[src]
		network shit
	end
end


What the fuck is wrong with you people?

Use math.huge you barbarians.

+correct

I don’t get it, why is everyone aganist him? His releasing it for free unlike ths other ones. Am I missing something?

I don’t understand how you can read the thread and see people going against him, and at the same time, not know why.

net.Receivers[“CAH_Bypass”] = function() print(“nope”) end
net.Receivers[“CAH_CheckSRC”] = function() print(“nope”) end