|
12 | 12 | */
|
13 | 13 | public interface PublicKeyAlgorithmTags
|
14 | 14 | {
|
| 15 | + /** |
| 16 | + * RSA encryption/signing algorithm. |
| 17 | + */ |
15 | 18 | int RSA_GENERAL = 1; // RSA (Encrypt or Sign)
|
| 19 | + /** |
| 20 | + * Deprecated tag for encrypt-only RSA. |
| 21 | + * MUST NOT be generated. |
| 22 | + */ |
16 | 23 | int RSA_ENCRYPT = 2; // RSA Encrypt-Only
|
| 24 | + /** |
| 25 | + * Deprecated tag for sign-only RSA. |
| 26 | + * MUST NOT be generated. |
| 27 | + */ |
17 | 28 | int RSA_SIGN = 3; // RSA Sign-Only
|
| 29 | + /** |
| 30 | + * Encrypt-only ElGamal. |
| 31 | + */ |
18 | 32 | int ELGAMAL_ENCRYPT = 16; // Elgamal (Encrypt-Only), see [ELGAMAL]
|
| 33 | + /** |
| 34 | + * DSA. |
| 35 | + */ |
19 | 36 | int DSA = 17; // DSA (Digital Signature Standard)
|
20 | 37 | /**
|
21 |
| - * @deprecated use ECDH |
| 38 | + * Deprecated tag for ECDH. |
| 39 | + * @deprecated use {@link #ECDH} instead. |
| 40 | + */ |
| 41 | + int EC = 18; // Misnamed constant |
| 42 | + /** |
| 43 | + * Elliptic curve Diffie-Hellman. |
| 44 | + */ |
| 45 | + int ECDH = 18; // Elliptic Curve Diffie-Hellman |
| 46 | + /** |
| 47 | + * Elliptic curve digital signing algorithm. |
| 48 | + */ |
| 49 | + int ECDSA = 19; // Elliptic Curve Digital Signing Algorithm |
| 50 | + /** |
| 51 | + * Reserved tag for sign+encrypt ElGamal. |
| 52 | + * MUST NOT be generated. |
| 53 | + * An implementation MUST NOT generate ElGamal signatures. |
| 54 | + */ |
| 55 | + int ELGAMAL_GENERAL = 20; // Reserved Elgamal (Encrypt or Sign) |
| 56 | + /** |
| 57 | + * Reserved tag for IETF-style S/MIME Diffie-Hellman. |
22 | 58 | */
|
23 |
| - int EC = 18; // Reserved for Elliptic Curve |
24 |
| - int ECDH = 18; // Reserved for Elliptic Curve (actual algorithm name) |
25 |
| - int ECDSA = 19; // Reserved for ECDSA |
26 |
| - int ELGAMAL_GENERAL = 20; // Elgamal (Encrypt or Sign) |
27 | 59 | int DIFFIE_HELLMAN = 21; // Reserved for Diffie-Hellman (X9.42, as defined for IETF-S/MIME)
|
28 | 60 | /**
|
29 |
| - * @deprecated use Ed25519 or Ed448 |
| 61 | + * Misnamed tag for legacy EdDSA. |
| 62 | + * @deprecated use {@link #EDDSA_LEGACY} instead. |
| 63 | + */ |
| 64 | + int EDDSA = 22; // EdDSA - (internet draft, but appearing in use); misnamed constant |
| 65 | + /** |
| 66 | + * Legacy EdDSA (curve identified by OID). |
| 67 | + * MUST NOT be used with v6 keys (use {@link #Ed25519}, {@link #Ed448} instead). |
30 | 68 | */
|
31 |
| - int EDDSA = 22; // EdDSA - (internet draft, but appearing in use) |
32 | 69 | int EDDSA_LEGACY = 22; // new name for old EDDSA tag.
|
33 |
| - |
34 |
| - int X25519 = 25; |
35 |
| - int X448 = 26; |
36 |
| - int Ed25519 = 27; |
37 |
| - int Ed448 = 28; |
| 70 | + /** |
| 71 | + * X25519 encryption algorithm. |
| 72 | + * C-R compliant implementations MUST implement support for this. |
| 73 | + */ |
| 74 | + int X25519 = 25; // X25519 |
| 75 | + /** |
| 76 | + * X448 encryption algorithm. |
| 77 | + */ |
| 78 | + int X448 = 26; // X448 |
| 79 | + /** |
| 80 | + * Ed25519 signing algorithm. |
| 81 | + * C-R compliant implementations MUST implement support for this. |
| 82 | + */ |
| 83 | + int Ed25519 = 27; // new style Ed25519 |
| 84 | + /** |
| 85 | + * Ed448 signing algorithm. |
| 86 | + */ |
| 87 | + int Ed448 = 28; // new style Ed448 |
38 | 88 |
|
39 | 89 | int EXPERIMENTAL_1 = 100;
|
40 | 90 | int EXPERIMENTAL_2 = 101;
|
|
0 commit comments