Andy Polyakov [Fri, 25 Nov 2016 10:52:06 +0000 (11:52 +0100)]
c6x/* "facelift":
- make scripts executable;
- "parameterize" platform selection in c6x/do_fips;
- add c6x/fips_algvs.mak;
- add c6x/run6x.js launcher for more recent CCS versions;
Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Stephen Henson <steve@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4265)
Andy Polyakov [Fri, 25 Nov 2016 12:11:09 +0000 (13:11 +0100)]
Add some C64x assembly modules [by minor adjustments of C64x+ modules].
AES, SHA256 and SHA512 modules can actually replace corresponding
C64x+ modules. This is because C64x+ instructions don't actually
provide "killer-argument" advantage in these modules. As for SHA1,
even though its performance exactly same, C64x+ module is more
responsive to interrupts, i.e. doesn't inhibit them for as long
periods as C64x module.
Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Stephen Henson <steve@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4265)
Andy Polyakov [Mon, 11 May 2015 10:16:01 +0000 (12:16 +0200)]
util/incore update that allows FINGERPRINT_premain-free build.
As for complementary fips.c modification. Goal is to ensure that
FIPS_signature does not end up in .bss segment, one guaranteed to
be zeroed upon program start-up. One would expect explicitly
initialized values to end up in .data segment, but it turned out
that values explicitly initialized with zeros can end up in .bss.
The modification does not affect program flow, because first byte
was the only one of significance [to FINGERPRINT_premain].
Reviewed-by: Dr. Stephen Henson <steve@openssl.org>
Andy Polyakov [Mon, 11 May 2015 10:04:12 +0000 (12:04 +0200)]
Add support for Android 5, both 32- and 64-bit cases.
Special note about additional -pie flag in android-armv7. The initial
reason for adding it is that Android 5 refuses to execute non-PIE
binaries. But what about older systems and previously validated
platforms? It should be noted that flag is not used when compiling
object code, fipscanister.o in this context, only when linking
applications, *supplementary* fips_algvs used during validation
procedure.
Reviewed-by: Dr. Stephen Henson <steve@openssl.org>
Andy Polyakov [Mon, 11 May 2015 09:50:29 +0000 (11:50 +0200)]
Add iOS-specific armv4cpud.S module.
Normally it would be generated from a perlasm module, but doing so
would affect existing armv4cpuid.S, which in turn would formally void
previously validated platforms. Hense separate module is generated.
Reviewed-by: Dr. Stephen Henson <steve@openssl.org>
Andy Polyakov [Mon, 11 May 2015 09:43:55 +0000 (11:43 +0200)]
Adapt ARM assembly pack for iOS.
This is achieved by filtering perlasm output through arm-xlate.pl. But note
that it's done only if "flavour" argument is not 'void'. As 'void' is
default value for other ARM targets, permasm output is not actually
filtered on previously validated platforms.
Reviewed-by: Dr. Stephen Henson <steve@openssl.org>
Andy Polyakov [Mon, 11 May 2015 09:20:52 +0000 (11:20 +0200)]
crypto/modes/modes_lcl.h: let STRICT_ALIGNMENT be on iOS.
While ARMv7 in general is capable of unaligned access, not all instructions
actually are. And trouble is that compiler doesn't seem to differentiate
those capable and incapable of unaligned access. As result exceptions could
be observed in xts128.c and ccm128.c modules. Contemporary Linux kernels
handle such exceptions by performing requested operation and resuming
execution as is if it succeeded. While on iOS exception is fatal.
Correct solution is to let STRICT_ALIGNMENT be on all ARM platforms,
but doing so is in formal conflict with FIPS maintenance policy.
Reviewed-by: Dr. Stephen Henson <steve@openssl.org>
Update fipsalgtest.pl to cope with changes in file names and format
X9.31 tests need to look in files for '9.31'
RSA-PSS tests may contain additonal text as well as "salt len: n".
We now just look at the start of a filename for a match.
Separate ECDSA2 test list.
Reorder test to handle new formats: for example PQGVer for DSA2 can be
detected based on file format but if this fails revert to PQGVER.
For future debugging add a --debug-detect option which prints out more
details of the test detection including the first few lines of each
request file. Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Steve Marquess <marquess@openssl.org
For FIPS builds we don't use the normal test files (and in the restricted
tarball some don't exist) so set TEST='' to avoid linking to them. This also
avoids problems on platforms that copy instead of symlink.
Add support for multicall fips_algvs utility combining functionality
of all fips test utilities in a single binary and some minimal script
parsing for platforms lacking a suitable shell.
In order to keep changes to the build system to a minimum it #includes all
the utilities C source files (yuck).