summaryrefslogtreecommitdiff
path: root/src/lib/libtls/tls_util.c (unfollow)
Commit message (Collapse)AuthorFilesLines
2015-09-14Wrap <net/if.h> and <net/if_dl.h> so internal calls go direct and all theguenther2-2/+4
symbols are weak
2015-09-14Remove cast of int* to int*guenther1-2/+2
2015-09-14Finish wrapping <netdb.h> so that calls go direct and the symbols are all weakguenther9-9/+24
2015-09-14Test the exported strsignal() API, not the (now hidden) internal APIguenther1-8/+2
noted by daniel@
2015-09-14Temporarily revive MD4 for MS CHAP support.doug35-59/+1505
2015-09-13Crank major version due to removal of SHA-0 and MD4 from libcrypto.doug5-10/+10
2015-09-13Remove MD4 support from LibreSSL.doug35-1504/+58
MD4 should have been removed a long time ago. Also, RFC 6150 moved it to historic in 2011. Rides the major crank from removing SHA-0. Discussed with many including beck@, millert@, djm@, sthen@ ok jsing@, input + ok bcook@
2015-09-13Wrap <arpa/inet.h> and <arpa/nameser.h> so that calls go direct and theguenther5-5/+11
symbols without underbar prefix are all weak
2015-09-13Another style(9) grenade.jsing1-550/+825
2015-09-13Remove SHA-0 support.doug25-825/+36
SHA-0 was withdrawn shortly after publication 20 years ago and replaced with SHA-1. This will require a major crank. ok bcook@, jsing@
2015-09-13For now, permit overriding of the malloc family, to make emacs happyguenther1-6/+6
2015-09-13Revise regression test so that it works correctly with AES taking priorityjsing1-34/+191
if hardware acceleration is available.
2015-09-13nc(1) seems worth an Xr in SEE ALSO now;jmc1-1/+2
2015-09-13Since a major bump of libcrypto is coming, remove OPENSSL_ia32cap andmiod4-34/+4
OPENSSL_ia32cap_loc; nothing in ports uses them besides embedded copies of OpenSSL. This opens the `all hell gets loose' window.
2015-09-13Handle negative-zero in BN_bn2dec() too, just like in BN_print().deraadt2-44/+62
ok miod
2015-09-13Reorder functions for readability/consistency.jsing2-470/+456
2015-09-13BN does support negative-zero -- BN_print() sets the standard here.deraadt2-6/+6
BN_bn2hex() had a 1-byte overflow when creating "-0\0". Reported to me a while back by unknown person -- did not have enough experience to push this through then. advice from jsing, ok miod
2015-09-13work around the stupid semantics of SSL_read and SSL_write to make surebeck1-3/+3
we can indicate an EOF properly on tls_read and tls_write ok jsing@
2015-09-13Wrap <pwd.h> so that calls go direct and the symbols are all weak.guenther2-7/+8
Hide bcrypt_autorounds(), prefixing with an underbar for static builds.
2015-09-13Overshot w/PROTO_DEPRECATED: seed48_deterministic() is used internallyguenther1-1/+2
2015-09-13Remove explicit NULL checks before *_free() calls and tidy some code.jsing1-28/+22
2015-09-13Use ECDH_size() and do some other clean up.jsing1-7/+6
2015-09-13Only check for key truncation if no KDF function is being used.jsing2-8/+8
ok beck@ miod@
2015-09-13remove e_os2.h includesbcook2-2/+0
ok jsing@
2015-09-13Wrap long lines.jsing1-16/+32
2015-09-13style(9) grenade.jsing1-153/+178
2015-09-13Don't leak conninfo - spotted by marko kreen.beck1-2/+3
ok jsing@
2015-09-13Stop generating private keys in a network buffer.jsing2-58/+58
The current client key exchange code generates DH and ECDH keys into the same buffer that we use to send data to the network - stop doing this and malloc() a new buffer, which we explicit_bzero() and free() on return. This also benefits from ASLR and means that the keys are no longer generated in a well known location. ok beck@
2015-09-13The number of rounds is just two digits in the salt. We've alreadymillert1-2/+2
verified that they are there via isdigit() so we can convert from ASCII to an int without using atoi(). OK guenther@ deraadt@
2015-09-13Factor out setup_up / destroy_ui functions.bcook4-58/+58
This pulls out and renames setup_ui/destroy_ui so we have something that can be replaced as-needed, moving the the console setup code for Windows to app_win.c in -portable, instead of needing a local patch to enable binary console mode ui_read/write are also simplified.
2015-09-13Use ECDH_size() instead of rolling our own.jsing4-24/+22
ok beck@
2015-09-13document extra algorithms available with openssl speed commandbcook1-1/+4
ok jmc@
2015-09-13Switch to miod's shiny new OPENSSL_cpu_caps() and we can now also enablejsing2-6/+6
the AES acceleration checking for i386. ok beck@ miod@
2015-09-13Merge ech_ossl.c into ech_key.c - not much point having one file with ajsing5-432/+294
four line function and a tonne of license text. ok beck@
2015-09-13Nuke openssl/e_os2.h, since nothing should be using it.jsing2-86/+1
ok deraadt@ "hurray! finally!" miod@ "Yay!" sthen@
2015-09-13Provide ECDH_size().jsing6-8/+22
"jajaja" miod@
2015-09-13Check ECDH output buffer length and avoid truncation.jsing6-12/+32
Currently, if you call ECDH_compute_key() it will silently truncate the resulting key if the output buffer is less than the key size. Instead, detect this condition and return an error. If the buffer provided is larger than the key length, zero the remainder. ok beck@ miod@ "+ shivers"
2015-09-13Add Certplus CA root certificate:sthen1-0/+86
C=FR, O=Certplus, CN=Class 2 Primary CA req by beck@, ok miod@ beck@
2015-09-13display negotiated TLS version and cipher suite in verbose mode.beck1-2/+3
ok jsing@
2015-09-13Lob a style(9) grenade in here.jsing12-362/+352
2015-09-13Mechanical minor bump to follow libcrypto.miod3-3/+3
2015-09-13add visibility of ciper and connection version stringsbeck4-6/+56
ok jsing@
2015-09-13Add a new interface, OPENSSL_cpu_caps(), to return the currently runningmiod6-6/+36
cpu's specific hardware capabilities users of libcrypto might be interested in, as an integer value. This deprecates the existing OPENSSL_ia32cap() macro and the OPENSSL_ia32cap_loc() function (which returns the pointer so that you can mess with stuff you shouldn't mess with). Interpreting the value returned by OPENSSL_cpu_caps() is, of course, machine-dependent. Minor version bump for libcrypto. ok beck@ jsing@
2015-09-13The *_accept() functions increment in_handshake at the start of the function,jsing4-38/+60
then decrement it and call a callback on exit from the function. As such, these functions should not return in the middle, otherwise in_handshake is never decremented and the callback never called. ok beck@ "with many sighs" miod@
2015-09-13If we have hardware acceleration for AES, prefer AES as a symmetric cipherjsing2-14/+60
over CHACHA20. Otherwise, prefer CHACHA20 with AES second. ok beck@ miod@
2015-09-13Wrap <stdlib.h> so that calls go direct and the symbols not in theguenther22-26/+54
C standard are all weak. Apply __{BEGIN,END}_HIDDEN_DECLS to gdtoa{,imp}.h, hiding the arch-specific __strtorx, __ULtox_D2A, __strtorQ, __ULtoQ_D2A symbols.
2015-09-13tweak STANDARDS;jmc1-3/+3
2015-09-12Adapt to just committed libtls api changebeck1-21/+14
2015-09-12Move connection info into it's own private structure allocated and filled inbeck7-120/+208
at handshake time. change accessors to return const char * to remove need for caller to free memory. ok jsing@
2015-09-12Split ssl3_send_client_key_exchange() (387 lines of code) into fivejsing2-654/+702
functions. The original was written as a huge if/else if chain - split out the handling for each key exchange type. This allows us to reduce two levels of indentation, make the code far more readable and have single return paths so that we can simplify clean up. ok beck@