Commit Graph

104 Commits

Author SHA1 Message Date
Dr. Stephen Henson c603c723ce Remove OPENSSL_FIPSCANISTER code.
OPENSSL_FIPSCANISTER is only set if the fips module is being built
(as opposed to being used). Since the fips module wont be built in
master this is redundant.
Reviewed-by: Tim Hudson <tjh@openssl.org>
2014-12-08 13:25:16 +00:00
Dr. Stephen Henson a4cc3c8041 Avoid Windows 8 Getversion deprecated errors.
Windows 8 SDKs complain that GetVersion() is deprecated.

We only use GetVersion like this:

	(GetVersion() < 0x80000000)

which checks if the Windows version is NT based. Use a macro check_winnt()
which uses GetVersion() on older SDK versions and true otherwise.
2014-02-25 13:40:33 +00:00
Andy Polyakov 99cda4376e cryptlib.c: fix typo in OPENSSL_showfatal. 2013-04-04 15:57:43 +02:00
Ben Laurie 7c770d572a Add and use a constant-time memcmp.
This change adds CRYPTO_memcmp, which compares two vectors of bytes in
an amount of time that's independent of their contents. It also changes
several MAC compares in the code to use this over the standard memcmp,
which may leak information about the size of a matching prefix.
(cherry picked from commit 2ee798880a)
2013-02-06 14:16:55 +00:00
Andy Polyakov a006fef78e Improve WINCE support.
Submitted by: Pierre Delaage
2013-01-19 21:23:13 +01:00
Andy Polyakov f91926a240 cryptlib.c: fix logical error. 2012-12-01 18:24:20 +00:00
Andy Polyakov cccf27c89a cryptlib.c: revert typo. 2012-11-17 21:42:57 +00:00
Andy Polyakov c5cd28bd64 Extend OPENSSL_ia32cap_P with extra word to accomodate AVX2 capability. 2012-11-17 19:04:15 +00:00
Ben Laurie 71fa451343 Version skew reduction: trivia (I hope). 2012-06-03 22:00:21 +00:00
Andy Polyakov a985410d2d cryptlib.c: sscanf warning. 2012-01-15 17:13:57 +00:00
Andy Polyakov 5d13669a2c cryptlib.c: make even non-Windows builds "strtoull-agnostic". 2012-01-14 18:46:15 +00:00
Andy Polyakov ff6f9f96fd cryptlib.c, etc.: fix linker warnings in 64-bit Darwin build. 2011-11-12 13:10:00 +00:00
Andy Polyakov 181fbb77f3 cryptlib.c: remove stdio dependency in Windows fipscanister.lib. 2011-10-23 19:41:00 +00:00
Andy Polyakov 2667162d33 cryptlib.c: OPENSSL_ia32cap environment variable to interpret ~ as cpuid mask. 2011-07-23 12:10:26 +00:00
Dr. Stephen Henson 9a4be82388 PR: 2470
Submitted by: Corinna Vinschen <vinschen@redhat.com>
Reviewed by: steve

Don't call ERR_remove_state from DllMain.
2011-06-22 15:38:21 +00:00
Dr. Stephen Henson 06b433acad Add FIPS support to the WIN32 build system. 2011-02-03 23:12:04 +00:00
Dr. Stephen Henson ad6019d6c0 Move locking and thread ID functions into new files lock.c and thr_id.c,
redirect locking to minimal FIPS_lock() function where required.
2011-01-27 14:27:24 +00:00
Dr. Stephen Henson e322fa2872 PR: 2376
Submitted by: Guenter <lists@gknw.net>
Reviewed by: steve

Cleanup alloca use, fix Win32 target for OpenWatcom.
2010-11-19 00:12:01 +00:00
Andy Polyakov 471d0eb397 cryptlib.c: allow application to override OPENSSL_isservice.
PR: 2194
2010-03-29 10:06:01 +00:00
Dr. Stephen Henson a25f33d28a Submitted by: Julia Lawall <julia@diku.dk>
The functions ENGINE_ctrl(), OPENSSL_isservice(), EVP_PKEY_sign(),
CMS_get1_RecipientRequest() and RAND_bytes() can return <=0 on error fix
so the return code is checked correctly.
2009-09-13 11:29:29 +00:00
Dr. Stephen Henson c869da8839 Update from 1.0.0-stable 2009-07-27 21:10:00 +00:00
Andy Polyakov 6022fe81a2 cryptlib.c: refine logic in OpenSSLDie (addenum to commit#18118). 2009-05-04 06:23:05 +00:00
Andy Polyakov 3b58c74c98 Avoid double dialogs in OpenSSLDie on Windows. 2009-05-03 14:16:40 +00:00
Andy Polyakov f00fdcd14d cryptlib.c: eliminate dependency on _strtoui64, older Windows CRT don't have it. 2009-05-02 12:51:37 +00:00
Richard Levitte d1417be75c Make the NULL definition of OPENSSL_ia32cap_loc() compatible with the
declaration in crypto.h.
2009-04-29 13:40:28 +00:00
Andy Polyakov e303f55fc7 Expand OPENSS_ia32cap to 64 bits. 2009-04-26 17:49:41 +00:00
Dr. Stephen Henson 8711efb498 Updates from 1.0.0-stable branch. 2009-04-20 11:33:12 +00:00
Dr. Stephen Henson 0f7efbc859 Ooops... remove code accidentally commited from FIPS version. 2008-10-14 15:44:14 +00:00
Dr. Stephen Henson 30661b1b01 Add missing lock definitions. 2008-10-14 15:22:11 +00:00
Geoff Thorpe 4c3296960d Remove the dual-callback scheme for numeric and pointer thread IDs,
deprecate the original (numeric-only) scheme, and replace with the
CRYPTO_THREADID object. This hides the platform-specifics and should reduce
the possibility for programming errors (where failing to explicitly check
both thread ID forms could create subtle, platform-specific bugs).

Thanks to Bodo, for invaluable review and feedback.
2008-08-06 15:54:15 +00:00
Geoff Thorpe 5f834ab123 Revert my earlier CRYPTO_THREADID commit, I will commit a reworked
version some time soon.
2008-07-03 19:59:25 +00:00
Ben Laurie 5ce278a77b More type-checking. 2008-06-04 11:01:43 +00:00
Bodo Möller 4bd4afa34e Change use of CRYPTO_THREADID so that we always use both the ulong and
ptr members.

(So if the id_callback is bogus, we still have &errno.)
2008-05-19 20:45:25 +00:00
Geoff Thorpe f7ccba3edf There was a need to support thread ID types that couldn't be reliably cast
to 'unsigned long' (ie. odd platforms/compilers), so a pointer-typed
version was added but it required portable code to check *both* modes to
determine equality. This commit maintains the availability of both thread
ID types, but deprecates the type-specific accessor APIs that invoke the
callbacks - instead a single type-independent API is used.  This simplifies
software that calls into this interface, and should also make it less
error-prone - as forgetting to call and compare *both* thread ID accessors
could have led to hard-to-debug/infrequent bugs (that might only affect
certain platforms or thread implementations). As the CHANGES note says,
there were corresponding deprecations and replacements in the
thread-related functions for BN_BLINDING and ERR too.
2008-03-28 02:49:43 +00:00
Dr. Stephen Henson 56c7754cab Avoid warnings. 2008-02-28 14:05:01 +00:00
Dr. Stephen Henson af32f9fdda Update from fips2 branch. 2007-02-03 17:32:49 +00:00
Bodo Möller 48fc582f66 New functions CRYPTO_set_idptr_callback(),
CRYPTO_get_idptr_callback(), CRYPTO_thread_idptr() for a 'void *' type
thread ID, since the 'unsigned long' type of the existing thread ID
does not always work well.
2006-06-23 15:21:36 +00:00
Ulf Möller 4700aea951 Add BeOS support.
PR: 1312
Submitted by: Oliver Tappe <zooey@hirschkaefer.de>
Reviewed by: Ulf Moeller
2006-04-11 21:34:21 +00:00
Andy Polyakov a00e414faf Unify sparcv9 assembler naming and build rules among 32- and 64-bit builds.
Engage run-time switch between bn_mul_mont_fpu and bn_mul_mont_int.
2005-12-16 17:39:57 +00:00
Andy Polyakov 19bd66fe74 WCE update, mostly typos. 2005-08-03 19:56:36 +00:00
Andy Polyakov 2031eca588 WCE-specific fix for cryptlib.c. 2005-08-02 22:07:28 +00:00
Andy Polyakov 1875e6db29 Pull up Win64 support from 0.9.8. 2005-07-05 11:44:45 +00:00
Andy Polyakov e476f94212 Move _WIN32_WINNT definition from command line to e_os.h. The change is
inspired by VC6 failure report. In addition abstain from taking screen
snapshots when running in NT service context.
2005-05-21 13:19:27 +00:00
Andy Polyakov 34c7ff6dc9 Cygwin doesn't expose Win32 [not "officially"]. 2005-05-03 21:20:17 +00:00
Richard Levitte 630e4a6e59 Provide a default OPENSSL_ia32cap_loc for non-Intel platforms where
util/libeay.num is important when building shared libraries, like
VMS.
2005-04-21 09:10:19 +00:00
Andy Polyakov 1bf955920a Fix typos. 2005-04-13 15:41:11 +00:00
Andy Polyakov 51d28013db Introduce OPENSSL_NONPIC_relocated to denote relocated DLLs. 2005-04-13 08:46:35 +00:00
Andy Polyakov 9e88c82703 Minor cryptlib.c update: compiler warnings in OPENSSL_showfatal and
OPENSSL_stderr stub.
2005-04-13 06:55:42 +00:00
Andy Polyakov 9f2027e56d Implement OPENSSL_showfatal and make it Win32 GUI and service aware
[meaning that it will detect in which context application is running
and either write message to stderr, post a dialog or log an event].
2005-04-07 18:39:45 +00:00
Andy Polyakov e1d51de41f Harmonize cygwin/mingw and VC targets. 2005-04-07 15:51:55 +00:00