openssl.git
4 years agoWindows build system: fix 32-bit appveyor build.
Andy Polyakov [Wed, 23 Mar 2016 20:04:22 +0000 (21:04 +0100)]
Windows build system: fix 32-bit appveyor build.

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoBuild system: VC-WIN64I fixups.
Andy Polyakov [Wed, 23 Mar 2016 19:33:29 +0000 (20:33 +0100)]
Build system: VC-WIN64I fixups.

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoWhen using no-dtls create OPENSSL_NO_DTLS
Kurt Roeckx [Sun, 27 Mar 2016 22:31:23 +0000 (00:31 +0200)]
When using no-dtls create OPENSSL_NO_DTLS

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
MR: #2452

4 years agoAdd session reuse tests.
Kurt Roeckx [Sun, 27 Mar 2016 18:53:01 +0000 (20:53 +0200)]
Add session reuse tests.

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
MR: #2452

4 years agoResolve DTLS cookie and version before session resumption.
David Benjamin [Sun, 6 Mar 2016 05:19:59 +0000 (00:19 -0500)]
Resolve DTLS cookie and version before session resumption.

Session resumption involves a version check, so version negotiation must
happen first. Currently, the DTLS implementation cannot do session
resumption in DTLS 1.0 because the ssl_version check always checks
against 1.2.

Switching the order also removes the need to fixup ssl_version in DTLS
version negotiation.

Signed-off-by: Kurt Roeckx <kurt@roeckx.be>
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
RT: #4392, MR: #2452

4 years agoIt's called SSL_session_reused(), not SSL_session_resumed()
Kurt Roeckx [Sun, 27 Mar 2016 18:52:03 +0000 (20:52 +0200)]
It's called SSL_session_reused(), not SSL_session_resumed()

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
MR: #2452

4 years agoAllow different protocol version when trying to reuse a session
Fedor Indutny [Fri, 11 Mar 2016 14:44:01 +0000 (17:44 +0300)]
Allow different protocol version when trying to reuse a session

We now send the highest supported version by the client, even if the session
uses an older version.

This fixes 2 problems:
- When you try to reuse a session but the other side doesn't reuse it and
  uses a different protocol version the connection will fail.
- When you're trying to reuse a session with an old version you might be
  stuck trying to reuse the old version while both sides support a newer
  version

Signed-off-by: Kurt Roeckx <kurt@roeckx.be>
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
GH: #852, MR: #2452

4 years agoMath::BigInt does floored divs, BN_div does truncated div, compensate
Richard Levitte [Fri, 25 Mar 2016 23:07:50 +0000 (00:07 +0100)]
Math::BigInt does floored divs, BN_div does truncated div, compensate

According to documentation, perl's Math::BigInt does floored division,
i.e. the bdiv function does 1 / -4 = -1.  OpenSSL's BN_div, as well as
bc, do truncated division, i.e. 1 / -4 = 0.

We need to compensate for that difference in test/recipes/bc.pl to
make sure to verify the bntest results under its own conditions, by
dividing the absolute values of the given numbers and fixup the
result's negativity afterwards.

Closes RT#4485

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
4 years agoRT4476: Fix some cast-alignment warnings
Jeffrey Walton [Fri, 25 Mar 2016 13:06:47 +0000 (09:06 -0400)]
RT4476: Fix some cast-alignment warnings

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoVMS: add a note about DECC$* logical names
Richard Levitte [Fri, 25 Mar 2016 07:27:35 +0000 (08:27 +0100)]
VMS: add a note about DECC$* logical names

These logical names are used to make the C RTL change certain
behaviors, sometimes to make it act more like Unix.  While they can
make life easier in some cases, they can be disruptive as well.  When
building and testing OpenSSL, the latter is the case, so we ask people
to avoid using them.

Reviewed-by: Tim Hudson <tjh@openssl.org>
4 years agoRevert part of applink/Borland commit
Rich Salz [Thu, 24 Mar 2016 20:43:19 +0000 (16:43 -0400)]
Revert part of applink/Borland commit

This allows developer to glue DLL built with VC into their application
compiled with Borland C.

Reviewed-by: Andy Polyakov <appro@openssl.org>
4 years agoMore Borland removal.
Rich Salz [Thu, 24 Mar 2016 17:36:23 +0000 (13:36 -0400)]
More Borland removal.

And thanks to Miod Vallat for the nudge about ERR_PACK :)

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoVMS: $? might be huge enough to break line length limit, so don't print it
Richard Levitte [Wed, 23 Mar 2016 23:29:31 +0000 (00:29 +0100)]
VMS: $? might be huge enough to break line length limit, so don't print it

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoVMS: install openssl.conf in OPENSSLDIR, not INSTALLTOP
Richard Levitte [Wed, 23 Mar 2016 23:29:17 +0000 (00:29 +0100)]
VMS: install openssl.conf in OPENSSLDIR, not INSTALLTOP

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoVMS: have mms ignore creation of already existing dirs
Richard Levitte [Wed, 23 Mar 2016 23:28:38 +0000 (00:28 +0100)]
VMS: have mms ignore creation of already existing dirs

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoVMS: Rethink the staging directory
Richard Levitte [Wed, 23 Mar 2016 22:08:18 +0000 (23:08 +0100)]
VMS: Rethink the staging directory

On Windows and Unix, the staging directory $(DESTDIR) can simply be
prepended to the installation directory.  An attempt was made to do
something similar on VMS, but that ended up being a half measure
solution.  Instead of that, simply use the staging directory as a
prefix under which [.OPENSSL-INSTALL] and [.OPENSSL-COMMON] will hold
the two directory trees that should end up in the directories
indicated by --prefix and --openssldir, and finish the installation
with appropriate instructions on what to do next.

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoMisc fixes in VMS/openssl_startup.com.in
Richard Levitte [Wed, 23 Mar 2016 22:07:56 +0000 (23:07 +0100)]
Misc fixes in VMS/openssl_startup.com.in

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoAdjust some default installation directories
Richard Levitte [Wed, 23 Mar 2016 22:04:32 +0000 (23:04 +0100)]
Adjust some default installation directories

- on VMS, SYS$COMMON:[SSL] is already used as installation directory
  by HP SSL, so we make our default for --openssldir
  SYS$COMMON:[OPENSSL-COMMON] instead.
- Updated notes on default installation dirs fir Unix and Windows

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoVMS: update the properties of symbol search
Richard Levitte [Wed, 23 Mar 2016 18:30:31 +0000 (19:30 +0100)]
VMS: update the properties of symbol search

In this OpenSSL version, we deliver engines with lower case symbol
names.  The DSO symbol finder must be updated to allow for mixed case
symbols or it won't fine them.

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoVMS: compensate for command line length limits with a logical name
Richard Levitte [Wed, 23 Mar 2016 18:27:08 +0000 (19:27 +0100)]
VMS: compensate for command line length limits with a logical name

Sometimes, you might end up with a rather long compile line due to
excessively long /INCLUDE directories.  Compensate for it by making
a temporary logical name with them and using said logical name as
/INCLUDE argument.

A note was added to NOTES.VMS regarding these limitations.

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoMove dso.h to internal
Rich Salz [Wed, 23 Mar 2016 12:54:52 +0000 (08:54 -0400)]
Move dso.h to internal

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoRemove several unused undocumented functions.
Rich Salz [Tue, 22 Mar 2016 18:33:00 +0000 (14:33 -0400)]
Remove several unused undocumented functions.

Removed the following:
    DSO_bind_var, DSO_bind_var, DSO_get_default_method,
    DSO_get_loaded_filename, DSO_get_loaded_filename, DSO_get_method,
    DSO_new_method, DSO_pathbyaddr, DSO_set_default_method, DSO_set_method,
    DSO_set_name_converter, DSO_set_name_converter

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoFix error code
FdaSilvaYY [Mon, 14 Mar 2016 20:46:54 +0000 (21:46 +0100)]
Fix error code

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoSmall fixups in DSO
Richard Levitte [Wed, 23 Mar 2016 07:40:56 +0000 (08:40 +0100)]
Small fixups in DSO

- VMS configs had no dso_scheme
- Incorrect return of NULL method.

Reviewed-by: Tim Hudson <tjh@openssl.org>
4 years agoRemoved unused fields of CT_POLICY_EVAL_CTX
Rob Percival [Thu, 17 Mar 2016 20:57:24 +0000 (20:57 +0000)]
Removed unused fields of CT_POLICY_EVAL_CTX

Reviewed-by: Kurt Roeckx <kurt@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoCorrect another batch of typos
Alex Gaynor [Sun, 20 Mar 2016 15:51:06 +0000 (11:51 -0400)]
Correct another batch of typos

Reviewed-by: Kurt Roeckx <kurt@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoCheck algo_strength using SSL_STRONG_MASK
Kurt Roeckx [Sun, 21 Feb 2016 17:02:36 +0000 (18:02 +0100)]
Check algo_strength using SSL_STRONG_MASK

algo_strength contains 2 parts that need to be checked by their own.

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
MR: #2082

4 years agoremove unused references field
Dr. Stephen Henson [Tue, 22 Mar 2016 15:26:36 +0000 (15:26 +0000)]
remove unused references field

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoHave only one DSO_METHOD_openssl
Rich Salz [Tue, 22 Mar 2016 17:35:03 +0000 (13:35 -0400)]
Have only one DSO_METHOD_openssl

Instead of have every DSO_METHOD_xxx in all platforms, ensure that only
one DSO_METHOD_openssl is available on all platforms.

Reviewed-by: Tim Hudson <tjh@openssl.org>
4 years agoMake DSO opaque.
Rich Salz [Tue, 22 Mar 2016 17:16:54 +0000 (13:16 -0400)]
Make DSO opaque.

This was really easy.

Reviewed-by: Tim Hudson <tjh@openssl.org>
4 years agoMake X509_PUBKEY opaque
Dr. Stephen Henson [Tue, 22 Mar 2016 13:16:42 +0000 (13:16 +0000)]
Make X509_PUBKEY opaque

Reviewed-by: Matt Caswell <matt@openssl.org>
4 years agomove x_pubkey.c to crypto/x509
Dr. Stephen Henson [Tue, 22 Mar 2016 12:45:58 +0000 (12:45 +0000)]
move x_pubkey.c to crypto/x509

Reviewed-by: Matt Caswell <matt@openssl.org>
4 years agoFix enable-zlib no-comp.
Ben Laurie [Tue, 22 Mar 2016 10:40:13 +0000 (10:40 +0000)]
Fix enable-zlib no-comp.

Reviewed-by: Matt Caswell <matt@openssl.org>
4 years agoFix no-rc4.
Ben Laurie [Tue, 22 Mar 2016 02:39:36 +0000 (02:39 +0000)]
Fix no-rc4.

Reviewed-by: Matt Caswell <matt@openssl.org>
4 years agoMove declaration of i into blocks where it is used.
Ben Laurie [Thu, 17 Mar 2016 18:17:27 +0000 (18:17 +0000)]
Move declaration of i into blocks where it is used.

Reviewed-by: Matt Caswell <matt@openssl.org>
4 years agosctp requires dgram.
Ben Laurie [Thu, 17 Mar 2016 18:17:03 +0000 (18:17 +0000)]
sctp requires dgram.

Reviewed-by: Matt Caswell <matt@openssl.org>
4 years agoRT4660: BIO_METHODs should be const.
David Benjamin [Sat, 19 Mar 2016 16:32:14 +0000 (12:32 -0400)]
RT4660: BIO_METHODs should be const.

BIO_new, etc., don't need a non-const BIO_METHOD. This allows all the
built-in method tables to live in .rodata.

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoDowncase VMS config names
Richard Levitte [Mon, 21 Mar 2016 19:20:15 +0000 (20:20 +0100)]
Downcase VMS config names

On VMS, we downcase option names, which means that config names are
downcased as well, so they need to be downcased in the target table to
be found.

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoJust like bio_out, bio_err needs the linebuffer filter on VMS
Richard Levitte [Mon, 21 Mar 2016 17:30:30 +0000 (18:30 +0100)]
Just like bio_out, bio_err needs the linebuffer filter on VMS

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoAdds s2i function for ct_precert_poison X509 extension
Rob Percival [Mon, 21 Mar 2016 15:29:52 +0000 (15:29 +0000)]
Adds s2i function for ct_precert_poison X509 extension

Allows CONF files for certificate requests to specify that a pre-
certificate should be created (see RFC6962).

Reviewed-by: Dr. Stephen Henson <steve@openssl.org>
4 years agoFix memory leak where fdlookup linked list is not freed during
Steven Linsell [Sun, 20 Mar 2016 23:00:13 +0000 (23:00 +0000)]
Fix memory leak where fdlookup linked list is not freed during
ASYNC_WAIT_CTX_free

Reviewed-by: Rich Salz <rsalz@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
4 years agoFix no-ts with --strict-warnings
Matt Caswell [Mon, 21 Mar 2016 16:24:30 +0000 (16:24 +0000)]
Fix no-ts with --strict-warnings

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoFix no-sock
Matt Caswell [Mon, 21 Mar 2016 15:32:40 +0000 (15:32 +0000)]
Fix no-sock

Misc fixes for no-sock

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoFix no-gost
Matt Caswell [Mon, 21 Mar 2016 15:04:08 +0000 (15:04 +0000)]
Fix no-gost

Configure had the wrong name for the no-gost option.

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoDon't use hardcoded values for types
Dr. Stephen Henson [Mon, 21 Mar 2016 14:49:11 +0000 (14:49 +0000)]
Don't use hardcoded values for types

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoIn for loop values, introduce a dummy to protect against empty list
Richard Levitte [Mon, 21 Mar 2016 07:11:14 +0000 (08:11 +0100)]
In for loop values, introduce a dummy to protect against empty list

In constructions such as 'for x in $(MAKEVAR); do ...', there's the
possibility that $(MAKEVAR) is en empty value.  Some shells don't like
that, so introduce a dummy value that gets discarded:

    for x in dummy $(MAKEVAR); do
        if [ "$$x" = "dummy" ]; then continue; fi

Closes RT#4459

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoFix no-seed
Matt Caswell [Mon, 21 Mar 2016 12:00:41 +0000 (12:00 +0000)]
Fix no-seed

Fix compilation with --strict-warnings and no-seed

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoRemove the no-rijndael option
Matt Caswell [Mon, 21 Mar 2016 11:51:16 +0000 (11:51 +0000)]
Remove the no-rijndael option

Rijndael is an old name for AES.

Reviewed-by: Rich Salz <rsalz@openssl.org>
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
4 years agoFix no-scrypt
Matt Caswell [Mon, 21 Mar 2016 11:23:08 +0000 (11:23 +0000)]
Fix no-scrypt

Fix the evp tests when no-scrypt is used.

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoSkip the CMS tests if CMS is disabled
Matt Caswell [Mon, 21 Mar 2016 11:07:14 +0000 (11:07 +0000)]
Skip the CMS tests if CMS is disabled

This fixes the no-cms compile time option.

Reviewed-by: Emilia Käsper <emilia@openssl.org>
4 years agoFix no-dsa
Matt Caswell [Fri, 18 Mar 2016 17:43:58 +0000 (17:43 +0000)]
Fix no-dsa

Misc fixes for no-dsa.

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoBuild system: VC-WIN64I fixups.
Andy Polyakov [Fri, 18 Mar 2016 14:45:52 +0000 (15:45 +0100)]
Build system: VC-WIN64I fixups.

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoConfigurations/windows-makefile.tmpl: respect no-makedepend.
Andy Polyakov [Fri, 18 Mar 2016 23:05:25 +0000 (00:05 +0100)]
Configurations/windows-makefile.tmpl: respect no-makedepend.

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoWindows build system: get uplink right.
Andy Polyakov [Fri, 18 Mar 2016 22:31:17 +0000 (23:31 +0100)]
Windows build system: get uplink right.

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoconfig: fix off-by-centimeter-to-the-right typo.
Andy Polyakov [Wed, 16 Mar 2016 13:29:16 +0000 (14:29 +0100)]
config: fix off-by-centimeter-to-the-right typo.

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
4 years agoConfigurations/10-main.conf: freeze -std option in darwin*-ppc-cc.
Andy Polyakov [Mon, 14 Mar 2016 19:56:44 +0000 (20:56 +0100)]
Configurations/10-main.conf: freeze -std option in darwin*-ppc-cc.

RT#4422

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoRemove mk1mf documentation
Richard Levitte [Thu, 17 Mar 2016 22:15:12 +0000 (23:15 +0100)]
Remove mk1mf documentation

Reviewed-by: Andy Polyakov <appro@openssl.org>
4 years agoRemove the remainder of util/mk1mf.pl and companion scripts
Richard Levitte [Thu, 17 Mar 2016 22:01:21 +0000 (23:01 +0100)]
Remove the remainder of util/mk1mf.pl and companion scripts

This removes all scripts that deal with MINFO as well, since that's
only used by mk1mf.

Reviewed-by: Andy Polyakov <appro@openssl.org>
4 years agoRemove generation of ms/version32.rc from Configure, use util/mkrc.pl
Richard Levitte [Thu, 17 Mar 2016 21:29:20 +0000 (22:29 +0100)]
Remove generation of ms/version32.rc from Configure, use util/mkrc.pl

utils/mkrc.pl was added a while ago as a better generator for the
Windows DLL resource file.  Finalize the change by removing the
ms/version32.rc generator from Configure and adding resource file
support using mkrc.pl in Configurations/windows-makefile.pl

Reviewed-by: Andy Polyakov <appro@openssl.org>
4 years agoRemove the mk1mf VC-WIN* builds and its supporting scripts
Richard Levitte [Thu, 17 Mar 2016 20:31:44 +0000 (21:31 +0100)]
Remove the mk1mf VC-WIN* builds and its supporting scripts

The mk1mf build for the VC-WIN* targets is broken and the unified
scheme works well enough, so we clean out the old.

Reviewed-by: Andy Polyakov <appro@openssl.org>
4 years agoFix ALPN - more fixes
Todd Short [Sat, 12 Mar 2016 14:14:05 +0000 (09:14 -0500)]
Fix ALPN - more fixes

* Clear proposed, along with selected, before looking at ClientHello
* Add test case for above
* Clear NPN seen after selecting ALPN on server
* Minor documentation updates

Reviewed-by: Emilia Käsper <emilia@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoAdd a comment on dane_verify() logic
Viktor Dukhovni [Mon, 21 Mar 2016 00:40:13 +0000 (20:40 -0400)]
Add a comment on dane_verify() logic

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoRemove #error from include files.
Rich Salz [Fri, 18 Mar 2016 18:30:20 +0000 (14:30 -0400)]
Remove #error from include files.

Don't have #error statements in header files, but instead wrap
the contents of that file in #ifndef OPENSSL_NO_xxx
This means it is now always safe to include the header file.

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoGH886: CONNECT should use HTTP/1.1
Rich Salz [Sat, 19 Mar 2016 16:40:02 +0000 (12:40 -0400)]
GH886: CONNECT should use HTTP/1.1

By default you get 0.9 which isn't widely available.
But we use HTTP/1.0 for now.
Courtesy beusink@users.github.com

Reviewed-by: Tim Hudson <tjh@openssl.org>
4 years agoHave makedepend output to stdout and redirect it
Richard Levitte [Sun, 20 Mar 2016 01:13:40 +0000 (02:13 +0100)]
Have makedepend output to stdout and redirect it

This gives us better control of what files are produced.

Reviewed-by: Andy Polyakov <appro@openssl.org>
4 years agoct_int.h only needed by crypto/ct
Rich Salz [Sun, 20 Mar 2016 14:14:13 +0000 (10:14 -0400)]
ct_int.h only needed by crypto/ct

Merge ct_int.h into ct_locl.h

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
4 years agoconstify DSA_SIG_get0()
Dr. Stephen Henson [Sun, 20 Mar 2016 18:58:19 +0000 (18:58 +0000)]
constify DSA_SIG_get0()

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoMove blake2_loclh to blake2 directory
Rich Salz [Sun, 20 Mar 2016 14:10:18 +0000 (10:10 -0400)]
Move blake2_loclh to blake2 directory

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
4 years agoFixed language
Alex Gaynor [Sat, 19 Mar 2016 16:43:48 +0000 (12:43 -0400)]
Fixed language
Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoFixed a bunch of typos in the docs
Alex Gaynor [Sat, 19 Mar 2016 16:28:58 +0000 (12:28 -0400)]
Fixed a bunch of typos in the docs

Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoconstify ECDSA_SIG_get0()
Dr. Stephen Henson [Thu, 17 Mar 2016 14:18:23 +0000 (14:18 +0000)]
constify ECDSA_SIG_get0()

PR#4436

Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
4 years agoIf the asm file to be compiled isn't generated, leave the ext alone
Richard Levitte [Sat, 19 Mar 2016 17:59:48 +0000 (18:59 +0100)]
If the asm file to be compiled isn't generated, leave the ext alone

Closes RT#4447

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
4 years agomake update
Richard Levitte [Sat, 19 Mar 2016 19:12:26 +0000 (20:12 +0100)]
make update

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
4 years agoDon't let 'generate' target depend on generated files, act directly instead
Richard Levitte [Sat, 19 Mar 2016 19:04:51 +0000 (20:04 +0100)]
Don't let 'generate' target depend on generated files, act directly instead

One of the 'generate' targets depended on $(SRCDIR)/apps/progs.h,
which depended on...  nothing.  This meant it never got regenerated
once it existed, regardless of need.  Of course, we could have it
depend on all the files checked to generate it, but they also depend
on progs.h, so we'd end up getting cricular dependencies, which makes
make unhappy.

Furthermore, and this applies for the other generated files, having
them as targets means that they may be regenerated on the fly in some
cases, and since they get written to the source tree, this isn't such
a good idea if that tree is read-only (which is a possible situation
in an out-of-tree build).

So, we move all the actions to the 'generate' targets themselves, thus
making sure they get regenerated in a controlled manner and regardless
of dependencies.

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
4 years agoapps/progs.pl: add back the INCLUDE_FUNCTION_TABLE wrapper
Richard Levitte [Sat, 19 Mar 2016 19:03:56 +0000 (20:03 +0100)]
apps/progs.pl: add back the INCLUDE_FUNCTION_TABLE wrapper

Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
4 years agoRevert "Ignore the generated apps/progs.h"
Viktor Dukhovni [Sat, 19 Mar 2016 02:10:40 +0000 (22:10 -0400)]
Revert "Ignore the generated apps/progs.h"

This reverts commit 91056e72693b4ee8cb5339d9091871ffc3b6f776.

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoRevert "Generate apps/progs.h on the fly"
Viktor Dukhovni [Sat, 19 Mar 2016 02:10:39 +0000 (22:10 -0400)]
Revert "Generate apps/progs.h on the fly"

This reverts commit 04e2a527379ad12ca512aef4e838f94af22d7f79.

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoRevert "Include progs.h directly in openssl.c instead of via apps.h"
Viktor Dukhovni [Sat, 19 Mar 2016 02:10:33 +0000 (22:10 -0400)]
Revert "Include progs.h directly in openssl.c instead of via apps.h"

This reverts commit a45d7d5388c6774a484cff4af13f188240d3d50b.

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoGH36: Add casts to match the documentation
Alex Gaynor [Sat, 19 Mar 2016 16:17:31 +0000 (12:17 -0400)]
GH36: Add casts to match the documentation

Reviewed-by: Richard Levitte <levitte@openssl.org>
4 years agoCorrect faulty L<> links in .pods
Richard Levitte [Sat, 19 Mar 2016 10:39:47 +0000 (11:39 +0100)]
Correct faulty L<> links in .pods

Closes RT#4450

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoAdd a few more quotes for Windows (install_ssldirs)
Richard Levitte [Sat, 19 Mar 2016 10:25:10 +0000 (11:25 +0100)]
Add a few more quotes for Windows (install_ssldirs)

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoThe command source are files, not directories
Richard Levitte [Sat, 19 Mar 2016 10:24:00 +0000 (11:24 +0100)]
The command source are files, not directories

Therefore, they should be concatenated with the source directory using
catfile(), not catdir()

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoReplace sed command with perl
Richard Levitte [Sat, 19 Mar 2016 10:18:56 +0000 (11:18 +0100)]
Replace sed command with perl

Some implementations of sed require a newline before an ending '}'.
The easier method is to replace that sed command with the
corresponding perl command.

Closes RT#4448

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoClear the exit code from 'find' in 'make depend'
Richard Levitte [Sat, 19 Mar 2016 10:15:00 +0000 (11:15 +0100)]
Clear the exit code from 'find' in 'make depend'

Depending on what has been built so far, all .d files may not be
present and 'find' will exit with non-zero exit code.  This isn't a
bother for us but may break make, so clear the exit code with an added
'exit 0'.

Closes RT#4444

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoShut find up about files not found
Richard Levitte [Sat, 19 Mar 2016 01:11:31 +0000 (02:11 +0100)]
Shut find up about files not found

Some of the files in $(DEPS) might not exist.  We don't need to know.

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoDon't free up EVP_MD_CTX.
Schüller Felix [Fri, 18 Mar 2016 19:20:34 +0000 (19:20 +0000)]
Don't free up EVP_MD_CTX.

Don't free up passed EVP_MD_CTX in ASN1_item_sign_ctx(). This
simplifies handling and retains compatiblity with previous behaviour.

PR#4446

Reviewed-by: Rich Salz <rsalz@openssl.org>
Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Stephen Henson <steve@openssl.org>
4 years agoUse the dependencies received in generatesrc()
Richard Levitte [Fri, 18 Mar 2016 23:57:35 +0000 (00:57 +0100)]
Use the dependencies received in generatesrc()

generatesrc() did already receive dependency information, but never
used it, and never really needed to...  until now.

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoIgnore the generated apps/progs.h
Richard Levitte [Fri, 18 Mar 2016 23:51:51 +0000 (00:51 +0100)]
Ignore the generated apps/progs.h

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoGenerate apps/progs.h on the fly
Richard Levitte [Fri, 18 Mar 2016 23:50:49 +0000 (00:50 +0100)]
Generate apps/progs.h on the fly

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoInclude progs.h directly in openssl.c instead of via apps.h
Richard Levitte [Fri, 18 Mar 2016 23:43:43 +0000 (00:43 +0100)]
Include progs.h directly in openssl.c instead of via apps.h

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoMake apps/progs.pl more flexible
Richard Levitte [Fri, 18 Mar 2016 23:41:14 +0000 (00:41 +0100)]
Make apps/progs.pl more flexible

Make Configure write @disablables to configdata.pm and have
apps/progs.pl use that data.

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoCorrect the export list when writing configdata.pm
Richard Levitte [Sat, 19 Mar 2016 00:31:48 +0000 (01:31 +0100)]
Correct the export list when writing configdata.pm

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoCorrect the check of files to depend on against known generated ones
Richard Levitte [Sat, 19 Mar 2016 00:29:01 +0000 (01:29 +0100)]
Correct the check of files to depend on against known generated ones

The check was erroneously inversed

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoDon't perform tsa tests if configured "no-ts"
Richard Levitte [Sat, 19 Mar 2016 00:01:52 +0000 (01:01 +0100)]
Don't perform tsa tests if configured "no-ts"

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoCorrect incorrect path
Richard Levitte [Sat, 19 Mar 2016 00:01:07 +0000 (01:01 +0100)]
Correct incorrect path

In crypto, buildinf.h depends on ../configdata.pm, not ./configdata.pm

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoBetter 'make depend' mechanism
Richard Levitte [Fri, 18 Mar 2016 19:52:29 +0000 (20:52 +0100)]
Better 'make depend' mechanism

Instead of relying on the '-nt' test operator, which doesn't exist
everywhere, use find's '-newer' to find out if any of the known .d
files is newer than Makefile.

Closes RT#4444

Reviewed-by: Andy Polyakov <appro@openssl.org>
4 years agomake update
Richard Levitte [Fri, 18 Mar 2016 19:06:45 +0000 (20:06 +0100)]
make update

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoImplement support for no-ts
Richard Levitte [Fri, 18 Mar 2016 19:06:29 +0000 (20:06 +0100)]
Implement support for no-ts

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoapps/progs.pl: more consistent output for digests
Richard Levitte [Fri, 18 Mar 2016 19:01:58 +0000 (20:01 +0100)]
apps/progs.pl: more consistent output for digests

Reviewed-by: Rich Salz <rsalz@openssl.org>
4 years agoFix no-des
Matt Caswell [Fri, 18 Mar 2016 15:56:06 +0000 (15:56 +0000)]
Fix no-des

Numerous fixes for no-des.

Reviewed-by: Rich Salz <rsalz@openssl.org>