UCF STIG Viewer Logo

All local initialization files' executable search paths must contain only absolute paths.


Overview

Finding ID Version Rule ID IA Controls Severity
V-11986 GEN001900 SV-12487r3_rule ECCD-2 ECCD-1 Medium
Description
The executable search path (typically the PATH environment variable) contains a list of directories for the shell to search to find executables. If this path includes the current working directory or other relative paths, executables in these directories may be executed instead of system commands. This variable is formatted as a colon-separated list of directories. If there is an empty entry, such as a leading or trailing colon or two consecutive colons, this is interpreted as the current working directory. Paths starting with a slash (/) are absolute paths.
STIG Date
SOLARIS 9 SPARC SECURITY TECHNICAL IMPLEMENTATION GUIDE 2015-10-01

Details

Check Text ( C-7951r3_chk )
NOTE: The following must be done in the BASH shell.

Examine the PATH variable contained in any user's local initialization files to ensure the use of only absolute paths, using a command shell that supports the use of ~USER as USER's home directory.

# cat /etc/passwd | cut -f 1,1 -d ":" | xargs -n1 -IUSER sh -c 'grep -i PATH ~USER/.*'

The PATH variable is a colon-delimited directory list.

An empty entry is defined by a leading/trailing colon or two consecutive colons.

A relative path is defined as an entry beginning with a character other than a slash (/).

If an empty or relative path is defined in the PATH variable, this is a finding.
Fix Text (F-11247r2_fix)
Edit the local initialization file(s) and remove the relative path entry from the PATH variable.