Changeset 121
- Timestamp:
- 12/07/07 13:12:17 (1 year ago)
- Files:
-
- trunk/RHEL4/scripts/stig-fix/cat1/gen000560.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat1/gen001400.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat1/gen002160.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat1/gen002700.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat1/gen004580.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat1/gen004640.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat1/gen005000.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat1/gen005500.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat1/lnx00320.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat1/lnx00580.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000020.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000400.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000440.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000460.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000480.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000500.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000540.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000580.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000600.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000700.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000800.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000920.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen000980.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001020.sh (modified) (2 diffs)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001120.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001260.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001380.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001420.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001580.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001620.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001660.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001680.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001720.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001740.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001760.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001800.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen001820.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002120.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002180.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002200.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002220.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002320.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002340.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002360.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002420.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002560.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002640.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002660.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002680.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002860.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen002980.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003040.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003060.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003080.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003100.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003120.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003140.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003180.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003200.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003240.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003260.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003300.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003320.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003340.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003400.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003420.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003460.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003480.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003600.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003660.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003700.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003740.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003760.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003780.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003960.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen003980.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004000.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004360.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004380.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004480.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004500.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004540.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004560.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004880.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004900.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004920.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen004940.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen005360.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen005400.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/gen005420.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen005600.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen005740.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006100.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006120.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006140.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006160.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006180.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006200.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006260.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006280.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006300.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006320.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006340.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006360.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006520.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/gen006620.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00160.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00220.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00340.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00360.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00400.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00420.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00440.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00480.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00500.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00520.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00620.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00640.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat2/lnx00660.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat3/gen001080.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat3/gen001280.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat3/gen001780.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat3/gen003500.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat3/gen003520.sh (modified) (1 diff)
- trunk/RHEL4/scripts/stig-fix/cat3/gen003860.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat3/gen005760.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat4 (added)
- trunk/RHEL4/scripts/stig-fix/cat4/gen001460.sh (added)
- trunk/RHEL4/scripts/stig-fix/cat4/gen004440.sh (added)
- trunk/RHEL4/scripts/stig-fix/run-fixes.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat1/gen000560.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat1/gen002700.sh (added)
- trunk/RHEL5.1/scripts/stig-fix/cat1/lnx00320.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen000020.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen001020.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen001120.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen001800.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen002660.sh (added)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen002680.sh (added)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen002980.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen003060.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen003100.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen003600.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat2/gen004000.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat2/lnx00340.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat3/gen001780.sh (modified) (1 diff)
- trunk/RHEL5.1/scripts/stig-fix/cat3/gen003860.sh (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/RHEL4/scripts/stig-fix/cat1/gen004640.sh
r105 r121 1 1 #!/bin/sh 2 2 3 ## (GEN004640: CAT I) (Previously â V126) The SA will ensure the decode entry 4 ## is disabled (deleted or commented out) from the alias file. 3 5 echo '===================================================' 4 echo 'Patching G en004640: Disable decode in alias file'5 echo '===================================================' 6 echo 'Patching GEN004640: Disable decode in alias file' 7 echo '===================================================' 6 8 sed --in-place s/^decode\:/\#decode\:/ /etc/aliases trunk/RHEL4/scripts/stig-fix/cat1/lnx00320.sh
r105 r121 1 1 #!/bin/sh 2 2 3 #Remove unnecessary privileged users from /etc/passwd 3 ## (LNX00320: CAT I) (Previously â L140) The SA will delete accounts that 4 ## provide a special privilege such as shutdown and halt. 4 5 echo '===================================================' 5 6 echo 'Patching LNX00320: Deleting accounts providing' 6 echo ' special privilege.'7 echo ' special privilege.' 7 8 echo '===================================================' 8 sed -i /shutdown/d /etc/passwd 9 sed -i /halt/d /etc/passwd 10 sed -i /sync/d /etc/passwd 11 sed -i /operator/d /etc/passwd 9 /usr/sbin/userdel shutdown 10 /usr/sbin/userdel halt 11 /usr/sbin/userdel sync trunk/RHEL4/scripts/stig-fix/cat1/lnx00580.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Disable CTRL-ALT-DEL on the system 3 ## (LNX00580: CAT I) (Previously â L222) The SA will disable the 4 ## Ctrl-Alt-Delete sequence unless the system is located in a controlled 5 ## access area accessible only by SAs. 4 6 echo '===================================================' 5 echo ' Patching LNX00580: Disable CTRL-ALT-DELETE' 7 echo ' Patching LNX00580: Disable CTRL-ALT-DELETE' 6 8 echo '===================================================' 7 9 sed --in-place s/ca\:\:ctrlaltdel/\#ca\:\:ctrlaltdel/ /etc/inittab trunk/RHEL4/scripts/stig-fix/cat2/gen000020.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Put a password on single-user mode 3 ## (GEN000020: CAT II) (Previously â G001) The IAO and SA will ensure, if 4 ## configurable, the UNIX host is configured to require a password for access 5 ## to single-user and maintenance modes. 4 6 echo '===================================================' 5 7 echo ' Patching GEN000020: Configuring Password for' 6 8 echo ' single-user and maintenance' 7 echo ' modes.' 9 echo ' modes.' 8 10 echo '===================================================' 9 11 echo "" >> /etc/inittab 10 echo " Require password in single-user mode" >> /etc/inittab12 echo "#Require password in single-user mode" >> /etc/inittab 11 13 echo "~:S:wait:/sbin/sulogin" >> /etc/inittab trunk/RHEL4/scripts/stig-fix/cat2/gen000400.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Change banner for local logins 4 # This can be modified as long as it still meets STIG requirement GEN000420. 5 # Namely, the banner must advise that: 6 # - The system is a DOD system. 7 # - The system is subject to monitoring. 8 # - Monitoring is authorized in accordance with applicable laws and 9 # regulations and conducted for purposes of systems management and 10 # protection, protection against improper or unauthorized use or access, 11 # and verification of applicable security features or procedures. 12 # - Use of the system constitutes consent to monitoring 13 # - This system is for authorized US government use only. 3 ## (GEN000400: CAT II) (Previously â G010) The SA will ensure a logon-warning banner is 4 ## displayed on all devices and sessions at the initial logon. 14 5 echo '===================================================' 15 echo ' Patching GEN000400: Providing logon-warning banner' 6 echo ' Patching GEN000400: Providing logon-warning banner' 16 7 echo '===================================================' 17 8 echo "THIS IS A DEPARTMENT OF DEFENSE COMPUTER SYSTEM. THIS COMPUTER SYSTEM, trunk/RHEL4/scripts/stig-fix/cat2/gen000440.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Make syslog log all authentication information 3 ## (GEN000440: CAT II) (Previously â G012) The SA will ensure all logon attempts (both 4 ## successful and unsuccessful) are logged to a system log file. 4 5 echo '===================================================' 5 echo ' Patching GEN00 440: ensuring logon attempts logged.'6 echo ' Patching GEN000440: ensuring logon attempts logged.' 6 7 echo '===================================================' 7 8 echo " 8 9 # Log all authentication information 9 auth.* /var/log/authlog" >> /etc/syslog.conf10 auth.* /var/log/authlog" >> /etc/syslog.conf trunk/RHEL4/scripts/stig-fix/cat2/gen000460.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Lock a user out after 3 failed logins 3 ## (GEN000460: CAT II) (Previously â G013) The SA will ensure, after three consecutive 4 ## failed logon attempts for an account, the account is locked for 15 minutes or until 5 ## the SA unlocks the account. 4 6 echo '===================================================' 5 echo ' Patching GEN000460: Disable after 3 consecutive' 7 echo ' Patching GEN000460: Disable after 3 consecutive' 6 8 echo ' failed attempts per account' 7 9 echo '===================================================' trunk/RHEL4/scripts/stig-fix/cat2/gen000480.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Make the system wait 4 seconds after a failed login attempt.4 # Slows brute-forcing of passwords.3 ## (GEN000480: CAT II) (Previously â G015) The SA will ensure the logon delay between 4 ## logon prompts after a failed logon is set to at least four seconds. 5 5 echo '===================================================' 6 echo ' Patching GEN000480: Set logon delay to 4 seconds.' 6 echo ' Patching GEN000480: Set logon delay to 4 seconds.' 7 7 echo '===================================================' 8 8 echo " trunk/RHEL4/scripts/stig-fix/cat2/gen000580.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Set minimum password length to 8 characters. 3 ## (GEN000580: CAT II) (Previously â G019) The IAO will ensure all passwords contain a 4 ## minimum of eight characters. 4 5 echo '===================================================' 5 echo ' Patching GEN000580: Set minimum Password length.' 6 echo ' Patching GEN000580: Set minimum Password length.' 6 7 echo '===================================================' 7 8 sed --in-place "s/PASS_MIN_LEN[ \t]*[0-9]*/PASS_MIN_LEN\t8/" /etc/login.defs trunk/RHEL4/scripts/stig-fix/cat2/gen000600.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Enforce stricter password standards. 4 # - Minimum length is now 9 5 # - Must have 2 upper-case letters 6 # - Must have 2 lower-case letters 7 # - Must have 2 digits 8 # - Must have 2 other characters 3 ## (GEN000600: CAT II) (Previously â G019) The IAO will ensure passwords include at 4 ## least two alphabetic characters, one of which must be capitalized. 9 5 echo '===================================================' 10 echo ' Patching GEN000600: Enforce more secure passwords.' 6 echo ' Patching GEN000600: Enforce more secure passwords.' 11 7 echo '===================================================' 12 8 sed -i s/minlen\=8/minlen\=9/ /etc/pam.d/system-auth trunk/RHEL4/scripts/stig-fix/cat2/gen000800.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Make the system remember the last 10 passwords a user used. 3 ## (GEN000800: CAT II) (Previously â G606) The SA will ensure passwords will not be 4 ## reused within the last ten changes. 4 5 echo '===================================================' 5 echo ' Patching GEN00080 : Disallow duplication passwords.'6 echo ' Patching GEN000800: Disallow duplication passwords.' 6 7 echo '===================================================' 7 8 sed -i "s/shadow/shadow remember\=10/" /etc/pam.d/system-auth trunk/RHEL4/scripts/stig-fix/cat2/gen000920.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Ensure that /root is only readable by the root user. 3 ## (GEN000920: CAT II) (Previously â G023) The SA will ensure the root account 4 ## home directory (other than â/â) has permissions of 700. Do not change the 5 ## permissions of the â/â directory to anything other than 0755. 4 6 echo '===================================================' 5 echo ' Patching GEN000920: /root is only readable by root' 7 echo ' Patching GEN000920: /root is only readable by root' 6 8 echo '===================================================' 7 9 chmod -R 700 /root trunk/RHEL4/scripts/stig-fix/cat2/gen000980.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # There should only be one entry in /etc/securetty 3 ## (GEN000980: CAT II) (Previously â G026) The SA will ensure root can only log 4 ## on as root from the system console, and then only when necessary to perform 5 ## system maintenance. 4 6 echo '===================================================' 5 7 echo ' Patching GEN000980: Ensure only one secure TTY.' trunk/RHEL4/scripts/stig-fix/cat2/gen001020.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Restrict direct logins to users that are in the "users" group.4 # Users will have to "su" to root or other shared accounts.5 3 ## (GEN001020: CAT II) The IAO will enforce users requiring root privileges to 4 ## log on to their personal account and invoke the /bin/su - command to switch 5 ## user to root. 6 6 echo '===================================================' 7 echo ' Patching GEN001020: root privilege must be gained' 7 echo ' Patching GEN001020: root privilege must be gained' 8 8 echo ' via switch from user account.' 9 9 echo '===================================================' … … 18 18 19 19 # Add a User who is in the users group allowing access to the system 20 adduser -G users,wheel CLIPUser20 /usr/sbin/adduser -G users,wheel CLIPUser 21 21 passwd CLIPUser < CLIPUserPassword 22 23 22 24 23 # Cron was previously set to use /etc/security/access.conf, which did trunk/RHEL4/scripts/stig-fix/cat2/gen001260.sh
r105 r121 1 1 #!/bin/sh 2 2 3 ## (GEN001260: CAT II) (Previously â G037) The SA will ensure all system log 4 ## files have permissions of 640, or more restrictive. 3 5 echo '===================================================' 4 echo ' Patching GEN001260: Setting permissions of system' 6 echo ' Patching GEN001260: Setting permissions of system' 5 7 echo ' log files.' 6 8 echo '===================================================' trunk/RHEL4/scripts/stig-fix/cat2/gen002320.sh
r105 r121 1 1 #!/bin/sh 2 2 3 ## (GEN002320: CAT II) (Previously â G501) The SA will ensure the audio devices 4 ## have permissions of 644, or more restrictive. 3 5 echo '===================================================' 4 echo ' Patching GEN002320: Setting permissions on audio' 6 echo ' Patching GEN002320: Setting permissions on audio' 5 7 echo ' devices.' 6 8 echo '===================================================' trunk/RHEL4/scripts/stig-fix/cat2/gen002560.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Default umask to 077 so that newly-created files are only accessible by owner 3 ## (GEN002560: CAT II) (Previously â G089) The SA will ensure the system and 4 ## user umask is 077. 4 5 echo '===================================================' 5 6 echo ' Patching GEN002560: Set default umask.' trunk/RHEL4/scripts/stig-fix/cat2/gen002680.sh
r105 r121 1 #!/bin/ sh1 #!/bin/bash 2 2 3 ## (GEN002680: CAT II) (Previously â G094) The SA will ensure audit data files 4 ## and directories will be readable only by personnel authorized by the IAO. 3 5 echo '===================================================' 4 echo ' Patching GEN002680: Setting permissions on: ' 5 echo ' /etc/security/audit_control' 6 echo 'Patching GEN002680: Set audit directory permissions' 6 7 echo '===================================================' 7 chmod 600 /etc/security/audit_control8 chmod 700 /var/log/audit trunk/RHEL4/scripts/stig-fix/cat2/gen003080.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # By STIG definition, crontab files are only readable by root. 3 ## (GEN003080: CAT II) (Previously â G205) The SA will ensure crontabs have 4 ## permissions of 600, or more restrictive, (700 for some Linux crontabs, which 5 ## is detailed in the UNIX Checklist). 4 6 echo '===================================================' 5 echo ' Patching GEN003080: Only allow root access to ' 6 echo ' crontab files.' 7 echo ' Patching GEN003080: Set permissions of crontabs' 7 8 echo '===================================================' 8 9 chmod -R 600 /etc/cron.daily trunk/RHEL4/scripts/stig-fix/cat2/gen003320.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Default system accounts are not to be run as at jobs. 3 ## (GEN003320: CAT II) (Previously â G213) The SA will ensure default system 4 ## accounts (with the possible exception of root) are not listed in the 5 ## at.allow file. If there is only an at.deny file, the default accounts 6 ## (with the possible exception of root) will be listed there. 4 7 echo '===================================================' 5 echo ' Patching GEN003320: Disallow system account access' 6 echo ' as at jobs.' 8 echo ' Patching GEN003320: Only root may be in at.allow' 7 9 echo '===================================================' 8 echo "daemon 9 bin 10 adm 11 uucp 12 lp 13 news 14 nobody 15 ftp 16 sshd 17 smmsp" > /etc/at.deny 10 echo "root" > /etc/at.allow trunk/RHEL4/scripts/stig-fix/cat2/gen003600.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Modify some kernel tunables to decrease risk of DoS attack.3 ## (GEN003600: CAT II) The SA will ensure network parameters are securely set. 4 4 echo '===================================================' 5 echo ' Patching GEN003600: Tune kernel decreasing risk' 6 echo ' of a DoS attack.' 5 echo ' Patching GEN003600: Set network parameters' 7 6 echo '===================================================' 8 echo " 9 # Increase the size of the unestablished connection queue 7 cat <<EOF > /etc/sysctl.conf 8 net.ipv4.ip_forward = 0 10 9 net.ipv4.tcp_max_syn_backlog = 1280 10 net.ipv4.conf.all.accept_source_route =0 11 net.ipv4.icmp_echo_ignore_broadcasts = 1 12 EOF 11 13 12 # Do not respond to echo request broadcasts13 net.ipv4.icmp_echo_ignore_broadcasts = 1" >> /etc/sysctl.conftrunk/RHEL4/scripts/stig-fix/cat2/gen003740.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # STIG-defined permissions for xinetd configuration files 3 ## (GEN003740: CAT II) (Previously â G108) The SA will ensure the inetd.conf 4 ## (xinetd.conf for Linux) file has permissions of 440, or more restrictive. 5 ## The Linux xinetd.d directory will have permissions of 755, or more 6 ## restrictive. This is to include any directories defined in the includedir 7 ## parameter. 4 8 echo '===================================================' 5 echo ' Patching GEN003740: Set permissions for xinetd' 9 echo ' Patching GEN003740: Set permissions for xinetd' 6 10 echo ' configuration files.' 7 11 echo '===================================================' trunk/RHEL4/scripts/stig-fix/cat2/gen004000.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Ensure that only root can use traceroute 3 ## (GEN004000: CAT II) (Previously â G633) The SA will ensure the traceroute 4 ## command has permissions of 700, or more restrictive. 4 5 echo '===================================================' 5 echo ' Patching GEN004000: Limit access to traceroute to' 6 echo ' Patching GEN004000: Limit access to traceroute to' 6 7 echo ' root user only.' 7 8 echo '===================================================' 8 chmod 700 /usr/sbin/traceroute 9 whereis traceroute | cut -d " " -f 2 | xargs chmod 700 trunk/RHEL4/scripts/stig-fix/cat2/gen004540.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Disable sendmail "help" command by emptying the help file 3 ## (GEN004540: CAT II) The SA will ensure the help sendmail command is 4 ## disabled. 4 5 echo '===================================================' 5 echo ' Patching GEN004540: Disable sendmail help.' 6 echo ' Patching GEN004540: Disable sendmail help.' 6 7 echo '===================================================' 7 8 mv /etc/mail/helpfile /etc/mail/helpfile.bak trunk/RHEL4/scripts/stig-fix/cat2/gen005400.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Ensure that only root can modify syslog.conf 3 ## (GEN005400: CAT II) (Previously â G656) The SA will ensure the owner of the 4 ## /etc/syslog.conf file is root with permissions of 640, or more restrictive. 4 5 echo '===================================================' 5 echo ' Patching GEN005400: Only allow root access to ' 6 echo ' syslog.conf file.' 6 echo ' Patching GEN005400: Set syslog.conf permissions' 7 7 echo '===================================================' 8 chown root /etc/syslog.conf 8 9 chmod 640 /etc/syslog.conf trunk/RHEL4/scripts/stig-fix/cat2/gen006620.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # By default, deny all services from serving incoming traffic. 4 # The system administrator should edit this to enable desired daemons. 3 ## (GEN006620: CAT II) The SA will ensure an access control program (e.g., 4 ## TCP_WRAPPERS) hosts.deny and hosts.allow files (or equivalent) are used to 5 ## grant or deny system access to specific hosts. 5 6 echo '===================================================' 6 echo ' Patching GEN006620: Disable all services.'7 echo ' Patching GEN006620: Set hosts.deny file' 7 8 echo '===================================================' 8 9 echo " trunk/RHEL4/scripts/stig-fix/cat2/lnx00340.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Remove unnecessary accounts from /etc/passwd 3 ## (LNX00340: CAT II) (Previously â L142) The SA will delete accounts that 4 ## provide no operational purpose, such as games or operator, and will delete 5 ## the associated software. 4 6 echo '===================================================' 5 echo ' Patching LNX00340: Disable unnecessary accounts.' 7 echo ' Patching LNX00340: Disable unnecessary accounts.' 6 8 echo '===================================================' 7 sed -i /news/d /etc/passwd 8 sed -i /operator/d /etc/passwd 9 sed -i /games/d /etc/passwd 10 sed -i /gopher/d /etc/passwd 11 sed -i /nfsnobody/d /etc/passwd 9 /usr/sbin/userdel news 10 /usr/sbin/userdel operator 11 /usr/sbin/userdel games 12 /usr/sbin/userdel gopher 13 /usr/sbin/userdel nfsnobody trunk/RHEL4/scripts/stig-fix/cat2/lnx00440.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Ensure that only root can modify access.conf 3 ## (LNX00440: CAT II) (Previously â L046) The SA will ensure /etc/login.access 4 ## or /etc/security/access.conf file will be 640, or more restrictive. 4 5 echo '===================================================' 5 echo ' Patching LNX00580: Only allow root access to ' 6 echo ' access.conf file.' 6 echo ' Patching LNX00440: Set access.conf permissions' 7 7 echo '===================================================' 8 8 chmod 640 /etc/security/access.conf trunk/RHEL4/scripts/stig-fix/cat2/lnx00520.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Ensure that only root can use sysctl.conf 3 ## (LNX00520: CAT II) (Previously â L208) The SA will ensure the 4 ## /etc/sysctl.conf file has permissions of 600, or more restrictive. 4 5 echo '===================================================' 5 echo ' Patching LNX00520: Only allow root access to ' 6 echo ' sysctl.conf file.' 6 echo ' Patching LNX00520: Set sysctl.conf permission' 7 7 echo '===================================================' 8 8 chmod 600 /etc/sysctl.conf trunk/RHEL4/scripts/stig-fix/cat3/gen001280.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Ensure that only root can modify man pages 3 ## (GEN001280: CAT III) (Previously â G042) The SA will ensure all manual page 4 ## files (i.e.,files in the man and cat directories) have permissions of 644, 5 ## or more restrictive. 4 6 echo '===================================================' 5 echo ' Patching GEN001280: Only allow root access to man' 6 echo ' pages.' 7 echo ' Patching GEN001280: Set manual page permissions' 7 8 echo '===================================================' 8 9 chmod -R 644 /usr/share/man trunk/RHEL4/scripts/stig-fix/cat3/gen003520.sh
r105 r121 1 1 #!/bin/sh 2 2 3 # Ensure that only root can see crash logs. 3 ## (GEN003520: CAT III) The SA will ensure the owner and group owner of the 4 ## core dump data directory is root with permissions of 700, or more 5 ## restrictive. 4 6 echo '===================================================' 5 echo ' Patching GEN003520: Only allow root access to ' 6 echo ' crash logs.' 7 echo ' Patching GEN003520: Set crash log dir permissions' 7 8 echo '===================================================' 8 9 chmod -R 700 /var/crash trunk/RHEL4/scripts/stig-fix/run-fixes.sh
r105 r121 7 7 echo 'Patching Cat III Secuity issues' 8 8 for i in `ls cat3`; do cat3/$i; done; 9 echo 'Patching Cat IV Secuity issues' 10 for i in `ls cat4`; do cat4/$i; done; 11 9 12 echo "run-fixes.sh completed" >> /root/stig-fixes-run.txt trunk/RHEL5.1/scripts/stig-fix/cat1/gen000560.sh
r113 r121 10 10 echo '===================================================' 11 11 for USERINFO in `cat /etc/shadow`; do 12 if [ -z `echo $USERINFO | cut -d: -f2`]12 if [ -z "`echo $USERINFO | cut -d: -f2`" ] 13 13 then 14 14 /usr/sbin/usermod -L -s /dev/null `echo $USERINFO | cut -d: -f1` trunk/RHEL5.1/scripts/stig-fix/cat1/lnx00320.sh
r115 r121 7 7 echo ' special privilege.' 8 8 echo '===================================================' 9 userdel shutdown10 userdel halt11 userdel sync9 /usr/sbin/userdel shutdown 10 /usr/sbin/userdel halt 11 /usr/sbin/userdel sync trunk/RHEL5.1/scripts/stig-fix/cat2/gen000020.sh
r115 r121 10 10 echo '===================================================' 11 11 echo "" >> /etc/inittab 12 echo " Require password in single-user mode" >
