Ralf S. Engelschall
667ac4ec6a
Make gcc 2.95.2 happy again, even under ``-Wall -Wshadow -Wpointer-arith -Wcast-align
...
-Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline''.
2000-02-11 09:47:18 +00:00
Dr. Stephen Henson
f07fb9b24b
Add command line password options to the reamining utilities,
...
amend docs.
2000-02-08 01:34:59 +00:00
Ulf Möller
4e539aaa1e
"print" is GNU bc specific.
2000-02-06 23:33:06 +00:00
Ulf Möller
fcb20be846
put missing line back in.
2000-02-06 16:35:28 +00:00
Ulf Möller
cae55bfc68
Improve bntest slightly, and fix another bug in the BN library.
2000-02-06 15:56:59 +00:00
Ulf Möller
4a6222d71b
BN_div bugfix. The q-- loop should not be entered in the n0==d0 case.
2000-02-06 00:25:39 +00:00
Bodo Möller
29a28ee503
Cosmetic changes.
2000-02-05 21:28:09 +00:00
Bodo Möller
eb5a6a55c5
Commit patch to bn.h that CVS decided to throw away during 'cvs update',
...
and initialize too_many because memset(..., 0, ...) is not used here.
2000-02-05 20:39:26 +00:00
Bodo Möller
37e48b88ad
Generate just one error code if iterated SSL_CTX_get() fails.
...
Avoid enabled 'assert()' in production library.
2000-02-05 19:29:00 +00:00
Ulf Möller
6535eb1728
Use MONT_WORD macro to control if the word-based or the bignum
...
algorithm is used.
2000-02-05 18:23:05 +00:00
Ulf Möller
9b141126d4
New functions BN_CTX_start(), BN_CTX_get(), BN_CTX_end() to access
...
temporary BIGNUMs. BN_CTX still uses a fixed number of BIGNUMs, but
the BN_CTX implementation could now easily be changed.
2000-02-05 14:17:32 +00:00
Ulf Möller
ce76ce43ae
*** empty log message ***
2000-02-03 23:38:55 +00:00
Ulf Möller
657e60fa00
ispell (and minor modifications)
2000-02-03 23:23:24 +00:00
Bodo Möller
7999c65c9b
Some 'const's for BNs.
2000-02-03 01:26:07 +00:00
Bodo Möller
bfe30e4d1b
Include OpenSSL license.
2000-02-02 23:30:32 +00:00
Bodo Möller
aff0825c61
Tolerate negative numbers in BN_is_prime.
2000-02-02 22:18:01 +00:00
Bodo Möller
e74231ed9e
rndsort{Miller, Rabin} primality test.
2000-02-02 21:20:44 +00:00
Andy Polyakov
fb81ac5e6b
Support for "multiply high" instruction, see BN_UMULT_HIGH comment in
...
crypto/bn/bn_lcl.h for further details. It should be noted that for
the moment of this writing the code was tested only on Alpha. If
compiled with DEC C the C implementation exhibits 12% performance
improvement over the crypto/bn/asm/alpha.s (on EV56 box running
AlphaLinux). GNU C is (unfortunately) 8% behind the assembler
implementation. But it's OpenVMS Alpha users who *may* benefit most
as 'apps/openssl speed rsa' exhibits 6 (six) times performance
improvement over the original VMS bignum implementation. Where "*may*"
means "as soon as code is enabled though #define SIXTY_FOUR_BIT and
crypto/bn/asm/vms.mar is skipped."
2000-02-02 16:18:12 +00:00
Ulf Möller
1399f17a07
Bug fix: BN_is_prime() would fail with a high probability for small
...
primes (negligible for larger ones).
2000-02-01 23:48:55 +00:00
Ulf Möller
0bde1089f8
match the prototype
2000-02-01 23:47:24 +00:00
Bodo Möller
cb5b7850ac
If n0 == d0, we must alway compute 'rem' "by hand"
2000-02-01 11:10:54 +00:00
Bodo Möller
fe7cd1647d
Typo in preprocessor symbol.
2000-02-01 08:48:30 +00:00
Ulf Möller
f40c02d908
undo. I keep confusing my directories. :(
2000-02-01 02:24:10 +00:00
Ulf Möller
8efb60144d
EBCDIC support.
...
Submitted by: Martin Kraemer <martin.kraemer@mch.sni.de>
2000-02-01 02:21:16 +00:00
Ulf Möller
51ca375e7e
Seek out and destroy another evil cast.
2000-01-30 23:33:40 +00:00
Bodo Möller
1baa94907c
Make output of "openssl dsaparam 1024" more interesting :-)
2000-01-30 03:32:28 +00:00
Bodo Möller
a87030a1ed
Make DSA_generate_parameters, and fix a couple of bug
...
(including another problem in the s3_srvr.c state machine).
2000-01-30 02:23:03 +00:00
Richard Levitte
f95a9f678a
Declare BN_pseudo_rand().
2000-01-27 22:07:42 +00:00
Bodo Möller
953aa79040
A couple of things were reversed for BN_pseudo_rand ...
2000-01-27 21:09:25 +00:00
Ulf Möller
157be2b67d
comment was wrong.
2000-01-27 19:52:58 +00:00
Ulf Möller
38e33cef15
Document DSA and SHA.
...
New function BN_pseudo_rand().
Use BN_prime_checks_size(BN_num_bits(w)) rounds of Miller-Rabin when
generating DSA primes (why not use BN_is_prime()?)
2000-01-27 19:31:26 +00:00
Bodo Möller
2233bed1cb
typo in a comment
2000-01-27 14:31:31 +00:00
Bodo Möller
ec1258dd44
Update comments to provide a better approximation of reality.
2000-01-27 13:00:10 +00:00
Bodo Möller
b99b110766
Add a pointer to a paper (is the algorithm in section 4.2 the
...
word-based algorithm we are using?)
2000-01-27 12:52:41 +00:00
Bodo Möller
6e0cad8d34
enable Montgomery test
2000-01-27 11:26:28 +00:00
Bodo Möller
5f5e96d92b
Update references.
2000-01-27 09:15:49 +00:00
Ulf Möller
e93f9a3284
Run ispell.
...
Clean up bn_mont.c.
2000-01-27 01:50:42 +00:00
Dr. Stephen Henson
dd9d233e2a
Tidy up CRYPTO_EX_DATA structures.
2000-01-23 23:41:49 +00:00
Ulf Möller
dd8dec69b8
Document the BN library.
2000-01-23 22:06:24 +00:00
Ulf Möller
4486d0cd7a
Document the DH library, and make some minor changes along the way.
2000-01-22 20:05:23 +00:00
Ulf Möller
b25c8db872
AFAICS lst1 stands for "lshift test" not "list".
2000-01-21 00:00:12 +00:00
Bodo Möller
4146aa6b42
Rename lst1 to list1 to avoid name conflict on some platforms.
2000-01-20 23:15:50 +00:00
Bodo Möller
0c50e02b30
- Pseudo-seed the PRNG in programs used for "make test"
...
because otherwise BN_rand will fail unless DEVRANDOM works,
which causes the programs to dump core because they
don't check the return value of BN_rand (and if they
did, we still couldn't test anything).
- add comment to some files that appear not to be used at all.
2000-01-14 17:55:37 +00:00
Ulf Möller
eb952088f0
Precautions against using the PRNG uninitialized: RAND_bytes() now
...
returns int (1 = ok, 0 = not seeded). New function RAND_add() is the
same as RAND_seed() but takes an estimate of the entropy as an additional
argument.
2000-01-13 20:59:17 +00:00
Bodo Möller
76aa0ddc86
Turn BN_prime_checks into a macro.
...
Primes p where (p-1)/2 is prime too are called "safe", not "strong".
2000-01-12 11:57:30 +00:00
Bodo Möller
e4b7645631
add dependency and auto-generation rule for bn_prime.h
...
(created by bn_prime.pl, which now prints the copyright/license
note as found in bn_prime.h)
2000-01-12 09:16:22 +00:00
Andy Polyakov
b96eb06f79
Makefile clean-ups, crypto/bn/asm/alpha.s compiles on Alpha Linux.
1999-12-25 16:08:31 +00:00
Ulf Möller
3b14cb717d
Solaris x86 assembler problem is already addressed in ./config
...
(bug reports keep coming in because that was still missing in 0.9.4)
1999-12-14 15:28:10 +00:00
Ulf Möller
a4af39ac44
Don't use inline assembler on x86 Solaris (would need a different syntax).
1999-12-08 22:55:06 +00:00
Mark J. Cox
ce2c95b2a2
Fix assembler for Alpha (tested only on DEC OSF not Linux or *BSD). The
...
problem was that one of the replacement routines had not been working since
SSLeay releases. For now the offending routine has been replaced with
non-optimised assembler. Even so, this now gives around 95% performance
improvement for 1024 bit RSA signs.
1999-11-03 14:10:10 +00:00
Bodo Möller
798757762a
Improve support for running everything as a monolithic application.
...
Submitted by: Lennart Bång, Bodo Möller
1999-10-25 19:36:01 +00:00
Ulf Möller
8e1589ece5
VC++ warning.
1999-09-29 22:11:06 +00:00
Andy Polyakov
0bbd03525e
Minor MIPS III/IV tune-up.
1999-08-24 16:02:16 +00:00
Ben Laurie
97e84e38df
Make it compile under -pedantic.
1999-08-03 10:18:27 +00:00
Andy Polyakov
4c22909e31
Extra i386+gcc bn_div.c tune-up featuring inline division and saving
...
the remainder left in %edx. Here is the resulting performance improvement
matrix (improvement as a result of this *and* previous tune-up committed
two days ago). The results were obtained by profiling the "div" part of
the crypto/bn/bnspeed.c.
CPU BN_div bn_div_words overall comment
------------------------------------------------------------------------
PII +16% accumulated by +2-3% PII multiplies damn fast! Taking
inlining multiplication out of the loop
didn't make too much difference.
Eliminating of the multiplication
involved in remainder calculation
is the major factor.
Pentium +45% accumulated by +7-9% mull isn't that fast and replacing
inlining multiplications with additions in
the loop has more visible effect:-)
MIPS +75% +12% +20-25% In addition to the taking mults
R10000 out of the loop (giving 12% in the
asm/mips3.s) three mults were
eliminated in BN_div.
Alpha +30% +50% +10-15% Same as above. But remember that
EV4 bn_div_words is a C implementation.
It takes 4 Alpha mults in C to do
the same thing as 1 MIPS mult in
assembler does. So the effect (50%)
is more impressive. But not the
overall one... Well, if Alpha
bn_mul_add would be implemented
in assembler overall improvement
would be closer to MIPS...
1999-07-31 23:27:41 +00:00
Bodo Möller
8d85b33eb5
by request: let BN_dup(NULL) just return NULL
1999-07-30 19:22:57 +00:00
Andy Polyakov
0dd25e3606
Bignum division tune-up. Idea is to move multiplications in front of
...
loop body and replace 'em with addition/subtraction.
1999-07-30 11:43:43 +00:00
Andy Polyakov
5965902e6e
when invoking bn_*_comba[48] result->top wasn't always set correctly.
1999-07-27 09:36:59 +00:00
Andy Polyakov
1656ef2997
SPARC Solaris config updates.
...
./config sences whole range of SPARC instruction sets. Do note that
it favors Sun C now if both gcc and cc 4.2 or later are present!
1999-07-25 22:25:12 +00:00
Andy Polyakov
a0618e3e5e
Added support for SPARC Linux.
1999-07-25 15:13:49 +00:00
Andy Polyakov
fccbb9b34f
- performance retunes, v8plus bn_*_comba routines are reimplemented;
...
- support for GNU assembler (read SPARC Linux);
1999-07-25 12:34:30 +00:00
Ulf Möller
40e29b1976
Remove obsolete files.
1999-07-22 21:57:41 +00:00
Andy Polyakov
cea538154b
Get rid of redundant multiplications in bn_div_words.
1999-07-21 13:53:01 +00:00
Andy Polyakov
7363455fac
MIPS III/IV assembler module is reimplemented.
1999-07-20 15:50:20 +00:00
Andy Polyakov
eaccfe8b29
crypto/bn/asm/mips3.s is moved to crypto/bn/asm/obsolete/
1999-07-20 13:43:26 +00:00
Andy Polyakov
d2759c2135
crypto/bn/asm/mips3.s is obsolete. I'm moving it to crypto/bn/asm/obsolete
...
in order to replace it with a new version.
1999-07-20 13:40:02 +00:00
Ulf Möller
cfa3747ba9
More DES library cleanups: remove references to srand/rand
...
and delete an unused file.
1999-07-15 23:47:02 +00:00
Ulf Möller
a026fd201f
Obsolete/experimental code.
1999-07-09 15:23:11 +00:00
Ulf Möller
e371828067
Use "long long" for all Win32 gcc ports.
1999-06-28 16:17:38 +00:00
Bodo Möller
7722424462
With mingw32, use "long long" rather than "_int64" (the latter does
...
not work, at least the package mentioned in INSTALL.W32 does not know
about it).
1999-06-28 14:38:31 +00:00
Dr. Stephen Henson
8623f693d9
New functions CONF_load_bio() and CONF_load_fp() to load a configuration
...
file from a bio or fp. Added some more constification to the BN library.
1999-06-20 17:36:11 +00:00
Bodo Möller
2eae234023
Some people don't have /dev/fd/0 on Solaris, so use - instead.
1999-06-15 23:17:09 +00:00
Bodo Möller
e0f12c41de
Avoid some warnings (on silly compilers).
1999-06-12 09:52:44 +00:00
Ulf Möller
adc7fe123b
Circumvent bug in SC5 without patch #107357-01.
...
Submitted by: Andy Polyakov <appro@fy.chalmers.se>
1999-06-09 21:13:27 +00:00
Ben Laurie
233bf734d3
Make "make test" fail if bntest fails an internal selfcheck.
1999-06-09 10:19:53 +00:00
Ben Laurie
8d8a8041ec
const/type fixes.
1999-06-05 12:16:33 +00:00
Ben Laurie
84c15db551
Some constification and stacks that slipped through the cracks (how?).
1999-06-04 22:23:10 +00:00
Ben Laurie
b4f76582d4
More evil cast removal.
1999-06-03 18:04:04 +00:00
Ben Laurie
4da88a8d92
Update dependencies.
1999-05-29 14:10:58 +00:00
Bodo Möller
436a376bb0
Some assembler-related clean-ups.
1999-05-28 23:18:51 +00:00
Bodo Möller
b14d0e0590
Circument egcs bug.
...
Submitted by: Andy Polyakov <appro@fy.chalmers.se>
1999-05-26 19:59:36 +00:00
Bodo Möller
7e70181723
It was a very bad idea to use #include "../e_os.h" -- when this occurs
...
in cryptlib.h (which is often included as "../cryptlib.h"), then the
question remains relative to which directory this is to be interpreted.
gcc went one further directory up, as intended; but makedepend thinks
differently, and so probably do some C compilers. So the ../ must go away;
thus e_os.h goes back into include/openssl (but I now use
#include "openssl/e_os.h" instead of <openssl/e_os.h> to make the point) --
and we have another huge bunch of dependency changes. Argh.
1999-05-21 11:16:48 +00:00
Bodo Möller
d6847aed10
Add a kludge :-(
...
There were problems with putting e_os.h just into the top directory,
because the test programs are compiled within test/ in the "standard"
case in in their original directories in the makefile.one case;
and in the latter symlinks may not be available.
1999-05-20 22:18:49 +00:00
Bodo Möller
17e3dd1c62
Don't install e_os.h in include/openssl, use it only as a local
...
include file.
1999-05-20 21:59:20 +00:00
Ulf Möller
e14d4443a2
Bignum library bug fix. IRIX 6 passes "make test" now!
...
This also avoids the problems with SC4.2 and unpatched SC5.
Submitted by: Andy Polyakov <appro@fy.chalmers.se>
1999-05-20 01:43:07 +00:00
Ulf Möller
fb92ba64a0
Move prototypes to the right place.
1999-05-17 22:25:31 +00:00
Ben Laurie
62bad77124
Add actual testing to bntest...
1999-05-15 15:59:28 +00:00
Bodo Möller
3398f6cc21
OPENSSL_EXTERN
1999-05-15 14:30:31 +00:00
Bodo Möller
7f0dae3276
OPENSSL_EXTERN, OPENSSL_GLOBAL
1999-05-15 14:23:29 +00:00
Bodo Möller
127640b449
Update dependencies.
1999-05-15 13:38:48 +00:00
Bodo Möller
0981259ada
For solaris-usparc configurations, avoid problems with GNU as, which
...
cannot handle all opcodes we need.
1999-05-13 15:02:49 +00:00
Ulf Möller
5c83b4c93f
Remove redundant ifdef.
1999-05-13 13:29:41 +00:00
Ulf Möller
7d7d2cbcb0
VMS support.
...
Submitted by: Richard Levitte <richard@levitte.org>
1999-05-13 11:37:32 +00:00
Ulf Möller
dcbe935125
Missing argument in prototype.
...
Submitted by: Andreas Ley <ley@rz.uni-karlsruhe.de>
1999-05-12 00:45:42 +00:00
Bodo Möller
84a370a400
The various character predicates (isspace and the like) may not be
...
used with negative char values, so I've added casts to unsigned char.
Maybe what really should be done is change all those arrays and
pointers to type unsigned char [] or unsigned char *, respectively;
but using plain char with those predicates is just wrong, so something
had to be done.
Submitted by:
Reviewed by:
PR:
1999-05-10 11:18:26 +00:00
Ulf Möller
0894315642
Superseded by sparcv8.S and sparcv8plus.s.
1999-05-08 10:39:15 +00:00
Ulf Möller
52c4409240
v8plus must be specified.
1999-05-05 22:03:50 +00:00
Ulf Möller
98f1c689a5
Fix problem with /usr/ccs/lib/cpp.
...
Submitted by: Andy Polyakov <appro@fy.chalmers.se>
1999-05-05 11:27:56 +00:00
Ulf Möller
744029c154
Recognise Ultra Sparc and compiler version number.
1999-05-04 23:18:24 +00:00
Ulf Möller
49dce898f0
Andy Polyakov points out there are default rules in make in gmake for this.
1999-05-04 22:06:53 +00:00