|
|
|||||||
กล่าวนำ
Bastille เป็นโปรแกรมที่ช่วยเสริมสร้างความแข็งแกร่ง (hardening) ให้กับระบบปฏิบัติการ
Red Hat Linux, Debian Linux, Mandrake Linux และ HP-UX โดย Bastille สามารถทำงานได้ใน
2 โหมด ดังต่อไปนี้
การติดตั้ง Bastille
# rpm -ivh Bastille-2.0.4-1.0.i386.rpm
# rpm -ivh perl-Tk.x.x.x.rpm
# rpm -ivh perl-Curses.x.x.x.rpm
ขั้นตอนการใช้งาน Bastille
คำแนะนำอื่นๆ
Bastille Modules
ข้อมูลดังต่อไปนี้ เป็นตัวอย่างคำถามในการรัน Bastille เวอร์ชัน 2.0.4-1.0 บน Red
Hat Linux 8.0 (ค่าที่อยู่ในเครื่องหมาย []
เป็นคำตอบที่เป็น default ของคำถามนั้นๆ)
Module: File Permissions
Q: Would you like to set more restrictive permissions on the administration utilities (linuxconf, fsck, ifconfig, runlevel and portmap) ? [N]
Q: Would you like to disable SUID status for mount/umount? [Y]
Q: Would you like to disable SUID status for ping? [Y]
Q: Would you like to disable SUID status for at? [Y]
Q: Would you like to disable the r-tools? [Y]
Q: Would you like to disable the r-tools (rsh/remsh, rcp, rlogin, rdist, etc.)? [Y]
Q: Would you like to disable SUID status for usernetctl? [Y]
Q: Would you like to disable SUID status for traceroute? [Y]
Module: ACCOUNT SECURITY
Q: Should Bastille disable clear-text r-protocols that use IP-based authentication? [Y]
Q: Would you like to enforce password aging? [Y] (ถ้าตอบ yes จะตั้งเป็น 180 วัน)
Q: Would you like to restrict the use of cron to administrative accounts? [Y]
Q: Do you want to set a default umask? [Y]
Q: What umask would you like to set for users on the system? [077] (สามารถเลือกได้ตั้งแต่ 002, 022, 027, 077
Q: Should we disallow root login on tty's 1-6? [N]
Module: Boot Security
Q: Would you like to password-protect the GRUB prompt? [N]
Q: Would you like to disable CTRL-ALT-DELETE rebooting? [N]
Q: Would you like to password protect single-user mode? [Y]Module: Secure Inetd Module
Q: Would you like to set a default-deny on TCP Wrappers and xinetd? [N]
Q: Should Bastille ensure the telnet service does not run on this system? [Y]
Q: Should Bastille ensure the FTP service does not run on this system? [Y]
Q: Would you like to display "Authorized Use" messages at log-in time? [Y]
Q: Who is responsible for granting authorization to use this machine? (ให้ใส่ชื่อผู้รับผิดชอบเครื่องนี้ หรือชื่อหน่วยงาน)Module: Disable User Tools
Q: Would you like to disable the gcc compiler? [N]Module: Configure Misc PAM
Q: Would you like to put limits on system resource usage? [N]
Q: Should we restrict console access to a small group of user accounts? [N]
Q: Which accounts should be able to login at console? [root]Module: Logging
Q: Would you like to add additional logging? [Y]
หากตอบ Yes โปรแกรมจะทำการแก้ไข /etc/syslog.conf ดังนี้############ BASTILLE ADDITIONS BELOW : #################
# Log warning and errors to the new file /var/log/syslog
*.warn;*.err /var/log/syslog# Log all kernel messages to the new file /var/log/kernel
kern.* /var/log/kernel# Log all logins to /var/log/loginlog
auth.*;user.*;daemon.none /var/log/loginlog# Log additional data to the Alt-F7 and Alt-F8 screens (Pseudo TTY 7 and 8)
*.info;mail.none;authpriv.none /dev/tty7
authpriv.* /dev/tty7
*.warn;*.err /dev/tty7
kern.* /dev/tty7
mail.* /dev/tty8*.* /dev/tty12
########## BASTILLE ADDITIONS CONCLUDED : ###############Q: Do you have a remote logging host? [N]
Module: Miscellaneous Daemons
Q: Would you like to deactivate NIS server programs? [Y]Module: Sendmail
Q: Do you want to stop sendmail from running in daemon mode? [Y]
Q: Would you like to run sendmail via cron to process the queue? [N]Module: DNS
Q: Would you like to chroot named and set it to run as a non-root user? [N]Module: Apache
Q: Would you like to bind the web server to listen only to the localhost? [N]
Q: Would you like to bind the web server to a particular interface? [N]
Q: Would you like to deactivate the following of symbolic links? [Y]
Q: Would you like to deactivate server-side includes? [Y]
Q: Would you like to disable CGI scripts, at least for now? [Y]
Q: Would you like to disable indexes? [N]Module: Printing
Q: Would you like to disable printing? [N]
Module: TMPDIR
Q: Would you like to install TMPDIR/TMP scripts? [N]Module: Firewall
Q: Would you like to run the packet filtering script? [N]
Q: Are you finished answering the questions, i.e. may we make the changes?หลังจากการรัน Bastille แล้ว ผู้ดูแลระบบควรรีสตาร์ทเครื่องคอมพิวเตอร์ เพื่อให้การแก้ไขทั้งหมดมีผลในทันที (การแก้ไขบางอย่างมีผลในทันทีโดยไม่ต้องรีสตาร์ทเครื่องคอมพิวเตอร์)
Removing Bastille
ไฟล์สำคัญที่เกี่ยวข้อง
Description Filename Configuration file /etc/Bastille/config Error log /var/log/Bastille/error-log Action log /var/log/Bastille/action-log TODO /var/log/Bastille/TODO Revert actions script /var/log/Bastille/revert/revert-actions
เอกสารอ้างอิง
| Home
|| เอกสารเผยแพร่ || Unix & Linux
ThaiCERT Disclaimer | Copyright © 2001 ThaiCERT(NECTEC). All rights reserved. |