سرور مجازی خود را امن و بهینه کنید - secure vps

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

- بررسی 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

آیا این پاسخ مفید بود؟

 چاپ این مقاله

خوانده شده

آموزش نصب IonCube در ssh

تغییر دایرکتوری cd /usr/local دانلود ورژن دلخواه از PHP Encoder,...

QSpeed اسکریپت چند برابر کننده ی سرعت سرور

وبسرور / مای اسکیو ال و پی اچ پی رو optimize می کند گفتم در اختیار دوستان هم بزارم : برای سیستم...

هاست دانلود چیست؟ - what is host download

هاست مخصوص دانلود سرویسی است که در الماس هاستینگ روی سرور های لینوکس ایجاد می شود، این سرویس...

تهیه backup و Restore آن به وسیله SSH

  در این پست شما یاد خواهید گرفت که چگونه در کنترل پنل قدرتمند Cpanel بتوانید به وسیله دستورات...

یافتن پوشه های 777 با SSH

برای یافتن فایل های 777 بر روی سرور از دستور زیر استفاده کنید. find adress -perm 777 و برای...