1. Home
  2. Security Hardening
  3. CIS Apache HTTP Server 2.4 L1 V2.0.0
  4. Ensure the Pid File Is Secured – ‘PidFile directory’

Ensure the Pid File Is Secured – ‘PidFile directory’

Details

The PidFile directive sets the file path to the process ID file to which the server records the process id of the server, which is useful for sending a signal to the server process or for checking on the health of the process.

Rationale:

If the PidFile is placed in a writable directory, other accounts could create a denial of service attack and prevent the server from starting by creating a PID file with the same name.

Solution

Find the directory in which the PidFile would be created. The default value is the ServerRoot/logs directory.

Modify the directory if the PidFile is in a directory within the Apache ‘DocumentRoot’.

Change the ownership and group to be root:root, if not already.

Change the permissions so that the directory is only writable by root, or the user under which Apache initially starts up (default is root).

Default Value:

The default process ID file is logs/httpd.pid.

Supportive Information

The following resource is also helpful.

This security hardening control applies to the following category of controls within NIST 800-53: Access Control.This control applies to the following type of system Unix.

References

Source

Updated on July 16, 2022
Was this article helpful?

Related Articles