Skip to content
Permalink
Browse files

Updated to version 0.8.6.5

Signed-off-by: Mr.Silence <Silenci0@users.noreply.github.com>
  • Loading branch information...
Silenci0 committed Jul 26, 2019
1 parent 2c0297f commit 7f99875bca961492311af809b9fc87a473f5ebd3
@@ -1,13 +1,21 @@
# SMAC
Sourcemod Anti-Cheat

For a lot of people, SMAC has been one of those more elusive plugins due to some of the issues surrounding it involving copyrights and headers. In 0.8.6.0, the original authors added the headers to it and left it at that. During that time, I was working on my own fork of it specifically for ZPS. So not only does the code have all the appropriate headers, but included is a license with those headers as well, so it should be okay to distribute, post, branch, and fork once again as needed provided everyone adheres to the license.
For a lot of people, SMAC has been one of those more elusive plugins due to some of the issues surrounding it involving copyrights and headers. In 0.8.6.0, the original authors added the headers to it and left it at that. During that time, I was working on my own fork of it specifically for ZPS which evolved from there into the current fork that is seen today. So not only does the code have all the appropriate headers, but included is a license with those headers as well, so it should be okay to distribute, post, branch, and fork once again as needed provided everyone adheres to the license.

Although progress is a bit slow, I do hope to add more features and update detections for various aimbots/hacks over the next few iterations. My hope is to return SMAC to active development as a free, open source project for multiple source-based games. Not sure how well that will go, but I'll give it a shot.
Although progress is a bit slow, I do hope to add more features and update detections for various aimbots/hacks over the next few iterations. My hope is to return SMAC to active development as a free, open source project for multiple source-based games. Not sure how well that will go, but I'll give it a shot. Also, if you want to help contribute to the plugin, please feel free to issue pull requests and contribute if you'd like.

For information about the plugin and its modules, please use the wiki here: https://github.com/Silenci0/SMAC/wiki

# Changelog
0.8.6.5 Update (07-26-2019)
-----------------
- Updated the smac_commands.smx module:
* Added the command snd_setsoundparam to the CS:GO ignore commands list in the code. While this command was removed from CS:GO on 05/29/2019, it seems that it has been getting randomly spammed and causing users to be kicked. This issue was brought up in https://github.com/Silenci0/SMAC/issues/8
* Please note that you can add commands to block or ignore via plugin commands from smac_commands.smx independently. Please see this wiki page for details: https://github.com/Silenci0/SMAC/wiki/Command-Monitor
* Added new convar smac_anticmdspam_kick. This toggles the ability to kick users for command spam (which is set as the default response) or to simply notify when someone is spamming.
* Updated smac.cfg with new cvars and recompiled all smac plugins to reflect updated version.

0.8.6.4 Update (05-07-2019)
-----------------
- Fixed a couple of issues related to tickcount with the smac_eyetest module that was causing false positives to occur in TF2 and CS:GO (someone might want to confirm for CS:GO):
BIN +0 Bytes (100%) addons/sourcemod/plugins/smac.smx
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -25,7 +25,7 @@
#include <smac_stocks>

/* Globals */
#define SMAC_VERSION "0.8.6.4"
#define SMAC_VERSION "0.8.6.5"
#define SMAC_URL "https://github.com/Silenci0/SMAC"
#define SMAC_AUTHOR "SMAC Development Team (original), Mr. Silence (updated)"
#define SMAC_MOD_ERROR "This module will not work for this mod and should be removed."
@@ -46,6 +46,7 @@ new Handle:g_hIgnoredCmds = INVALID_HANDLE;
new g_iCmdSpamLimit = 30;
new g_iCmdCount[MAXPLAYERS+1] = {0, ...};
new Handle:g_hCvarCmdSpam = INVALID_HANDLE;
new Handle:g_hCvarCmdSpmKick = INVALID_HANDLE;

/* Plugin Functions */
public OnPluginStart()
@@ -54,6 +55,7 @@ public OnPluginStart()

// Convars.
g_hCvarCmdSpam = SMAC_CreateConVar("smac_antispam_cmds", "20", "Amount of commands allowed per second. (0 = Disabled)", 0, true, 0.0);
g_hCvarCmdSpmKick = SMAC_CreateConVar("smac_anticmdspam_kick", "1", "Choose to kick or simply notify that commands are being spammed. (0 = Notify 1 = Kick)", 0, true, 0.0, true, 1.0);
OnSettingsChanged(g_hCvarCmdSpam, "", "");
HookConVarChange(g_hCvarCmdSpam, OnSettingsChanged);

@@ -160,6 +162,10 @@ public OnPluginStart()
SetTrieValue(g_hIgnoredCmds, "bitcmd", true);
SetTrieValue(g_hIgnoredCmds, "sg", true);
}
case Game_CSGO:
{
SetTrieValue(g_hIgnoredCmds, "snd_setsoundparam", true);
}
}

// Add commands to ignore list.
@@ -324,16 +330,22 @@ public Action:Command_Say(client, const String:command[], args)
public Action:Command_BlockEntExploit(client, const String:command[], args)
{
if (!IS_CLIENT(client))
{
return Plugin_Continue;
}

if (!IsClientInGame(client))
{
return Plugin_Stop;
}

decl String:sArgString[512];

if (GetCmdArgString(sArgString, sizeof(sArgString)) > 500)
{
return Plugin_Stop;

}

if (StrContains(sArgString, "admin") != -1 ||
StrContains(sArgString, "alias", false) != -1 ||
StrContains(sArgString, "logic_auto") != -1 ||
@@ -370,11 +382,15 @@ public Action:Command_BlockEntExploit(client, const String:command[], args)
public Action:Command_CommandListener(client, const String:command[], argc)
{
if (!IS_CLIENT(client) || (IsClientConnected(client) && IsFakeClient(client)))
{
return Plugin_Continue;

}

if (!IsClientInGame(client))
{
return Plugin_Stop;

}

// NOTE: InternalDispatch automatically lower cases "command".
new ActionType:cAction = Action_Block;

@@ -404,6 +420,10 @@ public Action:Command_CommandListener(client, const String:command[], argc)
SMAC_LogAction(client, "was kicked for command: %s %s", command, sArgString);
KickClient(client, "Command %s violation", command);
}
else
{
// Do Nothing
}
}

CloseHandle(info);
@@ -423,13 +443,25 @@ public Action:Command_CommandListener(client, const String:command[], argc)

if (SMAC_CheatDetected(client, Detection_CommandSpamming, info) == Plugin_Continue)
{
SMAC_PrintAdminNotice("%N was kicked for spamming: %s %s", client, command, sArgString);
SMAC_LogAction(client, "was kicked for spamming: %s %s", command, sArgString);
KickClient(client, "%t", "SMAC_CommandSpamKick");
if (GetConVarInt(g_hCvarCmdSpmKick) == 1)
{
SMAC_PrintAdminNotice("%N was kicked for spamming: %s %s", client, command, sArgString);
SMAC_LogAction(client, "was kicked for spamming: %s %s", command, sArgString);
KickClient(client, "%t", "SMAC_CommandSpamKick");
}
else if (GetConVarInt(g_hCvarCmdSpmKick) == 0)
{
SMAC_PrintAdminNotice("%N looks to be spamming commands: %s %s", client, command, sArgString);
SMAC_LogAction(client, "looks to be spamming commands: %s %s", command, sArgString);
}
else
{
// Do Nothing
}
}

CloseHandle(info);

return Plugin_Stop;
}

@@ -1,4 +1,4 @@
// This file was auto-generated by SourceMod (v1.6.3)
// This file was auto-generated by SourceMod (v1.9.0.6280)
// ConVars for plugin "smac.smx"

// [smac_aimbot.smx] Number of aimbot detections before a player is banned. Minimum allowed is 4. (0 = Never ban)
@@ -13,6 +13,13 @@ smac_aimbot_ban "6"
// Minimum: "0.000000"
smac_antispam_cmds "20"

// [smac_commands.smx] Choose to kick or simply notify that commands are being spammed. (0 = Notify 1 = Kick)
// -
// Default: "1"
// Minimum: "0.000000"
// Maximum: "1.000000"
smac_anticmdspam_kick "1"

// [smac_client.smx] Block reconnection attempts for X seconds. (0 = Disabled)
// -
// Default: "2"
@@ -25,6 +32,20 @@ smac_antispam_connect "2"
// Minimum: "0.000000"
smac_ban_duration "0"

// [smac_eyetest.smx] Automatically ban players on eye test detections.
// -
// Default: "0"
// Minimum: "0.000000"
// Maximum: "1.000000"
smac_eyetest_ban "0"

// [smac_eyetest.smx] Enable compatibility mode with third-party plugins. This will disable some detection methods.
// -
// Default: "1"
// Minimum: "0.000000"
// Maximum: "1.000000"
smac_eyetest_compat "1"

// Include extra information about a client being logged.
// -
// Default: "0"
@@ -45,9 +66,3 @@ smac_validate_auth "0"
// Minimum: "0.000000"
// Maximum: "1.000000"
smac_welcomemsg "0"

///////////////////////////////
// SMAC block commands list //
///////////////////////////////
//smac_addcmd "sm_entcontrol_distance_up" 1
//smac_addcmd "sm_entcontrol_distance_down" 1

0 comments on commit 7f99875

Please sign in to comment.
You can’t perform that action at this time.