svn commit: r323634 - in head/security/tpm-tools: . files
Hiroki Sato
hrs at FreeBSD.org
Thu Jul 25 10:49:56 UTC 2013
Author: hrs
Date: Thu Jul 25 10:49:53 2013
New Revision: 323634
URL: http://svnweb.freebsd.org/changeset/ports/323634
Log:
- Fix build on -CURRENT.
- Take maintainership.
Added:
head/security/tpm-tools/files/patch-src-data_mgmt-data_protect.c (contents, props changed)
head/security/tpm-tools/files/patch-src-tpm_mgmt-tpm_takeownership.c (contents, props changed)
Modified:
head/security/tpm-tools/Makefile
head/security/tpm-tools/files/patch-lib-tpm_utils.c
head/security/tpm-tools/files/patch-src-tpm_mgmt-tpm_present.c
head/security/tpm-tools/pkg-plist (contents, props changed)
Modified: head/security/tpm-tools/Makefile
==============================================================================
--- head/security/tpm-tools/Makefile Thu Jul 25 10:24:06 2013 (r323633)
+++ head/security/tpm-tools/Makefile Thu Jul 25 10:49:53 2013 (r323634)
@@ -1,9 +1,5 @@
-# New ports collection makefile for: tpm-tools
-# Date created: 18 Sep 2007
-# Whom: Sebastian Schuetz <sschuetz at fhm.edu>
-#
+# Created by: Sebastian Schuetz <sschuetz at fhm.edu>
# $FreeBSD$
-#
PORTNAME= tpm-tools
PORTVERSION= 1.3.5
@@ -11,27 +7,26 @@ PORTREVISION= 1
CATEGORIES= security
MASTER_SITES= SF/trousers/${PORTNAME}/${PORTVERSION}
-MAINTAINER= ports at FreeBSD.org
+MAINTAINER= hrs at FreeBSD.org
COMMENT= Provides a basic set of TPM tools
-LIB_DEPENDS= tspi.2:${PORTSDIR}/security/trousers
+LICENSE= CPL
+LICENSE_NAME= Common Public License
+LICENSE_FILE= ${WRKSRC}/LICENSE
+LICENSE_PERMS= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
+
+LIB_DEPENDS= tspi:${PORTSDIR}/security/trousers
BUILD_DEPENDS= pkcsconf:${PORTSDIR}/security/opencryptoki
-RUN_DEPENDS= ${LOCALBASE}/sbin/tcsd:${PORTSDIR}/security/trousers
-RUN_DEPENDS+= ${LOCALBASE}/lib/pkcs11/libopencryptoki.so:${PORTSDIR}/security/opencryptoki
+RUN_DEPENDS= ${LOCALBASE}/sbin/tcsd:${PORTSDIR}/security/trousers \
+ ${LOCALBASE}/lib/pkcs11/libopencryptoki.so:${PORTSDIR}/security/opencryptoki
-USE_GMAKE= YES
-USES= gettext iconv
+USES= gettext gmake iconv
USE_LDCONFIG= YES
USE_AUTOTOOLS= autoconf
GNU_CONFIGURE= YES
LDFLAGS+= -L${LOCALBASE}/lib -lintl -liconv
MAKE_JOBS_SAFE= YES
-LICENSE= CPL
-LICENSE_NAME= Common Public License
-LICENSE_FILE= ${WRKSRC}/LICENSE
-LICENSE_PERMS= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
-
MAN1= tpm_sealdata.1 tpm_version.1 \
tpmtoken_import.1 tpmtoken_init.1 tpmtoken_objects.1 \
tpmtoken_protect.1 tpmtoken_setpasswd.1
Modified: head/security/tpm-tools/files/patch-lib-tpm_utils.c
==============================================================================
--- head/security/tpm-tools/files/patch-lib-tpm_utils.c Thu Jul 25 10:24:06 2013 (r323633)
+++ head/security/tpm-tools/files/patch-lib-tpm_utils.c Thu Jul 25 10:49:53 2013 (r323634)
@@ -1,5 +1,5 @@
--- lib/tpm_utils.c.orig 2010-02-02 02:17:23.000000000 +0900
-+++ lib/tpm_utils.c 2010-10-25 01:55:31.065559348 +0900
++++ lib/tpm_utils.c 2013-07-24 22:00:15.000000000 +0900
@@ -55,6 +55,7 @@
CmdHelpFunction tCmdHelp = ( a_tCmdHelpFunction ) ? a_tCmdHelpFunction
: logCmdHelp;
@@ -8,7 +8,7 @@
char szShortOpts[strlen( pszGenShortOpts )
+ ( ( a_pszShortOpts == NULL ) ? 0 : strlen( a_pszShortOpts ) )
+ 1];
-@@ -64,6 +65,26 @@
+@@ -64,12 +65,36 @@
int iOpt;
int rc;
@@ -35,3 +35,13 @@
strcpy( szShortOpts, pszGenShortOpts);
if ( a_pszShortOpts )
+ strcat( szShortOpts, a_pszShortOpts );
+
++#ifdef __GCC
+ memset( sLongOpts, 0, sizeof( sLongOpts ) );
++#else
++ memset( sLongOpts, 0, (iNumGenLongOpts + a_iNumOpts + 1) * sizeof(struct option));
++#endif
+ memcpy( sLongOpts, sGenLongOpts, sizeof( sGenLongOpts ) );
+ if ( a_sLongOpts ) {
+ memcpy( sLongOpts + iNumGenLongOpts,
Added: head/security/tpm-tools/files/patch-src-data_mgmt-data_protect.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/security/tpm-tools/files/patch-src-data_mgmt-data_protect.c Thu Jul 25 10:49:53 2013 (r323634)
@@ -0,0 +1,10 @@
+--- src/data_mgmt/data_protect.c.orig 2013-07-24 22:04:32.000000000 +0900
++++ src/data_mgmt/data_protect.c 2013-07-24 22:04:59.000000000 +0900
+@@ -425,6 +425,7 @@
+ CK_OBJECT_HANDLE hObject;
+ CK_MECHANISM tMechanism = { CKM_AES_ECB, NULL, 0 };
+
++ memset(&hSession, 0, sizeof(hSession));
+ // Set up i18n
+ initIntlSys( );
+
Modified: head/security/tpm-tools/files/patch-src-tpm_mgmt-tpm_present.c
==============================================================================
--- head/security/tpm-tools/files/patch-src-tpm_mgmt-tpm_present.c Thu Jul 25 10:24:06 2013 (r323633)
+++ head/security/tpm-tools/files/patch-src-tpm_mgmt-tpm_present.c Thu Jul 25 10:49:53 2013 (r323634)
@@ -1,6 +1,6 @@
--- src/tpm_mgmt/tpm_present.c.orig 2009-08-20 23:46:31.000000000 +0900
-+++ src/tpm_mgmt/tpm_present.c 2010-10-25 01:55:31.071556276 +0900
-@@ -168,7 +168,7 @@
++++ src/tpm_mgmt/tpm_present.c 2013-07-24 22:02:07.000000000 +0900
+@@ -168,9 +168,10 @@
TSS_HPOLICY hTpmPolicy;
char *pwd = NULL;
int pswd_len;
@@ -8,4 +8,7 @@
+ char rsp[6];
int scanCount;
++ memset(&hTpmPolicy, 0, sizeof(hTpmPolicy));
//get status w/o owner auth (FAILS 1.1, should PASS 1.2)
+ if (tpmGetStatus(hTpm, flags[cmdEnable].property, &bCmd) !=
+ TSS_SUCCESS
Added: head/security/tpm-tools/files/patch-src-tpm_mgmt-tpm_takeownership.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/security/tpm-tools/files/patch-src-tpm_mgmt-tpm_takeownership.c Thu Jul 25 10:49:53 2013 (r323634)
@@ -0,0 +1,10 @@
+--- src/tpm_mgmt/tpm_takeownership.c.orig 2013-07-24 22:02:59.000000000 +0900
++++ src/tpm_mgmt/tpm_takeownership.c 2013-07-24 22:03:53.000000000 +0900
+@@ -77,6 +77,7 @@
+ {"srk-well-known", no_argument, NULL, 'z'},
+ };
+
++ memset(&hSrk, 0, sizeof(hSrk));
+ initIntlSys();
+
+ if (genericOptHandler
Modified: head/security/tpm-tools/pkg-plist
==============================================================================
--- head/security/tpm-tools/pkg-plist Thu Jul 25 10:24:06 2013 (r323633)
+++ head/security/tpm-tools/pkg-plist Thu Jul 25 10:49:53 2013 (r323634)
@@ -1,3 +1,4 @@
+ at comment $FreeBSD$
bin/tpm_sealdata
bin/tpm_unsealdata
bin/tpmtoken_import
More information about the svn-ports-head
mailing list