Download Advanced Information Assurance Handbook
Transcript
configuration file, syslog.conf, is also set up with default settings to log certain messages to the console, users, and/or log files. In Linux, logs are sent to various files in the /var/log directory, but the files can be created in other directories, preferably ones owned by “root.” Syslogd is designed to support both local and remote logging. Syslogd will listen on a UNIX domain socket as well as on the standard syslog port 514 UDP.59 The UNIX domain socket connection listens for locally generated logs. The UDP 514 connection tries to connect to the remote log server. Syslogd will make 10 attempts to resolve the log server’s hostname. If the domain name server starts up after syslogd’s tenth attempt to resolve the remote log server’s hostname, the connection will fail out. However, the hostname can be added to /etc/hosts to correct this infrequently occurring problem. 4.5.2 Protect Logs to Ensure That They Are Reliable60 To protect sensitive information, ensure that log files are protected from being accessed or modified by unauthorized users. Confirm that only authorized users can access utilities that reconfigure logging mechanisms; turn utilities on and off; or write to, modify, and read log data. It is important to collect and archive log files in a location that is only accessible by administrators. This is to ensure that intruders cannot modify the logs to remove or alter signs of an intrusion or add erroneous information. Consider the following methods to ensure that log files are not modified: • Send log data to a file on a separate host that is dedicated solely to log collecting. The log host should reside in a physically secure location that is not easily accessible from the network. For example, capturing log data using a computer via a dedicated serial line provides a way of storing the log files more securely than if they were written on the logging host's disks. • Use encrypted transmission channels to send log data from client hosts to the log host. • Send log data to a “write once, read many” (WORM) device (such as CD-ROM or a specially configured tape drive) or to a write-only device (such as a printer) to eliminate the possibility of the data being modified once it is written. • If your systems permit, set selected log file attributes that enable only new information to be appended to the log files (i.e., new records can be added, those already recorded cannot be modified). • Encrypt log files, particularly those that contain sensitive data or those being transmitted across a network. 59 60 http://www.die.net/doc/linux/man/man8/syslogd.8.html http://www.cert.org/security-improvement/practices/p092.html 186 CMU/SEI-2004-HB-001