Skip to content

Commit 127a308

Browse files
committed
Update crypto-refresh references to RFC9580
1 parent 303d59f commit 127a308

37 files changed

+112
-111
lines changed

pg/src/main/j2me/org/bouncycastle/bcpg/S2K.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -452,7 +452,7 @@ public Argon2Params(byte[] salt, int passes, int parallelism, int memSizeExp)
452452

453453
// log_2(p) = log_e(p) / log_e(2)
454454
//double log2_p = Math.log((double)parallelism) / Math.log(2.0);
455-
// see https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-05.html#section-3.7.1.4-5
455+
// see https://www.rfc-editor.org/rfc/rfc9580.html#section-3.7.1.4-5
456456
//if (memSizeExp < (3 + Math.ceil(log2_p)) || memSizeExp > 31)
457457
//{
458458
//throw new IllegalArgumentException("Memory size exponent MUST be between 3+ceil(log_2(parallelism)) and 31");

pg/src/main/java/org/bouncycastle/bcpg/AEADAlgorithmTags.java

+5-5
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22

33
/**
44
* AEAD Algorithm IDs.
5-
* Crypto-Refresh (OpenPGP) defines IDs 1 through 3, while LibrePGP only defines 1 and 2.
6-
* Further, the use of AEAD differs between C-R and LibrePGP.
5+
* RFC9580 (OpenPGP) defines IDs 1 through 3, while LibrePGP only defines 1 and 2.
6+
* Further, the use of AEAD differs between OpenPGP and LibrePGP.
77
*
8-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-aead-algorithms">
9-
* Crypto-Refresh: AEAD Algorithms</a>
8+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-aead-algorithms">
9+
* OpenPGP - AEAD Algorithms</a>
1010
* @see <a href="https://www.ietf.org/archive/id/draft-koch-librepgp-00.html#name-encryption-modes">
1111
* LibrePGP - Encryption Modes</a>
1212
*/
@@ -18,7 +18,7 @@ public interface AEADAlgorithmTags
1818
int EAX = 1;
1919
/**
2020
* OCB with 15-bit nonce/IV and 16-bit auth tag length.
21-
* C-R compliant implementations MUST implement OCB.
21+
* RFC9580-compliant implementations MUST implement OCB.
2222
*/
2323
int OCB = 2;
2424
/**

pg/src/main/java/org/bouncycastle/bcpg/CompressionAlgorithmTags.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55
*
66
* @see <a href="https://www.rfc-editor.org/rfc/rfc4880.html#section-9.3">
77
* RFC4880 - Compression Algorithms</a>
8+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-compression-algorithms">
9+
* RFC9580 - Compression Algorithms</a>
810
* @see <a href="https://www.ietf.org/archive/id/draft-koch-librepgp-00.html#name-compression-algorithms">
911
* LibrePGP - Compression Algorithms</a>
10-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-compression-algorithms">
11-
* Crypto-Refresh - Compression Algorithms</a>
1212
*/
1313
public interface CompressionAlgorithmTags
1414
{

pg/src/main/java/org/bouncycastle/bcpg/ECDHPublicBCPGKey.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616
* If you want to be compatible with legacy applications however, you should use this class instead.
1717
* Note though, that for v6 keys, {@link X25519PublicBCPGKey} or {@link X448PublicBCPGKey} MUST be used for X25519, X448.
1818
*
19-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-algorithm-specific-part-for-ecd">
20-
* Crypto-Refresh - Algorithm-Specific Parts for ECDH Keys</a>
19+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-algorithm-specific-part-for-ecd">
20+
* OpenPGP - Algorithm-Specific Parts for ECDH Keys</a>
2121
*/
2222
public class ECDHPublicBCPGKey
2323
extends ECPublicBCPGKey

pg/src/main/java/org/bouncycastle/bcpg/ECDSAPublicBCPGKey.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
* Base class for an ECDSA Public Key.
1111
* This type is used with {@link PublicKeyAlgorithmTags#ECDSA} and the curve is identified by providing an OID.
1212
*
13-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-algorithm-specific-part-for-ec">
14-
* Crypto-Refresh - Algorithm-Specific Parts for ECDSA Keys</a>
13+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-algorithm-specific-part-for-ec">
14+
* OpenPGP - Algorithm-Specific Parts for ECDSA Keys</a>
1515
*/
1616
public class ECDSAPublicBCPGKey
1717
extends ECPublicBCPGKey

pg/src/main/java/org/bouncycastle/bcpg/ECSecretBCPGKey.java

+6-6
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,12 @@
1616
* If you want to be compatible with legacy applications however, you should use this class instead.
1717
* Note though, that for v6 keys, {@link X25519SecretBCPGKey} or {@link X448SecretBCPGKey} MUST be used for X25519, X448.
1818
*
19-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-algorithm-specific-part-for-ecd">
20-
* Crypto-Refresh - Algorithm-Specific Parts for ECDH Keys</a>
21-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-algorithm-specific-part-for-ec">
22-
* Crypto-Refresh - Algorithm-Specific Parts for ECDSA Keys</a>
23-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-curve25519legacy-ecdh-secre">
24-
* Crypto-Refresh - Curve25519Legacy ECDH Secret Key Material (deprecated)</a>
19+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-algorithm-specific-part-for-ecd">
20+
* OpenPGP - Algorithm-Specific Parts for ECDH Keys</a>
21+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-algorithm-specific-part-for-ec">
22+
* OpenPGP - Algorithm-Specific Parts for ECDSA Keys</a>
23+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-curve25519legacy-ecdh-secre">
24+
* OpenPGP - Curve25519Legacy ECDH Secret Key Material (deprecated)</a>
2525
*/
2626
public class ECSecretBCPGKey
2727
extends BCPGObject

pg/src/main/java/org/bouncycastle/bcpg/Ed25519PublicBCPGKey.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44

55
/**
66
* Public key of type {@link PublicKeyAlgorithmTags#Ed25519}.
7-
* This type was introduced with Crypto-Refresh and can be used with v4, v6 keys.
7+
* This type was introduced with RFC9580 and can be used with v4, v6 keys.
88
* Note however, that legacy implementations might not understand this key type yet.
99
* For a key type compatible with legacy v4 implementations, see {@link EdDSAPublicBCPGKey} with
1010
* {@link PublicKeyAlgorithmTags#EDDSA_LEGACY}.
1111
*
12-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-algorithm-specific-part-for-ed2">
13-
* Crypto-Refresh - Algorithm-Specific Part for Ed25519 Keys</a>
12+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-algorithm-specific-part-for-ed2">
13+
* OpenPGP - Algorithm-Specific Part for Ed25519 Keys</a>
1414
*/
1515
public class Ed25519PublicBCPGKey
1616
extends OctetArrayBCPGKey

pg/src/main/java/org/bouncycastle/bcpg/Ed25519SecretBCPGKey.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44

55
/**
66
* Secret key of type {@link PublicKeyAlgorithmTags#Ed25519}.
7-
* This type was introduced with Crypto-Refresh and can be used with v4, v6 keys.
7+
* This type was introduced with RFC9580 and can be used with v4, v6 keys.
88
* Note however, that legacy implementations might not understand this key type yet.
99
* For a key type compatible with legacy v4 implementations, see {@link EdDSAPublicBCPGKey} with
1010
* {@link PublicKeyAlgorithmTags#EDDSA_LEGACY}.
1111
*
12-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-algorithm-specific-part-for-ed2">
13-
* Crypto-Refresh - Algorithm-Specific Part for Ed25519 Keys</a>
12+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-algorithm-specific-part-for-ed2">
13+
* OpenPGP - Algorithm-Specific Part for Ed25519 Keys</a>
1414
*/
1515
public class Ed25519SecretBCPGKey
1616
extends OctetArrayBCPGKey

pg/src/main/java/org/bouncycastle/bcpg/Ed448PublicBCPGKey.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44

55
/**
66
* Public key of type {@link PublicKeyAlgorithmTags#Ed448}.
7-
* This type was introduced with Crypto-Refresh and can be used with v4, v6 keys.
7+
* This type was introduced with RFC9580 and can be used with v4, v6 keys.
88
* Note however, that legacy implementations might not understand this key type yet.
99
* For a key type compatible with legacy v4 implementations, see {@link EdDSAPublicBCPGKey} with
1010
* {@link PublicKeyAlgorithmTags#EDDSA_LEGACY}.
1111
*
12-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-algorithm-specific-part-for-ed4">
13-
* Crypto-Refresh - Algorithm-Specific Part for Ed448 Keys</a>
12+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-algorithm-specific-part-for-ed4">
13+
* OpenPGP - Algorithm-Specific Part for Ed448 Keys</a>
1414
*/
1515
public class Ed448PublicBCPGKey
1616
extends OctetArrayBCPGKey

pg/src/main/java/org/bouncycastle/bcpg/Ed448SecretBCPGKey.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44

55
/**
66
* Secret key of type {@link PublicKeyAlgorithmTags#Ed448}.
7-
* This type was introduced with Crypto-Refresh and can be used with v4, v6 keys.
7+
* This type was introduced with RFC9580 and can be used with v4, v6 keys.
88
* Note however, that legacy implementations might not understand this key type yet.
99
* For a key type compatible with legacy v4 implementations, see {@link EdDSAPublicBCPGKey} with
1010
* {@link PublicKeyAlgorithmTags#EDDSA_LEGACY}.
1111
*
12-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-algorithm-specific-part-for-ed4">
13-
* Crypto-Refresh - Algorithm-Specific Part for Ed448 Keys</a>
12+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-algorithm-specific-part-for-ed4">
13+
* OpenPGP - Algorithm-Specific Part for Ed448 Keys</a>
1414
*/
1515
public class Ed448SecretBCPGKey
1616
extends OctetArrayBCPGKey

pg/src/main/java/org/bouncycastle/bcpg/EdDSAPublicBCPGKey.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
* Modern OpenPGP uses dedicated key types:
1414
* For {@link PublicKeyAlgorithmTags#Ed25519} see {@link Ed25519PublicBCPGKey} instead.
1515
* For {@link PublicKeyAlgorithmTags#Ed448} see {@link Ed448PublicBCPGKey} instead.
16-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-algorithm-specific-part-for-ed">
17-
* Crypto-Refresh - Algorithm-Specific Parts for EdDSALegacy Keys (deprecated)</a>
16+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-algorithm-specific-part-for-ed">
17+
* OpenPGP - Algorithm-Specific Parts for EdDSALegacy Keys (deprecated)</a>
1818
*/
1919
public class EdDSAPublicBCPGKey
2020
extends ECPublicBCPGKey

pg/src/main/java/org/bouncycastle/bcpg/EdSecretBCPGKey.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
* For {@link PublicKeyAlgorithmTags#Ed25519} see {@link Ed25519SecretBCPGKey} instead.
1111
* For {@link PublicKeyAlgorithmTags#Ed448} see {@link Ed448SecretBCPGKey} instead.
1212
*
13-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-algorithm-specific-part-for-ed">
14-
* Crypto-Refresh - Algorithm-Specific Parts for EdDSALegacy Keys (deprecated)</a>
13+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-algorithm-specific-part-for-ed">
14+
* OpenPGP - Algorithm-Specific Parts for EdDSALegacy Keys (deprecated)</a>
1515
*/
1616
public class EdSecretBCPGKey
1717
extends BCPGObject

pg/src/main/java/org/bouncycastle/bcpg/HashAlgorithmTags.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55
*
66
* @see <a href="https://www.rfc-editor.org/rfc/rfc4880.html#section-9.4">
77
* RFC4880 - Hash Algorithms</a>
8-
* @see <a href="https://www.ietf.org/archive/id/draft-koch-librepgp-00.html#name-hash-algorithms">
8+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-hash-algorithms">
9+
* RFC9580 - Hash Algorithms</a>
10+
* @see <a href="https://www.ietf.org/archive/id/draft-koch-librepgp-01.html#name-hash-algorithms">
911
* LibrePGP - Hash Algorithms</a>
10-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-hash-algorithms">
11-
* Crypto-Refresh - Hash Algorithms</a>
1212
*/
1313
public interface HashAlgorithmTags
1414
{

pg/src/main/java/org/bouncycastle/bcpg/HashUtils.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ public class HashUtils
66
/**
77
* Return the length of the salt per hash algorithm, used in OpenPGP v6 signatures.
88
*
9-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#hash-algorithms-registry">
10-
* Salt Size declarations</a>
9+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#hash-algorithms-registry">
10+
* OpenPGP - Salt Size declarations</a>
1111
* @param hashAlgorithm hash algorithm tag
1212
* @return size of the salt for the given hash algorithm in bytes
1313
*/

pg/src/main/java/org/bouncycastle/bcpg/OnePassSignaturePacket.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
*
2020
* @see <a href="https://www.rfc-editor.org/rfc/rfc4880.html#section-5.4">
2121
* Definition of version 3 OPS packets in RFC4880</a>
22-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-one-pass-signature-packet-t">
23-
* Definition of version 3 and 6 OPS packets in crypto-refresh</a>
22+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-one-pass-signature-packet-t">
23+
* Definition of version 3 and 6 OPS packets in RFC9580</a>
2424
* @see <a href="https://www.ietf.org/archive/id/draft-koch-librepgp-00.html#section-5.4">
2525
* Definition of version 3 and 6 OPS packets in librepgp</a>
2626
*/

pg/src/main/java/org/bouncycastle/bcpg/Packet.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ public boolean hasNewPacketFormat()
5252
* Tags 40 to 59 are reserved for unassigned, non-critical packets.
5353
* Tags 60 to 63 are non-critical private or experimental packets.
5454
*
55-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-09.html#name-packet-tags">
56-
* Packet Tags</a>
55+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-packet-tags">
56+
* OpenPGP - Packet Tags</a>
5757
* @return true if the packet is critical, false otherwise.
5858
*/
5959
public boolean isCritical()

pg/src/main/java/org/bouncycastle/bcpg/PacketFormat.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
/**
44
* OpenPGP Packet Header Length Format.
55
*
6-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-packet-headers">
6+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-packet-headers">
77
* OpenPGP Packet Headers</a>
88
*/
99
public enum PacketFormat

pg/src/main/java/org/bouncycastle/bcpg/PublicKeyAlgorithmTags.java

+8-8
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
/**
44
* Public Key Algorithm IDs.
55
*
6-
* @see <a href="RFC4880 - Public-Key Algorithms">
7-
* https://www.rfc-editor.org/rfc/rfc4880.html#section-9.1</a>
8-
* @see <a href="LibrePGP - Public-Key Algorithms">
9-
* https://www.ietf.org/archive/id/draft-koch-librepgp-00.html#name-public-key-algorithms</a>
10-
* @see <a href="Crypto-Refresh - Public-Key Algorithms">
11-
* https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-public-key-algorithms</a>
6+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-public-key-algorithms">
7+
* RFC9580 - Public-Key Algorithms</a>
8+
* @see <a href="https://www.rfc-editor.org/rfc/rfc4880.html#section-9.1">
9+
* RFC4880 - Public-Key Algorithms</a>
10+
* @see <a href="https://www.ietf.org/archive/id/draft-koch-librepgp-00.html#name-public-key-algorithms">
11+
* LibrePGP - Public-Key Algorithms</a>
1212
*/
1313
public interface PublicKeyAlgorithmTags
1414
{
@@ -80,7 +80,7 @@ public interface PublicKeyAlgorithmTags
8080
int AEDSA = 24; // Reserved
8181
/**
8282
* X25519 encryption algorithm.
83-
* C-R compliant implementations MUST implement support for this.
83+
* RFC9580-compliant implementations MUST implement support for this.
8484
*/
8585
int X25519 = 25; // X25519
8686
/**
@@ -89,7 +89,7 @@ public interface PublicKeyAlgorithmTags
8989
int X448 = 26; // X448
9090
/**
9191
* Ed25519 signing algorithm.
92-
* C-R compliant implementations MUST implement support for this.
92+
* RFC9580-compliant implementations MUST implement support for this.
9393
*/
9494
int Ed25519 = 27; // new style Ed25519
9595
/**

pg/src/main/java/org/bouncycastle/bcpg/PublicKeyPacket.java

+15-15
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010
* An OpenPGP certificate (transferable public key) consists of one primary key and optionally multiple subkey packets.
1111
*
1212
* @see <a href="https://www.rfc-editor.org/rfc/rfc4880.html#section-5.5.1.1">
13-
* rfc4880 - Public-Key Packet</a>
14-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-public-key-packet-type-id-6">
15-
* C-R - Public-Key Packet</a>
13+
* RFC4880 - Public-Key Packet</a>
14+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-public-key-packet-type-id-6">
15+
* RFC9580 - Public-Key Packet</a>
1616
* @see <a href="https://www.ietf.org/archive/id/draft-koch-librepgp-00.html#name-public-key-packet-tag-6">
1717
* LibrePGP - Public-Key Packet</a>
1818
*/
@@ -24,15 +24,15 @@ public class PublicKeyPacket
2424
* OpenPGP v3 keys are deprecated.
2525
* They can only be used with RSA.
2626
*
27-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-version-3-public-keys">
28-
* C-R - Version 3 Public Keys</a>
27+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-version-3-public-keys">
28+
* OpenPGP - Version 3 Public Keys</a>
2929
*/
3030
public static final int VERSION_3 = 3;
3131
/**
3232
* OpenPGP v4 keys are (at the time of writing) widely used, but are subject to some attacks.
3333
*
34-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-version-4-public-keys">
35-
* C-R - Version 4 Public Keys</a>
34+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-version-4-public-keys">
35+
* OpenPGP - Version 4 Public Keys</a>
3636
*/
3737
public static final int VERSION_4 = 4;
3838
/**
@@ -42,8 +42,8 @@ public class PublicKeyPacket
4242
/**
4343
* OpenPGP v6 keys are newly introduced.
4444
*
45-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-version-6-public-keys">
46-
* C-R - Version 6 Public Keys</a>
45+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-version-6-public-keys">
46+
* OpenPGP - Version 6 Public Keys</a>
4747
*/
4848
public static final int VERSION_6 = 6;
4949

@@ -111,12 +111,12 @@ public class PublicKeyPacket
111111
* @param newPacketFormat packet format
112112
* @throws IOException if the key packet cannot be parsed
113113
*
114-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-version-3-public-keys">
115-
* C-R - Version 3 Public Keys</a>
116-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-version-4-public-keys">
117-
* C-R - Version 4 Public Keys</a>
118-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-version-6-public-keys">
119-
* C-R - Version 6 Public Keys</a>
114+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-version-3-public-keys">
115+
* OpenPGP - Version 3 Public Keys</a>
116+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-version-4-public-keys">
117+
* OpenPGP - Version 4 Public Keys</a>
118+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-version-6-public-keys">
119+
* OpenPGP - Version 6 Public Keys</a>
120120
* @see <a href="https://www.ietf.org/archive/id/draft-koch-librepgp-01.html#name-public-key-packet-formats">
121121
* LibrePGP - Public-Key Packet Formats</a>
122122
*/

pg/src/main/java/org/bouncycastle/bcpg/S2K.java

+7-7
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,10 @@
3838
* </ul>
3939
*
4040
* @see <a href="https://www.rfc-editor.org/rfc/rfc4880.html#section-3.7">
41-
* rfc4880 - String-to-Key (S2K) Specifiers</a>
42-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-string-to-key-s2k-specifier">
43-
* C-R - String-to-Key (S2K) Specifier</a>
44-
* @see <a href="https://www.ietf.org/archive/id/draft-koch-librepgp-00.html#name-string-to-key-s2k-specifier">
41+
* RFC4880 - String-to-Key (S2K) Specifiers</a>
42+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-string-to-key-s2k-specifier">
43+
* RFC9580 - String-to-Key (S2K) Specifier</a>
44+
* @see <a href="https://www.ietf.org/archive/id/draft-koch-librepgp-01.html#name-string-to-key-s2k-specifier">
4545
* LibrePGP - String-to-Key (S2K) Specifiers</a>
4646
*/
4747
public class S2K
@@ -480,8 +480,8 @@ private void writeOneOctetOrThrow(BCPGOutputStream out, int val, String valName)
480480

481481
/**
482482
* Parameters for Argon2 S2K.
483-
* @see <a href="https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-13.html#name-argon2">
484-
* C-R - Argon2</a>
483+
* @see <a href="https://www.rfc-editor.org/rfc/rfc9580.html#name-argon2">
484+
* OpenPGP - Argon2</a>
485485
*/
486486
public static class Argon2Params
487487
{
@@ -555,7 +555,7 @@ public Argon2Params(byte[] salt, int passes, int parallelism, int memSizeExp)
555555

556556
// log₂p = logₑp / logₑ2
557557
double log2_p = Math.log(parallelism) / Math.log(2);
558-
// see https://www.ietf.org/archive/id/draft-ietf-openpgp-crypto-refresh-05.html#section-3.7.1.4-5
558+
// see https://www.rfc-editor.org/rfc/rfc9580.html#section-3.7.1.4-5
559559
if (memSizeExp < (3 + Math.ceil(log2_p)) || memSizeExp > 31)
560560
{
561561
throw new IllegalArgumentException("Memory size exponent MUST be between 3 + ⌈log₂(parallelism)⌉ and 31");

0 commit comments

Comments
 (0)