6.2.26 Ensure local interactive users' dot files executable paths resolve to the users home directory.

Information

The operating system must be configured so that all local interactive user initialization (dot) files executable search paths contain only paths that resolve to the users home directory.

Rationale:

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 (other than the user's home directory), 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. If deviations from the default system search path for the local interactive user are required, they must be documented with the Information System Security Officer (ISSO).

NOTE: Nessus has provided the target output to assist in reviewing the benchmark to ensure target compliance.

Solution

Edit the local interactive user initialization files to change any PATH variable statements that reference directories other than their home directory.
Note: The example will be for the smithj user, which has a home directory of /home/smithj.
Utilizing the files listed in the Audit run this command to edit them and change the PATH variable statement.
Example: vim /home/smithj/.bash_profile
Update the PATH accordingly:

:PATH=$PATH:$HOME/.local/bin:$HOME/bin

If a local interactive user requires path variables to reference a directory owned by the application, it must be documented with the ISSO.

See Also

https://workbench.cisecurity.org/files/3636

Item Details

Category: CONFIGURATION MANAGEMENT

References: 800-53|CM-6b., CCI|CCI-000366, CSCv7|14.6, Rule-ID|SV-204477r603261_rule, STIG-ID|RHEL-07-020720

Plugin: Unix

Control ID: daa14e738e85bb0230cc2e8060b0611a2d3930c444c0ec570bc641208df9c1f7