summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Revert previous - we still want to do this, but I forgot about the installerbeck2017-04-292-14/+6
| | | | | and want to avoid the wrath of theo when he arrives home in a couple of hours :)
* We now require you to have a working libpthreadbeck2017-04-291-1/+2
|
* Make it safe to call SSL_library_init more than once.beck2017-04-291-5/+12
| | | | | | We are basically admitting that pthread is everywhere, and we will be using it for other things too. ok jsing@
* Stop calling OPENSSL_init() internally, since it is a no-op. Also placejsing2017-04-293-9/+4
| | | | | | it under #ifndef LIBRESSL_INTERNAL. ok beck@
* Switch Linux getrandom() usage to non-blocking mode, continuing tobeck2017-04-291-6/+9
| | | | | | | | | | use fallback mechanims if unsuccessful. The design of Linux getrandom is broken. It has an uninitialized phase coupled with blocking behaviour, which is unacceptable from within a library at boot time without possible recovery. ok deraadt@ jsing@
* Revert previous change that forced consistency between return value andbeck2017-04-281-10/+2
| | | | | | | error code, since this breaks the documented API. Under certain circumstances this will result in incorrect successful certiticate verification (where a user supplied callback always returns 1, and later code checks the error code to potentially abort post verification)
* revert previous accidental commitbeck2017-04-285-25/+46
|
* *** empty log message ***beck2017-04-285-46/+25
|
* Remove "len < 0" check; len is socklen_t (uint32_t) so can't bemillert2017-04-271-2/+2
| | | | negative. Quiets a warning from clang. OK bluhm@
* tls_free(3) and tls_config_free(3) accept NULL;schwarze2017-04-272-4/+14
| | | | | patch from Matthew Martin <phy1729 at gmail dot com>, slightly tweaked by me
* Rearrange text a bit to make it clear what "discarded" means; ok jmc@ deraadt@otto2017-04-231-8/+13
|
* For small allocations (chunk) freezero only validates the givenotto2017-04-221-5/+10
| | | | | | | | size if canaries are enabled. In that case we have the exact requested size of the allocation. But we can at least check the given size against the chunk size if C is not enabled. Plus add some braces so my brain doesn't have to scan for dangling else problems when I see this code.
* Fix previous.visa2017-04-201-2/+2
|
* Get TCB address using the RDHWR instruction instead of __get_tcb().visa2017-04-201-4/+5
| | | | | | | | | | | This gives fast access to the address on systems that implement the UserLocal register. TCB caching is still used when running in the single-threaded mode in order not to penalize old systems. The kernel counterpart of this change must be in place before using this diff! With guenther@
* don't forget to fill in canary bytes for posix_memalign(3); reported byotto2017-04-181-1/+4
| | | | and ok jeremy@
* use freezero() instead of 4-line conditional explicit_bzero + freederaadt2017-04-184-28/+10
|
* consictently use .Dv NULL and a few other tweaks; ok schwarze@otto2017-04-171-20/+17
|
* whitespace fixesotto2017-04-171-14/+14
|
* Use INT_MAX instead of SIZE_MAX as the maximum file size we can handle.kettenis2017-04-161-2/+2
| | | | | | Fixes this test on 64-bit architectures. ok visa@
* Define DEF_WEAK like we do for ld.so to fix building this with clang.kettenis2017-04-161-1/+2
| | | | ok millert@, deraadt@
* Move comments into a block and uses {} to unconfuse reading.deraadt2017-04-161-12/+13
|
* Use %zu to print a size_t.kettenis2017-04-161-2/+2
|
* Remove unused rnd_seed variable. Upstream made the same change 4 days ago.kettenis2017-04-161-3/+0
| | | | Fixes compiling this test using clang on arm64.
* backout previous, data_len is not always initializedotto2017-04-161-2/+5
|
* Use freezero(3) when cleaning up session tickets - not only does it requirejsing2017-04-141-6/+3
| | | | | less code, but there is also a potential performance gain since they can be larger allocations.
* Use freezero(3) to clean up the X25519 keys - simpler, cleaner code.jsing2017-04-141-6/+3
|
* Use freezero(3) in the CBB clean up path, since this could hold sensitivejsing2017-04-141-3/+2
| | | | information (such as master keys).
* Switch i2d_SSL_SESSION() back to freezero(3) now that the size constraintsjsing2017-04-141-5/+2
| | | | have been relaxed.
* Clean up server key exchange EC point handling. Encode the point directlyjsing2017-04-141-27/+15
| | | | | | | | into the CBB memory, rather than mallocing and memcpying, which also makes makes the code more consistent with the client. Add a missing check for the first EC_POINT_point2oct() call. ok beck@
* allow clearing less than allocated and document freezero(3) betterotto2017-04-132-13/+26
|
* New strstr() implementation from musl libc by Rich Felker. Thismillert2017-04-121-44/+180
| | | | | | | | version uses the two-way string matching algorithm and is faster than the old implementation. With this change, ports that check for strstr having linear complexity time strstr will no longer replace the libc strstr with a private version. OK deraadt@ espie@
* Revert ssl_asn1.c r1.50 - CBB and freezero(3) do not play nicely together.jsing2017-04-111-2/+5
| | | | | | Back this out while we investigate and implement a solution. Found the hard way by sthen@
* new X25519(3) manual page;schwarze2017-04-105-10/+113
| | | | from Dr. Stephen Henson <steve@openssl.org>, OpenSSL commit d218f3c3
* Use freezero() for the internal opaque structures, instead of the currentjsing2017-04-103-18/+9
| | | | explicit_bzero()/free(). Less code and potentially less overhead.
* Use freezero() for X25519 keys - same result with more readable code.jsing2017-04-101-7/+3
|
* document three additional functions;schwarze2017-04-101-7/+60
| | | | from Emilia Kasper <emilia at openssl dot org>, OpenSSL commit 4ac139b4
* Rework and significantly extend TLS name verification tests to matchjsing2017-04-101-99/+377
| | | | changes in libtls.
* Rework name verification code so that a match is indicated via an argument,jsing2017-04-105-47/+76
| | | | | | | | | | rather than return codes. More strictly follow RFC 6125, in particular only check the CN if there are no SAN identifiers present in the certificate (per section 6.4.4). Previous behaviour questioned by Daniel Stenberg <daniel at haxx dot se>. ok beck@ jca@
* freezero() the key block; simpler code and less of it.jsing2017-04-101-7/+3
|
* Use freezero() for i2d_SSL_SESSION() - one line of code instead of three.jsing2017-04-101-5/+2
| | | | | | In this case the memory allocated can also be significant, in which case freezero() will have less overhead than explicit_bzero() (munmap instead of touching all of the memory to write zeros).
* fix some .Xr errors that jmc@ found with mdoclint(1)schwarze2017-04-103-12/+13
|
* new manual page SSL_get_server_tmp_key(3)schwarze2017-04-103-2/+88
| | | | from Matt Caswell <matt@openssl.org>, OpenSSL commit 508fafd8
* Additional SSL_SESSION documentationschwarze2017-04-1011-16/+349
| | | | | from Matt Caswell <matt at openssl dot org>, OpenSSL commit b31db505. Improve crosslinking while here.
* for pure *_ctrl() wrapper macros, move the reference from ssl(3)schwarze2017-04-1014-49/+54
| | | | to SSL_CTX_ctrl(3) to make ssl(3) slightly more palatable
* new manual page SSL_CTX_set_tlsext_servername_callback(3) for SNI;schwarze2017-04-102-1/+126
| | | | | from <Jon dot Spillett at oracle dot com> via OpenSSL commit 8c55c461
* tweak previous;jmc2017-04-101-4/+4
|
* Convert various client key exchange functions to freezero(3). The memoryjsing2017-04-101-14/+5
| | | | | contents needs to be made inaccessible - this is simpler and less error prone than the current "if not NULL, explicit_bzero(); free()" dance.
* Introducing freezero(3) a version of free that guarantees the processotto2017-04-102-36/+130
| | | | | | no longer has access to the content of a memmory object. It does this by either clearing (if the object memory remains cached) or by calling munmap(2). ok millert@, deraadt@, guenther@
* pasto; from <Jon dot Spillett at oracle dot com> via OpenSSL commit 3aaa1bd0schwarze2017-04-101-3/+3
|
* typo fix; from <Jon dot Spillett at oracle dot com>schwarze2017-04-101-5/+5
| | | | via OpenSSL commit 7bd27895