1.2.1.2 Ensure gpgcheck is globally activated

Warning! Audit Deprecated

This audit has been deprecated and will be removed in a future update.

View Next Audit Version

Information

The gpgcheck option, found in the main section of the /etc/zypp/zypp.conf and individual /etc/zypp/repos.d/*.repo files determines if an RPM package's signature is checked prior to its installation.

It is important to ensure that an RPM's package signature is always checked prior to installation to ensure that the software is obtained from a trusted source.

Solution

Edit /etc/zypp/zypp.conf and set gpgcheck=on :

Example

# sed -i 's/^gpgchecks*=s*.*/gpgcheck=on/' /etc/zypp/zypp.conf

Edit any failing files in /etc/zypp/repos.d/* and set all instances starting with gpgcheck to on

Example:

# find /etc/zypp/repos.d/ -name "*.repo" -exec echo "Checking:" {} ; -exec sed -i 's/^gpgchecks*=s*.*/gpgcheck=on/' {} ;

Note: true yes or 1 is also acceptable.

See Also

https://workbench.cisecurity.org/benchmarks/20333