ipban.sh:
where fs_homepath for example: root/cod2Code:#!/bin/sh #Add ./ipban.sh to Scheduler every one minute(*/1) iptables -D INPUT -j IPBAN iptables -F IPBAN iptables -X IPBAN iptables -N IPBAN iptables -A INPUT -j IPBAN cat fs_homepath/banip.txt | xargs -I {IP} iptables -A IPBAN -s {IP} -j DROP
when give ban:
or SELECT banips in DataBase to array every new map - Callback_StartGameType()Code:filename = getCvar("fs_homepath")+"/banip.txt"; file = fopen(filename, "w"); fwrite(file,self getIP()+"\n"); fclose(file);
array add to banip.txt
before write to .txt need delete .txt:
This way full ban to status server/ispmanager/shell/root/url... and etc.Code:system("rm -rf getCvar("fs_homepath")+"/banip.txt");//delete file
many ideas



Reply With Quote