Skip to content

2.1.11 Ensure print server services are not in use

Audit#

Run the following command to verify cups is not Installed:

# dpkg-query -s cups &>/dev/null && echo "cups is installed"
Nothing should be returned.

- OR - - IF - the package is required for dependencies: Run the following command to verify the cups.socket and cups.service is not enabled:

# systemctl is-enabled cups.socket cups.service 2>/dev/null | grep 'enabled'
Nothing should be returned.

Run the following command to verify the cups.socket and cups.service is not active:

# systemctl is-active cups.socket cups.service 2>/dev/null | grep '^active'
Nothing should be returned.

Note: If the package is required for a dependency - Ensure the dependent package is approved by local site policy - Ensure stopping and masking the service and/or socket meets local site policy

Remediation#

Run the following commands to stop cups.socket and cups.service, and remove the cups package:

# systemctl stop cups.socket cups.service
# apt purge cups

- OR - - IF - the cups package is required as a dependency: Run the following commands to stop and mask the cups.service and cups.service:

# systemctl stop cups.socket cups.service
# systemctl mask cups.socket cups.service