summaryrefslogtreecommitdiff
path: root/src/lib/libc/stdlib/recallocarray.c (unfollow)
Commit message (Collapse)AuthorFilesLines
2021-08-28Only remove the directories if there's an obj/ or obj@tb1-2/+4
2021-08-28Add a pass using the modern vfy with by_dir roots, code by me, script tobeck3-15/+106
generate certdirs by jsing, and make chicken sacrifies by tb. ok tb@ jsing@
2021-08-28Zap blanks before tabs.tb1-4/+4
2021-08-28Add RCS markertb1-0/+1
2021-08-28Add case 2c to the go side. Don't tell jsing I touched go.beck1-0/+1
2021-08-28Remove the "dump_chain" flag and code. This was a workaround for a problem wherebeck2-16/+4
roots were not checked correctly before intermediates that has since been fixed and is no longer necessary. It is regress checked by case 2c in regress/lib/libcrypto/x509/verify.c ok jsing@ tb@
2021-08-28Check X509_get_notAfter return value in openssl(1) ca.cinoguchi1-3/+5
2021-08-28Use strndup instead of malloc, memcpy and NULL termination in openssl(1) ca.cinoguchi1-11/+4
suggested from tb@ for do_updatedb(), and applied the same for do_body() and do_revoke().
2021-08-28Remove ASN1_TIME_new and use NULL for X509_gmtime_adj, free tmptm in err pathinoguchi1-15/+7
comments from tb@
2021-08-28Unwrap lines in openssl(1) ca.cinoguchi1-5/+3
suggested from tb@
2021-08-28Avoid leak with X509_REVOKED variable in openssl(1) ca.cinoguchi1-1/+3
pointed out by tb@
2021-08-28Checking the return value in openssl(1) ca.cinoguchi1-41/+127
Some functions are used without verifying the return value in openssl(1) ca. This diff adds checking for the function return value. With this diff, I changed return value of the write_new_certificate from void to int to return the condition to the caller. ok and comments from tb@
2021-08-27Add regress test testing having the root cert in the intermediate bundlebeck5-1/+96
2021-08-27Remove unused #include <assert.h>.tb1-2/+1
This is from upstream where there is an assert() that EVP_MD_size(digest) matches the length returned by HMAC(). We avoid asserts in our libraries. From Martin Vahlensieck
2021-08-24Fix various read buffer overflow when printing ASN.1 strings (which aretb4-14/+20
not necessarily NUL terminated). Same as schwarze's fix in t_x509a.c r1.9. From David Benjamin and Matt Caswell (part of the fixes in OpenSSL 1.1.1l) ok inoguchi
2021-08-19Pull roots out of the trust store in the legacy xsc when building chainsbeck3-8/+26
to handly by_dir and fun things correctly. - fixes dlg@'s case and by_dir regress in openssl-ruby ok jsing@
2021-08-18Import regress tests for SM2. Not yet linked to the build.tb4-0/+640
Part of Github PR #105
2021-08-18Import initial code for the SM2 ciphertb7-0/+1870
This adds the SM2 algorithm defined in the Chinese standards GB/T 32918.1-2016, GB/T 32918.2-2016, GB/T 32918.3-2016, GB/T 32918.4-2016 and GB/T 32918.5-2017. This is an ISC licensed implementation contributed by Ribose.inc, based on the same code that was contributed to OpenSSL by Jack Lloyd. The port to LibreSSL was done by Ronald Tse and Nickolay Olshevsky. Github PR #105 I made quite a few cleanup passes on this, but more is needed, some of which will happen in-tree before this is linked to the build. ok deraadt inoguchi (a long time ago), jsing
2021-08-18Add a check_trust call to the legacy chain validation on chain add, rememberingbeck1-2/+10
the result in order to return the same errors as OpenSSL users expect to override the generic "Untrusted cert" error. This fixes the openssl-ruby timestamp test. ok tb@
2021-08-18Refactor the legacy chain validation from the chain adding code into itsbeck1-52/+70
own function, in preparation for subesquent change. No functional change. ok tb@
2021-08-16typo in commenttb1-2/+2
2021-08-11add new (unsupported) eddsa in certificate verify teststb1-1/+3
2021-08-06link X509_STORE_get_by_subject(3) and X509_ocspid_print(3) to the build,schwarze1-1/+3
forgotten in earlier commits
2021-08-06new manual page X509_ocspid_print(3)schwarze3-6/+66
using input from tb@, and OK tb@ on an earlier version
2021-08-06add a roff(7) comment marking the API function X509_get_default_private_dir()schwarze1-2/+5
as intentionally undocumented because it is trivial and unused in the wild; OK tb@
2021-08-04SSL_CTX_remove_session() checks for a NULL session, avoid doing it twice.jsing1-2/+2
Noted by tb@ during review of a larger change.
2021-08-03Document X509_get_default_cert_dir_env(3)schwarze1-8/+35
and X509_get_default_cert_file_env(3). LibreSSL itself does not call getenv(3), but a few application programs including epic5, fetchmail, fossil, slic3r call these functions, so in case programmers find them in existing code, telling them what they do seems useful.
2021-08-03Document X509_get_default_cert_area(3).schwarze1-7/+41
Put it into this page because this is the code actually using it. Despite its name and include file, it is unrelated to X.509 and unrelated to certificates: it is just the default directory containing the library configuration file, openssl.cnf(5).
2021-08-02tweaks regarding X509_LOOKUP_by_subject(3):schwarze1-8/+28
* document the X509_OBJECT output parameter * more precision regarding return values * clarify relationship with X509_LOOKUP_ctrl(3) for the dir lookup method
2021-08-02new manual page X509_STORE_get_by_subject(3)schwarze5-12/+212
2021-08-01document X509_STORE_load_mem(3) and X509_STORE_add_lookup(3)schwarze1-7/+67
2021-07-31document X509_LOOKUP_mem(3) in X509_LOOKUP_hash_dir(3)schwarze8-32/+636
and add a new manual page X509_LOOKUP_new(3)
2021-07-31We have defines for alert levels - use them instead of magic numbers.jsing2-7/+5
2021-07-30Move the explanations related to *ptree closer together and correctschwarze1-16/+19
the lie that *ptree is set upon success - in some cases of success, it is set to NULL, whereas in some cases of failure, a non-trivial tree may be returned. beck@ pointed out that statements related to *ptree were scattered all over the place, and this patch works for him.
2021-07-29Ensure that the kill signal undergoing testing is not ignored.anton1-1/+15
ok bluhm@
2021-07-29Fix a documentation bug i introduced that tb@ pointed out:schwarze1-12/+3
X509_policy_check(3) never returns 2. If validation succeeds, it always returns 1.
2021-07-29Document X509_STORE_set_verify_func(3), mostly using text from theschwarze1-8/+32
OpenSSL 1.1.1 branch, which is still under a free license, tweaked by me. While here, garbage collect the weird BUGS section.
2021-07-29document X509_STORE_CTX_get0_parent_ctx(3)schwarze1-4/+34
2021-07-29document X509_STORE_CTX_set_app_data(3) and X509_STORE_CTX_get_app_data(3)schwarze1-4/+51
2021-07-28document X509_STORE_CTX_get0_policy_tree(3)schwarze1-4/+41
and X509_STORE_CTX_get_explicit_policy(3)
2021-07-28document X509_policy_tree_free(3)schwarze1-3/+19
2021-07-28consisely explain the meaning of return values rather than merelyschwarze1-3/+20
refering to child object names defined in the standard
2021-07-28Explain the meaning of the policy_oids input argument, correct theschwarze1-14/+12
description of the *pexplicit_policy output argument and make it less technical, and drop the mention of the expected_policy_set because the library provides no accessor function for it.
2021-07-28explicitely -> explicitly;jmc1-4/+4
2021-07-27new manual page X509_policy_check(3)schwarze6-10/+198
2021-07-26Add error checks for i2d_X509_NAME()tb1-3/+5
This avoids potential malloc(-1) and malloc(0), spotted by schwarze while documenting X509_ocspid_print(). ok schwarze
2021-07-26new manual page X509_policy_tree_level_count(3)schwarze4-6/+168
documenting the X509_POLICY_TREE object and its sub-objects
2021-07-26Dedup dtls1_dispatch_alert()/ssl3_dispatch_alert().jsing6-65/+26
The code for dtls1_dispatch_alert() and ssl3_dispatch_alert() is largely identical - with a bit of reshuffling we can use ssl3_dispatch_alert() for both protocols and remove the ssl_dispatch_alert function pointer. ok inoguchi@ tb@
2021-07-25Document X509_STORE_CTX_set_trust(3), X509_STORE_CTX_set_purpose(3),schwarze1-4/+226
and X509_STORE_CTX_purpose_inherit(3). These functions look deceptively simple on first sight, but their semantics is surprisingly complicated.
2021-07-24Two new manual pages X509_TRUST_set(3) and X509_check_trust(3)schwarze8-12/+516
documenting ten functions related to X509_TRUST objects, trust identifiers, and trust indices.