8 Jipher Reference Information
Supported Algorithm Strings
The following table lists the algorithm strings and their aliases supported by Jipher. These strings are grouped by their associated engine class.
Table 8-1 Algorithm Strings Supported by Jipher
Engine | Supported Algorithm Strings and Their Aliases | Notes |
---|---|---|
SecureRandom |
DRBG (SHA1PRNG ,
CTRDRBG , CTRDRBG128 ,
NativePRNG ,
NativePRNGNonBlocking )
|
All aliases use the same underlying DRBG algorithm from OpenSSL |
MessageDigest |
SHA-1 (SHA , SHA1 , 1.3.14.3.2.26 , OID.1.3.14.3.2.26
)
|
— |
|
— | |
|
— | |
Cipher |
|
— |
|
— | |
|
— | |
|
RFC 3394 | |
|
RFC 5649 | |
|
PBES2 password-based cipher | |
|
PKCS #12 password-based encryption.
The key derivation function used for this algorithm is a not a FIPS 140 allowed algorithm. This algorithm will be removed in a future release of Jipher. See Supported Non-FIPS 140 Allowed Algorithms. |
|
|
— | |
|
— | |
KeyFactory |
|
— |
Signature |
|
RSA with PKCS1 |
|
— | |
|
— | |
|
— | |
Mac |
|
— |
|
PKCS #12 password-based encryption HMAC algorithms
The key derivation function used for these algorithms is not a FIPS 140 allowed algorithm. These algorithms will be removed in a future release of Jipher. See Supported Non-FIPS 140 Allowed Algorithms. |
|
KeyGenerator |
|
— |
|
— | |
|
These non-standard KeyGenerator algorithms are needed to provide the cryptography required by the SunJSSE provider to support TLSv1.2. | |
AlgorithmParameters |
|
— |
|
— | |
|
The key derivation function used for the PBEWithSHA1AndDESede algorithm is a not a FIPS 140 allowed algorithm. The PBEWithSHA1AndDESede algorithm will be removed in a future release of Jipher. See Supported Non-FIPS 140 Allowed Algorithms. | |
|
— | |
KeyPairGenerator |
|
— |
AlgorithmParameterGenerator |
|
— |
SecretKeyFactory |
|
— |
|
— | |
|
— | |
|
The key derivation function used for this algorithm is a not a FIPS 140 allowed algorithm. This algorithm will be removed in a future release of Jipher. See Supported Non-FIPS 140 Allowed Algorithms. | |
KeyAgreement |
|
— |
Supported Non-FIPS 140 Allowed Algorithms
Note:
Support for the PKCS #12 KDF algorithm will be removed in a future Jipher release. Once Jipher no longer supports the PKCS #12 KDF algorithm, it will no longer support the following algorithms (and aliases):- AlgorithmParameters
- PBEWithSHA1AndDESede (OID.1.2.840.113549.1.12.1.3, 1.2.840.113549.1.12.1.3)
- Cipher
- PBEWithSHA1AndDESede (OID.1.2.840.113549.1.12.1.3, 1.2.840.113549.1.12.1.3)
- SecretKeyFactory
- PBEWithSHA1AndDESede (OID.1.2.840.113549.1.12.1.3, 1.2.840.113549.1.12.1.3)
- Mac
- HmacPBESHA1
- HmacPBESHA224
- HmacPBESHA256
- HmacPBESHA384
- HmacPBESHA512
Jipher supports the PKCS #12 Key Derivation Function (KDF) algorithm as described in Appendix B. Deriving Keys and IVs from Passwords and Salt in RFC 7292 - PKCS #12: Personal Information Exchange Syntax v1.1. This algorithm is not allowed by FIPS 140. This algorithm is supported for interoperability reasons, specifically to support the following:
- Password integrity mode: Integrity is guaranteed through a Message Authentication Code
(MAC) derived from a secret integrity password. The PKCS #12 KDF algorithm is used to
derive a MAC key for this mode in the
Mac
algorithms HmacPBESHA1, HmacPBESHA224, HmacPBESHA256, HmacPBESHA384, and HmacPBESHA512. - Password privacy mode: Personal information is encrypted with a symmetric key derived
from a user name and a privacy password. The PKCS #12 KDF algorithm is used to derive a
decryption key for this mode in the
Cipher
algorithm PBEWithSHA1AndDESede. Note that this use of the PKCS #12 KDF algorithm is deprecated.
Keysize Restrictions
Jipher uses the following default key sizes (in bits) and enforces the following restrictions for KeyGenerator, KeyPairGenerator, and AlgorithmParameterGenerator.
KeyGenerator
Jipher honors the
system property jdk.security.defaultKeySize
, which enables users to
configure the default key size used by KeyGenerator. The value of this
property is a list of comma-separated entries. Each entry consists of a case-insensitive
algorithm name and the corresponding default key size (in decimal) separated by a
colon.
Table 8-2 KeyGenerator Algorithms and Default Key Sizes
Algorithm Name | Default Key Size | Restrictions and Comments |
---|---|---|
AES | 256 if permitted by the cryptographic policy (see Import Limits on Cryptographic Algorithms), 128 otherwise. | Key size must be equal to 128, 192, or 256. |
AES_128/<mode>/<padding> | 128 | Key size must be equal to 128. |
AES_192/<mode>/<padding> | 192 | Key size must be equal to 192. |
AES_256/<mode>/<padding> | 256 | Key size must be equal to 256. |
DESede (Triple DES) | 192 | Key size must be equal to 168 or 192. |
HmacSHA1 | 160 |
Key size must be at least 40 bits. Key sizes that are not a multiple of 8 are increased to the next multiple of 8. |
HmacSHA224 | 224 |
Key size must be at least 40 bits. Key sizes that are not a multiple of 8 are increased to the next multiple of 8. |
HmacSHA256 | 256 |
Key size must be at least 40 bits. Key sizes that are not a multiple of 8 are increased to the next multiple of 8. |
HmacSHA384 | 384 |
Key size must be at least 40 bits. Key sizes that are not a multiple of 8 are increased to the next multiple of 8. |
HmacSHA512 | 512 |
Key size must be at least 40 bits. Key sizes that are not a multiple of 8 are increased to the next multiple of 8. |
KeyPairGenerator
Jipher honors the
system property jdk.security.defaultKeySize
, which enables users to
configure the default key size used by KeyPairGenerator. The value of
this property is a list of comma-separated entries. Each entry consists of a
case-insensitive algorithm name and the corresponding default key size (in decimal)
separated by a colon.
Table 8-3 KeyPairGenerator Algorithms and Default Key Sizes
Algorithm Name | Default Key Size | Restrictions and Comments |
---|---|---|
DiffieHellman | 3072 |
Key size must be equal to 2048, 3072 or 4096. Algorithm parameter specification must specify an approved FFC Safe-prime group defined in SP 800-56A Rev. 3, "Appendix D: Approved ECC Curves and FFC Safe-prime Groups." |
DSA | 2048 |
Key size must be equal to 2048 or 3072. Algorithm parameter specification must specify one of the following (prime size, sub-prime size) ___domain parameter size pairings (2048, 224), (2048, 256) or (3072, 256). |
EC | 256 |
Key size must be equal to 224, 256, 384, 521. Algorithm parameter specification must specify one the four approved ECC named curves listed in Approved ECC Named Curves and SP 800-56A Rev. 3, "Appendix D: Approved ECC Curves and FFC Safe-prime Groups" defined in RFC 8422: Elliptic Curve Cryptography (ECC) Cipher Suites for Transport Layer Security (TLS) Versions 1.2 and Earlier. |
RSA and RSASSA-PSS | 3072 |
Key size must be between 2,048 and 15,360 bits. The public exponent length must exceed 16 bits and cannot exceed 256 bits. If the key size exceeds 3072, then the public exponent length cannot exceed 64 bits. |
Approved ECC Named Curves
Standard for Efficient Cryptography Group (SECG) Name | NIST | OID |
---|---|---|
secp224r1 | P-224 | 1.3.132.0.33 |
secp256r1 | P-256 | 1.2.840.10045.3.1.7 |
secp384r1 | P-384 | 1.3.132.0.34 |
secp521r1 | P-521 | 1.3.132.0.35 |
AlgorithmParameterGenerator
Table 8-4 AlgorithmParameterGenerator Algorithms and Default Key Sizes
Algorithm Name | Default Key Size | Restrictions and Comments |
---|---|---|
DSA | 2048 |
Key size must be equal to 2048 or 3072. Algorithm parameter specification must specify one of the following (prime size, sub-prime size) ___domain parameter size pairings (2048, 224), (2048, 256), or (3072, 256). |
Supported Elliptic Curve Names
Jipher supports only a fixed set of named (published) elliptic curves. These are NIST-recommended curves based on prime fields.
The following table lists the elliptic curves that are provided by Jipher.
Table 8-5 Supported Elliptic Curve Names
Elliptic Curve | Object Identifier and Aliases | Aliases |
---|---|---|
secp224r1 | 1.3.132.0.33 |
P-224 , P224 |
secp256r1 | 1.2.840.10045.3.1.7 |
P-256 , P256 ,
prime256v1 |
secp384r1 | 1.3.132.0.34 |
P-384 , P384 |
secp521r1 | 1.3.132.0.35 |
P-521 , P521 |
Default Diffie-Hellman Parameters
When generating Diffie-Hellman (DH) key pairs, default DH parameters are selected based on key size. Supported key sizes are 2048, 3072, and 4096.
The default parameters are from RFC 7919: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for Transport Layer Security.
Table 8-6 Default DH Parameters
Key Size | Default Parameter |
---|---|
2048 | ffdhe2048 |
3072 | ffdhe3072 |
4096 | ffdhe4096 |
Default Digital Signature Algorithm Parameters
When generating Default Digital Signature Algorithm (DSA) key pairs, default DSA parameters are selected based on key size. Supported key sizes are 2048 and 3072.
The default parameters are verifiably generated using the FIPS 186-4 algorithm. Line breaks have been added for the values of P and G for clarity.
Table 8-7 Default DSA Parameters for the Key Size 2048
Parameter Name | Default Parameter Value |
---|---|
Qlen |
|
Digest |
|
P |
|
Q |
|
G |
|
seed |
|
j |
|
counter |
|
Table 8-8 Default DSA Parameters for the Key Size 3072
Parameter Name | Default Parameter Value |
---|---|
Qlen |
|
Digest |
|
P |
|
Q |
|
G |
|
seed |
|
j |
|
counter |
|