203 Commits

Author SHA1 Message Date
Geoff Thorpe
fd509d6da5 This memset() in the ubsec ENGINE is a bug. Zeroing out the result array
should not be necessary in any case, but more importantly the result and
input BIGNUMs could be the same, in which case this is clearly a problem.

Submitted by: Jonathan Hersch
Reviewed by: Joe Orton
Approved by: Geoff Thorpe
2003-06-06 17:54:22 +00:00
Richard Levitte
322f190a18 If an application supports static locks, it MUST support dynamic locks as
well to be able to use the CHIL engine.
PR: 281
2002-12-05 00:57:41 +00:00
Richard Levitte
c4a150c242 Supported REF_PRINT with specified reference counter 2002-12-05 00:56:41 +00:00
Richard Levitte
a3c5420b28 PR: 381 2002-12-05 00:14:08 +00:00
Richard Levitte
63e86149c1 Recent changes from 0.9.6-stable. 2002-11-28 12:26:05 +00:00
Richard Levitte
53b80e2e43 Addapt hw_ubsec.c to OpenSSL 0.9.6x [engine]. 2002-11-06 07:08:38 +00:00
Geoff Thorpe
311d8d84bd Correct some "read" locks that should actually be "write" locks. 2002-10-16 01:37:07 +00:00
Bodo Möller
ecdf154993 avoid crash on Windows
Submitted by: Lynn Gazis <lgazis@rainbow.com>
2002-08-09 08:16:11 +00:00
Richard Levitte
89918b5c17 Certain flag macros were tested with #if instead if #ifdef... 2002-08-02 11:14:36 +00:00
Richard Levitte
7462f2644c It seems like we forgot to move from strdup() to BUF_strdup() in this file.
PR: 54
2002-05-29 11:04:39 +00:00
Richard Levitte
d2f64ef725 surewarehk_dh_ex_free() isn't used, so do not compile it. 2002-04-17 07:53:56 +00:00
Richard Levitte
842931098f Avoid variable shadowing. 2002-04-17 07:52:56 +00:00
Richard Levitte
a7a71d0ec9 Make sure strdup() gets properly declared. 2002-04-17 07:52:21 +00:00
Richard Levitte
d007411335 Forgot one of the casts 2002-04-03 15:00:41 +00:00
Richard Levitte
9a78b3db52 HW_aep was a little too constified for this version of OpenSSL. 2002-04-03 14:57:40 +00:00
Richard Levitte
e874ee0850 Cast the pointers to the BIGNUM data to unsigned long *. This would be
harmful if we didn't also pass the exact number of bytes of that data
2002-04-03 14:47:23 +00:00
Richard Levitte
192060947c A couple of typos.
Discovered and submitted by Diarmuid O'Neill <Diarmuid.ONeill@aep.ie>
2002-04-03 13:52:51 +00:00
Richard Levitte
ff0a0c46a7 AEPRAND it is... 2002-03-07 19:40:55 +00:00
Richard Levitte
c568a9820a Synchronise the AEP engine in all branches. For 0.9.6-stable [engine], implement software fallback 2002-03-07 19:39:44 +00:00
Bodo Möller
b76b87fdf5 fix prototype
Submitted by: Oscar Jacobsson <oscar@jacobsson.org>
2002-03-01 13:59:22 +00:00
Richard Levitte
dac7098464 Back port of the latest updates of the AEP engine. 2002-02-28 13:45:55 +00:00
Richard Levitte
ed2f196afe A number of corrections of the aep engine implementation:
1. rnd_reference was a duplication of the work the the engine
   framework does, and wasn't ever checked.  Removed.
2. use the NO_ macros to disable appropriate algorithms.
3. Only implement the RNG stuff if AEPRAND is defined (default: not
   defined, because the AEP people plan on having boards without it.
   I'll see if I can device a more dynamic way of disabling this).
4. aep_finish() now closes all connections, and if that worked, does a
   proper finalize.
5. proper AEP types are used to conform to the AEP definitions of
   their own functions.
6. remake the use of thread locks.  The use of CRYPTO_LOCK_DYNLOCK was
   definitely inappropriate, and for random generator stuff, it's
   better to use CRYPTO_LOCK_RAND.

Also, I applied certain changes that were provided by the AEP people.
Among others, BN_CTX_new() is not used to initialise a BN context
(this was never done before, and may have made things slower or not
working at all.
2002-02-07 22:04:30 +00:00
Richard Levitte
88e89f9022 For the sake of DOS and Windows, provide a different way to get a
pid_t.
2002-01-27 17:13:35 +00:00
Richard Levitte
e4f165e71e Apply a change by Toomas Kiisk <vix@cyber.ee>:
* Fix a crashbug and a logic bug in hwcrhk_load_pubkey()
2002-01-25 17:46:34 +00:00
Richard Levitte
91102def2e Make the type of hConnection consistent. 2001-12-11 07:40:51 +00:00
Richard Levitte
35933d170d Problem:
1. some platforms do not have inttypes.h, and chasing them down
   becomes ridiculous.  Therefore, uint64_t can't be used for 64-bit
   values.
2. some (other) platforms do not support "long long".

Solution: make AEP_U64 a struct with two longs unless long already is
64 bit long.

Also, restore all other types back to use unsigned char, unsigned int
and unsigned long.  Make sure that AEP_U32 actually becomes 32 bits,
even on platforms where long is 64 bits (actually, we're just guessing
that int will stay at 32 bits on those...).
2001-12-11 07:37:40 +00:00
Bodo Möller
dae0b520a0 fixes submitted by Andy Schneider <andy.schneider@bjss.co.uk> 2001-11-23 20:56:27 +00:00
Richard Levitte
595241e17f inttypes.h apparently doesn't exist with VC++. Therefore, use the
built-in types __int8, __int16 and so on on that platform.
2001-11-21 13:26:57 +00:00
Geoff Thorpe
c6d14d26fd Squash a VC++ warning. 2001-11-21 03:49:51 +00:00
Geoff Thorpe
832e09cd23 Testing on WIN32 turned up a faulty default value. 2001-11-20 05:19:20 +00:00
Richard Levitte
07ad3257fc unsigned long long is not accepted anywhere, especially on certain
32-bit platforms.  Instead, make use of inttypes.h and use the types
defined there to get 8-, 16-, 32- an 64-bit values.

There might be some operating systems where one should use int_types.h
instead of inttypes.h.  Unfortunately, I don't recall which one(s).
2001-11-17 23:01:25 +00:00
Geoff Thorpe
b26f6ee5f2 Another ENGINE that's been working in 0.9.6-engine for a while that will
be included for 0.9.6c-engine.
2001-11-17 05:29:25 +00:00
Richard Levitte
b5719e9673 Use memset() instead of bzero(). 2001-11-16 23:31:07 +00:00
Richard Levitte
f56412e895 unsigned char * vs. char * 2001-11-16 23:28:45 +00:00
Richard Levitte
edcace97a8 Merge in latest changes from 0.9.6-stable.
make update
perl util/mkerr.pl -recurse -write -rebuild

(now, just look at the effect that last thing had on the ENGINE error
strings!  How did that unbalance between macros and strings happen?)
2001-11-15 13:33:08 +00:00
Geoff Thorpe
b0eda65f1c "sureware" should not be "hwcrhk".
Also, the "to" variable used in cleanup is never non-NULL and is entirely
unused. As such, the cleanup might have been missed under genuine error
conditions and caused leaks and/or returned invalid pointers.
2001-11-15 02:51:01 +00:00
Mark J. Cox
c3970428ac Back-port of Broadcom engine code from 0.9.7 to 0.9.6, but with a few
patches taken from Red Hat Linux 7.2.  Original code from Broadcom with
patches and backport by Nalin, more backport to fix warnings and const
changes by Mark
Submitted by: Mark Cox
Reviewed by:
PR:
2001-11-12 20:28:09 +00:00
Mark J. Cox
b1d9279a41 Add initial support for Baltimore SureWare accelerator cards; this works
for acceleration only at the moment, but full key management is being
worked on for the future.  This code has been compiled cross-platform but
not extensively tested
Submitted by: Mark Cox, Baltimore Technologies
Reviewed by: Mark Cox
PR:
2001-11-12 15:21:55 +00:00
Mark J. Cox
c7d827fc90 Commit missing AEP files (oops)
Submitted by:
Reviewed by:
PR:
2001-11-12 12:11:06 +00:00
Mark J. Cox
37fe697597 Add support for AEP crypto cards to 0.9.6c. This patch is in Red Hat Linux
7.2 and been given extensive testing; it also compiles okay on our selection
of random machines (including 64-bit)
Submitted by: AEP, Mark Cox
Reviewed by: Mark Cox
PR:
2001-11-12 11:17:19 +00:00
cvs2svn
d8616888ee This commit was manufactured by cvs2svn to create branch 'OpenSSL-engine-
0_9_6-stable'.
2001-11-10 02:12:57 +00:00
Bodo Möller
3a8a0a3945 2001, not 2000 2001-11-09 13:15:05 +00:00
Richard Levitte
6acc3b9689 Place the OpenSSL-specific headers back so they always get included,
or we get a dependency war in Makefile.ssl
2001-11-05 18:18:12 +00:00
Richard Levitte
66aa856698 No need to include anything on systems that do not have /dev/crypt 2001-11-05 12:44:14 +00:00
Richard Levitte
b30245dae0 'make update' 2001-10-10 07:56:20 +00:00
Richard Levitte
116daf4c2f To avoid commit wars over dependencies, let's make it so things that
depend on the environment, like the presence of the OpenBSD crypto
device or of Kerberos, do not change the dependencies within OpenSSL.
2001-10-10 07:55:02 +00:00
Geoff Thorpe
7526e2c043 As ENGINE_load_openbsd_dev_crypto() is an API function, it makes sense for
it to be defined on all platforms whether or not it is of any practical
use on them. This also resolves linker problems on "special" platforms,
such as win32.
2001-10-08 17:08:17 +00:00
Geoff Thorpe
6d52f260bf Make sure the "ENGINE_TABLE" cleanup callbacks have correct prototypes. 2001-10-08 17:06:52 +00:00
Geoff Thorpe
752f2b6785 Missing pointer in the eng_table_register function. Reported by
Martin Szotkowski.
2001-10-08 14:44:38 +00:00
Richard Levitte
f8000b9345 'make update' 2001-10-04 07:49:09 +00:00