Process Isolation
Last updated
Last updated
By default, users can use a utility such as ps or top to see everyone else's processes, as well as their own.
the best way to deal with this is to mount the /proc filesystem with the hidepid option. You can do this by adding the following line to the end of the /etc/fstab file, like so:
nano /etc/fstab
Then, remount /proc , like so:
Now, any user who doesn't have sudo privileges can only view his or her own processes.
The three values for the hidepid option are as follows:
0 : This is the default, which allows all users to see each others' processes.
1 : This allows all users to see other users' process directories within /proc . However, users will only be able to cd into their own process directories. Also, they'll only be able to see their own process information with ps or top .
2 : This hides all other users' process information, including the process directories within /proc .
A core dump is the memory of an executable program. It is generally used to determine why a program aborted. It can also be used to glean confidential information from a core file. The system provides the ability to set a soft limit for core dumps, but this can be overridden by the user.
Setting a hard limit on core dumps prevents users from overriding the soft variable. If core dumps are required, consider setting limits for user groups (see limits.conf(5) ). In addition, setting the fs.suid_dumpable variable to 0 will prevent setuid programs from dumping core.
Run the following commands and verify output matches:
Run the following command to check if systemd-coredump is installed:
if enabled or disabled is returned systemd-coredump is installed
Add the following line to /etc/security/limits.conf or a /etc/security/limits.d/* file:
Set the following parameter in /etc/sysctl.conf or a /etc/sysctl.d/* file:
Run the following command to set the active kernel parameter:
If systemd-coredump is installed:
edit /etc/systemd/coredump.conf
and add/modify the following lines:
Run the command:
Set the following parameter in /etc/sysctl.conf
or a /etc/sysctl.d/*
file:
Run the following command to set the active kernel parameter:
prelink is a program that modifies ELF shared libraries and ELF dynamically linked binaries in such a way that the time needed for the dynamic linker to perform relocations at startup significantly decreases.
The prelinking feature can interfere with the operation of AIDE, because it changes binaries. Prelinking can also increase the vulnerability of the system if a malicious user is able to compromise a common library such as libc
Verify prelink is not installed. Depending on the package management in use one of the following commands may provide the needed information:
Run the following command to restore binaries to normal:
Uninstall prelink using the appropriate package manager or manual installation: