summaryrefslogtreecommitdiffstats
path: root/doc/crypto
AgeCommit message (Collapse)Author
2019-02-26Update copyright yearMatt Caswell
Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/8348)
2019-02-18Move stray POD file into the foldRichard Levitte
Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> (Merged from https://github.com/openssl/openssl/pull/8273)
2018-12-12doc/man3: remove copy&paste leftoverDr. Matthias St. Pierre
Fixes #7883 Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7884) (cherry picked from commit 00eb879f74971e3c048286ef44f6f544676f90d7)
2018-12-06rsa/rsa_pk1.c: remove memcpy calls from RSA_padding_check_PKCS1_type_2.Andy Polyakov
And make RSAErr call unconditional. Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Matt Caswell <matt@openssl.org> (cherry picked from commit e875b0cf2f10bf2adf73e0c2ec81428290f4660c) Resolved conflicts: crypto/rsa/rsa_pk1.c (Merged from https://github.com/openssl/openssl/pull/7737)
2018-12-03Docs fixup: some man3 pages had unindented code in SYNOPSISRichard Levitte
Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> (Merged from https://github.com/openssl/openssl/pull/7744) (cherry picked from commit 7b4a3515a4ddb567d48000e61d7cb640d0c5f261)
2018-09-24Document OPENSSL_VERSION_TEXT macroDaniel Bevenius
This commit documents the OPENSSL_VERSION_TEXT which is currently missing in the man page. Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7301) (cherry picked from commit 7c69495712e3dc9aa8db38271f0c3faeb2037165)
2018-09-04Clarify the EVP_DigestSignInit docsMatt Caswell
They did not make it clear how the memory management works for the |pctx| parameter. Reviewed-by: Tim Hudson <tjh@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7043)
2018-07-26Fix inconsistent use of bit vs bitsKurt Roeckx
Reviewed-by: Tim Hudson <tjh@openssl.org> GH: #6794 (cherry picked from commit b9e54e98066c1ff8adab5d68b6c114b14d2f74e5)
2018-07-26Make number of Miller-Rabin tests for a prime tests depend on the security ↵Kurt Roeckx
level of the prime The old numbers where all generated for an 80 bit security level. But the number should depend on security level you want to reach. For bigger primes we want a higher security level and so need to do more tests. Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> Reviewed-by: Paul Dale <paul.dale@oracle.com> GH: #6075 Fixes: #6012 (cherry picked from commit feac7a1c8be49fbcb76fcb721ec9f02fdd91030e)
2018-07-13Documentation typo fix in BN_bn2bin.podAlexandre Perrin
Change the description for BN_hex2bn() so that it uses the same BIGNUM argument name as its prototype. CLA: trivial Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6712)
2018-06-21Improve the example getpass() implementation to show an error returnNick Mathewson
Also, modernize the code, so that it isn't trying to store a size_t into an int, and then check the int's sign. :/ Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6271) (cherry picked from commit c8c250333cd254ab3f4d709ebc5ed86a7c065721) (cherry picked from commit 50d06d1c7d2682b0042e921a76beb509d7ea68e1)
2018-06-21doc/crypto/pem.pod: modernise the example codeRichard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6552)
2018-06-21Update documentation for PEM callback: error is now -1.Nick Mathewson
In previous versions of OpenSSL, the documentation for PEM_read_* said: The callback B<must> return the number of characters in the passphrase or 0 if an error occurred. But since c82c3462267afdbbaa5, 0 is now treated as a non-error return value. Applications that want to indicate an error need to return -1 instead. Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6271) (cherry picked from commit bbbf752a3c8b5a966bcb48fc71a3dc03832e7b27) (cherry picked from commit e4b47f7f19392e3be604e44f6999de2bc9e7ecf3)
2018-06-18Warn against nonce reuse in DSA_sign_setup() docNicola Tuveri
Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6465)
2018-06-02Document failure return of ECDSA_SIG_newKen Goldman
ECDSA_SIG_new() returns NULL on error. Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6398) (cherry picked from commit 6da34cfbddede5e46f9c9183b724c99999dcfb41)
2018-05-11Fix typo 'is an error occurred' in documentationDr. Matthias St. Pierre
Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6231)
2018-05-01Clarify BN_mod_exp docsMatt Caswell
Specifically this is not supported with an even modulus and BN_FLG_CONSTTIME. Fixes #5082 Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6138) (cherry picked from commit 966b3df182b9c8644c154f1c3e686027d37acb05)
2018-05-01Fix some errors and missing info in the CMS docsMatt Caswell
Fixes #5063 Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6136)
2018-03-11Fix propotype to include the const qualifierKurt Roeckx
Reviewed-by: Andy Polyakov <appro@openssl.org> GH: #5582
2018-03-07BIO_s_mem.pod: fix indirection for out parameter **ppDr. Matthias St. Pierre
BIO_get_mem_data() and BIO_get_mem_ptr() assign to *pp, not pp Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/5544)
2018-03-01Fix typo in ASN1_STRING_length docIvan Filenko
CLA: trivial Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> (Merged from https://github.com/openssl/openssl/pull/5458)
2018-01-24Add warnings to thread doc.Rich Salz
Thanks to Yun Jiang for pointing this out. Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/5164)
2018-01-24Fix BN docRich Salz
Backport from https://github.com/openssl/openssl/pull/5141 Reviewed-by: Viktor Dukhovni <viktor@openssl.org> Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/5151) (cherry picked from commit 8b2124aba357a928fec6d7a3bafe186fc83080fc)
2017-12-23Add missing comma between referencesViktor Dukhovni
Reviewed-by: Ben Kaduk <kaduk@mit.edu> Reviewed-by: Paul Dale <paul.dale@oracle.com>
2017-12-13Document the X509_V_FLAG_PARTIAL_CHAIN flagViktor Dukhovni
Also documented X509_V_FLAG_TRUSTED_FIRST Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org>
2017-11-30Fix docs for EVP_EncryptUpdate and EVP_DecryptUpdateFdaSilvaYY
Fixes #4775 Reviewed-by: Andy Polyakov <appro@openssl.org> Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4815) (cherry picked from commit a61c15eb9b8d0ef513d695c854516958e2ccf1eb)
2017-10-03Fix backport by moving file.Dr. Stephen Henson
Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4453)
2017-09-29doc: note that the BN_new() initialises the BIGNUMHubert Kario
BN_new() and BN_secure_new() not only allocate memory, but also initialise it to deterministic value - 0. Document that behaviour to make it explicit backport from #4438 Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4443)
2017-09-29doc: BN_free() is NULL-safeHubert Kario
document that parameter to BN_free can be NULL backport from master Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4439)
2017-08-24Correct GCM docs.Dr. Stephen Henson
Fix GCM documentation: the tag does not have to be supplied before decrypting any data any more. Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4231)
2017-08-23Tweak wording to be more clear.Rich Salz
Reviewed-by: Andy Polyakov <appro@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4234) (cherry picked from commit a130950df92abf7dd787b000403da02af8f41c2d)
2017-07-26Backport X509_check_private_key.podPaul Yang
to address #3973, and original PR to master branch is #3614 test case in the original PR is not applied. Reviewed-by: Andy Polyakov <appro@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4002)
2017-07-18RSA_padding_check_PKCS1_type_2 is not constant time.Emilia Kasper
This is an inherent weakness of the padding mode. We can't make the implementation constant time (see the comments in rsa_pk1.c), so add a warning to the docs. Reviewed-by: Rich Salz <rsalz@openssl.org>
2017-05-25Document that HMAC() with a NULL md is not thread safeMatt Caswell
Fixes #3541 Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/3555)
2017-04-22Fixed typo in X509_STORE_CTX_new descriptionCamille Guérin
'X509_XTORE_CTX_cleanup' -> 'X509_STORE_CTX_cleanup' Reviewed-by: Kurt Roeckx <kurt@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/3271) (cherry picked from commit 7643a1723ef8eb4e542e57dfadeeb8eff788ec05) (cherry picked from commit 2c0b8d2872057fdda22d3f41c3d4e59835b414b4)
2017-03-29doc: Add stitched ciphers to EVP_EncryptInit.podSteven Collison
These ciphers don't appear to be documented anywhere. Given the performance[1] benefits I think it makes sense to expose them. [1] https://software.intel.com/sites/default/files/open-ssl-performance-paper.pdf Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/3067) (cherry picked from commit 209fac9f8a24000beaa8a438517115b42ca7e7c6)
2017-03-10Fix some RSA documentationMatt Caswell
RSA_private_encrypt(), RSA_public_decrypt(), RSA_public_encrypt() and RSA_private_decrypt() are declared with a "const" from parameter, but this is not reflected in the docs. Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/2899) (cherry picked from commit b41f6b64f809e5992b9f1b601b3dff1a2129da2d)
2017-03-07Remove doc reference to non-existant GCM examplePauli
Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/2866) (cherry picked from commit c1f84df2484d9d6745f5aaf1eb708f0bcd3faf28)
2017-02-13DES keys are not 7 days long.Darren Tucker
CLA: trivial Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/2604) (cherry picked from commit ca423a693a619b38fb96d94b0385f8ce91a8e759)
2016-12-18Fix typo.Finn Hakansson
Reviewed-by: Kurt Roeckx <kurt@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> CLA: trivial (Merged from https://github.com/openssl/openssl/pull/2086) (cherry picked from commit 0b742f93ea7882a447f6523ac56a6f847d9f8e92) (cherry picked from commit f7a2da1d584bed2e05774f92d69fee39ce3edda2)
2016-11-23Clarify what X509_NAME_online does with the given buffer and sizeRichard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/1980) (cherry picked from commit 19cb71ef6e414759d737918bab10be2cc1d8bd99) (cherry picked from commit 793d9b79033c2fffc8e781dab2fd678661b348cd)
2016-11-18Use consistent variable namesBeat Bolli
In the X509_NAME_get_index_by_NID.pod example, the initialized variable is called "loc", but the one used in the for loop is called "lastpos". Make the names match. CLA: trivial Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/1949) (cherry picked from commit 4b9c2669f31da26bfe56f629973fa014083dc2a0)
2016-10-15Fix signatures of EVP_Digest{Sign,Verify}UpdateSteven Fackler
These are implemented as macros delegating to `EVP_DigestUpdate`, which takes a `size_t` as its third argument, not an `unsigned int`. CLA: trivial Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Matt Caswell <matt@openssl.org> (cherry picked from commit 8bdce8d160e29b4e1b80fec31f618d85d8c2b7a8)
2016-09-06Misc BN fixesRich Salz
Never output -0; make "negative zero" an impossibility. Do better checking on BN_rand top/bottom requirements and #bits. Update doc. Ignoring trailing garbage in BN_asc2bn. Port this commit from boringSSL: https://boringssl.googlesource.com/boringssl/+/899b9b19a4cd3fe526aaf5047ab9234cdca19f7d%5E!/ Ensure |BN_div| never gives negative zero in the no_branch code. Have |bn_correct_top| fix |bn->neg| if the input is zero so that we don't have negative zeros lying around. Thanks to Brian Smith for noticing. Reviewed-by: Richard Levitte <levitte@openssl.org> (cherry picked from commit 01c09f9fde5793e0b3712d602b02e2aed4908e8d) (Some manual work required)
2016-08-19Fix NULL-return checks in 1.0.2Rich Salz
RT4386: Add sanity checks for BN_new() RT4384: Missing Sanity Checks for RSA_new_method() RT4384: Missing Sanity Check plus potential NULL pointer deref RT4382: Missing Sanity Check(s) for BUF_strdup() RT4380: Missing Sanity Checks for EVP_PKEY_new() RT4377: Prevent potential NULL pointer dereference RT4375: Missing sanity checks for OPENSSL_malloc() RT4374: Potential for NULL pointer dereferences RT4371: Missing Sanity Check for malloc() RT4370: Potential for NULL pointer dereferences Also expand tabs, make update, typo fix (rsalz) Minor tweak by Paul Dale. Some minor internal review feedback. Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-07-22Clarify digest change in HMAC_Init_ex()Dr. Stephen Henson
RT#4603 Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-06-26RT2964: Fix it via docRich Salz
OBJ_nid2obj() and friends should be treated as const. Reviewed-by: Dr. Stephen Henson <steve@openssl.org> (cherry picked from commit 5d28ff38fd4127c5894d22533e842ee446c3d3c2)
2016-06-25Revert "RT2964: Fix it via doc"Rich Salz
This reverts commit 58b18779ba6e6060ac357cd0803d83317ed00f8b. Reviewed-by: Dr. Stephen Henson <steve@openssl.org>
2016-06-25RT2964: Fix it via docRich Salz
OBJ_nid2obj() and friends should be treated as const. Reviewed-by: Dr. Stephen Henson <steve@openssl.org> (cherry picked from commit 82f31fe4dd0dac30229fa8684229b49d2bcef404)
2016-06-22doc/crypto/OPENSSL_ia32cap.pod: harmonize with actual declaration.Andy Polyakov
[Note that in master declaration is different.] RT#4568 Reviewed-by: Rich Salz <rsalz@openssl.org>