1
0
Fork 0
mirror of https://github.com/pgpainless/pgpainless.git synced 2024-11-26 06:12:06 +01:00

Fix linking in KDoc documentation

This commit is contained in:
Paul Schaub 2024-09-16 14:10:09 +02:00
parent 67457bbe78
commit b719810575
Signed by: vanitasvitae
GPG key ID: 62BEE9264BF17311
16 changed files with 88 additions and 94 deletions

View file

@ -129,7 +129,7 @@ class PGPainless private constructor() {
* *
* <p> * <p>
* After making the desired changes in the builder, the modified key can be extracted using * After making the desired changes in the builder, the modified key can be extracted using
* {@link SecretKeyRingEditorInterface#done()}. * [org.pgpainless.key.modification.secretkeyring.SecretKeyRingEditorInterface.done].
* *
* @param secretKeys secret key ring * @param secretKeys secret key ring
* @param referenceTime reference time used as signature creation date * @param referenceTime reference time used as signature creation date

View file

@ -42,7 +42,7 @@ enum class KeyFlag(val flag: Int) {
} }
/** /**
* Encode a list of {@link KeyFlag KeyFlags} into a bitmask. * Encode a list of [KeyFlags][KeyFlag] into a bitmask.
* *
* @param flags list of flags * @param flags list of flags
* @return bitmask * @return bitmask

View file

@ -23,7 +23,7 @@ enum class SignatureType(val code: Int) {
/** /**
* Signature of a canonical text document. This means the signer owns it, created it, or * Signature of a canonical text document. This means the signer owns it, created it, or
* certifies that it has not been modified. The signature is calculated over the text data with * certifies that it has not been modified. The signature is calculated over the text data with
* its line endings converted to {@code <CR><LF>}. * its line endings converted to `<CR><LF>`.
*/ */
CANONICAL_TEXT_DOCUMENT(0x01), CANONICAL_TEXT_DOCUMENT(0x01),

View file

@ -50,16 +50,16 @@ class EncryptionOptions(private val purpose: EncryptionPurpose) {
constructor() : this(EncryptionPurpose.ANY) constructor() : this(EncryptionPurpose.ANY)
/** /**
* Factory method to create an {@link EncryptionOptions} object which will encrypt for keys * Factory method to create an [EncryptionOptions] object which will encrypt for keys which
* which carry the flag {@link org.pgpainless.algorithm.KeyFlag#ENCRYPT_COMMS}. * carry the flag [org.pgpainless.algorithm.KeyFlag.ENCRYPT_COMMS].
* *
* @return encryption options * @return encryption options
*/ */
fun setEvaluationDate(evaluationDate: Date) = apply { this.evaluationDate = evaluationDate } fun setEvaluationDate(evaluationDate: Date) = apply { this.evaluationDate = evaluationDate }
/** /**
* Identify authenticatable certificates for the given user-ID by querying the {@link * Identify authenticatable certificates for the given user-ID by querying the
* CertificateAuthority} for identifiable bindings. Add all acceptable bindings, whose trust * [CertificateAuthority] for identifiable bindings. Add all acceptable bindings, whose trust
* amount is larger or equal to the target amount to the list of recipients. * amount is larger or equal to the target amount to the list of recipients.
* *
* @param userId userId * @param userId userId
@ -88,8 +88,8 @@ class EncryptionOptions(private val purpose: EncryptionPurpose) {
} }
/** /**
* Add all key rings in the provided {@link Iterable} (e.g. {@link PGPPublicKeyRingCollection}) * Add all key rings in the provided [Iterable] (e.g.
* as recipients. * [org.bouncycastle.openpgp.PGPPublicKeyRingCollection]) as recipients.
* *
* @param keys keys * @param keys keys
* @return this * @return this
@ -102,9 +102,9 @@ class EncryptionOptions(private val purpose: EncryptionPurpose) {
} }
/** /**
* Add all key rings in the provided {@link Iterable} (e.g. {@link PGPPublicKeyRingCollection}) * Add all key rings in the provided [Iterable] (e.g.
* as recipients. Per key ring, the selector is applied to select one or more encryption * [org.bouncycastle.openpgp.PGPPublicKeyRingCollection]) as recipients. Per key ring, the
* subkeys. * selector is applied to select one or more encryption subkeys.
* *
* @param keys keys * @param keys keys
* @param selector encryption key selector * @param selector encryption key selector
@ -245,9 +245,9 @@ class EncryptionOptions(private val purpose: EncryptionPurpose) {
} }
/** /**
* Add an {@link PGPKeyEncryptionMethodGenerator} which will be used to encrypt the message. * Add a [PGPKeyEncryptionMethodGenerator] which will be used to encrypt the message. Method
* Method generators are either {@link PBEKeyEncryptionMethodGenerator} (passphrase) or {@link * generators are either [org.bouncycastle.openpgp.operator.PBEKeyEncryptionMethodGenerator]
* PGPKeyEncryptionMethodGenerator} (public key). * (passphrase) or [PGPKeyEncryptionMethodGenerator] (public key).
* *
* This method is intended for advanced users to allow encryption for specific subkeys. This can * This method is intended for advanced users to allow encryption for specific subkeys. This can
* come in handy for example if data needs to be encrypted to a subkey that's ignored by * come in handy for example if data needs to be encrypted to a subkey that's ignored by
@ -278,10 +278,10 @@ class EncryptionOptions(private val purpose: EncryptionPurpose) {
} }
/** /**
* If this method is called, subsequent calls to {@link #addRecipient(PGPPublicKeyRing)} will * If this method is called, subsequent calls to [addRecipient] will allow encryption for
* allow encryption for subkeys that do not carry any {@link org.pgpainless.algorithm.KeyFlag} * subkeys that do not carry any [org.pgpainless.algorithm.KeyFlag] subpacket. This is a
* subpacket. This is a workaround for dealing with legacy keys that have no key flags subpacket * workaround for dealing with legacy keys that have no key flags subpacket but rely on the key
* but rely on the key algorithm type to convey the subkeys use. * algorithm type to convey the subkeys use.
* *
* @return this * @return this
*/ */

View file

@ -176,8 +176,7 @@ private constructor(
* @return this * @return this
* @see <a href="https://datatracker.ietf.org/doc/html/rfc4880#section-5.9">RFC4880 §5.9. * @see <a href="https://datatracker.ietf.org/doc/html/rfc4880#section-5.9">RFC4880 §5.9.
* Literal Data Packet</a> * Literal Data Packet</a>
* @deprecated options other than the default value of {@link StreamEncoding#BINARY} are * @deprecated options other than the default value of [StreamEncoding.BINARY] are discouraged.
* discouraged.
*/ */
@Deprecated("Options other than BINARY are discouraged.") @Deprecated("Options other than BINARY are discouraged.")
fun setEncoding(encoding: StreamEncoding) = apply { encodingField = encoding } fun setEncoding(encoding: StreamEncoding) = apply { encodingField = encoding }

View file

@ -23,8 +23,8 @@ abstract class OpenPgpFingerprint : CharSequence, Comparable<OpenPgpFingerprint>
abstract fun getVersion(): Int abstract fun getVersion(): Int
/** /**
* Return the key id of the OpenPGP public key this {@link OpenPgpFingerprint} belongs to. This * Return the key id of the OpenPGP public key this [OpenPgpFingerprint] belongs to. This method
* method can be implemented for V4 and V5 fingerprints. V3 key-IDs cannot be derived from the * can be implemented for V4 and V5 fingerprints. V3 key-IDs cannot be derived from the
* fingerprint, but we don't care, since V3 is deprecated. * fingerprint, but we don't care, since V3 is deprecated.
* *
* @return key id * @return key id
@ -127,10 +127,10 @@ abstract class OpenPgpFingerprint : CharSequence, Comparable<OpenPgpFingerprint>
@JvmStatic fun of(keys: PGPKeyRing): OpenPgpFingerprint = of(keys.publicKey) @JvmStatic fun of(keys: PGPKeyRing): OpenPgpFingerprint = of(keys.publicKey)
/** /**
* Try to parse an {@link OpenPgpFingerprint} from the given fingerprint string. If the * Try to parse an [OpenPgpFingerprint] from the given fingerprint string. If the trimmed
* trimmed fingerprint without whitespace is 64 characters long, it is either a v5 or v6 * fingerprint without whitespace is 64 characters long, it is either a v5 or v6
* fingerprint. In this case, we return a {@link _64DigitFingerprint}. Since this is * fingerprint. In this case, we return a [_64DigitFingerprint]. Since this is ambiguous, it
* ambiguous, it is generally recommended to know the version of the key beforehand. * is generally recommended to know the version of the key beforehand.
* *
* @param fingerprint fingerprint * @param fingerprint fingerprint
* @return parsed fingerprint * @return parsed fingerprint
@ -152,7 +152,7 @@ abstract class OpenPgpFingerprint : CharSequence, Comparable<OpenPgpFingerprint>
} }
/** /**
* Parse a binary OpenPGP fingerprint into an {@link OpenPgpFingerprint} object. * Parse a binary OpenPGP fingerprint into an [OpenPgpFingerprint] object.
* *
* @param binaryFingerprint binary representation of the fingerprint * @param binaryFingerprint binary representation of the fingerprint
* @return parsed fingerprint * @return parsed fingerprint

View file

@ -20,7 +20,7 @@ import org.bouncycastle.util.encoders.Hex
open class _64DigitFingerprint : OpenPgpFingerprint { open class _64DigitFingerprint : OpenPgpFingerprint {
/** /**
* Create an {@link _64DigitFingerprint}. * Create a [_64DigitFingerprint].
* *
* @param fingerprint uppercase hexadecimal fingerprint of length 64 * @param fingerprint uppercase hexadecimal fingerprint of length 64
*/ */

View file

@ -64,14 +64,13 @@ class KeyRingTemplates {
} }
/** /**
* Creates a simple RSA KeyPair of length {@code length} with user-id {@code userId}. The * Creates a simple RSA KeyPair of length `length` with user-id `userId`. The KeyPair consists
* KeyPair consists of a single RSA master key which is used for signing, encryption and * of a single RSA master key which is used for signing, encryption and certification.
* certification.
* *
* @param userId user id. * @param userId user id.
* @param length length in bits. * @param length length in bits.
* @param password Password of the key. Can be empty for unencrypted keys. * @param password Password of the key. Can be empty for unencrypted keys.
* @return {@link PGPSecretKeyRing} containing the KeyPair. * @return [PGPSecretKeyRing] containing the KeyPair.
*/ */
@JvmOverloads @JvmOverloads
fun simpleRsaKeyRing( fun simpleRsaKeyRing(
@ -95,14 +94,13 @@ class KeyRingTemplates {
.build() .build()
/** /**
* Creates a simple RSA KeyPair of length {@code length} with user-id {@code userId}. The * Creates a simple RSA KeyPair of length `length` with user-id `userId`. The KeyPair consists
* KeyPair consists of a single RSA master key which is used for signing, encryption and * of a single RSA master key which is used for signing, encryption and certification.
* certification.
* *
* @param userId user id. * @param userId user id.
* @param length length in bits. * @param length length in bits.
* @param password Password of the key. Can be null or blank for unencrypted keys. * @param password Password of the key. Can be null or blank for unencrypted keys.
* @return {@link PGPSecretKeyRing} containing the KeyPair. * @return [PGPSecretKeyRing] containing the KeyPair.
*/ */
fun simpleRsaKeyRing(userId: CharSequence?, length: RsaLength, password: String?) = fun simpleRsaKeyRing(userId: CharSequence?, length: RsaLength, password: String?) =
password.let { password.let {
@ -120,7 +118,7 @@ class KeyRingTemplates {
* *
* @param userId user-id * @param userId user-id
* @param passphrase Password of the private key. Can be empty for an unencrypted key. * @param passphrase Password of the private key. Can be empty for an unencrypted key.
* @return {@link PGPSecretKeyRing} containing the key pairs. * @return [PGPSecretKeyRing] containing the key pairs.
*/ */
@JvmOverloads @JvmOverloads
fun simpleEcKeyRing( fun simpleEcKeyRing(
@ -153,7 +151,7 @@ class KeyRingTemplates {
* *
* @param userId user-id * @param userId user-id
* @param passphrase Password of the private key. Can be null or blank for an unencrypted key. * @param passphrase Password of the private key. Can be null or blank for an unencrypted key.
* @return {@link PGPSecretKeyRing} containing the key pairs. * @return [PGPSecretKeyRing] containing the key pairs.
*/ */
fun simpleEcKeyRing(userId: CharSequence?, password: String?): PGPSecretKeyRing = fun simpleEcKeyRing(userId: CharSequence?, password: String?): PGPSecretKeyRing =
password.let { password.let {

View file

@ -41,8 +41,7 @@ interface KeyType {
val bitStrength: Int val bitStrength: Int
/** /**
* Return an implementation of {@link AlgorithmParameterSpec} that can be used to generate the * Return an implementation of [AlgorithmParameterSpec] that can be used to generate the key.
* key.
* *
* @return algorithm parameter spec * @return algorithm parameter spec
*/ */
@ -50,7 +49,7 @@ interface KeyType {
/** /**
* Return true if the key that is generated from this type is able to carry the SIGN_DATA key * Return true if the key that is generated from this type is able to carry the SIGN_DATA key
* flag. See {@link org.pgpainless.algorithm.KeyFlag#SIGN_DATA}. * flag. See [org.pgpainless.algorithm.KeyFlag.SIGN_DATA].
* *
* @return true if the key can sign. * @return true if the key can sign.
*/ */
@ -59,7 +58,7 @@ interface KeyType {
/** /**
* Return true if the key that is generated from this type is able to carry the CERTIFY_OTHER * Return true if the key that is generated from this type is able to carry the CERTIFY_OTHER
* key flag. See {@link org.pgpainless.algorithm.KeyFlag#CERTIFY_OTHER}. * key flag. See [org.pgpainless.algorithm.KeyFlag.CERTIFY_OTHER].
* *
* @return true if the key is able to certify other keys * @return true if the key is able to certify other keys
*/ */
@ -68,7 +67,7 @@ interface KeyType {
/** /**
* Return true if the key that is generated from this type is able to carry the AUTHENTICATION * Return true if the key that is generated from this type is able to carry the AUTHENTICATION
* key flag. See {@link org.pgpainless.algorithm.KeyFlag#AUTHENTICATION}. * key flag. See [org.pgpainless.algorithm.KeyFlag.AUTHENTICATION].
* *
* @return true if the key can be used for authentication purposes. * @return true if the key can be used for authentication purposes.
*/ */
@ -77,7 +76,7 @@ interface KeyType {
/** /**
* Return true if the key that is generated from this type is able to carry the ENCRYPT_COMMS * Return true if the key that is generated from this type is able to carry the ENCRYPT_COMMS
* key flag. See {@link org.pgpainless.algorithm.KeyFlag#ENCRYPT_COMMS}. * key flag. See [org.pgpainless.algorithm.KeyFlag.ENCRYPT_COMMS].
* *
* @return true if the key can encrypt communication * @return true if the key can encrypt communication
*/ */
@ -86,7 +85,7 @@ interface KeyType {
/** /**
* Return true if the key that is generated from this type is able to carry the ENCRYPT_STORAGE * Return true if the key that is generated from this type is able to carry the ENCRYPT_STORAGE
* key flag. See {@link org.pgpainless.algorithm.KeyFlag#ENCRYPT_STORAGE}. * key flag. See [org.pgpainless.algorithm.KeyFlag.ENCRYPT_STORAGE].
* *
* @return true if the key can encrypt for storage * @return true if the key can encrypt for storage
*/ */

View file

@ -35,7 +35,7 @@ class KeyRingInfo(
private val signatures: Signatures = Signatures(keys, referenceDate, policy) private val signatures: Signatures = Signatures(keys, referenceDate, policy)
/** Primary {@link PGPPublicKey}.´ */ /** Primary [PGPPublicKey]. */
val publicKey: PGPPublicKey = KeyRingUtils.requirePrimaryPublicKeyFrom(keys) val publicKey: PGPPublicKey = KeyRingUtils.requirePrimaryPublicKeyFrom(keys)
/** Primary key ID. */ /** Primary key ID. */
@ -73,8 +73,8 @@ class KeyRingInfo(
val version: Int = publicKey.version val version: Int = publicKey.version
/** /**
* Return all {@link PGPPublicKey PGPPublicKeys} of this key ring. The first key in the list * Return all [PGPPublicKeys][PGPPublicKey] of this key ring. The first key in the list being
* being the primary key. Note that the list is unmodifiable. * the primary key. Note that the list is unmodifiable.
* *
* @return list of public keys * @return list of public keys
*/ */
@ -448,7 +448,7 @@ class KeyRingInfo(
signatures.subkeyRevocations[keyId] signatures.subkeyRevocations[keyId]
/** /**
* Return a list of {@link KeyFlag KeyFlags} that apply to the subkey with the provided key id. * Return a list of [KeyFlags][KeyFlag] that apply to the subkey with the provided key id.
* *
* @param keyId key-id * @param keyId key-id
* @return list of key flags * @return list of key flags
@ -478,7 +478,7 @@ class KeyRingInfo(
} }
/** /**
* Return a list of {@link KeyFlag KeyFlags} that apply to the given user-id. * Return a list of [KeyFlags][KeyFlag] that apply to the given user-id.
* *
* @param userId user-id * @param userId user-id
* @return key flags * @return key flags
@ -622,8 +622,8 @@ class KeyRingInfo(
* Return the current primary user-id of the key ring. * Return the current primary user-id of the key ring.
* *
* <p> * <p>
* Note: If no user-id is marked as primary key using a {@link PrimaryUserID} packet, this * Note: If no user-id is marked as primary key using a [PrimaryUserID] packet, this method
* method returns the first user-id on the key, otherwise null. * returns the first user-id on the key, otherwise null.
* *
* @return primary user-id or null * @return primary user-id or null
*/ */

View file

@ -15,7 +15,7 @@ class KeyIdUtil {
* Convert a long key-id into a key-id. A long key-id is a 16 digit hex string. * Convert a long key-id into a key-id. A long key-id is a 16 digit hex string.
* *
* @param longKeyId 16-digit hexadecimal string * @param longKeyId 16-digit hexadecimal string
* @return key-id converted to {@link Long}. * @return key-id converted to [Long].
*/ */
@JvmStatic @JvmStatic
@Deprecated( @Deprecated(

View file

@ -27,8 +27,8 @@ class KeyRingUtils {
@JvmStatic private val LOGGER: Logger = LoggerFactory.getLogger(KeyRingUtils::class.java) @JvmStatic private val LOGGER: Logger = LoggerFactory.getLogger(KeyRingUtils::class.java)
/** /**
* Return the primary {@link PGPSecretKey} from the provided {@link PGPSecretKeyRing}. If it * Return the primary [PGPSecretKey] from the provided [PGPSecretKeyRing]. If it has no
* has no primary secret key, throw a {@link NoSuchElementException}. * primary secret key, throw a [NoSuchElementException].
* *
* @param secretKeys secret keys * @param secretKeys secret keys
* @return primary secret key * @return primary secret key
@ -61,8 +61,8 @@ class KeyRingUtils {
} }
/** /**
* Return the primary {@link PGPPublicKey} from the provided key ring. Throws a {@link * Return the primary [PGPPublicKey] from the provided key ring. Throws a
* NoSuchElementException} if the key ring has no primary public key. * [NoSuchElementException] if the key ring has no primary public key.
* *
* @param keyRing key ring * @param keyRing key ring
* @return primary public key * @return primary public key
@ -74,8 +74,7 @@ class KeyRingUtils {
} }
/** /**
* Return the primary {@link PGPPublicKey} from the provided key ring or null if it has * Return the primary [PGPPublicKey] from the provided key ring or null if it has none.
* none.
* *
* @param keyRing key ring * @param keyRing key ring
* @return primary public key * @return primary public key
@ -93,7 +92,7 @@ class KeyRingUtils {
/** /**
* Require the public key with the given subKeyId from the keyRing. If no such subkey * Require the public key with the given subKeyId from the keyRing. If no such subkey
* exists, throw an {@link NoSuchElementException}. * exists, throw an [NoSuchElementException].
* *
* @param keyRing key ring * @param keyRing key ring
* @param subKeyId subkey id * @param subKeyId subkey id
@ -108,7 +107,7 @@ class KeyRingUtils {
/** /**
* Require the secret key with the given secret subKeyId from the secret keyRing. If no such * Require the secret key with the given secret subKeyId from the secret keyRing. If no such
* subkey exists, throw an {@link NoSuchElementException}. * subkey exists, throw an [NoSuchElementException].
* *
* @param keyRing secret key ring * @param keyRing secret key ring
* @param subKeyId subkey id * @param subKeyId subkey id
@ -131,8 +130,8 @@ class KeyRingUtils {
} }
/** /**
* Extract a {@link PGPPublicKeyRing} containing all public keys from the provided {@link * Extract a [PGPPublicKeyRing] containing all public keys from the provided
* PGPSecretKeyRing}. * [PGPSecretKeyRing].
* *
* @param secretKeys secret key ring * @param secretKeys secret key ring
* @return public key ring * @return public key ring
@ -146,9 +145,9 @@ class KeyRingUtils {
} }
/** /**
* Extract {@link PGPPublicKeyRing PGPPublicKeyRings} from all {@link PGPSecretKeyRing * Extract [PGPPublicKeyRings][PGPPublicKeyRing] from all
* PGPSecretKeyRings} in the given {@link PGPSecretKeyRingCollection} and return them as a * [PGPSecretKeyRings][PGPSecretKeyRing] in the given [PGPSecretKeyRingCollection] and
* {@link PGPPublicKeyRingCollection}. * return them as a [PGPPublicKeyRingCollection].
* *
* @param secretKeyRings secret key ring collection * @param secretKeyRings secret key ring collection
* @return public key ring collection * @return public key ring collection
@ -162,8 +161,8 @@ class KeyRingUtils {
} }
/** /**
* Create a new {@link PGPPublicKeyRingCollection} from an array of {@link PGPPublicKeyRing * Create a new [PGPPublicKeyRingCollection] from an array of
* PGPPublicKeyRings}. * [PGPPublicKeyRings][PGPPublicKeyRing].
* *
* @param certificates array of public key rings * @param certificates array of public key rings
* @return key ring collection * @return key ring collection
@ -176,8 +175,8 @@ class KeyRingUtils {
} }
/** /**
* Create a new {@link PGPSecretKeyRingCollection} from an array of {@link PGPSecretKeyRing * Create a new [PGPSecretKeyRingCollection] from an array of
* PGPSecretKeyRings}. * [PGPSecretKeyRings][PGPSecretKeyRing].
* *
* @param secretKeys array of secret key rings * @param secretKeys array of secret key rings
* @return secret key ring collection * @return secret key ring collection
@ -190,8 +189,8 @@ class KeyRingUtils {
} }
/** /**
* Return true, if the given {@link PGPPublicKeyRing} contains a {@link PGPPublicKey} for * Return true, if the given [PGPPublicKeyRing] contains a [PGPPublicKey] for the given key
* the given key id. * id.
* *
* @param certificate public key ring * @param certificate public key ring
* @param keyId id of the key in question * @param keyId id of the key in question
@ -207,7 +206,7 @@ class KeyRingUtils {
* *
* @param keyRing key ring * @param keyRing key ring
* @param certification key signature * @param certification key signature
* @param <T> either {@link PGPPublicKeyRing} or {@link PGPSecretKeyRing} * @param <T> either [PGPPublicKeyRing] or [PGPSecretKeyRing]
* @return key ring with injected signature * @return key ring with injected signature
*/ */
@JvmStatic @JvmStatic
@ -221,7 +220,7 @@ class KeyRingUtils {
* @param keyRing key ring * @param keyRing key ring
* @param certifiedKey signed public key * @param certifiedKey signed public key
* @param certification key signature * @param certification key signature
* @param <T> either {@link PGPPublicKeyRing} or {@link PGPSecretKeyRing} * @param <T> either [PGPPublicKeyRing] or [PGPSecretKeyRing]
* @return key ring with injected signature * @return key ring with injected signature
* @throws NoSuchElementException in case that the signed key is not part of the key ring * @throws NoSuchElementException in case that the signed key is not part of the key ring
*/ */
@ -265,7 +264,7 @@ class KeyRingUtils {
* @param keyRing key ring * @param keyRing key ring
* @param userId signed user-id * @param userId signed user-id
* @param certification signature * @param certification signature
* @param <T> either {@link PGPPublicKeyRing} or {@link PGPSecretKeyRing} * @param <T> either [PGPPublicKeyRing] or [PGPSecretKeyRing]
* @return key ring with injected certification * @return key ring with injected certification
*/ */
@JvmStatic @JvmStatic
@ -300,7 +299,7 @@ class KeyRingUtils {
* @param keyRing key ring * @param keyRing key ring
* @param userAttributes certified user attributes * @param userAttributes certified user attributes
* @param certification certification signature * @param certification certification signature
* @param <T> either {@link PGPPublicKeyRing} or {@link PGPSecretKeyRing} * @param <T> either [PGPPublicKeyRing] or [PGPSecretKeyRing]
* @return key ring with injected user-attribute certification * @return key ring with injected user-attribute certification
*/ */
@JvmStatic @JvmStatic
@ -330,11 +329,11 @@ class KeyRingUtils {
} }
/** /**
* Inject a {@link PGPPublicKey} into the given key ring. * Inject a [PGPPublicKey] into the given key ring.
* *
* @param keyRing key ring * @param keyRing key ring
* @param publicKey public key * @param publicKey public key
* @param <T> either {@link PGPPublicKeyRing} or {@link PGPSecretKeyRing} * @param <T> either [PGPPublicKeyRing] or [PGPSecretKeyRing]
* @return key ring with injected public key * @return key ring with injected public key
*/ */
@JvmStatic @JvmStatic
@ -372,7 +371,7 @@ class KeyRingUtils {
} }
/** /**
* Inject a {@link PGPSecretKey} into a {@link PGPSecretKeyRing}. * Inject a [PGPSecretKey] into a [PGPSecretKeyRing].
* *
* @param secretKeys secret key ring * @param secretKeys secret key ring
* @param secretKey secret key * @param secretKey secret key

View file

@ -284,8 +284,8 @@ class Policy(
companion object { companion object {
/** /**
* Default {@link CompressionAlgorithmPolicy} of PGPainless. The default compression * Default [CompressionAlgorithmPolicy] of PGPainless. The default compression algorithm
* algorithm policy accepts any compression algorithm. * policy accepts any compression algorithm.
* *
* @return default algorithm policy * @return default algorithm policy
* @deprecated not expressive - might be removed in a future release * @deprecated not expressive - might be removed in a future release
@ -385,17 +385,16 @@ class Policy(
enum class SignerUserIdValidationLevel { enum class SignerUserIdValidationLevel {
/** /**
* PGPainless will verify {@link org.bouncycastle.bcpg.sig.SignerUserID} subpackets in * PGPainless will verify [org.bouncycastle.bcpg.sig.SignerUserID] subpackets in signatures
* signatures strictly. This means, that signatures with Signer's User-ID subpackets * strictly. This means, that signatures with Signer's User-ID subpackets containing a value
* containing a value that does not match the signer key's user-id exactly, will be * that does not match the signer key's user-id exactly, will be rejected. E.g. Signer's
* rejected. E.g. Signer's user-id "alice@pgpainless.org", User-ID: "Alice * user-id "alice@pgpainless.org", User-ID: "Alice &lt;alice@pgpainless.org&gt;" does not
* &lt;alice@pgpainless.org&gt;" does not match exactly and is therefore rejected. * match exactly and is therefore rejected.
*/ */
STRICT, STRICT,
/** /**
* PGPainless will ignore {@link org.bouncycastle.bcpg.sig.SignerUserID} subpackets on * PGPainless will ignore [org.bouncycastle.bcpg.sig.SignerUserID] subpackets on signature.
* signature.
*/ */
DISABLED DISABLED
} }

View file

@ -64,7 +64,7 @@ class SignatureSubpacketsUtil {
* such packet is present, return null. * such packet is present, return null.
* *
* @param signature signature * @param signature signature
* @return issuer key-id as {@link Long} * @return issuer key-id as [Long]
*/ */
@JvmStatic @JvmStatic
fun getIssuerKeyIdAsLong(signature: PGPSignature): Long? = getIssuerKeyId(signature)?.keyID fun getIssuerKeyIdAsLong(signature: PGPSignature): Long? = getIssuerKeyId(signature)?.keyID

View file

@ -153,8 +153,8 @@ class ArmorUtils {
): String = toAsciiArmoredString(bytes.inputStream(), header) ): String = toAsciiArmoredString(bytes.inputStream(), header)
/** /**
* Return the ASCII armored encoding of the OpenPGP data from the given {@link InputStream}. * Return the ASCII armored encoding of the OpenPGP data from the given [InputStream]. The
* The ASCII armor will include armor headers from the given header map. * ASCII armor will include armor headers from the given header map.
* *
* @param inputStream input stream of OpenPGP data * @param inputStream input stream of OpenPGP data
* @param header ASCII armor header map * @param header ASCII armor header map
@ -179,7 +179,7 @@ class ArmorUtils {
/** /**
* Return an [ArmoredOutputStream] prepared with headers for the given key ring, which wraps * Return an [ArmoredOutputStream] prepared with headers for the given key ring, which wraps
* the given {@link OutputStream}. * the given [OutputStream].
* *
* The armored output stream can be used to encode the key ring by calling * The armored output stream can be used to encode the key ring by calling
* [PGPKeyRing.encode] with the armored output stream as an argument. * [PGPKeyRing.encode] with the armored output stream as an argument.

View file

@ -9,7 +9,7 @@ package org.pgpainless.util
* notations that are not known to the application, there must be some way to tell PGPainless which * notations that are not known to the application, there must be some way to tell PGPainless which
* notations actually are known. * notations actually are known.
* *
* To add a notation name, call {@link #addKnownNotation(String)}. * To add a notation name, call [addKnownNotation].
*/ */
class NotationRegistry constructor(notations: Set<String> = setOf()) { class NotationRegistry constructor(notations: Set<String> = setOf()) {
private val knownNotations: MutableSet<String> private val knownNotations: MutableSet<String>