Use OSSL_PARAM types. Limits are explained in the description where appropriate.
authorPauli <paul.dale@oracle.com>
Wed, 25 Sep 2019 10:42:42 +0000 (20:42 +1000)
committerPauli <paul.dale@oracle.com>
Wed, 25 Sep 2019 21:10:41 +0000 (07:10 +1000)
Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/10011)

doc/man7/provider-digest.pod
doc/man7/provider-mac.pod
doc/man7/provider-signature.pod

index 3d7808452c0c29f14b3b42955367af2fc812a89f..83989dcf8b89a4aeb980bdcbdbe154e847320414 100644 (file)
@@ -227,9 +227,10 @@ parameters are relevant to, or are understood by all digests:
 
 =over 4
 
-=item B<OSSL_DIGEST_PARAM_XOFLEN> (size_t)
+=item B<OSSL_DIGEST_PARAM_XOFLEN> (unsigned integer)
 
 Sets the digest length for extendable output functions.
+The length of the "xoflen" parameter should not exceed that of a B<size_t>.
 
 =item B<OSSL_DIGEST_PARAM_SSL3_MS> (octet string)
 
@@ -243,7 +244,7 @@ section 5.6.8.
 The next call after setting this parameter will be OP_digest_final().
 This is only relevant for implementations of SHA1 or MD5_SHA1.
 
-=item B<OSSL_DIGEST_PARAM_PAD_TYPE> (uint)
+=item B<OSSL_DIGEST_PARAM_PAD_TYPE> (unsigned integer)
 
 Sets the pad type to be used.
 The only built-in digest that uses this is MDC2.
@@ -251,7 +252,7 @@ Normally the final MDC2 block is padded with 0s.
 If the pad type is set to 2 then the final block is padded with 0x80 followed by
 0s.
 
-=item B<OSSL_DIGEST_PARAM_MICALG> (utf8 string)
+=item B<OSSL_DIGEST_PARAM_MICALG> (UTF8 string)
 
 Gets the digest Message Integrity Check algorithm string.
 This is used when creating S/MIME multipart/signed messages, as specified in
index 77feab6b9b2fc0bbf950fe713915e9a126cffe45..f9d6e3532937d294428a5bfc4fd886758e7d9cb9 100644 (file)
@@ -159,7 +159,7 @@ Sets the key in the associated MAC ctx.
 
 Sets the IV of the underlying cipher, when applicable.
 
-=item B<OSSL_MAC_PARAM_CUSTOM> (utf8 string)
+=item B<OSSL_MAC_PARAM_CUSTOM> (UTF8 string)
 
 Sets the custom string in the associated MAC ctx.
 
@@ -167,31 +167,31 @@ Sets the custom string in the associated MAC ctx.
 
 Sets the salt of the underlying cipher, when applicable.
 
-=item B<OSSL_MAC_PARAM_BLOCK_XOF> (int)
+=item B<OSSL_MAC_PARAM_BLOCK_XOF> (integer)
 
 Sets XOF mode in the associated MAC ctx.
 0 means no XOF mode, 1 means XOF mode.
 
-=item B<OSSL_MAC_PARAM_FLAGS> (int)
+=item B<OSSL_MAC_PARAM_FLAGS> (integer)
 
 Gets flags associated with the MAC.
 
 =for comment We need to investigate if this is the right approach
 
-=item B<OSSL_MAC_PARAM_CIPHER> (utf8 string)
+=item B<OSSL_MAC_PARAM_CIPHER> (UTF8 string)
 
-=item B<OSSL_MAC_PARAM_DIGEST> (utf8 string)
+=item B<OSSL_MAC_PARAM_DIGEST> (UTF8 string)
 
 Sets the name of the underlying cipher or digest to be used.
 It must name a suitable algorithm for the MAC that's being used.
 
-=item B<OSSL_MAC_PARAM_PROPERTIES> (utf8 string)
+=item B<OSSL_MAC_PARAM_PROPERTIES> (UTF8 string)
 
 Sets the properties to be queried when trying to fetch the underlying algorithm.
 This must be given together with the algorithm naming parameter to be
 considered valid.
 
-=item B<OSSL_MAC_PARAM_SIZE> (int)
+=item B<OSSL_MAC_PARAM_SIZE> (integer)
 
 Can be used to get the resulting MAC size.
 
index 1ab4831035cd7f758c56238a32ede87687c49fc4..777b991cc6bbbaf1ef1b546e1fd9d7c7709ca30f 100644 (file)
@@ -194,15 +194,17 @@ algorithms:
 
 =over 4
 
-=item "digest" (B<OSSL_SIGNATURE_PARAM_DIGEST>) <utf8 string>
+=item "digest" (B<OSSL_SIGNATURE_PARAM_DIGEST>) <UTF8 string>
 
 Get or sets the name of the digest algorithm used for the input to the signature
 functions.
 
-=item "digest-size" (B<OSSL_SIGNATURE_PARAM_DIGEST_SIZE>) <size_t>
+=item "digest-size" (B<OSSL_SIGNATURE_PARAM_DIGEST_SIZE>) <unsigned integer>
 
 Gets or sets the output size of the digest algorithm used for the input to the
 signature functions.
+The length of the "digest-size" parameter should not exceed that of a B<size_t>.
+
 
 =back