Previous: Disabling FIPS mode, Up: Preparation [Contents][Index]
Libgcrypt makes use of certain hardware features. If the use of a feature is not desired, it may be disabled either by a program or globally using a configuration file. The currently supported features are
padlock-rngpadlock-aespadlock-shapadlock-mmulintel-cpuintel-fast-shldintel-bmi2intel-ssse3intel-sse4.1intel-pclmulintel-aesniintel-rdrandintel-avxintel-avx2intel-fast-vpgatherintel-rdtscintel-shaextintel-vaes-vpclmularm-neonarm-aesarm-sha1arm-sha2arm-pmullppc-vcryptoppc-arch_3_00ppc-arch_2_07ppc-arch_3_10s390x-msas390x-msa-4s390x-msa-8s390x-msa-9s390x-vxTo disable a feature for all processes using Libgcrypt 1.6 or newer, create the file /etc/gcrypt/hwf.deny and put each feature not to be used on a single line. Empty lines, white space, and lines prefixed with a hash mark are ignored. The file should be world readable.
To disable a feature specifically for a program, that program must tell
it Libgcrypt before before calling gcry_check_version.
Example:2
gcry_control (GCRYCTL_DISABLE_HWF, "intel-rdrand", NULL);
To print the list of active features you may use this command:
mpicalc --print-config | grep ^hwflist: | tr : '\n' | tail -n +2
NB. Libgcrypt uses the RDRAND feature only as one source of entropy. A CPU with a broken RDRAND will thus not compromise the random number generator