Commit Graph

900 Commits

Author SHA1 Message Date
Stefan Berger
61ee460356 Version bump to 0.6.0
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2015-12-07 19:14:30 -05:00
Stefan Berger
769fb37a25 build: Simplify the check for -fstack-protector-strong
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2015-10-26 11:28:25 -04:00
Stefan Berger
3251bfba69 build: Check for -fstack-protector-strong before using it
Import AX_CHECK_COMPILE_FLAG to help check for compiler option
-fstack-protector-strong.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2015-10-26 09:50:46 -04:00
Stefan Berger
f79e8301f4 rpmbuild: Fix dependencies for OpenSSL
Fix the Requires and BuildRequires dependencies for OpenSSL build.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2015-07-16 12:39:19 -04:00
Stefan Berger
acbfe13344 rpmbuild: Add virtual provide libtpms-<crypto subsystem>
Add a virtual provide libtpms-freebl or libtpms-openssl to
indicate which crypto library libtpms is using.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2015-07-16 12:33:34 -04:00
Stefan Berger
384bf2e2a7 build: Disable volatile storage debug for debug build
Disable the volatile storage debug for a debug build since this
causes the volatile state file to be written and this changes
the behavior upon a restart of the TPM. This may cause the TPM to
not work correctly then.

Print out some more build parameters.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2015-05-01 21:15:46 -04:00
Stefan Berger
40e13951a9 build: do not set -D_FORTIFY_SOURCE=2 when -O0 is set or -O is missing
-D_FORTIFY_SOURCE needs optimization, so we do not set it if -O0 is
set or -O is missing.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2015-05-01 12:07:21 -04:00
Stefan Berger
4461f8a74e Add LT_INIT to configure.ac
Add missing LT_INIT to configure.ac.
2015-04-29 10:29:01 -04:00
Stefan Berger
793852f1a5 Add relro and now to hardening cflags, if available
Check ld for availability of relro and now flags and add them to the
hardening cflags if available.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2015-02-03 14:06:46 -05:00
Stefan Berger
bfb1c7739a Use hardening CFLAGS
Add hardening CFLAGS -D_FORTIFY_SOURCE=2 and stack protector.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2015-02-02 06:58:59 -05:00
root
7e973dd60c Remove 'missing' file since it will be added by bootstrap.sh 2014-12-18 10:52:06 -05:00
Stefan Berger
893d9b9528 Check for missing freebl headers and freebl lib
Add a check for missing freebl header blapi.h (missing in Ubuntu)
and missing freebl static library that provides AES_CreateContext.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-12-18 10:44:08 -05:00
Stefan Berger
03d25ba067 Make compileable on Ubuntu and docu for Ubuntu
Ubuntu has different package names that need to be documented separtely.
Ubuntu requires exec_prefix in the libtpms.pc file for pkg-config to work.
Rework some of the configure.ac parts.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-12-15 22:10:07 -05:00
Stefan Berger
9acd053d6d Also request nss-softok-freebl-static on Fedora. 2014-10-16 13:12:59 -04:00
Stefan Berger
2e31126832 Do not package libtpms.la. 2014-10-16 13:12:01 -04:00
Stefan Berger
35ff4b3cba adding some more files to be ignored 2014-07-23 14:37:15 -04:00
Stefan Berger
327c8be0af Some fixes to the spm spec
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-07-14 17:22:14 -04:00
Stefan Berger
e04b1231ec Fix public header files for c++
Fix the public header files for c++ usage.
2014-07-14 17:22:14 -04:00
Stefan Berger
fd8aa8c36f Catch missing nss-devel and nspr-devel dependencies
Catch nspr-config and nss-config dependencies in te configure script.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-07-03 17:38:34 -04:00
Stefan Berger
d987a4b844 Fix a memory leak in the TPMLibrary interface
Fix a memory leak in TPMLIB_Terminate.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2014-07-02 21:56:58 -04:00
Stefan Berger
052581174f Adapt spec so it can also be built on RHEL6.
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-07-02 07:37:05 -04:00
Stefan Berger
ff5fac41e4 Create version 0.5.2
Set the version of the library to 0.5.2.
Synchronize the rpm spec with the one used in Fedora and set the release
version to 1.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-06-30 15:04:15 -04:00
Stefan Berger
f1cb52002c Remove tpm_library.h since it is generated from tpm_library.h.in
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-06-30 15:04:15 -04:00
Stefan Berger
9b392bf3fb Fix support for ARM64
Fix support for ARM64 by testing for whether __aarch64__ is defined.

Also see http://sourceforge.net/p/predef/wiki/Architectures for the
gcc preprocessor defines.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-06-30 15:04:15 -04:00
Stefan Berger
b886be8010 Clear NVRAM area before deleting it
Clear the NVRAM area before deleting it.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-06-30 15:04:15 -04:00
Stefan Berger
7ccf4d9711 Update the maintainers in the README.
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-06-30 15:04:15 -04:00
Stefan Berger
3428922eeb Remove config.h.in
Remove config.h.in and create it in bootstrap.h using autoheader.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-06-30 15:04:15 -04:00
Stefan Berger
017c810393 Use boostrap.sh to build rpm on Fedora machines
Use bootstrap.sh before running configure when building an rpm.
Reorder the tools in bootstrap.sh to avoid error messages.

Rename configure.in to configure.ac to quite down more recent autotools.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Signed-off-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
2014-01-21 14:21:36 -06:00
Stefan Berger
ea5d455718 Sync libtpms.spec.in with Fedora repository
Sync the libtpms.spec.in with the content in the Fedora repository.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Signed-off-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
2014-01-21 14:21:36 -06:00
Corey Bryant
f50ebe844a Maintainer change
Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
Acked-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
2014-01-16 14:35:02 -05:00
Corey Bryant
ddc5845969 Change permissions of bootstrap.sh to 755
Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
Acked-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-01-13 20:49:41 -05:00
Corey Bryant
087cd91991 Ignore patch files in gitignore
Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
Acked-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-01-13 20:49:32 -05:00
Corey Bryant
98f0d19ab6 Remove files from index for gitignore
Remove files from the git index so that gitignore
can actually ignore them.

Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
Acked-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-01-13 17:18:48 -05:00
Stefan Berger
38e1c44281 Build dll on cygwin and build OpenSSL build cleanup
Fix the build process to build a dll on cygwin and remove
freebl specific shell calls when building for OpenSSL.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2014-01-13 16:41:06 -05:00
Stefan Berger
9cb84e249c Add .gitignore
Add .gitignore file to ignore certain files in the repository.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2014-01-13 16:40:01 -05:00
Stefan Berger
54c5659647 Remove unnecessary build files from repository
Remove unnecessary files in the repository and add boostrap.sh to create the
configure file and other files we are removing here. Users have to run
bootstrap.sh to have those files created in their build environment.
Update the INSTALL instructions.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2014-01-13 16:39:13 -05:00
Stefan Berger
55c0004468 Fix compile error on cygwin
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2014-01-08 11:44:01 -05:00
Stefan Berger
30a95c3c82 Make libtpms compileable with OpenSSL
Implement missing base64 decoder support when using OpenSSL library.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2014-01-08 11:43:51 -05:00
Stefan Berger
b888045f4f Add a test case for the TPMLIB_DecodeBlob API
Add a test case testing the TPMLIB_DecodeBlob function.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2014-01-08 11:43:37 -05:00
Stefan Berger
ba95ec6290 Address coverity warnings
Fixed typing errors.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2014-01-07 15:18:02 -05:00
Stefan Berger
337717ab32 Address coverity warnings
Handle function return codes.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2014-01-07 15:16:54 -05:00
Stefan Berger
ebcefd0548 Rename function TPM_SBuffer_Set to TPM_Sbuffer_Set
Minor typo in function name

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2013-12-20 16:41:39 -05:00
Stefan Berger
93a6459a8e Fix spacing in tpm_audit.c
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2013-12-20 16:40:36 -05:00
Stefan Berger
f1eb496720 A fix related to the physical presence flag
The physical presence flag should not be used if CMD enable is false

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2013-12-20 16:40:20 -05:00
Stefan Berger
4e3500d5d5 Fix a typo in tpm_crypto.c
Trivial typo in comment

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Acked-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2013-12-20 16:39:59 -05:00
Corey Bryant
a2b246e283 Change the mailing list
Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
Acked-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2013-12-20 10:00:38 -05:00
Corey Bryant
edd8da864d Update build directions in INSTALL file
Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
Acked-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2013-10-31 16:39:13 -04:00
Corey Bryant
a5a3e1cb99 Add mailing list and maintainers to README
Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
Acked-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2013-10-31 16:38:59 -04:00
Corey Bryant
acc0ddfc79 Add CREDITS file
Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
Acked-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2013-10-31 16:37:33 -04:00
Corey Bryant
a0098eda2d Initial import of project
This is the initial import of the libtpms library.  The libtpms library
provides software emulation of a Trusted Platform Module (TPM).  It is
intended to be used by applications when a hardware TPM is not adequate.
For example, a hypervisor can use libtpms to emulate an independent TPM
for each of it's virtual machine guests.  The library provides a high-
level API for developers to integrate the emulated TPM support into
their application.

The code was originally written by Kenneth Goldman <kgoldman@us.ibm.com>
and Stefan Berger <stefanb@us.ibm.com>.

The code is licensed under the Modified BSD License.

Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com>
2013-10-31 15:33:22 -05:00