Red Hat Enterprise Linux Kernel Crypto API Cryptographic Module version 7.0 FIPS 140-2 Non-Proprietary Security Policy Version 1.2 Last update: 2019-11-08 Prepared by: atsec information security corporation 9130 Jollyville Road, Suite 260 Austin, TX 78759 www.atsec.com ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 1 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy Table of Contents 1 Cryptographic Module Specifcation.......................................................................................4 1.1 Module Overview..........................................................................................................4 1.2 FIPS 140-2 validation....................................................................................................6 1.3 Modes of Operations.....................................................................................................6 2 Cryptographic Module Ports and Interfaces............................................................................8 3 Roles, Services and Authentication........................................................................................9 3.1 Roles.............................................................................................................................9 3.2 Services........................................................................................................................9 3.3 Authentication............................................................................................................11 4 Physical Security..................................................................................................................13 5 Operational Environment.....................................................................................................14 5.1 Applicability................................................................................................................14 5.2 Policy..........................................................................................................................14 6 Cryptographic Key Management..........................................................................................15 6.1 Random Number Generation......................................................................................15 6.2 Key / Critical Security Parameter (CSP) Access...........................................................16 6.3 Key / CSP Storage.......................................................................................................16 6.4 Key / CSP Zeroization..................................................................................................16 7 Electromagnetic Interference/Electromagnetic Compatibility (EMI/EMC)..............................17 8 Self-Tests..............................................................................................................................18 8.1 Power-Up Self-Tests.....................................................................................................18 8.1.1 Integrity Tests....................................................................................................18 8.2 Conditional Tests.........................................................................................................19 9 Guidance..............................................................................................................................20 9.1 Cryptographic Ofcer Guidance..................................................................................20 9.1.1 Secure Installation and Startup.........................................................................20 9.1.2 FIPS 140-2 and AES NI Support..........................................................................20 9.2 User Guidance............................................................................................................21 9.2.1 XTS Usage.........................................................................................................21 9.2.2 GCM Usage........................................................................................................21 9.2.3 Triple-DES Usage...............................................................................................21 9.3 Handling Self Test Errors.............................................................................................21 Appendix A Glossary and Abbreviations..................................................................................23 Appendix B References...........................................................................................................25 ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 2 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy Introduction This document is the non-proprietary Security Policy for the Red Hat Enterprise Linux Kernel Crypto API Cryptographic Module version 7.0. It contains the security rules under which the module must operate and describes how this module meets the requirements as specifed in FIPS PUB 140-2 (Federal Information Processing Standards Publication 140-2) for a Security Level 1 module. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 3 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy 1 Cryptographic Module Specifcation 1.1 Module Overview The Red Hat Enterprise Linux Kernel Crypto API Cryptographic Module (hereafter referred to as the “Module”) is a software only cryptographic module that provides general-purpose cryptographic services to the remainder of the Linux kernel. The Red Hat Enterprise Linux Kernel Crypto API Cryptographic Module is software only, security level 1 cryptographic module, running on a multi-chip standalone platform. The module is implemented as a set of shared libraries / binary fles. Figure 1: Cryptographic Module Logical Boundary The module is aimed to run on a general purpose computer; the physical boundary is the surface of the case of the target platform, as shown in the diagram below: ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 4 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy The following list of packages is required for the module to operate: • the kernel-3.10.0-957.10.1.el7 package, which contains the binary fles, integrity check HMAC fles and Man Pages for the kernel • the dracut-fps-033-554.el7 and the dracut-fps-aesni-033-554.el7 packages, which provide the confguration of the FIPS mode • the hmaccalc-0.9.13-4.el7 package. The module is made of the following fles: • kernel loadable components /lib/modules/$(uname -r)/kernel/crypto/*.ko • kernel loadable components /lib/modules/$(uname -r)/kernel/arch/x86/crypto/*.ko • static kernel binary (vmlinuz): /boot/vmlinuz-$(uname -r) • static kernel binary (vmlinuz) HMAC fle: /boot/.vmlinuz-$(uname -r).hmac • sha512hmac binary fle for performing the integrity checks: usr/bin/sha512hmac • sha512hmac binary HMAC fle: /usr/lib64/hmaccalc/sha512hmac.hmac The bound module Red Hat Enterprise Linux NSS Cryptographic Module version 6.0 with FIPS 140-2 Certifcate 3270 (hereafter referred to as the “NSS bound module” or “NSS module”) provides the HMAC-SHA-512 algorithm used by the sha512hmac binary fle to verify the integrity of both the sha512hmac fle and the vmlinuz (static kernel binary) fle. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 5 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Figure 2: Cryptographic Module Physical Boundary Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy 1.2 FIPS 140-2 validation For the purpose of the FIPS 140-2 validation, the module is a software-only, multi-chip standalone cryptographic module validated at security level 1. The table below shows the security level claimed for each of the eleven sections that comprise the FIPS 140-2 standard: FIPS 140-2 Section Security Level 1 Cryptographic Module Specifcation 1 2 Cryptographic Module Ports and Interfaces 1 3 Roles, Services and Authentication 1 4 Finite State Model 1 5 Physical Security N/A 6 Operational Environment 1 7 Cryptographic Key Management 1 8 EMI/EMC 1 9 Self Tests 1 10 Design Assurance 1 11 Mitigation of Other Attacks N/A Table 1: Security Levels The module has been tested on the following platforms with the following confguration: Hardware Platform Processor Operating System Tested With PAA (AES- NI) Without PAA (AES-NI) Dell PowerEdge R630 Intel Xeon E5 Red Hat Enterprise Linux 7 yes yes Table 2: Tested Platforms The physical boundary is the surface of the case of the target platform. The logical boundary is depicted in Figure 1. The module also includes algorithm implementations using Processor Algorithm Acceleration (PAA) functions provided by the diferent processors supported, as shown in the following table: Processor Processor Algorithm Acceleration (PAA) function Algorithm Intel Xeon E5 AES-NI AES Table 3: PAA function implementations 1.3 Modes of Operations The module supports two modes of operation: the FIPS approved and non-approved modes. Section 9.1.1 describes the Secure Installation and Startup to correctly install and confgure the module. The module turns to FIPS approved mode after correct initialization, successful completion of power-on self-tests. Invoking a non-Approved algorithm or a non-Approved key size with an Approved algorithm as listed in Table 7 will result in the module implicitly entering the non-FIPS mode of operation. The approved services available in FIPS mode can be found in section 3.2, Table 5. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 6 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy The non-approved services not available in FIPS mode can be found in section 3.2, Table 7. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 7 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy 2 Cryptographic Module Ports and Interfaces As a software-only module, the module does not have physical ports. For the purpose of the FIPS 140-2 validation, the physical ports are interpreted to be the physical ports of the hardware platform on which it runs. The logical interfaces are the application program interface (API) through which applications request services. The following table summarizes the four logical interfaces: Logical interfaces Description Physical ports mapping the logical interfaces Command In API function calls, kernel command line Keyboard Status Out API return codes, kernel logs Display Data In API input parameters Keyboard Data Out API output parameters Display Power Input PC Power Port Physical Power Connector Table 4: Ports and Logical Interfaces ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 8 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy 3 Roles, Services and Authentication 3.1 Roles The module supports the following roles: ⚫ User role: performs symmetric encryption/decryption, keyed hash, message digest, random number generation, show status ⚫ Crypto Ofcer role: performs the module installation and confguration, module's initialization, self-tests, zeroization and signature verifcation The User and Crypto Ofcer roles are implicitly assumed by the entity accessing the module services. 3.2 Services The module supports services available to users in the available roles. All services are described in detail in the user documentation. The following table shows the available services, the roles allowed, the Critical Security Parameters involved and how they are accessed in the FIPS mode. 'R' stands for Read permission, 'W' stands for write permission and 'EX' stands for executable permission of the module: Service Algorithms Note(s) / Mode(s) CAVS Cert(s). Role CSPs Access Symmetric encryption/ decryption Triple-DES CBC, CTR, ECB C341 User 168 bits Triple-DES keys R, W, EX AES CBC, CCM, CTR, ECB, GCM, GMAC, XTS C333 C334 C338 128, 192 and 256 bits AES keys Note: XTS mode only with 128 and 256 bits keys CBC, CTR, ECB, GCM C332 C335 C339 C340 CBC, CTR, ECB, GCM, XTS C337 Keyed hash (HMAC) HMAC SHA-1, HMAC SHA-224, HMAC SHA-256, HMAC SHA-384, HMAC SHA-512 BS < KS, KS = BS, KS > BS C343 C344 User at least 112 bits HMAC keys R, W, EX HMAC SHA-1, HMAC SHA-256, HMAC SHA-512 C342 C345 Message digest (SHS) SHA-1, SHA-224, SHA-256, SHA-384 SHA-512 N/A C343 C344 User N/A R, W, EX SHA-1, SHA-256, SHA-512 C342 C345 Authenticated encryption (KTS) AES-CBC and HMAC- SHA-1, SHA-256 or SHA-512 CBC and HMAC used with encrypt-then- MAC cipher See AES and HMAC User 128, 192 and 256 bits AES keys, R, W, EX ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 9 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy Service Algorithms Note(s) / Mode(s) CAVS Cert(s). Role CSPs Access (authenc) used for IPsec certs HMAC keys AES GCM and CCM Random number generation (SP 800-90A DRBG) CTR DRBG With derivation function, with and without prediction resistance function using AES-128, AES- 192 and AES-256 C333 C334 C338 User Entropy input string, V, C values and Key R, W, EX Hash DRBG With derivation function, with and without prediction resistance function using SHA-1, SHA- 256 and SHA-512 C342 C343 C344 C345 HMAC DRBG With and without prediction resistance function using SHA-1, SHA- 256 and SHA-512 Signature verifcation RSA 2048 and 3072 bits signature verifcation according to PKCS 1 v1.5, using SHA-1, SHA-256, SHA-512 C342 C345 Crypto Ofcer N/A R, W, EX 2048 and 3072 bits signature verifcation according to PKCS 1 v1.5, using SHA-1, SHA-224, SHA-256, SHA-384, SHA-512 C343 C344 Module initialization N/A N/A N/A Crypto ofcer N/A EX Self-tests HMAC-SHA-512, RSA Signature Verifcation Integrity test of the kernel static binary performed by the sha512hmac binary provided by the bound NSS module RSA signature verifcation performs the signature verifcation of the kernel loadable components NSS HMAC: 3735 Crypto ofcer HMAC-SHA- 512 key R, EX Show status N/A Via verbose mode, exit codes and kernel logs (dmesg) N/A User N/A R, EX Zeroize N/A N/A N/A Crypto ofcer N/A R, EX Installation and N/A N/A N/A Crypto N/A R, EX ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 10 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy Service Algorithms Note(s) / Mode(s) CAVS Cert(s). Role CSPs Access confguration ofcer Table 5: Available Cryptographic Module's Services in FIPS mode The module claims SP 800-38F compliant key wrapping with the following modes (using any available implementation specifed in Table 5): • AES-GCM • AES-CCM • AES-CBC with HMAC-SHA1, HMAC-SHA-256 or HMAC-SHA-512. Therefore, the following caveats apply: KTS (AES Certs. C332, C333, C334, C335, C337, C338, C339 and C340, key establishment methodology provides between 128 and 256 bits of encryption strength) KTS (AES Certs. C332, C333, C334, C335, C337, C338, C339 and C340 and HMAC Certs. C342, C343, C344 and C345, key establishment methodology provides between 128 and 256 bits of encryption strength) In the FIPS Approved mode the Module supports the following non-FIPS Approved but allowed algorithms and/or services, which can be used in the FIPS Approved mode of operation: Service Algorithms Note(s) / Mode(s) Role CSPs Access Non Deterministic Random Number Generation NDRNG N/A User N/A N/A Table 6: Non-Approved but Allowed Service Details for the FIPS Approved mode In non-Approved mode the Module supports the following non-FIPS Approved algorithms, which shall not be used in the FIPS Approved mode of operation: Service Algorithms Note(s) / Mode(s) Role CSPs Access Symmetric encryption/ decryption AES XTS with 192-bit keys User 192 bits AES keys R, W, EX DES ECB 56 bits DES keys Message digest SHA-1 (multiple- bufer implementation) N/A User N/A R, W, EX Keyed hash HMAC Keys smaller than 112 bits User HMAC keys with size less than 112 bits R, W, EX Random number generation ansi_cprng N/A User seed R, W, EX Key agreement Dife-Hellman Shared secret computation User Dife-Hellman private keys (1536 bits and larger) R, W, EX EC Dife-Hellman EC Dife-hellman private keys (P-192 and P-256) Table 7: Service Details for the non-FIPS mode 3.3 Authentication The module is a Level 1 software-only cryptographic module and does not implement authentication. The role is implicitly assumed based on the service requested. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 11 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy 4 Physical Security The module is comprised of software only and thus does not claim any physical security. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 12 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy 5 Operational Environment 5.1 Applicability The Red Hat Enterprise Linux operating system is used as the basis of other products which include but are not limited to: • Red Hat Enterprise Linux Atomic Host • Red Hat Virtualization (RHV) • Red Hat OpenStack Platform • OpenShift Container Platform • Red Hat Gluster Storage • Red Hat Ceph Storage • Red Hat CloudForms • Red Hat Satellite. Compliance is maintained for these products whenever the binary is found unchanged. The module operates in a modifable operational environment per FIPS 140-2 level 1 specifcations. The module runs on a commercially available general-purpose operating system executing on the hardware specifed in section 1.2. 5.2 Policy The operating system is restricted to a single operator (concurrent operators are explicitly excluded). The application that request cryptographic services is the single user of the module, even when the application is serving multiple clients. In FIPS Approved mode, the ptrace(2) system call, the debugger (gdb(1)), and strace(1) shall be not used. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 13 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy 6 Cryptographic Key Management The application that uses the module is responsible for appropriate destruction and zeroization of the key material. The library provides functions for key allocation and destruction, which overwrites the memory that is occupied by the key information with “zeros” before it is deallocated. 6.1 Random Number Generation The module employs the Deterministic Random Bit Generator (DRBG) based on [SP800-90A] for the creation of random numbers. The DRBG is initialized during module initialization. The module loads by default the DRBG using HMAC DRBG with SHA-512, with derivation function, without prediction resistance. The DRBG is seeded during initialization with a seed obtained from /dev/urandom of length 3/2 times the DRBG strength. Please note that /dev/urandom is an NDRNG located within the module's physical boundary but outside its logical boundary. The NDRNG provides 256 bits of entropy. The module implements the health checks defned by SP 800-90A, section 11.3. The noise source of /dev/urandom implements continuous tests. Here are listed the CSPs/keys details concerning storage, input, output, generation and zeroization: Type Keys/CSPs Key Generation Key Storage Key Entry/Output Key Zeroization Symmetric keys AES N/A Protected kernel memory API allows caller on the same GPC to supply key Memory is automatically overwritten by zeroes when freeing the cipher handler Triple-DES N/A Protected kernel memory API allows caller on the same GPC to supply key Memory is automatically overwritten by zeroes when freeing the cipher handler DRBG SP800-90A entropy string SP 800-90A DRBG Entropy string The seed data obtained from /dev/urandom Module’s application memory N/A Automatic zeroization when seeding operation completes SP 800-90A DRBG nonce SP 800-90A DRBG Seed and internal state values V, C and K Based on entropy string as defned in SP 800-90A Protected kernel memory N/A Memory is automatically overwritten by zeroes when freeing the cipher handler HMAC keys HMAC keys N/A Protected kernel memory HMAC key can be supplied by calling application Memory is automatically overwritten by zeroes when freeing the cipher handler HMAC key used for integrity HMAC key N/A – Installed as aprt of the module Persistently stored in plaintext as part of the sha512hmac N/A - key is only used for integrity verifcation Zeroized in memory by sha512hmac ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 14 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy application Table 8: Keys/CSPs As defned in SP800-90A, the DRBG obtains the entropy string and nonce from the Linux kernel non-deterministic random number generator during: a. initialization of a DRBG instance b. after 2⁴⁸ requests for random numbers The module does not provide any key generation service or perform key generation for any of its Approved algorithms. Keys are passed in from calling application via API parameters. 6.2 Key / Critical Security Parameter (CSP) Access An authorized application as user (the User role) has access to all key data generated during the operation of the module. Moreover, the module does not support the output of intermediate key generation values during the key generation process. 6.3 Key / CSP Storage Symmetric keys are provided to the module by the calling process, and are destroyed when released by the appropriate API function calls. The module does not perform persistent storage of keys. The RSA public key used for signature verifcation of the kernel loadable components is stored outside of the module’s boundary, in a keyring fle in /proc/keys/. 6.4 Key / CSP Zeroization When a calling kernel components calls the appropriate API function that operation overwrites memory with 0s and then frees that memory (please see the API document for full details). ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 15 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy 7 Electromagnetic Interference/Electromagnetic Compatibility (EMI/EMC) MARKETING NAME......................….PowerEdge R630 REGULATORY MODEL................…..E26S REGULATORY TYPE.....................….E26S001 EFFECTIVE DATE..........................…September 03, 2014 EMC EMISSIONS CLASS...............…Class A This product has been determined to be compliant with the applicable standards, regulations, and directives for the countries where the product is marketed. The product is afxed with regulatory marking and text as necessary for the country/agency. Generally, Information Technology Equipment (ITE) product compliance is based on IEC and CISPR standards and their national equivalent such as Product Safety, IEC 60950-1 and European Norm EN 60950-1 or EMC, CISPR 22/CISPR 24 and EN 55022/55024. Dell products have been verifed to comply with the EU RoHS Directive 2011/65/EU. Dell products do not contain any of the restricted substances in concentrations and applications not permitted by the RoHS Directive. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 16 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy 8 Self-Tests FIPS 140-2 requires that the Module perform self-tests to ensure the integrity of the Module and the correctness of the cryptographic functionality at start up. In addition, the module performs conditional test for DRBG. A failure of any of the self-tests panics the Module. The only recovery is to reboot. For persistent failures, you must reinstall the kernel. See section 9.1 for details. No operator intervention is required during the running of the self-tests. 8.1 Power-Up Self-Tests The module performs power-up self-tests at module initialization to ensure that the module is not corrupted and that the cryptographic algorithms work as expected. The self-tests are performed without any user intervention. While the module is performing the power-up tests, services are not available and input or output is not possible: the module is single-threaded and will not return to the calling application until the self-tests are completed successfully. 8.1.1 Integrity Tests The Module performs power-up self tests (at module initialization). Input, output, and cryptographic functions cannot be performed while the Module is in a self test or error state. The Module is single-threaded during the self tests and will stop the boot procedure, and therefore any subsequent operation before any other kernel component can request services from the Module. The Crypto Ofcer with physical or logical access to the Module can run the POST (Power-On Self-Tests) on demand by power cycling the Module or by rebooting the operating system. For Known Answer Test, HMAC SHA-512 provided by the NSS bound module is tested before the NSS module makes itself available to the sha512hmac application. In addition, if the Intel AES-NI support is present and the dracut-fps aesni RPM package (see section 1) is installed, the AES-NI implementation is self-tested with the same KAT vector as the other AES implementations. An HMAC SHA-512 (provided by the NSS bound module) calculation is performed on the sha512hmac utility and static Linux kernel binary to verify their integrity. The Linux kernel crypto API kernel components, and any additional code components loaded into the Linux kernel are checked with the RSA signature verifcation implementation of the Linux kernel when loading them into the kernel to confrm their integrity. NOTE: The fact that the kernel integrity check passed, which requires the loading of sha512hmac with the self tests implies a successful execution of the integrity and self tests of sha512hmac (the HMAC is stored in /usr/lib/hmaccalc/sha512hmac.hmac). With respect to the integrity check of kernel loadable components providing the cryptographic functionality, the fact that the self test of these cryptographic components are displayed implies that the integrity checks of each kernel component passed successfully. The table below summarizes the power-on self tests performed by the module, which includes the Integrity Test of the module itself as stated above and the Known Answer Test for each approved cryptographic algorithm. Algorithm Test AES KAT, encryption and decryption are tested separately Triple-DES KAT, encryption and decryption are tested separately RSA signature verifcation Part of the integrity test (considered as a KAT) ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 17 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy DRBG (CTR, Hash, HMAC) KAT HMAC SHA-1, -224, -256, -384, -512 KAT SHA-1, -224, -256, -384, -512 KAT Integrity check HMAC SHA-512 Table 9: Module Self-Tests 8.2 Conditional Tests The module does not perform any conditional tests. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 18 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy 9 Guidance 9.1 Cryptographic Ofcer Guidance To operate the Kernel Crypto API module, the operating system must be restricted to a single operator mode of operation. (This should not be confused with single user mode which is runlevel 1 on RHEL. This refers to processes having access to the same cryptographic instance which RHEL ensures cannot happen by the memory management hardware.) 9.1.1 Secure Installation and Startup Crypto Ofcers use the Installation instructions to install the Module in their environment. The version of the RPM containing the FIPS validated module is stated in section 1.1 above. The integrity of the RPM is automatically verifed during the installation and the Crypto Ofcer shall not install the RPM fle if the RPM tool indicates an integrity error. To bring the Module into FIPS approved mode, perform the following: 1. Install the dracut-fps package: # yum install dracut-fips 2. Recreate the INITRAMFS image: # dracut -f After regenerating the initramfs, the Crypto Ofcer has to append the following string to the kernel command line by changing the setting in the boot loader: fips=1 If /boot or /boot/efi resides on a separate partition, the kernel parameter boot= must be supplied. The partition can be identifed with the command "df /boot" or "df /boot/efi" respectively. For example: $ df /boot Filesystem 1K-blocks Used Available Use% Mounted on /dev/sda1 233191 30454 190296 14% /boot The partition of /boot is located on /dev/sda1 in this example. Therefore, the following string needs to be appended to the kernel command line: boot=/dev/sda1 9.1.2 FIPS 140-2 and AES NI Support According to the Kernel Crypto API FIPS 140-2 Security Policy, the Kernel Crypto API module supports the AES-NI Intel processor instruction set as an approved cipher. The AES-NI instruction set is used by the Module. In case you confgured a full disk encryption using AES, you may use the AES-NI support for a higher performance compared to the software-only implementation. To utilize the AES-NI support, the mentioned Module must be loaded during boot time by installing a plugin. Before you install the plugin, you MUST verify that your processor ofers the AES-NI instruction set by calling the following command: cat /proc/cpuinfo | grep aes If the command returns a list of properties, including the “aes” string, your CPU provides the AES-NI instruction set. If the command returns nothing, AES-NI is not supported. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 19 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy You MUST NOT install the following plugin if your CPU does not support AES-NI because the kernel will panic during boot. The support for the AES-NI instruction set during boot time is enabled by installing the following plugin (make sure that the version of the plugin RPM matches the version of the installed RPMs!): # install the dracut-fips-aesni package yum install dracut-fips-aesni-*.noarch.rpm # recreate the initramfs image dracut -f The changes come into efect during the next reboot. 9.2 User Guidance CTR and RFC3686 mode must only be used for IPsec. It must not be used otherwise. There are three implementations of AES: aes-generic, aesni-intel, and aes-x86_64 on x86_64 machines. The additional specifc implementations of AES for the x86 architecture are disallowed and not available on the test platforms. When using the Module, the user shall utilize the Linux Kernel Crypto API provided memory allocation mechanisms. In addition, the user shall not use the function copy_to_user() on any portion of the data structures used to communicate with the Linux Kernel Crypto API. Only the cryptographic mechanisms provided with the Linux Kernel Crypto API are considered for use. The NSS bound module, although used, is only considered to support the integrity verifcation and is not intended for general-purpose use with respect to this Module. 9.2.1 XTS Usage The XTS mode must only be used for the disk encryption functionality ofered by dm-crypt. The AES-XTS mode shall only be used for the cryptographic protection of data on storage devices. The AES-XTS shall not be used for other purposes, such as the encryption of data in transit. 9.2.2 GCM Usage In case the module’s power is lost and then restored, the key used for the AES-GCM encryption or decryption shall be redistributed. The module generates the IV internally randomly with an approved SP 800-90B DRBG, which is compliant with provision 2) of IG A.5. When a GCM IV is used for decryption, the responsibility for the IV generation lies with the party that performs the AES-GCM encryption therefore there is no restriction on the IV generation. 9.2.3 Triple-DES Usage According to IG A.13, the same Triple-DES key shall not be used to encrypt more than 2^16 64-bit blocks of data. It is the user’s responsibility to make sure that the module complies with this requirement and that the module does not exceed this limit. 9.3 Handling Self Test Errors Self test failure within the Kernel Crypto API module or the dm-crypt kernel component will panic the kernel and the operating system will not load. Recover from this error by trying to reboot the system. If the failure continues, you must reinstall the software package being sure to follow all instructions. If you downloaded the ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 20 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy software verify the package hash to confrm a proper download. Contact Red Hat if these steps do not resolve the problem. The Kernel Crypto API module performs a power-on self test that includes an integrity check and known answer tests for the available cryptographic algorithms. The kernel dumps self test success and failure messages into the kernel message ring bufer. Post boot, the messages are moved to /var/log/messages. Use dmesg to read the contents of the kernel ring bufer. The format of the ringbufer (dmesg) output is: alg: self-tests for %s (%s) passed Typical messages are similar to "alg: self-tests for xts(aes) (xts(aes-x86_64)) passed" for each algorithm/sub-algorithm type. ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 21 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy Appendix A Glossary and Abbreviations AES Advanced Encryption Standard AES-NI Advanced Encryption Standard New Instructions CAVP Cryptographic Algorithm Validation Program CBC Cipher Block Chaining CCM Counter with Cipher Block Chaining Message Authentication Code CFB Cipher Feedback CMAC Cipher-based Message Authentication Code CMVP Cryptographic Module Validation Program CSP Critical Security Parameter CTR Counter Mode DES Data Encryption Standard DSA Digital Signature Algorithm DRBG Deterministic Random Bit Generator ECB Electronic Code Book ECC Elliptic Curve Cryptography FFC Finite Field Cryptography FIPS Federal Information Processing Standards Publication FSM Finite State Model GCM Galois Counter Mode HMAC Hash Message Authentication Code KAS Key Agreement Schema KAT Known Answer Test MAC Message Authentication Code NDF No Derivation Function NIST National Institute of Science and Technology NDRNG Non-Deterministic Random Number Generator OFB Output Feedback O/S Operating System PAA Processor Algorithm Acceleration PR Prediction Resistance PSS Probabilistic Signature Scheme RNG Random Number Generator RSA Rivest, Shamir, Addleman ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 22 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy SHA Secure Hash Algorithm SHS Secure Hash Standard TDES Triple DES XTS XEX-based Tweaked-codebook mode with ciphertext Stealing ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 23 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy Appendix B References FIPS180-4 Secure Hash Standard (SHS) March 2012 http://csrc.nist.gov/publications/fps/fps180-4/fps 180-4.pdf FIPS186-4 Digital Signature Standard (DSS) July 2013 http://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-4.pdf FIPS197 Advanced Encryption Standard November 2001 http://csrc.nist.gov/publications/fps/fps197/fps-197.pdf FIPS198-1 The Keyed Hash Message Authentication Code (HMAC) July 2008 http://csrc.nist.gov/publications/fps/fps198 1/FIPS-198 1_fnal.pdf RFC3394 Advanced Encryption Standard (AES) Key Wrap Algorithm September 2002 http://www.ietf.org/rfc/rfc3394.txt RFC5649 Advanced Encryption Standard (AES) Key Wrap with Padding Algorithm September 2009 http://www.ietf.org/rfc/rfc5649.txt SP800-38A NIST Special Publication 800-38A - Recommendation for Block Cipher Modes of Operation Methods and Techniques December 2001 http://csrc.nist.gov/publications/nistpubs/800-38a/sp800-38a.pdf SP800-38B NIST Special Publication 800-38B - Recommendation for Block Cipher Modes of Operation: The CMAC Mode for Authentication May 2005 http://csrc.nist.gov/publications/nistpubs/800-38B/SP_800-38B.pdf SP800-38C NIST Special Publication 800-38C - Recommendation for Block Cipher Modes of Operation: the CCM Mode for Authentication and Confdentiality May 2004 http://csrc.nist.gov/publications/nistpubs/800-38C/SP800-38C_updated July20_2007.pdf SP800-38D NIST Special Publication 800-38D - Recommendation for Block Cipher Modes of Operation: Galois/Counter Mode (GCM) and GMAC November 2007 http://csrc.nist.gov/publications/nistpubs/800-38D/SP-800-38D.pdf SP800-38E NIST Special Publication 800-38E - Recommendation for Block Cipher Modes of Operation: The XTS AES Mode for Confdentiality on Storage Devices January 2010 http://csrc.nist.gov/publications/nistpubs/800-38E/nist-sp-800-38E.pdf SP800-38F NIST Special Publication 800-38F - Recommendation for Block Cipher Modes of Operation: Methods for Key Wrapping December 2012 http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-38F.pdf ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 24 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice. Red Hat Enterprise Linux Kernel Crypto API Cryptographic ModuleFIPS 140-2 Non-Proprietary Security Policy SP800-56A NIST Special Publication 800-56A Revision 2 - Recommendation for Pair Wise Key Establishment Schemes Using Discrete Logarithm Cryptography May 2013 http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800 56Ar2.pdf SP800-56C Recommendation for Key Derivation through Extraction-then- Expansion November 2011 http://csrc.nist.gov/publications/nistpubs/800-56C/SP-800-56C.pdf SP800-67 NIST Special Publication 800-67 Revision 1 - Recommendation for the Triple Data Encryption Algorithm (TDEA) Block Cipher January 2012 http://csrc.nist.gov/publications/nistpubs/800-67-Rev1/SP-800-67-Rev1.pdf SP800-90A NIST Special Publication 800-90A - Recommendation for Random Number Generation Using Deterministic Random Bit Generators January 2012 http://csrc.nist.gov/publications/nistpubs/800-90A/SP800-90A.pdf SP800-90B NIST Draft Special Publication 800-90B - Recommendation for the Entropy Sources Used for Random Bit Generation August 2012 http://csrc.nist.gov/publications/drafts/800-90/draft-sp800-90b.pdf SP800-108 NIST Special Publication 800-108 - Recommendation for Key Derivation Using Pseudorandom Functions October 2009 http://csrc.nist.gov/publications/nistpubs/800-108/sp800-108.pdf SP800-131A NIST Special Publication 800-131A - Transitions: Recommendation for Transitioning the Use of Cryptographic Algorithms and Key Lengths January 2011 http://csrc.nist.gov/publications/nistpubs/800-131A/sp800-131A.pdf ©2019 Red Hat Enterprise Linux / atsec information security corporation Page 25 of 25 This document can be reproduced and distributed only whole and intact, including this copyright notice.