EVP_SIGNATURE-RSA.pod 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. =pod
  2. =head1 NAME
  3. EVP_SIGNATURE-RSA
  4. - The EVP_PKEY RSA signature implementation
  5. =head1 DESCRIPTION
  6. Support for computing RSA signatures.
  7. See L<EVP_PKEY-RSA(7)> for information related to RSA keys.
  8. =head2 Signature Parameters
  9. The following signature parameters can be set using EVP_PKEY_CTX_set_params().
  10. This may be called after EVP_PKEY_sign_init() or EVP_PKEY_verify_init(),
  11. and before calling EVP_PKEY_sign() or EVP_PKEY_verify().
  12. =over 4
  13. =item "digest" (B<OSSL_SIGNATURE_PARAM_DIGEST>) <UTF8 string>
  14. =item "properties" (B<OSSL_SIGNATURE_PARAM_PROPERTIES>) <UTF8 string>
  15. These common parameters are described in L<provider-signature(7)>.
  16. =item "pad-mode" (B<OSSL_SIGNATURE_PARAM_PAD_MODE>) <UTF8 string>
  17. The type of padding to be used. Its value can be one of the following:
  18. =over 4
  19. =item "none" (B<OSSL_PKEY_RSA_PAD_MODE_NONE>)
  20. =item "pkcs1" (B<OSSL_PKEY_RSA_PAD_MODE_PKCSV15>)
  21. =item "x931" (B<OSSL_PKEY_RSA_PAD_MODE_X931>)
  22. =item "pss" (B<OSSL_PKEY_RSA_PAD_MODE_PSS>)
  23. =back
  24. =item "mgf1-digest" (B<OSSL_SIGNATURE_PARAM_MGF1_DIGEST>) <UTF8 string>
  25. The digest algorithm name to use for the maskGenAlgorithm used by "pss" mode.
  26. =item "mgf1-properties" (B<OSSL_SIGNATURE_PARAM_MGF1_PROPERTIES>) <UTF8 string>
  27. Sets the name of the property query associated with the "mgf1-digest" algorithm.
  28. NULL is used if this optional value is not set.
  29. =item "pss-saltlen" (B<OSSL_SIGNATURE_PARAM_PSS_SALTLEN>) <UTF8 string>
  30. Set or get the "pss" mode minimum salt length. The value can either be a string
  31. value representing a number or one of the following:
  32. =over 4
  33. =item "digest" (B<OSSL_PKEY_RSA_PSS_SALT_LEN_DIGEST>)
  34. Use the same length as the digest size.
  35. =item "max" (B<OSSL_PKEY_RSA_PSS_SALT_LEN_MAX>)
  36. Use the maximum salt length.
  37. =item "auto" (B<OSSL_PKEY_RSA_PSS_SALT_LEN_AUTO>)
  38. Auto detect the salt length.
  39. =back
  40. =back
  41. The following signature parameters can be retrieved using
  42. EVP_PKEY_CTX_get_params().
  43. =over 4
  44. =item "algorithm-id" (B<OSSL_SIGNATURE_PARAM_ALGORITHM_ID>) <octet string>
  45. This common parameter is described in L<provider-signature(7)>.
  46. =item "digest" (B<OSSL_SIGNATURE_PARAM_DIGEST>) <UTF8 string>
  47. =item "pad-mode" (B<OSSL_SIGNATURE_PARAM_PAD_MODE>) <UTF8 string>
  48. =item "mgf1-digest" (B<OSSL_SIGNATURE_PARAM_MGF1_DIGEST>) <UTF8 string>
  49. These parameters are as described above.
  50. =back
  51. =head1 SEE ALSO
  52. L<EVP_PKEY_CTX_set_params(3)>,
  53. L<EVP_PKEY_sign(3)>,
  54. L<EVP_PKEY_verify(3)>,
  55. L<provider-signature(7)>,
  56. =head1 COPYRIGHT
  57. Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
  58. Licensed under the Apache License 2.0 (the "License"). You may not use
  59. this file except in compliance with the License. You can obtain a copy
  60. in the file LICENSE in the source distribution or at
  61. L<https://www.openssl.org/source/license.html>.
  62. =cut