با سلام اینم از آموزش نصب و کانفیگ CXS برای اولین بار ابتدا خرید لایسنس از لینک ConfigServer eXploit Scanner License جهت نصب آنتی شلرپس از نصب در ssh دستورات زیر را دنبال کنید ابتدا mod_security را روی سرور نصب کنید سپس با دستور زیر یه پوشه قرنطینه میسازیمکد:wget http://www.configserver.com/free/cxsinstaller.tgz tar -xzf cxsinstaller.tgz perl cxsinstaller.pl rm -fv cxsinstaller.*سپس دستورکد:mkdir /home/quarantine/ chmod 1777 /home/quarantine/موارد زیر را داخلش قرار بدیدکد:nano /usr/local/apache/conf/modsec2.user.confبالای خطوط اصلی بذارید بهتره ریستارت آپاچیکد:SecRequestBodyAccess On SecRule FILES_TMPNAMES "@inspectFile /etc/cxs/cxscgi.sh" \ "log,auditlog,deny,severity:2,id:'1010101'سپس فایلکد:/scripts/restartsrv_httpdو بعد از خط آخر بذاریدکد:nano /etc/cxs/cxscgi.shمیتونید این کار رو انجام هم ندید برید داخل whm و ConfigServer Explorer و برید به /etc/cxs و پرمیشنهای زیر رو به ترتیب تنظیم کنیدکد:/usr/sbin/cxs --quiet --cgi --qoptions Mv --mail root \ --quarantine /home/quarantine/ "$1"سپسکد:cxs.xtra 644 cxs.defaults 644 cxs.ignore 644 cxscgi.sh 755 cxsftp.sh 755و از پشت SecRuleEngine On علامت # بردارید حالا برید به whm و ConfigServer eXploit Scanner و بعد Generate Cxs Commands تیک اولین گزینه ی All cPanel users رو بزنید تیک public_html scan بزنید و تیکهای Report file Log file Email جلوی Email تو کادر آدرس ایمیلی که میخواید ریپورت بیاد براشو بزنید و تیک SMTP Exploit scan (L) symlink (O) socket (f) suspicious file name/type (M) fingerprint match (S) SUID file (G) GUID file (c) core dump file (Z) scan within zip, tar, tar.gz and tar.bz2 files (h) suspected exploit file (d) suspicious directory name (n) hidden directory owned by nobody (w) world writable directory Virus scan (f) suspicious file name/type (h) suspected exploit file (T) all PHP, Perl, and other script files (m) regex pattern match Ignore file Xtra file Quarantine Directory و در قسمت Quarantine Options (S) SUID file (G) GUID file (h) suspected exploit file (c) core dump file (T) all PHP, Perl, and other script files (E) all email scripts (M) fingerprint match (v) virus (f) suspicious file name/type Show statistics summary و بعد Save as default رو بزنید دوباره برگردید به Generate Cxs Commands و سپس پایین صفحه کنار Save as default روی Create Cron job کلیک کنید و یه کرون بسازید و بعد برید صفحه ی اول Start Cxs Watchکد:nano /usr/local/apache/conf/modsec2.confدر آخرین خط بزنیدکد:nano /etc/cxs/cxsftp.sh/usr/sbin/cxs -Z –ftp –mail root –qopt Mv -I /etc/cxs/cxs.ignore -Q /home/quarantine “$1”در آخرین خط بزنیدکد:nano /etc/cxs/cxscgi.sh/usr/sbin/cxs -Z –cgi –mail root –qopt Mv -I /etc/cxs/cxs.ignore -Q /home/quarantine “$1”کد:nano /etc/cxs/cxswatch.sh/usr/sbin/cxs –Wstart –mail root -Q /home/quarantine -I /etc/cxs/cxs.ignore –qopt Mv –www –all
