components/openssl/README
author Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
Fri, 28 Aug 2015 11:04:52 -0700
changeset 4822 1fb8a14c6702
parent 4370 7043c27399f1
permissions -rw-r--r--
PSARC/2015/353 OpenSSL 1.0.2 20829622 Upgrade to OpenSSL 1.0.2d
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
363
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
     1
#
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
     2
# CDDL HEADER START
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
     3
#
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
     7
#
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
     8
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    11
# and limitations under the License.
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    12
#
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    14
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    18
#
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    19
# CDDL HEADER END
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    20
#
4370
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
    21
# Copyright (c) 2009, 2015, Oracle and/or its affiliates. All rights reserved.
363
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    22
#
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    23
1267
3d7359ef8168 15824599 SUNBT7206151 T4 hash should be embedded in the OpenSSL upstream src
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 763
diff changeset
    24
363
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    25
Build Layout
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    26
---
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    27
4822
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
    28
OpenSSL build is run four times. Once for regular dynamic non-fips, once 
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
    29
for static bits to link with standalone wanboot binary, once for fips-140,
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
    30
and once for FIPS-140 canister (in the openssl-fips component)
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
    31
needed to build FIPS-140 certified libraries. All builds apart from 
745
09fd85317532 7141635 Deliver wanboot-openssl.o for wanboot
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 426
diff changeset
    32
static libraries for wanboot are done for 32 and 64 bits. So, in total, OpenSSL
2180
bc1340c26305 19789902 pkcs11 engine dumps core when the softtoken is disabled
Ivo Raisr <ivo.raisr@oracle.com>
parents: 2041
diff changeset
    33
is built seven times. OpenSSL for wanboot is only built on sparc.
363
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    34
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    35
See also comments in all the Makefiles for more information.
363
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    36
1267
3d7359ef8168 15824599 SUNBT7206151 T4 hash should be embedded in the OpenSSL upstream src
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 763
diff changeset
    37
OpenSSL Version
4822
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
    38
--------------
1267
3d7359ef8168 15824599 SUNBT7206151 T4 hash should be embedded in the OpenSSL upstream src
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 763
diff changeset
    39
363
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    40
The non-fips Build.
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    41
---
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    42
4370
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
    43
The non-fips build is the 'default' build of OpenSSL and includes the regular
363
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    44
binaries, libraries, man pages, and header files.
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    45
1884
d1a47da60382 17799549 libcrypto openssl incorrect size for libcrypto.so.1.0.0`_sparcv9_random
jenny.yung@oracle.com <jenny.yung@oracle.com>
parents: 1680
diff changeset
    46
363
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    47
The fips Build
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    48
---
9c0cad004039 7039910 move OpenSSL from SFW to Userland gate
Jan Pechanec <Jan.Pechanec@Oracle.COM>
parents:
diff changeset
    49
4822
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
    50
We are now shipping FIPS-140 certified OpenSSL with S11.2 and later.
1680
49cf3ba424f0 18161027 OpenSSL 1.0.1f: ON nightly fails with missing symbol in wanboot-openssl.o
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 1596
diff changeset
    51
The admin may choose to activate 'openssl-fips' implementation using 'pkg mediator'.
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    52
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    53
The wanboot Build
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    54
----
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    55
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    56
There are some significant differences when building OpenSSL for wanboot.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    57
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    58
Some additional Configuration options are needed:
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    59
-DNO_CHMOD		chmod not available in stand-alone environment
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    60
-DBOOT			guard for wanboot specific patches
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    61
-DOPENSSL_NO_DTLS1	to avoid dtls1_min_mtu() - DTLS not used anyway
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    62
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    63
List of object files for wanboot-openssl.o
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    64
----
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    65
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    66
At this moment, object files for wanboot-openssl.o need to be listed explicitly.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    67
This is cumbersome and relatively tedious with respect to upgrading to higher
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    68
version of openssl. 
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    69
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    70
In future, it would be nice, if this could be performed automatically by the
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    71
linker. The required interface for wanboot is already defined in a mapfile and
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    72
linker option '-zdiscard-unused=sections,files' is already used to discard
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    73
unused code. 
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    74
But sadly, at this moment when the linker is given all the object files, it
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    75
correctly discards some unused files, but references to undefined symbols from
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    76
the discarded files don't get discarded along. Later, these undefined references
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    77
cause wanboot linking failure. 
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    78
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    79
In order to determine which openssl object files are required for wanboot,
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    80
first build static standalone openssl bits in Userland. As a site effect,
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    81
static libraries libssl.a and libcrypto.a are created in build/sparcv9-wanboot.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    82
4822
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
    83
    $ cd $USERLAND/components/openssl/openssl-default ; gmake build
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    84
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    85
Next, collect some information from linking wanboot static libraries in ON.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    86
This can be done by the following hack.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    87
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    88
    $ cd $ON/usr/src/psm/stand/boot/sparcv9/sun4
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    89
    $ touch wanboot.o
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    90
    $ LD_OPTIONS="-Dfiles,symbols,output=ld.dbg \
4822
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
    91
        -L$USERLAND/components/openssl/openssl-default/build/sparcv9-wanboot " \
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    92
        WAN_OPENSSL=" -lwanboot -lssl -lcrypto" dmake all
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    93
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    94
The following sort of information ends up in ld.dbg (note that the debugging
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    95
output from the link-editor is not considered a 'stable interface' and may
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    96
change in the future):
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    97
4822
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
    98
    debug: file=/builds/tkuthan/ul-wanboot-rebuilt/components/openssl/openssl-default/build/sparcv9-wanboot/libcrypto.a(sparcv9cap.o)  [ ET_REL ]
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
    99
    debug:
4822
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
   100
    debug: symbol table processing; file=/builds/tkuthan/ul-wanboot-rebuilt/components/openssl/openssl-default/build/sparcv9-wanboot/libcrypto.a(sparcv9cap.o)  [ ET_REL ]
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   101
    debug: symbol[1]=sparcv9cap.c
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   102
    ....
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   103
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   104
Now run the following script in Userland:
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   105
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   106
    #!/bin/bash
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   107
 
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   108
    # set to workspace paths:
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   109
    USERLAND=/builds/tkuthan/ul-wanboot-rebuilt
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   110
    ON=/builds/tkuthan/on11u1-wanboot-rti
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   111
 
4822
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
   112
    BUILD=$USERLAND/components/openssl/openssl-default/build/sparcv9-wanboot
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   113
    LD_DBG=$ON/usr/src/psm/stand/boot/sparcv9/sun4/ld.dbg
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   114
 
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   115
    for i in `find $BUILD/crypto $BUILD/ssl -name '*.o'`
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   116
    do
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   117
            f=`basename $i`
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   118
            if grep -q "^debug: file.*\<$f\>" $LD_DBG
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   119
            then
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   120
                    echo $i | sed "s#$BUILD/##"
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   121
            fi
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   122
    done
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   123
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   124
to get the list of required object files.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   125
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   126
Additionally, you can format the list for including to Makefile by:
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   127
    sort | tr '\n' ' ' | fold -s -w74 | sed -e 's/^/    /' -e 's/$/\\/'
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   128
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   129
Linking with wanboot
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   130
----
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   131
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   132
When linking with wanboot please pay attention to following pitfalls.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   133
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   134
Correct openssl header files need to be included. This is done in
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   135
$ON/usr/src/stand/lib/wanboot/Makefile
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   136
Make sure CPPFLAGS point to the right directories.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   137
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   138
EXTREME CAUTION needs to be employed, if WANBOOT GREW IN SIZE because of the
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   139
changes!
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   140
Wanboot is a statically linked standalone binary and it is loaded on a fixed
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   141
address before execution. This address is defined in 
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   142
$ON/usr/src/psm/stand/boot/sparc/common/mapfile:
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   143
2180
bc1340c26305 19789902 pkcs11 engine dumps core when the softtoken is disabled
Ivo Raisr <ivo.raisr@oracle.com>
parents: 2041
diff changeset
   144
	LOAD_SEGMENT text {
bc1340c26305 19789902 pkcs11 engine dumps core when the softtoken is disabled
Ivo Raisr <ivo.raisr@oracle.com>
parents: 2041
diff changeset
   145
		FLAGS = READ EXECUTE;
bc1340c26305 19789902 pkcs11 engine dumps core when the softtoken is disabled
Ivo Raisr <ivo.raisr@oracle.com>
parents: 2041
diff changeset
   146
		VADDR = 0x130000;
bc1340c26305 19789902 pkcs11 engine dumps core when the softtoken is disabled
Ivo Raisr <ivo.raisr@oracle.com>
parents: 2041
diff changeset
   147
		ASSIGN_SECTION {
bc1340c26305 19789902 pkcs11 engine dumps core when the softtoken is disabled
Ivo Raisr <ivo.raisr@oracle.com>
parents: 2041
diff changeset
   148
			TYPE = PROGBITS;
bc1340c26305 19789902 pkcs11 engine dumps core when the softtoken is disabled
Ivo Raisr <ivo.raisr@oracle.com>
parents: 2041
diff changeset
   149
			FLAGS = ALLOC !WRITE;
bc1340c26305 19789902 pkcs11 engine dumps core when the softtoken is disabled
Ivo Raisr <ivo.raisr@oracle.com>
parents: 2041
diff changeset
   150
		};
bc1340c26305 19789902 pkcs11 engine dumps core when the softtoken is disabled
Ivo Raisr <ivo.raisr@oracle.com>
parents: 2041
diff changeset
   151
	};
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   152
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   153
This address (VADDR) NEEDS TO BE GREATER THEN 
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   154
    size of wanboot binary + 0x4000
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   155
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   156
The reason for this is in how wanboot is loaded by OpenBoot Prom:
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   157
1) user initiates boot from network - "boot net"
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   158
2) obp loads wanboot binary at address 0x4000
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   159
3) obp parses ELF header, reads virtual address where to load wanboot to
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   160
4) obp mem-copies .text section to this address
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   161
5) obp copies .data section behind .text
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   162
6) obp starts executing wanboot at entry address
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   163
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   164
If the given address is too small, obp overwrites part of .data with
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   165
instructions from .text in step 4. resulting in .data being corrupted.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   166
Initialized variables get bogus values and failure is inevitable.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   167
This is very hard to troubleshoot.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   168
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   169
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   170
Testing wanboot with new openssl
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   171
----
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   172
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   173
With every upgrade of OpenSSL, it is necessary to make sure wanboot builds and
1911
17096cac036b 18793926 The .annotate section should be removed for wanboot-openssl.o
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 1884
diff changeset
   174
works well with the new bits (post lullaby).
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   175
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   176
Provided you have a freshly built ON workspace, you can link wanboot with new
1911
17096cac036b 18793926 The .annotate section should be removed for wanboot-openssl.o
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 1884
diff changeset
   177
OpenSSL bits as follows:
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   178
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   179
    # copy wanboot-openssl.o to ON build machine
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   180
    cp wanboot-openssl.o /var/tmp/
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   181
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   182
    # prepare to rebuild wanboot
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   183
    cd $ON
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   184
    cd usr/src/psm/stand/boot/sparcv9/sun4
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   185
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   186
    # hack to force a rebuild
1911
17096cac036b 18793926 The .annotate section should be removed for wanboot-openssl.o
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 1884
diff changeset
   187
    touch $ON/build.sparc/usr/src/psm/stand/boot/sparcv9/sun4/wanboot.o
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   188
1911
17096cac036b 18793926 The .annotate section should be removed for wanboot-openssl.o
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 1884
diff changeset
   189
    # modify Makefile and assign the WAN_OPENSSL macro to your binary
17096cac036b 18793926 The .annotate section should be removed for wanboot-openssl.o
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 1884
diff changeset
   190
    # something like
17096cac036b 18793926 The .annotate section should be removed for wanboot-openssl.o
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 1884
diff changeset
   191
    WAN_OPENSSL    = /var/tmp/wanboot-openssl.o
17096cac036b 18793926 The .annotate section should be removed for wanboot-openssl.o
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 1884
diff changeset
   192
17096cac036b 18793926 The .annotate section should be removed for wanboot-openssl.o
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 1884
diff changeset
   193
    # build a wanboot binary
17096cac036b 18793926 The .annotate section should be removed for wanboot-openssl.o
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 1884
diff changeset
   194
    build -i dmake all
763
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   195
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   196
Wanboot should build without warning.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   197
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   198
If there is something like this in the output:
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   199
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   200
    Undefined                       first referenced
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   201
     symbol                             in file
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   202
    CRYPTO_ccm128_setiv                 /var/tmp/wanboot-openssl.o
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   203
    SSL_get_srtp_profiles               /var/tmp/wanboot-openssl.o
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   204
    ssl_parse_clienthello_use_srtp_ext  /var/tmp/wanboot-openssl.o
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   205
    CRYPTO_gcm128_setiv                 /var/tmp/wanboot-openssl.o
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   206
    ...
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   207
    cmac_pkey_meth                      /var/tmp/wanboot-openssl.o
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   208
    ld: fatal: symbol referencing errors. No output written to wanboot
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   209
    *** Error code 1
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   210
    dmake: Fatal error: Command failed for target `wanboot'
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   211
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   212
some additional work has to be done in OpenSSL to either satisfy the function 
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   213
references listed in the linker error message, or to remove the calls to these
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   214
functions.
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   215
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   216
Finally, resulting wanboot binary shall be deployed on some install server and
45da4d38492e 7156086 OpenSSL for wanboot should not be build in a separate directory
Tomas Kuthan <tomas.kuthan@oracle.com>
parents: 745
diff changeset
   217
wanbooting from this server shall be tested.
4370
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   218
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   219
===============
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   220
Common Patches
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   221
===============
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   222
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   223
Common patch files are located in the components/openssl/common/patches dir,
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   224
and they are copied to both FIPS and non-FIPS 'patches' dir as soon as the
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   225
Makefile is parsed.  The Common patch filename has prefix '0',
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   226
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   227
=========================
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   228
Non-FIPS specific Patches
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   229
=========================
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   230
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   231
Non-FIPS specific patch files are located in the
4822
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
   232
components/openssl/openssl-default/patches dir.
4370
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   233
The Non-FIPS specific patch filename has prefix '1',
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   234
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   235
=========================
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   236
FIPS specific Patches
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   237
=========================
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   238
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   239
FIPS specific patch files are located in the
4822
1fb8a14c6702 PSARC/2015/353 OpenSSL 1.0.2
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 4370
diff changeset
   240
components/openssl/openssl-fips-140/patches dir.
4370
7043c27399f1 19375978 Common code between openssl-1.0.1 and openssl-1.0.1-fips-140 should be shared
Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
parents: 2180
diff changeset
   241
The FIPS specific patch filename has prefix '2',