سرور مجازی خود را امن و بهینه کنید پرینت

  • یاسر هاست, سرور مجازی, امن کردن سرور
  • 407

با انجام روش های درج شده میتوانید تا حد مطلوبی سرور مجازی خود را امن و بهینه کنید.

- بررسی formmail : form mail ها که مورد استفاده هکر ها قرار میگیرد و اقدام به ارسال ایمیل های اسپم به وسیله متدهای relay و injection میکنند.

با دستور زیر میتوانید فرم ایمیل های مزاحم را پیدا کنید:

find / -name “[Ff]orm[mM]ai*”

CGIemail یک ریسک امنیتی است :

find / -name “[Cc]giemai*”

طریقه غیر فعال کردن form mail :

chmod a-rwx /path/to/filename

(a-rwx به معنای آن است که همه نوع نه خواندی نه نوشنی و نه قابل اجرا)

Root kit Checker (rkhunter or chkrootkit)

بررسی root kits به وسیله cronjob . (به شما اخطار خواهد داد)

cd /root/

wget ftp://ftp.pangeia.com.br/pub/seg/pac/chkrootkit.tar.gz
tar xvzf chkrootkit.tar.gz
cd chkrootkit-0.47
make sense

اجرای برنامه:

/root/chkrootkit-0.47/chkrootkit

هرکس که با کاربر ریشه به سرور وارد شد به ادمین ایمیل خواهد داد

cd /root

nano .bash_profile
echo ‘ALERT – Root Shell Access on:’ `date` `who` | mail -s “Alert: Root Access from `who | awk ‘{print $6}’`” your@email.com

جهت ذخیره سازی ctrl+x را بزنید.

Cpanel / WHM را امن نمایید

Go to: Server Setup -> Tweak Settings

Under Domains tick:
· Prevent users from parking/adding common internet domains (hotmail.com, aol.com, etc)

Under Mail tick:
· Attempt to prevent pop3 connection floods
· Default catch-all/default address behavior for new accounts – set this to FAIL

Under System tick:
· Use jailshell as default on new accounts

Go to: Server Setup -> Tweak Security
· Enable php open_basedir protection
· Enable mod_userdir protection
· Disable compilers for unprivileged users

Go to: Server Setup -> Shell Fork Bomb Protection
· Enable shell bomb/memory protection

When creating reseller packages, be sure to:
· Disallow creation of packages with shell acces
· Disallow creation of packages with full root access

Go to: Service Configuration -> FTP Configuration
· Disable anonymous FTP access

Go to: Account functions -> Manage Shell Acess
· Disable shell access for all users (except yourself)

Go to: MySQL -> Manage Root Password
· Change Root Password for MySQL

سیستم عامل و نرم افزار هارا بروز نمایید:

اگر از سی پنل استفاده میکنید:

/scripts/upcp
/scripts/easyapache

اگر از سی پنل استفاده نمیکنید:

yum upgrade

 

آیا این پاسخ به شما کمک کرد؟

« برگشت