oweals/openssl.git
20 years agoRemove the creation of $(INSTALL_PREFIX)$(OPENSSLDIR)/lib, since we don't
Richard Levitte [Thu, 6 May 2004 09:46:41 +0000 (09:46 +0000)]
Remove the creation of $(INSTALL_PREFIX)$(OPENSSLDIR)/lib, since we don't
use it.

Notified by Frédéric L. W. Meunier <0@pervalidus.tk> in PR 713

20 years agoWhen the pointer 'from' changes, it's stored length needs to change as
Richard Levitte [Thu, 6 May 2004 09:33:22 +0000 (09:33 +0000)]
When the pointer 'from' changes, it's stored length needs to change as
well.

Notified by Frank Kardel <kardel@acm.org> in PR 879.

20 years agoFix realloc usage in ec_curve.c
Geoff Thorpe [Tue, 4 May 2004 20:08:55 +0000 (20:08 +0000)]
Fix realloc usage in ec_curve.c

Submitted by: Nils Larsch
Reviewed by: Geoff Thorpe

20 years ago- update from current 0.9.6-stable CHANGES file
Bodo Möller [Tue, 4 May 2004 01:15:48 +0000 (01:15 +0000)]
- update from current 0.9.6-stable CHANGES file
- update from current 0.9.7-stable CHANGES file:

  Now here we have "CHANGES between 0.9.7e and 0.9.8", and I hope
  that all patches mentioned for 0.9.7d and 0.9.7e actually are
  in the CVS HEAD, i.e. what is to become 0.9.8.

  I have rewritten the 'openssl ca -create_serial' entry (0.9.8)
  so that it explains the earlier change that is now listed (0.9.7e).

  The ENGINE_set_default typo bug entry has been moved from 0.9.8
  to 0.9.7b, which is where it belongs.

20 years agoThe new BN_CTX code makes this sort of abuse unnecessary.
Geoff Thorpe [Wed, 28 Apr 2004 18:34:39 +0000 (18:34 +0000)]
The new BN_CTX code makes this sort of abuse unnecessary.

20 years agoOops! Typo in ./config...
Andy Polyakov [Tue, 27 Apr 2004 22:17:25 +0000 (22:17 +0000)]
Oops! Typo in ./config...

20 years agoImproved PowerPC support. Proper ./config support for ppc targets,
Andy Polyakov [Tue, 27 Apr 2004 22:05:50 +0000 (22:05 +0000)]
Improved PowerPC support. Proper ./config support for ppc targets,
especially for AIX. But most important BIGNUM assembler implementation
submitted by IBM.

Submitted by: Peter Waltenberg <pwalten@au1.ibm.com>
Reviewed by: appro

20 years agoMake ASN1 code work again...
Dr. Stephen Henson [Tue, 27 Apr 2004 18:33:40 +0000 (18:33 +0000)]
Make ASN1 code work again...

20 years agoWith the new dynamic BN_CTX implementation, there should be no need for
Geoff Thorpe [Tue, 27 Apr 2004 13:24:51 +0000 (13:24 +0000)]
With the new dynamic BN_CTX implementation, there should be no need for
additional contexts.

20 years agoThe problem of rsa key-generation getting stuck in a loop for (pointlessly)
Geoff Thorpe [Mon, 26 Apr 2004 15:38:44 +0000 (15:38 +0000)]
The problem of rsa key-generation getting stuck in a loop for (pointlessly)
small key sizes seems to result from the code continually regenerating the
same prime value once the range is small enough. From my tests, this change
fixes the problem by setting an escape velocity of 3 repeats for the second
of the two primes.

PR: 874

20 years agoAllow RSA key-generation to specify an arbitrary public exponent. Jelte
Geoff Thorpe [Mon, 26 Apr 2004 15:31:35 +0000 (15:31 +0000)]
Allow RSA key-generation to specify an arbitrary public exponent. Jelte
proposed the change and submitted the patch, I jiggled it slightly and
adjusted the other parts of openssl that were affected.

PR: 867
Submitted by: Jelte Jansen
Reviewed by: Geoff Thorpe

20 years agoMore ASN1 reformat/tidy.
Dr. Stephen Henson [Sun, 25 Apr 2004 12:46:39 +0000 (12:46 +0000)]
More ASN1 reformat/tidy.

20 years agoReformat/tidy some of the ASN1 code.
Dr. Stephen Henson [Sat, 24 Apr 2004 17:02:48 +0000 (17:02 +0000)]
Reformat/tidy some of the ASN1 code.

20 years agoFix leak.
Dr. Stephen Henson [Thu, 22 Apr 2004 12:37:16 +0000 (12:37 +0000)]
Fix leak.

PR:870

20 years agoAs far as I can tell, the bugfix this comment refers to was committed to
Geoff Thorpe [Wed, 21 Apr 2004 15:12:20 +0000 (15:12 +0000)]
As far as I can tell, the bugfix this comment refers to was committed to
0.9.7-stable as well as HEAD (and doesn't apply to the 0.9.6-engine
variant).

20 years agoExtend the index parameter checking from sk_value to sk_set(). Also tidy up
Geoff Thorpe [Wed, 21 Apr 2004 15:08:56 +0000 (15:08 +0000)]
Extend the index parameter checking from sk_value to sk_set(). Also tidy up
some similar code elsewhere.

Thanks to Francesco Petruzzi for bringing this to my attention.

20 years agoNew option to 'x509' -next_serial. This outputs the certificate
Dr. Stephen Henson [Wed, 21 Apr 2004 12:46:20 +0000 (12:46 +0000)]
New option to 'x509' -next_serial. This outputs the certificate
serial number plus 1 to the output file. Its purpose is to allow
serial number files to be initialized when random serial numbers
are used.

20 years agoUse X509_get_serialNumber() instead of accessing internals in x509.c
Dr. Stephen Henson [Wed, 21 Apr 2004 12:43:21 +0000 (12:43 +0000)]
Use X509_get_serialNumber() instead of accessing internals in x509.c

20 years agoReduce chances of issuer and serial number duplication by use of random
Dr. Stephen Henson [Tue, 20 Apr 2004 12:05:26 +0000 (12:05 +0000)]
Reduce chances of issuer and serial number duplication by use of random
initial serial numbers.

PR: 842

20 years agoWhooaaaaa, the BN_CTX_DEBUG macro really produces output these
Richard Levitte [Tue, 20 Apr 2004 11:53:33 +0000 (11:53 +0000)]
Whooaaaaa, the BN_CTX_DEBUG macro really produces output these
days...  A little too much for my tests, currently...

20 years agoPrint the debug thingies on stderr instead of stdout. If for nothing
Richard Levitte [Tue, 20 Apr 2004 10:57:07 +0000 (10:57 +0000)]
Print the debug thingies on stderr instead of stdout.  If for nothing
else then at least so bc doesn't have problems parsing the output from
bntest :-).

20 years agomake update
Geoff Thorpe [Mon, 19 Apr 2004 18:33:41 +0000 (18:33 +0000)]
make update

20 years ago"make update" noticed a new function.
Geoff Thorpe [Mon, 19 Apr 2004 18:32:19 +0000 (18:32 +0000)]
"make update" noticed a new function.

20 years agoMore updates for the header cleanups (and apologies, again, for not having
Geoff Thorpe [Mon, 19 Apr 2004 18:30:41 +0000 (18:30 +0000)]
More updates for the header cleanups (and apologies, again, for not having
consolidated these prior to committing).

20 years agoWhen generating dependencies in the makefiles, generate the reduced
Geoff Thorpe [Mon, 19 Apr 2004 18:19:24 +0000 (18:19 +0000)]
When generating dependencies in the makefiles, generate the reduced
dependencies of the OPENSSL_NO_DEPRECATED mode. This prevents dependencies
being reproduced for "deprecated" header behaviour when a developer doesn't
define the symbol (with the subsequent CVS wars that can ensue).

20 years agoheader cleanup in apps/
Geoff Thorpe [Mon, 19 Apr 2004 18:13:07 +0000 (18:13 +0000)]
header cleanup in apps/

20 years ago(oops) Apologies all, that last header-cleanup commit was from the wrong
Geoff Thorpe [Mon, 19 Apr 2004 18:09:28 +0000 (18:09 +0000)]
(oops) Apologies all, that last header-cleanup commit was from the wrong
tree. This further reduces header interdependencies, and makes some
associated cleanups.

20 years agoReduce header interdependencies, initially in engine.h (the rest of the
Geoff Thorpe [Mon, 19 Apr 2004 17:46:04 +0000 (17:46 +0000)]
Reduce header interdependencies, initially in engine.h (the rest of the
changes are the fallout). As this could break source code that doesn't
directly include headers for interfaces it uses, changes to recursive
includes are covered by the OPENSSL_NO_DEPRECATED symbol. It's better to
define this when building and using openssl, and then adapt code where
necessary - this is how to stay current. However the mechanism exists for
the lethargic.

20 years agoClear error if unique_subject lookup fails.
Dr. Stephen Henson [Thu, 15 Apr 2004 00:32:19 +0000 (00:32 +0000)]
Clear error if unique_subject lookup fails.

20 years agoAdd some root CAs.
Dr. Stephen Henson [Tue, 13 Apr 2004 17:47:37 +0000 (17:47 +0000)]
Add some root CAs.

20 years agoAvoid undefined results when the parameter is out of range.
Geoff Thorpe [Fri, 2 Apr 2004 06:25:11 +0000 (06:25 +0000)]
Avoid undefined results when the parameter is out of range.

20 years agoDon't use C++ reserved word.
Dr. Stephen Henson [Thu, 1 Apr 2004 22:23:46 +0000 (22:23 +0000)]
Don't use C++ reserved word.

20 years agoOops forgot CHANGES entry.
Dr. Stephen Henson [Wed, 31 Mar 2004 12:55:33 +0000 (12:55 +0000)]
Oops forgot CHANGES entry.

20 years agoNew function X509_POLICY_NODE_print()
Dr. Stephen Henson [Wed, 31 Mar 2004 12:17:24 +0000 (12:17 +0000)]
New function X509_POLICY_NODE_print()

20 years agoAdd symbol hacks for some long names.
Richard Levitte [Mon, 29 Mar 2004 08:13:49 +0000 (08:13 +0000)]
Add symbol hacks for some long names.
make update

20 years agoThis is essentially Intel 32-bit compiler tune-up. To start with all
Andy Polyakov [Sun, 28 Mar 2004 21:27:47 +0000 (21:27 +0000)]
This is essentially Intel 32-bit compiler tune-up. To start with all
available compiler versions generated bogus machine code trying to
compile new crypto/des/cfb_enc.c. Secondly, 8th version defines
__GNUC__ macro, but fails to compile *some* inline assembler correctly.
Note that all versions of icc implement MSC-like _lrot[rl] intrinsic,
which is used now instead of offensive asm. Finally, unnecessary linker
dependencies are eliminated. Most notably dependency from libirc.a
caused trouble at application start-up, if libcrypto.so is linked with
-Bsymbolic (which it is).

20 years agoEnhance EVP code to generate random symmetric keys of the
Dr. Stephen Henson [Sun, 28 Mar 2004 17:38:00 +0000 (17:38 +0000)]
Enhance EVP code to generate random symmetric keys of the
appropriate form, for example correct DES parity.

Update S/MIME code and EVP_SealInit to use new functions.

PR: 700

20 years agoMake {i2v,v2i}_ASN1_BIT_STRING global.
Dr. Stephen Henson [Sun, 28 Mar 2004 12:40:11 +0000 (12:40 +0000)]
Make {i2v,v2i}_ASN1_BIT_STRING global.

make update

20 years agoRemove obsolete files.
Dr. Stephen Henson [Sun, 28 Mar 2004 12:29:05 +0000 (12:29 +0000)]
Remove obsolete files.

20 years agoAllow CRLs to be passed into X509_STORE_CTX. This is useful when the
Dr. Stephen Henson [Sat, 27 Mar 2004 22:49:28 +0000 (22:49 +0000)]
Allow CRLs to be passed into X509_STORE_CTX. This is useful when the
verified structure can contain its own CRLs (such as PKCS#7 signedData).

Tidy up some of the verify code.

20 years agoExtend OID config module format.
Dr. Stephen Henson [Sat, 27 Mar 2004 13:30:14 +0000 (13:30 +0000)]
Extend OID config module format.

20 years agoFree up BIO properly when using streaming S/MIME sign.
Dr. Stephen Henson [Fri, 26 Mar 2004 00:24:38 +0000 (00:24 +0000)]
Free up BIO properly when using streaming S/MIME sign.

20 years agoRemove BN_CTX debug from debug-steve
Dr. Stephen Henson [Thu, 25 Mar 2004 23:32:06 +0000 (23:32 +0000)]
Remove BN_CTX debug from debug-steve

20 years agoSSL_COMP_get_compression_method is a typo (a missing 's' at the end of
Richard Levitte [Thu, 25 Mar 2004 21:32:30 +0000 (21:32 +0000)]
SSL_COMP_get_compression_method is a typo (a missing 's' at the end of
the symbol name).

20 years agoMove the definition of Win32_rename(), since the macro rename gets undefined
Richard Levitte [Thu, 25 Mar 2004 20:09:00 +0000 (20:09 +0000)]
Move the definition of Win32_rename(), since the macro rename gets undefined
in the middle of the code on Windows, and that disrupts operations in functions
later that use rename()...
PR: 853

20 years agoWrap code starting with a definition.
Richard Levitte [Thu, 25 Mar 2004 20:01:01 +0000 (20:01 +0000)]
Wrap code starting with a definition.
PR: 854

20 years agoChange spaces to symbols in names.
Richard Levitte [Thu, 25 Mar 2004 19:52:34 +0000 (19:52 +0000)]
Change spaces to symbols in names.
PR: 856

20 years agoMake prototypes for some callback pointers.
Richard Levitte [Thu, 25 Mar 2004 16:21:42 +0000 (16:21 +0000)]
Make prototypes for some callback pointers.

20 years agoA couple more cases where RAND_add() gets an integer instead of a
Richard Levitte [Thu, 25 Mar 2004 16:04:02 +0000 (16:04 +0000)]
A couple more cases where RAND_add() gets an integer instead of a
doule as last argument.

20 years agoRAND_add() wants a double as it's last argument.
Richard Levitte [Thu, 25 Mar 2004 15:52:43 +0000 (15:52 +0000)]
RAND_add() wants a double as it's last argument.

20 years agoFix loads of warnings in policy code.
Dr. Stephen Henson [Thu, 25 Mar 2004 13:45:58 +0000 (13:45 +0000)]
Fix loads of warnings in policy code.

I'll remember to try to compile this with warnings enabled next time :-)

20 years agoFix ASN1 warnings.
Dr. Stephen Henson [Thu, 25 Mar 2004 13:37:02 +0000 (13:37 +0000)]
Fix ASN1 warnings.

20 years agoAdjust various bignum functions to use BN_CTX for variables instead of
Geoff Thorpe [Thu, 25 Mar 2004 04:32:24 +0000 (04:32 +0000)]
Adjust various bignum functions to use BN_CTX for variables instead of
locally initialising their own.

NB: I've removed the "BN_clear_free()" loops for the exit-paths in some of
these functions, and that may be a major part of the performance
improvements we're seeing. The "free" part can be removed because we're
using BN_CTX. The "clear" part OTOH can be removed because BN_CTX
destruction automatically performs this task, so performing it inside
functions that may be called repeatedly is wasteful. This is currently safe
within openssl due to the fact that BN_CTX objects are never created for
longer than a single high-level operation. However, that is only because
there's currently no mechanism in openssl for thread-local storage. Beyond
that, this might be an issue for applications using the bignum API directly
and caching their own BN_CTX objects. The solution is to introduce a flag
to BN_CTX_start() that allows its variables to be automatically sanitised
on release during BN_CTX_end(). This way any higher-level function (and
perhaps the application) can specify this flag in its own
BN_CTX_start()/BN_CTX_end() pair, and this will cause inner-loop functions
specifying the flag to be ignored so that sanitisation is handled only once
back out at the higher level. I will be implementing this in the near
future.

20 years agoReplace the BN_CTX implementation with my current work. I'm leaving the
Geoff Thorpe [Thu, 25 Mar 2004 04:16:14 +0000 (04:16 +0000)]
Replace the BN_CTX implementation with my current work. I'm leaving the
little TODO list in there as well as the debugging code (only enabled if
BN_CTX_DEBUG is defined).

I'd appreciate as much review and testing as can be spared for this. I'll
commit some changes to other parts of the bignum code shortly to make
better use of this implementation (no more fixed size limitations). Note
also that under identical optimisations, I'm seeing a noticable speed
increase over openssl-0.9.7 - so any feedback to confirm/deny this on other
systems would also be most welcome.

20 years agoAdds warnings about two curves and fixes the "seed" value for two other
Geoff Thorpe [Thu, 25 Mar 2004 03:03:52 +0000 (03:03 +0000)]
Adds warnings about two curves and fixes the "seed" value for two other
curves.

Submitted by: Nils Larsch

20 years ago... and this should likewise fix up those RSA implementations that weren't
Geoff Thorpe [Thu, 25 Mar 2004 02:55:17 +0000 (02:55 +0000)]
... and this should likewise fix up those RSA implementations that weren't
already built and tested.

20 years agoBy adding a BN_CTX parameter to the 'rsa_mod_exp' callback, private key
Geoff Thorpe [Thu, 25 Mar 2004 02:52:04 +0000 (02:52 +0000)]
By adding a BN_CTX parameter to the 'rsa_mod_exp' callback, private key
operations no longer require two distinct BN_CTX structures. This may put
more "strain" on the current BN_CTX implementation (which has a fixed limit
to the number of variables it will hold), but so far this limit is not
triggered by any of the tests pass and I will be changing BN_CTX in the
near future to avoid this problem anyway.

This also changes the default RSA implementation code to use the BN_CTX in
favour of initialising some of its variables locally in each function.

20 years agoDamn, I was a bit hasty with my fix and hadn't spotted the linker
Geoff Thorpe [Thu, 25 Mar 2004 02:41:35 +0000 (02:41 +0000)]
Damn, I was a bit hasty with my fix and hadn't spotted the linker
dependency from asn1.

20 years agoRemove some warnings.
Geoff Thorpe [Thu, 25 Mar 2004 02:24:38 +0000 (02:24 +0000)]
Remove some warnings.

20 years agoProtect against gcc's "warning: cast does not match function type".
Geoff Thorpe [Thu, 25 Mar 2004 02:19:42 +0000 (02:19 +0000)]
Protect against gcc's "warning: cast does not match function type".

20 years agoDon't define fd for platforms that do not use it, as some may not declare fileno...
Richard Levitte [Wed, 24 Mar 2004 10:55:48 +0000 (10:55 +0000)]
Don't define fd for platforms that do not use it, as some may not declare fileno() properly

20 years agoCorrect constness problems.
Richard Levitte [Wed, 24 Mar 2004 10:50:42 +0000 (10:50 +0000)]
Correct constness problems.

20 years agoMake it easier to buld test applications...
Richard Levitte [Wed, 24 Mar 2004 10:50:25 +0000 (10:50 +0000)]
Make it easier to buld test applications...

20 years agoOnly build the PKCS#7 test applications if "pkcs7" is present in
Richard Levitte [Wed, 24 Mar 2004 10:48:50 +0000 (10:48 +0000)]
Only build the PKCS#7 test applications if "pkcs7" is present in
SDIRS.

20 years agoAdd store.h among the exported headers on VMS.
Richard Levitte [Wed, 24 Mar 2004 09:52:16 +0000 (09:52 +0000)]
Add store.h among the exported headers on VMS.

20 years agoo_str.h isn't a public header file, so make sure it will still be
Richard Levitte [Wed, 24 Mar 2004 09:43:03 +0000 (09:43 +0000)]
o_str.h isn't a public header file, so make sure it will still be
included.

20 years agoo_str.h isn't a public header file.
Richard Levitte [Wed, 24 Mar 2004 09:41:33 +0000 (09:41 +0000)]
o_str.h isn't a public header file.

20 years agoTypo...
Richard Levitte [Wed, 24 Mar 2004 09:40:59 +0000 (09:40 +0000)]
Typo...

20 years agoMake sure toupper() is properly declared.
Richard Levitte [Wed, 24 Mar 2004 09:40:23 +0000 (09:40 +0000)]
Make sure toupper() is properly declared.

20 years agoMake it clear that for RSA_NO_PADDING, flen must be RSA_size(rsa)
Richard Levitte [Tue, 23 Mar 2004 21:01:34 +0000 (21:01 +0000)]
Make it clear that for RSA_NO_PADDING, flen must be RSA_size(rsa)

20 years agomake update
Richard Levitte [Tue, 23 Mar 2004 15:06:33 +0000 (15:06 +0000)]
make update

20 years agoSync the VMS build with Unix.
Richard Levitte [Tue, 23 Mar 2004 14:50:16 +0000 (14:50 +0000)]
Sync the VMS build with Unix.

20 years agoInitial support for certificate policy checking and evaluation.
Dr. Stephen Henson [Tue, 23 Mar 2004 14:14:35 +0000 (14:14 +0000)]
Initial support for certificate policy checking and evaluation.

This is currently *very* experimental and needs to be more fully integrated
with the main verification code.

20 years agoCorrect minor spelling error.
Richard Levitte [Sun, 21 Mar 2004 23:03:52 +0000 (23:03 +0000)]
Correct minor spelling error.
PR: 845

20 years agoChange \t to real tab in echo argument.
Richard Levitte [Sun, 21 Mar 2004 22:50:20 +0000 (22:50 +0000)]
Change \t to real tab in echo argument.
PR: 847

20 years agoRemove a warning for conversion double->long. This has impacts on Windows.
Richard Levitte [Sun, 21 Mar 2004 22:39:52 +0000 (22:39 +0000)]
Remove a warning for conversion double->long.  This has impacts on Windows.
PR: 849

20 years agoMake sure fd is defined where it should.
Richard Levitte [Sun, 21 Mar 2004 22:36:27 +0000 (22:36 +0000)]
Make sure fd is defined where it should.
PR: 849

20 years agoNote my bignum hijinx in case app maintainers are using CHANGES for their
Geoff Thorpe [Wed, 17 Mar 2004 18:30:47 +0000 (18:30 +0000)]
Note my bignum hijinx in case app maintainers are using CHANGES for their
porting efforts. Also, add Richard's name to the prior change.

20 years agoVariety of belt-tightenings in the bignum code. (Please help test this!)
Geoff Thorpe [Wed, 17 Mar 2004 17:36:54 +0000 (17:36 +0000)]
Variety of belt-tightenings in the bignum code. (Please help test this!)

- Remove some unnecessary "+1"-like fudges. Sizes should be handled
  exactly, as enlarging size parameters causes needless bloat and may just
  make bugs less likely rather than fixing them: bn_expand() macro,
  bn_expand_internal(), and BN_sqr().
- Deprecate bn_dup_expand() - it's new since 0.9.7, unused, and not that
  useful.
- Remove unnecessary zeroing of unused bytes in bn_expand2().
- Rewrite BN_set_word() - it should be much simpler, the previous
  complexities probably date from old mismatched type issues.
- Add missing bn_check_top() macros in bn_word.c
- Improve some degenerate case handling in BN_[add|sub]_word(), add
  comments, and avoid a bignum expansion if an overflow isn't possible.

20 years agoAvoid warnings.
Dr. Stephen Henson [Tue, 16 Mar 2004 13:51:11 +0000 (13:51 +0000)]
Avoid warnings.

20 years agoConstify d2i, s2i, c2i and r2i functions and other associated
Richard Levitte [Mon, 15 Mar 2004 23:15:26 +0000 (23:15 +0000)]
Constify d2i, s2i, c2i and r2i functions and other associated
functions and macros.

This change has associated tags: LEVITTE_before_const and
LEVITTE_after_const.  Those will be removed when this change has been
properly reviewed.

20 years agoIt was just pointed out to me that it's better to cast to double...
Richard Levitte [Mon, 15 Mar 2004 23:02:55 +0000 (23:02 +0000)]
It was just pointed out to me that it's better to cast to double...

20 years agoMake sure that the last argument to RAND_add() is a float, or some
Richard Levitte [Mon, 15 Mar 2004 22:37:08 +0000 (22:37 +0000)]
Make sure that the last argument to RAND_add() is a float, or some
compilers may complain.

20 years agoMake sure we use unsigned constants, or come compilers may complain.
Richard Levitte [Mon, 15 Mar 2004 22:33:19 +0000 (22:33 +0000)]
Make sure we use unsigned constants, or come compilers may complain.

20 years agoConvert openssl code not to assume the deprecated form of BN_zero().
Geoff Thorpe [Sat, 13 Mar 2004 23:57:20 +0000 (23:57 +0000)]
Convert openssl code not to assume the deprecated form of BN_zero().

Remove certain redundant BN_zero() initialisations, because BN_CTX_get(),
BN_init(), [etc] already initialise to zero.

Correct error checking in bn_sqr.c, and be less wishy-wash about how/why
the result's 'top' value is set (note also, 'max' is always > 0 at this
point).

20 years agoThe efforts to eliminate the dual-representation of zero and to ensure
Geoff Thorpe [Sat, 13 Mar 2004 23:04:15 +0000 (23:04 +0000)]
The efforts to eliminate the dual-representation of zero and to ensure
bignums are passed in and out of functions and APIs in a consistent form
has highlighted that zero-valued bignums don't need any allocated word
data. The use of BN_set_word() to initialise a bignum to zero causes
needless allocation and gives it a return value that must be checked. This
change converts BN_zero() to a self-contained macro that has no
return/expression value and does not cause any expansion of bignum data.

Note, it would be tempting to rewrite the deprecated version as a
success-valued comma expression, such as;
   #define BN_zero(a) ((a)->top = (a)->neg = 0, 1)
However, this evaluates 'a' twice and would confuse initialisation loops
(eg. while(..) { BN_zero(bn++) } ). As such, the deprecated version
continues to use BN_set_word().

20 years agoDocument a change I'd already made, and at the same time, correct the
Geoff Thorpe [Sat, 13 Mar 2004 22:10:15 +0000 (22:10 +0000)]
Document a change I'd already made, and at the same time, correct the
change to work properly; BN_zero() should set 'neg' to zero as well as
'top' to match the behaviour of BN_new().

20 years agoIRIX 6.x shared build fix-up.
Andy Polyakov [Fri, 12 Mar 2004 21:52:54 +0000 (21:52 +0000)]
IRIX 6.x shared build fix-up.

For reference. Note that both cc and gcc support -Wl flag, but we can't
use -Wl,-[not]all with both drivers, because cc rearranges options
passed through -Wl. We can't use -Wl,-all,libcrypto.a,-notall with cc
either, because it refuses to start with "no input" error.

20 years agostatic
Geoff Thorpe [Wed, 10 Mar 2004 01:20:26 +0000 (01:20 +0000)]
static

20 years agoMinimise the amount of code dependent on BN_DEBUG_RAND. In particular,
Geoff Thorpe [Tue, 9 Mar 2004 03:53:40 +0000 (03:53 +0000)]
Minimise the amount of code dependent on BN_DEBUG_RAND. In particular,
redefine bn_clear_top2max() to be a NOP in the non-debugging case, and
remove some unnecessary usages in bn_nist.c.

Submitted by: Nils Larsch
Reviewed by: Geoff Thorpe, Ulf Möller

20 years agoMore changes coming out of the bignum auditing. BN_CTX_get() should ideally
Geoff Thorpe [Tue, 9 Mar 2004 03:47:35 +0000 (03:47 +0000)]
More changes coming out of the bignum auditing. BN_CTX_get() should ideally
return a "zero" bignum as BN_new() does - so reset 'top'. During
BN_CTX_end(), released bignums should be consistent so enforce this in
debug builds. Also, reduce the number of wasted BN_clear_free() calls from
BN_CTX_end() (typically by 75% or so).

Submitted by: Nils Larsch
Reviewed by: Geoff Thorpe, Ulf Möller

20 years agoFix policy constraints syntax.
Dr. Stephen Henson [Mon, 8 Mar 2004 18:15:32 +0000 (18:15 +0000)]
Fix policy constraints syntax.

20 years agoSupport for inhibitAnyPolicy extension.
Dr. Stephen Henson [Mon, 8 Mar 2004 13:56:31 +0000 (13:56 +0000)]
Support for inhibitAnyPolicy extension.

20 years agotypo
Ulf Möller [Sat, 6 Mar 2004 08:43:36 +0000 (08:43 +0000)]
typo

20 years agoCleanup ASN1 OID module when it exits.
Dr. Stephen Henson [Fri, 5 Mar 2004 23:47:56 +0000 (23:47 +0000)]
Cleanup ASN1 OID module when it exits.

20 years agoCall autoconfig code in pkcs7 utility.
Dr. Stephen Henson [Fri, 5 Mar 2004 23:46:29 +0000 (23:46 +0000)]
Call autoconfig code in pkcs7 utility.

20 years agoMemory leak fix.
Dr. Stephen Henson [Fri, 5 Mar 2004 23:39:42 +0000 (23:39 +0000)]
Memory leak fix.

20 years agoVarious X509 fixes. Disable broken certificate workarounds
Dr. Stephen Henson [Fri, 5 Mar 2004 17:16:35 +0000 (17:16 +0000)]
Various X509 fixes. Disable broken certificate workarounds
when X509_V_FLAG_X509_STRICT is set. Check for CRLSign in
CRL issuer certificates. Reject CRLs with unhandled (any)
critical extensions.

20 years agoTypos.
Dr. Stephen Henson [Thu, 4 Mar 2004 21:44:39 +0000 (21:44 +0000)]
Typos.

Reported by: Jose Castejon-Amenedo <Jose.Castejon-Amenedo@hp.com>

20 years agoMake our page with pointers to binary distributions visible in the FAQ
Richard Levitte [Thu, 4 Mar 2004 07:47:40 +0000 (07:47 +0000)]
Make our page with pointers to binary distributions visible in the FAQ