summaryrefslogtreecommitdiff
path: root/xed25519.h
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2018-12-25 08:45:34 -0500
committerJeffrey Walton <noloader@gmail.com>2018-12-25 08:45:34 -0500
commitf528e9a238de8b92ea849a86915ba7b08585a419 (patch)
tree5dc8007e22f90b62d6e47b3111470fa985ed0b1a /xed25519.h
parente389e2adc03f155bd41c1c35aff882f364f4b944 (diff)
downloadcryptopp-git-f528e9a238de8b92ea849a86915ba7b08585a419.tar.gz
Update documentation
Diffstat (limited to 'xed25519.h')
-rw-r--r--xed25519.h17
1 files changed, 15 insertions, 2 deletions
diff --git a/xed25519.h b/xed25519.h
index f2894db6..6f0aa995 100644
--- a/xed25519.h
+++ b/xed25519.h
@@ -187,7 +187,7 @@ public:
/// \brief DER encode ASN.1 object
/// \param bt BufferedTransformation object
/// \param version indicates version
- /// \details DEREncodeSave() will write the OID associated with algorithm or
+ /// \details DEREncode() will write the OID associated with algorithm or
/// scheme. In the case of public and private keys, this function writes
/// the subjectPubicKeyInfo parts.
/// \details The default OID is from RFC 8410 using id-X25519.
@@ -367,10 +367,23 @@ struct ed25519PrivateKey : public PKCS8PrivateKey
// PKCS8PrivateKey
void BERDecode(BufferedTransformation &bt);
void DEREncode(BufferedTransformation &bt) const { DEREncode(bt, 0); }
- void DEREncode(BufferedTransformation &bt, int version) const;
void BERDecodePrivateKey(BufferedTransformation &bt, bool parametersPresent, size_t size);
void DEREncodePrivateKey(BufferedTransformation &bt) const;
+ /// \brief DER encode ASN.1 object
+ /// \param bt BufferedTransformation object
+ /// \param version indicates version
+ /// \details DEREncode() will write the OID associated with algorithm or
+ /// scheme. In the case of public and private keys, this function writes
+ /// the subjectPubicKeyInfo parts.
+ /// \details The default OID is from RFC 8410 using id-X25519.
+ /// The default private key format is RFC 5208.
+ /// \details The value of version is written as the INTEGER. Version 0 means
+ /// RFC 5208 format, which is the old format. The old format provides
+ /// the best interop, and keys will work with OpenSSL. The value 1 INTEGER
+ /// means RFC 5958 format, which is the new format.
+ void DEREncode(BufferedTransformation &bt, int version) const;
+
/// \brief Determine of OID is valid for this object
/// \details BERDecodeAndCheckAlgorithmID() parses the OID from
/// <tt>bt</tt> and determines if it valid for this object. The