oweals/openssl.git
11 years agoMake sure all tests are actually run, plus some fixups for things that
Ben Laurie [Sun, 7 Apr 2013 15:52:54 +0000 (16:52 +0100)]
Make sure all tests are actually run, plus some fixups for things that
turn out to be made somewhere by existing Makefiles.

11 years agoUse original alltests target for definitive test list.
Ben Laurie [Sat, 6 Apr 2013 19:42:38 +0000 (20:42 +0100)]
Use original alltests target for definitive test list.

11 years agoMissing semicolon.
Ben Laurie [Sat, 6 Apr 2013 15:17:14 +0000 (16:17 +0100)]
Missing semicolon.

11 years agoFix non-copy builds.
Dr. Stephen Henson [Sat, 6 Apr 2013 15:05:23 +0000 (16:05 +0100)]
Fix non-copy builds.

Only use -MMD and .sinclude in copy builds: other platforms don't
support them.

11 years agoMissing file.
Ben Laurie [Sat, 6 Apr 2013 14:25:43 +0000 (15:25 +0100)]
Missing file.

11 years agoMake executable.
Ben Laurie [Sat, 6 Apr 2013 14:22:28 +0000 (15:22 +0100)]
Make executable.

11 years agoHelper scripts for one makefile build.
Ben Laurie [Sat, 6 Apr 2013 14:17:30 +0000 (15:17 +0100)]
Helper scripts for one makefile build.

11 years agoMerge, go back to copy-if-different.
Ben Laurie [Sat, 6 Apr 2013 14:15:11 +0000 (15:15 +0100)]
Merge, go back to copy-if-different.

11 years agoFix test_ss.
Ben Laurie [Wed, 3 Apr 2013 05:50:47 +0000 (06:50 +0100)]
Fix test_ss.

11 years agoAdd new asm target.
Ben Laurie [Wed, 3 Apr 2013 05:38:33 +0000 (06:38 +0100)]
Add new asm target.

11 years agoShow start/end of tests.
Ben Laurie [Wed, 3 Apr 2013 05:30:16 +0000 (06:30 +0100)]
Show start/end of tests.

11 years agoAvoid collisions.
Ben Laurie [Wed, 3 Apr 2013 05:05:33 +0000 (06:05 +0100)]
Avoid collisions.

11 years agoMake session ID test work.
Ben Laurie [Tue, 2 Apr 2013 05:04:58 +0000 (06:04 +0100)]
Make session ID test work.

11 years agoMake S/MIME test work.
Ben Laurie [Tue, 2 Apr 2013 05:02:13 +0000 (06:02 +0100)]
Make S/MIME test work.

11 years agoMake RSA test work.
Ben Laurie [Tue, 2 Apr 2013 04:38:57 +0000 (05:38 +0100)]
Make RSA test work.

11 years agoMake PKCS#7 test work.
Ben Laurie [Tue, 2 Apr 2013 04:36:21 +0000 (05:36 +0100)]
Make PKCS#7 test work.

11 years agoMake OCSP test work.
Ben Laurie [Tue, 2 Apr 2013 04:33:15 +0000 (05:33 +0100)]
Make OCSP test work.

11 years agoMore progress towards working tests.
Ben Laurie [Mon, 1 Apr 2013 17:22:58 +0000 (18:22 +0100)]
More progress towards working tests.

11 years agoGet closer to a working single Makefile with test support.
Ben Laurie [Sat, 23 Mar 2013 19:05:19 +0000 (19:05 +0000)]
Get closer to a working single Makefile with test support.

11 years agoFix warnings.
Ben Laurie [Sat, 23 Mar 2013 19:04:46 +0000 (19:04 +0000)]
Fix warnings.

11 years agoMake TLS 1.2 ciphers work again.
Dr. Stephen Henson [Thu, 4 Apr 2013 17:19:18 +0000 (18:19 +0100)]
Make TLS 1.2 ciphers work again.

Since s->method does not reflect the final client version when a client
hello is sent for SSLv23_client_method it can't be relied on to indicate
if TLS 1.2 ciphers should be used. So use the client version instead.

11 years agocryptlib.c: fix typo in OPENSSL_showfatal.
Andy Polyakov [Thu, 4 Apr 2013 13:57:43 +0000 (15:57 +0200)]
cryptlib.c: fix typo in OPENSSL_showfatal.

11 years agoaesni-x86_64.pl: optimize CBC decrypt.
Andy Polyakov [Thu, 4 Apr 2013 13:56:23 +0000 (15:56 +0200)]
aesni-x86_64.pl: optimize CBC decrypt.

Give CBC decrypt approximately same treatment as to CTR and collect 25%.

11 years agoe_aes.c: reserve for future extensions.
Andy Polyakov [Thu, 4 Apr 2013 13:55:49 +0000 (15:55 +0200)]
e_aes.c: reserve for future extensions.

11 years agogcm128.c: fix linking problems in 32-bit Windows build.
Andy Polyakov [Thu, 4 Apr 2013 13:54:58 +0000 (15:54 +0200)]
gcm128.c: fix linking problems in 32-bit Windows build.

11 years agodest4-sparcv9.pl: add clarification comment.
Andy Polyakov [Thu, 4 Apr 2013 13:54:08 +0000 (15:54 +0200)]
dest4-sparcv9.pl: add clarification comment.

11 years agoevptests.txt: add XTS test vectors
Andy Polyakov [Thu, 4 Apr 2013 13:53:01 +0000 (15:53 +0200)]
evptests.txt: add XTS test vectors

11 years agoUse $(PERL) when calling scripts in mk1mf.pl
Dr. Stephen Henson [Wed, 3 Apr 2013 21:38:18 +0000 (22:38 +0100)]
Use $(PERL) when calling scripts in mk1mf.pl

11 years agoTypo.
Dr. Stephen Henson [Sun, 31 Mar 2013 16:42:46 +0000 (17:42 +0100)]
Typo.

11 years agoAdd support for SPARC T4 DES opcode.
Andy Polyakov [Sun, 31 Mar 2013 12:32:05 +0000 (14:32 +0200)]
Add support for SPARC T4 DES opcode.

11 years agodes_enc.m4: add missing #include.
Andy Polyakov [Sun, 31 Mar 2013 12:07:48 +0000 (14:07 +0200)]
des_enc.m4: add missing #include.

Submitted by: David Miller

11 years agoAdd AES-NI GCM stitch.
Andy Polyakov [Fri, 29 Mar 2013 19:45:33 +0000 (20:45 +0100)]
Add AES-NI GCM stitch.

11 years agoaesni-x86_64.pl: fix typo and optimize small block performance.
Andy Polyakov [Fri, 29 Mar 2013 17:54:24 +0000 (18:54 +0100)]
aesni-x86_64.pl: fix typo and optimize small block performance.

11 years agoCall RAND_cleanup in openssl application.
Dr. Stephen Henson [Thu, 28 Mar 2013 14:28:06 +0000 (14:28 +0000)]
Call RAND_cleanup in openssl application.
(cherry picked from commit 944bc29f9004cf8851427ebfa83ee70b8399da57)

11 years agoEnable TLS 1.2 ciphers in DTLS 1.2.
Dr. Stephen Henson [Wed, 27 Mar 2013 19:54:48 +0000 (19:54 +0000)]
Enable TLS 1.2 ciphers in DTLS 1.2.

Port TLS 1.2 GCM code to DTLS. Enable use of TLS 1.2 only ciphers when in
DTLS 1.2 mode too.

11 years agoUpdate fixed DH requirements.
Dr. Stephen Henson [Wed, 27 Mar 2013 16:05:10 +0000 (16:05 +0000)]
Update fixed DH requirements.

The relaxed signing requirements for fixed DH certificates apply to DTLS 1.2
too.

11 years agoDTLS 1.2 cached record support.
Dr. Stephen Henson [Wed, 27 Mar 2013 15:50:42 +0000 (15:50 +0000)]
DTLS 1.2 cached record support.

Add DTLS1.2 support for cached records when computing handshake macs
instead of the MD5+SHA1 case for DTLS < 1.2 (this is a port of the
equivalent TLS 1.2 code to DTLS).

11 years agoMake binary curve ASN.1 work in FIPS mode.
Matt Caswell [Tue, 26 Mar 2013 15:39:50 +0000 (15:39 +0000)]
Make binary curve ASN.1 work in FIPS mode.

Don't check for binary curves by checking methods: the values will
be different in FIPS mode as they are redirected to the validated module
version.

11 years agoProvisional DTLS 1.2 support.
Dr. Stephen Henson [Wed, 20 Mar 2013 15:49:14 +0000 (15:49 +0000)]
Provisional DTLS 1.2 support.

Add correct flags for DTLS 1.2, update s_server and s_client to handle
DTLS 1.2 methods.

Currently no support for version negotiation: i.e. if client/server selects
DTLS 1.2 it is that or nothing.

11 years agoRemove versions test from dtls1_buffer_message
Dr. Stephen Henson [Tue, 26 Mar 2013 14:46:18 +0000 (14:46 +0000)]
Remove versions test from dtls1_buffer_message

Since this is always called from DTLS code it is safe to assume the header
length should be the DTLS value. This avoids the need to check the version
number and should work with any version of DTLS (not just 1.0).

11 years agoExtend DTLS method macros.
Dr. Stephen Henson [Tue, 19 Mar 2013 15:51:26 +0000 (15:51 +0000)]
Extend DTLS method macros.

Extend DTLS method creation macros to support version numbers and encryption
methods. Update existing code.

11 years agoEnable various DTLS extensions.
Dr. Stephen Henson [Tue, 19 Mar 2013 15:49:35 +0000 (15:49 +0000)]
Enable various DTLS extensions.

Some TLS extensions were disabled for DTLS. Possibly because they caused
problems with the old duplicated code. Enable them again.

11 years agoaesni-x86_64.pl: optimize CTR even further.
Andy Polyakov [Tue, 26 Mar 2013 13:29:18 +0000 (14:29 +0100)]
aesni-x86_64.pl: optimize CTR even further.

Based on suggestions from Shay Gueron and Vlad Krasnov.
PR: 3021

11 years agoghash-x86_64.pl: add AVX code path.
Andy Polyakov [Sun, 24 Mar 2013 22:44:35 +0000 (23:44 +0100)]
ghash-x86_64.pl: add AVX code path.

11 years agoaesni-x86_64.pl: optimize CTR even further.
Andy Polyakov [Tue, 19 Mar 2013 19:03:02 +0000 (20:03 +0100)]
aesni-x86_64.pl: optimize CTR even further.

11 years agoghash-x86_64.pl: minor optimization.
Andy Polyakov [Tue, 19 Mar 2013 19:02:11 +0000 (20:02 +0100)]
ghash-x86_64.pl: minor optimization.

11 years agoDisable compression for DTLS.
Dr. Stephen Henson [Tue, 19 Mar 2013 13:43:06 +0000 (13:43 +0000)]
Disable compression for DTLS.

The only standard compression method is stateful and is incompatible with
DTLS.

11 years agoTypo.
Dr. Stephen Henson [Tue, 19 Mar 2013 12:41:13 +0000 (12:41 +0000)]
Typo.

11 years agoe_aes_cbc_hmac_sha1.c: fix rare bad record mac on AES-NI plaforms.
Andy Polyakov [Mon, 18 Mar 2013 18:29:41 +0000 (19:29 +0100)]
e_aes_cbc_hmac_sha1.c: fix rare bad record mac on AES-NI plaforms.

PR: 3002

11 years agoUse enc_flags when deciding protocol variations.
Dr. Stephen Henson [Wed, 13 Mar 2013 15:33:24 +0000 (15:33 +0000)]
Use enc_flags when deciding protocol variations.

Use the enc_flags field to determine whether we should use explicit IV,
signature algorithms or SHA256 default PRF instead of hard coding which
versions support each requirement.

11 years agoUse appropriate versions of SSL3_ENC_METHOD
Dr. Stephen Henson [Wed, 13 Mar 2013 13:30:44 +0000 (13:30 +0000)]
Use appropriate versions of SSL3_ENC_METHOD

11 years agoDTLS revision.
Dr. Stephen Henson [Mon, 11 Mar 2013 15:34:28 +0000 (15:34 +0000)]
DTLS revision.

Revise DTLS code. There was a *lot* of code duplication in the
DTLS code that generates records. This makes it harder to maintain and
sometimes a TLS update is omitted by accident from the DTLS code.

Specifically almost all of the record generation functions have code like
this:

some_pointer = buffer + HANDSHAKE_HEADER_LENGTH;
... Record creation stuff ...
set_handshake_header(ssl, SSL_MT_SOMETHING, message_len);

...

write_handshake_message(ssl);

Where the "Record creation stuff" is identical between SSL/TLS and DTLS or
in some cases has very minor differences.

By adding a few fields to SSL3_ENC to include the header length, some flags
and function pointers for handshake header setting and handshake writing the
code can cope with both cases.

Note: although this passes "make test" and some simple DTLS tests there may
be some minor differences in the DTLS code that have to be accounted for.

11 years agoAvoid unnecessary fragmentation.
Michael Tuexen [Mon, 18 Mar 2013 14:30:38 +0000 (14:30 +0000)]
Avoid unnecessary fragmentation.

11 years agoEncode INTEGER correctly.
Dr. Stephen Henson [Mon, 18 Mar 2013 14:19:40 +0000 (14:19 +0000)]
Encode INTEGER correctly.

If an ASN1_INTEGER structure is allocated but not explicitly set encode
it as zero: don't generate an invalid zero length INTEGER.
(cherry picked from commit 1643edc63c3e15b6db5a15a728bc288f2cc2bbc7)

11 years agoTypo.
Dr. Stephen Henson [Mon, 18 Mar 2013 13:58:32 +0000 (13:58 +0000)]
Typo.
(cherry picked from commit 1546fb780bc11556a18d70c5fb29af4a9d5beaff)

11 years agoDTLS trace support.
Dr. Stephen Henson [Fri, 8 Mar 2013 16:45:37 +0000 (16:45 +0000)]
DTLS trace support.

Add DTLS record header parsing, different client hello format and add
HelloVerifyRequest message type.

Add code to d1_pkt.c to send message headers to the message callback.

11 years agoevptests.txt: additional GCM test vectors.
Andy Polyakov [Wed, 6 Mar 2013 18:24:05 +0000 (19:24 +0100)]
evptests.txt: additional GCM test vectors.

11 years agoGCM and CCM test support
Dr. Stephen Henson [Wed, 6 Mar 2013 15:45:15 +0000 (15:45 +0000)]
GCM and CCM test support

Add code to support GCM an CCM modes in evp_test. On encrypt this
will compare the expected ciphertext and tag. On decrypt it will
compare the expected plaintext: tag comparison is done internally.

Add a simple CCM test case and convert all tests from crypto/modes/gcm128.c

11 years agoAdd CCM ciphers to tables.
Dr. Stephen Henson [Wed, 6 Mar 2013 15:41:29 +0000 (15:41 +0000)]
Add CCM ciphers to tables.

11 years agoghash-x86_64.pl: fix length handling bug.
Andy Polyakov [Wed, 6 Mar 2013 09:42:21 +0000 (10:42 +0100)]
ghash-x86_64.pl: fix length handling bug.

Thanks to Shay Gueron & Vlad Krasnov for report.

11 years agotypo
Dr. Stephen Henson [Tue, 5 Mar 2013 21:19:39 +0000 (21:19 +0000)]
typo

11 years agoInitial CCM code.
Dr. Stephen Henson [Tue, 5 Mar 2013 18:29:14 +0000 (18:29 +0000)]
Initial CCM code.

Simple example of CCM code use: translated from the FIPS self tests.

11 years agoUse CFLAG for LFLAGS instead of the nonexistent CFLAGS.
Ben Laurie [Tue, 5 Mar 2013 05:55:19 +0000 (05:55 +0000)]
Use CFLAG for LFLAGS instead of the nonexistent CFLAGS.

11 years agoIgnore mk1mf.pl output directories.
Ben Laurie [Tue, 5 Mar 2013 04:29:41 +0000 (04:29 +0000)]
Ignore mk1mf.pl output directories.

11 years agoRemove unused variable.
Ben Laurie [Mon, 4 Mar 2013 22:48:38 +0000 (22:48 +0000)]
Remove unused variable.

11 years agoActually comment out the cpuid asm!
Ben Laurie [Mon, 4 Mar 2013 20:31:59 +0000 (20:31 +0000)]
Actually comment out the cpuid asm!

11 years agoMerge branch 'master' of openssl.net:openssl
Ben Laurie [Mon, 4 Mar 2013 20:26:17 +0000 (20:26 +0000)]
Merge branch 'master' of openssl.net:openssl

Conflicts:
util/mk1mf.pl

11 years agoFix WIN32 build.
Dr. Stephen Henson [Mon, 4 Mar 2013 19:14:57 +0000 (19:14 +0000)]
Fix WIN32 build.

Make assembly language handling conditional on the "copy" platform
as Windows does its own thing here.

11 years agox86cpuid.pl: make it work with older CPUs.
Andy Polyakov [Mon, 4 Mar 2013 19:05:04 +0000 (20:05 +0100)]
x86cpuid.pl: make it work with older CPUs.

PR: 3005

11 years agoOnly copy headers if they've changed.
Ben Laurie [Mon, 4 Mar 2013 16:56:18 +0000 (16:56 +0000)]
Only copy headers if they've changed.

11 years agoDon't make CPUID stuff twice.
Ben Laurie [Mon, 4 Mar 2013 16:10:47 +0000 (16:10 +0000)]
Don't make CPUID stuff twice.

11 years agoHandle assembler files.
Ben Laurie [Mon, 4 Mar 2013 14:11:18 +0000 (14:11 +0000)]
Handle assembler files.

11 years agoMissing MINFO generation.
Ben Laurie [Mon, 4 Mar 2013 14:10:13 +0000 (14:10 +0000)]
Missing MINFO generation.

11 years agoOverride local vars for MINFO build.
Ben Laurie [Mon, 4 Mar 2013 14:09:17 +0000 (14:09 +0000)]
Override local vars for MINFO build.

11 years agoAllow variables to be overridden on the command line.
Ben Laurie [Mon, 4 Mar 2013 14:08:23 +0000 (14:08 +0000)]
Allow variables to be overridden on the command line.

11 years agoTake the first definition of a variable.
Ben Laurie [Sun, 3 Mar 2013 02:56:45 +0000 (02:56 +0000)]
Take the first definition of a variable.

11 years agoUse "copy" instead of "auto".
Ben Laurie [Sat, 2 Mar 2013 04:44:36 +0000 (04:44 +0000)]
Use "copy" instead of "auto".

11 years agoRemove pointless diagnostic.
Ben Laurie [Wed, 27 Feb 2013 22:21:14 +0000 (22:21 +0000)]
Remove pointless diagnostic.

11 years agoPreserve the C compiler.
Ben Laurie [Wed, 27 Feb 2013 22:20:37 +0000 (22:20 +0000)]
Preserve the C compiler.

11 years agoInherit CFLAGS when plaform is "auto".
Ben Laurie [Wed, 27 Feb 2013 22:07:26 +0000 (22:07 +0000)]
Inherit CFLAGS when plaform is "auto".

11 years agoInclude correctly.
Ben Laurie [Wed, 27 Feb 2013 05:01:36 +0000 (05:01 +0000)]
Include correctly.

11 years agoRemove empty command.
Ben Laurie [Wed, 27 Feb 2013 04:34:26 +0000 (04:34 +0000)]
Remove empty command.

11 years agoSpelling.
Ben Laurie [Wed, 27 Feb 2013 04:16:23 +0000 (04:16 +0000)]
Spelling.

11 years agoAdd dependency on destination directory.
Ben Laurie [Wed, 27 Feb 2013 04:12:11 +0000 (04:12 +0000)]
Add dependency on destination directory.

11 years agoSpelling.
Ben Laurie [Wed, 27 Feb 2013 04:09:38 +0000 (04:09 +0000)]
Spelling.

11 years agoAdd reallyclean target.
Ben Laurie [Wed, 27 Feb 2013 04:07:55 +0000 (04:07 +0000)]
Add reallyclean target.

11 years agox86_64-gf2m.pl: fix typo.
Andy Polyakov [Fri, 1 Mar 2013 21:36:36 +0000 (22:36 +0100)]
x86_64-gf2m.pl: fix typo.

11 years agox86_64-gf2m.pl: add missing Windows build fix for #2963.
Andy Polyakov [Fri, 1 Mar 2013 20:43:10 +0000 (21:43 +0100)]
x86_64-gf2m.pl: add missing Windows build fix for #2963.

PR: 3004

11 years agoIgnore MINFO.
Ben Laurie [Tue, 26 Feb 2013 21:50:40 +0000 (21:50 +0000)]
Ignore MINFO.

11 years agoMissing files target.
Ben Laurie [Tue, 26 Feb 2013 21:50:26 +0000 (21:50 +0000)]
Missing files target.

11 years agoAdd function CMS_RecipientInfo_encrypt
Dr. Stephen Henson [Tue, 26 Feb 2013 16:48:49 +0000 (16:48 +0000)]
Add function CMS_RecipientInfo_encrypt

Add CMS_RecipientInfo_encrypt: this function encrypts an existing content
encryption key to match the key in the RecipientInfo structure: this is
useful if a new recpient is added to and existing enveloped data structure.

Add documentation.

11 years agoFix error codes.
Dr. Stephen Henson [Tue, 26 Feb 2013 16:46:58 +0000 (16:46 +0000)]
Fix error codes.

11 years agoDemo code for SSL_CONF API
Dr. Stephen Henson [Tue, 26 Feb 2013 16:33:05 +0000 (16:33 +0000)]
Demo code for SSL_CONF API

Two example programs one for command line argument processing and
one for configuration file processing.

11 years agoUpdate SSL_CONF docs.
Dr. Stephen Henson [Tue, 26 Feb 2013 15:27:56 +0000 (15:27 +0000)]
Update SSL_CONF docs.

Fix some typos and update version number first added: it has now been
backported to OpenSSL 1.0.2.

11 years agoFix ignored return value warnings.
Ben Laurie [Thu, 21 Feb 2013 18:30:04 +0000 (18:30 +0000)]
Fix ignored return value warnings.

Not sure why I am getting these now and not before.

11 years agomake depend.
Ben Laurie [Thu, 21 Feb 2013 18:17:38 +0000 (18:17 +0000)]
make depend.

11 years agoFix POD errors to stop make install_docs dying with pod2man 2.5.0+
Nick Alcock [Fri, 15 Feb 2013 17:44:11 +0000 (17:44 +0000)]
Fix POD errors to stop make install_docs dying with pod2man 2.5.0+

podlators 2.5.0 has switched to dying on POD syntax errors. This means
that a bunch of long-standing erroneous POD in the openssl documentation
now leads to fatal errors from pod2man, halting installation.

Unfortunately POD constraints mean that you have to sort numeric lists
in ascending order if they start with 1: you cannot do 1, 0, 2 even if
you want 1 to appear first. I've reshuffled such (alas, I wish there
were a better way but I don't know of one).

11 years agosha256-586.pl: code refresh.
Andy Polyakov [Fri, 15 Feb 2013 10:23:06 +0000 (11:23 +0100)]
sha256-586.pl: code refresh.

11 years agosha1-586.pl: code refresh.
Andy Polyakov [Thu, 14 Feb 2013 21:20:17 +0000 (22:20 +0100)]
sha1-586.pl: code refresh.

11 years agoghash-x86[_64].pl: code refresh.
Andy Polyakov [Thu, 14 Feb 2013 15:28:09 +0000 (16:28 +0100)]
ghash-x86[_64].pl: code refresh.