Various custom extension fixes.

Force no SSL2 when custom extensions in use.
Don't clear extension state when cert is set.
Clear on renegotiate.
crypto/sha/asm/sha*-x86_64.pl: comply with Win64 ABI.
crypto/bn/asm/rsax-x86_64.pl: make it work on Darwin.
crypto/evp/e_aes.c: fix logical pre-processor bug and formatting.

Bug would emerge when XTS is added to bsaes-armv7.pl. Pointed out by
Ard Biesheuvel of Linaro.
Algorithm parameter support.

Check and set AlgorithmIdenfier parameters for key wrap algorithms.
Currently these just set parameters to NULL.
Minor optimisation to KDF algorithm.

Don't need to use temporary buffer if remaining length equals digest length.
If present print j, seed and counter values for DH
Enhance DH dup functions.

Make DHparams_dup work properly with X9.42 DH parameters.
Extend DH parameter generation support.

Add support for DH parameter generation using DSA methods including
FIPS 186-3.
Add KDF for DH.

Add X9.42 DH KDF. Move sharedinfo generation code to CMS library as the
same structure is used by DH and ECDH.

Move ASN1_OBJECT typedef to ossl_typ.h so it can be picked up by dh headers
without the need to use ASN1.
CMS RFC2631 X9.42 DH enveloped data support.
Add X9.42 DH certificate to S/MIME test
Add X9.42 DH test.
Update cms docs.
Fix for PEM_X509_INFO_read_bio.

PR: 3028
Fix bug introduced in PEM_X509_INFO_bio which wouldn't process RSA keys
correctly if they appeared first.
DTLS handshake fix.

Reported by: Prashant Jaikumar <rmstar@gmail.com>

Fix handling of application data received before a handshake.
DTLS message_sequence number wrong in rehandshake ServerHello

This fix ensures that
* A HelloRequest is retransmitted if not responded by a ClientHello
* The HelloRequest "consumes" the sequence number 0. The subsequent
ServerHello uses the sequence number 1.
* The client also expects the sequence number of the ServerHello to
be 1 if a HelloRequest was received earlier.
This patch fixes the RFC violation.
Add the server 'hang' issue to the FAQ
Return 1 when setting ECDH auto mode.
Make no-ec compilation work.