Commit graph

10258 commits

Author SHA1 Message Date
Dr. Stephen Henson
8546add692 cert_flags is unsigned
(backport from HEAD)
2012-12-26 14:48:05 +00:00
Dr. Stephen Henson
aa5c5eb4c1 add support for client certificate callbak, fix memory leak
(backport from HEAD)
2012-12-26 14:47:31 +00:00
Dr. Stephen Henson
731abd3bd7 new function SSL_is_server to which returns 1 is the corresponding SSL context is for a server
(backport from HEAD)
2012-12-26 14:45:46 +00:00
Dr. Stephen Henson
7531dd18dc no need to check s->server as default_nid is never used for TLS 1.2 client authentication
(backport from HEAD)
2012-12-26 14:45:27 +00:00
Dr. Stephen Henson
04c32cddaa Separate client and server permitted signature algorithm support: by default
the permitted signature algorithms for server and client authentication
are the same but it is now possible to set different algorithms for client
authentication only.
(backport from HEAD)
2012-12-26 14:44:56 +00:00
Dr. Stephen Henson
623a5e24cb Add certificate callback. If set this is called whenever a certificate
is required by client or server. An application can decide which
certificate chain to present based on arbitrary criteria: for example
supported signature algorithms. Add very simple example to s_server.
This fixes many of the problems and restrictions of the existing client
certificate callback: for example you can now clear existing certificates
and specify the whole chain.
(backport from HEAD)
2012-12-26 14:43:51 +00:00
Dr. Stephen Henson
bd9fc1d667 New functions to retrieve certificate signatures and signature OID NID.
(backport from HEAD)
2012-12-26 14:31:05 +00:00
Dr. Stephen Henson
c550f2e37b Function tls1_check_ec_server_key is now redundant as we make
appropriate checks in tls1_check_chain.
(backport from HEAD)
2012-12-26 14:27:27 +00:00
Dr. Stephen Henson
484f876235 Add new "valid_flags" field to CERT_PKEY structure which determines what
the certificate can be used for (if anything). Set valid_flags field
in new tls1_check_chain function. Simplify ssl_set_cert_masks which used
to have similar checks in it.

Add new "cert_flags" field to CERT structure and include a "strict mode".
This enforces some TLS certificate requirements (such as only permitting
certificate signature algorithms contained in the supported algorithms
extension) which some implementations ignore: this option should be used
with caution as it could cause interoperability issues.
(backport from HEAD)
2012-12-26 14:26:53 +00:00
Dr. Stephen Henson
c70a1fee71 Reorganise supported signature algorithm extension processing.
Only store encoded versions of peer and configured signature algorithms.
Determine shared signature algorithms and cache the result along with NID
equivalents of each algorithm.
(backport from HEAD)
2012-12-26 14:26:16 +00:00
Dr. Stephen Henson
0b362de5f5 Add support for application defined signature algorithms for use with
TLS v1.2. These are sent as an extension for clients and during a certificate
request for servers.

TODO: add support for shared signature algorithms, respect shared algorithms
when deciding which ciphersuites and certificates to permit.
(backport from HEAD)
2012-12-26 14:25:29 +00:00
Dr. Stephen Henson
d312f7be37 Make it possible to delete all certificates from an SSL structure.
(backport from HEAD)
2012-12-26 14:18:50 +00:00
Dr. Stephen Henson
2b5e5c3d08 Revert incompatible OCSP_basic_verify changes.
Make partial chain chekcing work with EE certificates only.
Remove unneeded -trust_other option from tocsp.
(Backport from HEAD)
2012-12-26 14:12:09 +00:00
Dr. Stephen Henson
708454f010 add missing \n 2012-12-23 18:12:28 +00:00
Dr. Stephen Henson
f1aec4dec3 fix typo 2012-12-21 18:33:53 +00:00
Dr. Stephen Henson
1c53a72f17 update/fix tocsp script (from HEAD) 2012-12-20 19:15:35 +00:00
Dr. Stephen Henson
9b157602e0 Backport enhancements to OCSP utility from HEAD:
Support - as a file for standard input or output.

Add -badsig option to generate invalid signatures for testing.

New -rmd option to specify digest to sign OCSP responses with.
2012-12-20 19:06:39 +00:00
Dr. Stephen Henson
67e217c84c revert, missing commit message 2012-12-20 19:01:55 +00:00
Dr. Stephen Henson
e6b650df0a oops, revert 2012-12-20 19:01:34 +00:00
Dr. Stephen Henson
7b7b667ddc apps/ocsp.c 2012-12-20 18:59:09 +00:00
Dr. Stephen Henson
70cd3c6b95 Integrate host, email and IP address checks into X509_verify.
Add new verify options to set checks.

(backport from HEAD)
2012-12-19 15:14:10 +00:00
Dr. Stephen Henson
db05bc512d Return success when the responder is active.
Don't verify our own responses.
(backport from HEAD)
2012-12-19 15:02:58 +00:00
Dr. Stephen Henson
45da1efcdb Backport X509 hostname, IP address and email checking code from HEAD. 2012-12-19 15:01:59 +00:00
Dr. Stephen Henson
54a0076e94 Check chain is not NULL before assuming we have a validated chain. The
modification to the OCSP helper purpose breaks normal OCSP verification. It is
no longer needed now we can trust partial chains.
2012-12-19 15:01:32 +00:00
Andy Polyakov
f8cab37bc1 VC-32.pl: fix typo [from HEAD].
Submitted by: Pierre Delaage
2012-12-16 19:40:51 +00:00
Dr. Stephen Henson
2e65277695 Use new partial chain flag instead of modifying input parameters.
(backport from HEAD)
2012-12-14 14:31:16 +00:00
Dr. Stephen Henson
9a1f59cd31 New verify flag to return success if we have any certificate in the trusted
store instead of the default which is to return an error if we can't build
the complete chain. [backport from HEAD]
2012-12-14 14:30:46 +00:00
Ben Laurie
4e72220fd6 Documentation improvements by Chris Palmer (Google). 2012-12-14 13:29:17 +00:00
Ben Laurie
d65b8b2162 Backport OCSP fixes. 2012-12-14 12:53:53 +00:00
Ben Laurie
5dca1e338c Document -pubkey option. 2012-12-13 16:16:48 +00:00
Ben Laurie
5f4cf08864 Make verify return errors. 2012-12-13 15:49:15 +00:00
Ben Laurie
2a2e537983 Ignore more. 2012-12-13 12:43:18 +00:00
Ben Laurie
d79fc8da02 Add my 64-bit debug target. 2012-12-12 13:45:32 +00:00
Dr. Stephen Henson
e04ccbc5cc Fix two bugs which affect delta CRL handling:
Use -1 to check all extensions in CRLs.
Always set flag for freshest CRL.
2012-12-06 18:24:47 +00:00
Andy Polyakov
bc946bfb97 aes-s390x.pl: fix XTS bugs in z196-specific code path [from HEAD]. 2012-12-05 17:45:09 +00:00
Dr. Stephen Henson
38680fa466 check mval for NULL too 2012-12-04 17:26:04 +00:00
Dr. Stephen Henson
a902b6bd98 fix leak 2012-12-03 16:33:15 +00:00
Andy Polyakov
c5e91a9ae9 aes-s390x.pl: harmonize software-only path [from HEAD]. 2012-12-01 11:09:13 +00:00
Dr. Stephen Henson
b5f57f455a PR: 2803
Submitted by: jean-etienne.schwartz@bull.net

In OCSP_basic_varify return an error if X509_STORE_CTX_init fails.
2012-11-29 19:15:27 +00:00
Andy Polyakov
ad00a52f2d Intel compiler support update from HEAD. 2012-11-28 13:12:09 +00:00
Dr. Stephen Henson
e08c7f15b4 change inaccurate error message 2012-11-26 15:47:44 +00:00
Dr. Stephen Henson
7469af4484 reject zero length point format list or supported curves extensions 2012-11-22 14:15:36 +00:00
Dr. Stephen Henson
ec76d850af PR: 2908
Submitted by: Dmitry Belyavsky <beldmit@gmail.com>

Fix DH double free if parameter generation fails.
2012-11-21 14:02:30 +00:00
Dr. Stephen Henson
cedf19f356 fix leaks 2012-11-20 00:28:22 +00:00
Dr. Stephen Henson
1d5f3f4640 correct docs 2012-11-19 20:06:57 +00:00
Andy Polyakov
a060fc3b8e x86_64-gcc.c: resore early clobber constraint [from HEAD].
Submitted by: Florian Weimer
2012-11-19 15:02:34 +00:00
Dr. Stephen Henson
bda5153703 PR: 2880
Submitted by: "Florian Rüchel" <florian.ruechel@ruhr-uni-bochum.de>

Correctly handle local machine keys in the capi ENGINE.
2012-11-18 15:21:12 +00:00
Dr. Stephen Henson
6f539399ef add "missing" TLSv1.2 cipher alias 2012-11-15 19:15:07 +00:00
Andy Polyakov
d90bf2ab21 [vp]aes-x86[_64].pl: update from HEAD. 2012-11-12 18:11:17 +00:00
Andy Polyakov
02620cfcd5 Cumulative updates from HEAD. 2012-10-29 22:29:29 +00:00