You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
David Acker has patched socat to add OpenSSL FIPS.See http://oss-institute.org/fips-faq.html andhttp://linuxdevices.com/news/NS4742716157.html for more information.
The patch that is integrated into socat 1.5 does the following:
Add support for LDFLAGS in Makefile. LDFLAGS can be specified on theconfigure command line and then will be carried over into the make.
Add fips support. Requires OpenSSL 0.9.7j-fips-dev fromhttp://www.openssl.org/source/OpenSSL-fips-1.0.tar.gz built with fipssupport turned on. use ./Configure fips [os-arc], for example./Configure fips linux-pentium
The LDFLAGS is needed to point a build against a librarylocated in a non-standard location. For example, if you download andbuild openssl manually, it gets installed in /usr/local/ssl by default.
The FIPS support patches involve adding an option to enable/disable fipsin configure (enabled by default), checking the system for FIPS supportduring configure, and then adding a fips option to socats openssl addressto turn on fips mode. The openssl binary uses an environment variable instead of a command line flag.FIPS mode requires both a compile time flag of OPENSSL_FIPS and aruntime call of FIPS_mode_set(1). Fips mode requires building with the fipsld script provided by OpenSSL. FIPS tracks the pid of the process that initializes things so after a fork, the child must reinitialize. When the ssl code detects a forks occur and if FIPS mode was enabled, it reinitializes FIPS by disabling and then enabling it again.
To produce Davids enviroment, do the following:To build openssldownload OpenSSL 0.9.7j-fips-dev fromhttp://www.openssl.org/source/OpenSSL-fips-1.0.tar.gztar xzf OpenSSL-fips-1.0.tar.gzcd openssl./Configure fips linux-pentiummakemake test(become root)make installThis leaves an install in /usr/local/ssl
To build socat:setup directory with socat 1.5 or higher.cd socat-1.5.0.0./configure CPPFLAGS=-I/usr/local/ssl/include/ LDFLAGS=-L/usr/local/ssl/lib/ FIPSLD=/usr/local/ssl/bin/fipsldmake(become root)make install
To run tests we make sure the new openssl is used:
export PATH=/usr/local/ssl/bin:$PATH./test.sh fips
There are two tests in test.sh that depend on fips:
OPENSSL_FIPS_BOTHAUTH performs a SSL client to server connection withcertificate based authentication in both directions. If it works FIPS modeseems to be ok.
OPENSSL_FIPS_SECURITY generates a certificaet/key pair without fips support. Itthen tries a SSL connection in "normal" mode which is expected to work. In thesecond phase it uses fips mode with these credentials which is expected tofail. If so, the test succeeded.
|