From nobody Mon Jan 8 12:17:56 2024 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4T7tPJ4Z2jz55X9p; Mon, 8 Jan 2024 12:17:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4T7tPJ1x13z56X3; Mon, 8 Jan 2024 12:17:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704716276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4f+o92tEB3v2RUgca0yqpC7hg13LWTPJlWiXsQsERzs=; b=DB7hCPM8MtnEpIQTexOneWFYvbaDbXhqJWp/UGda60JRZGk8I1NmtAfIDGs/lN5q/7CYnJ 62CV23EXMI1xB55q0xbA8+yT59WNQkx5+JvuoU5YUPgaoltyx17HbkO/WPExWH4EoZ1PUo t96I5k/FhT+GvHAc6BN/GPCC5tCM0e+FXxLHV84owyYrQrYe8IGnHBVZURz47auUfscbNc VIxUD7Ya4+rLNzzd3eRe07rlcu8Dc2aVJCjFZXY7lr9nPIkxCm9K2U3VrRFTAPB5MWEwso CUxY2XQ1xKfyBUyEm6Dzw0puBZcQtGGRlZYIdc+Grie5e8obWL3vyhgg1CJqMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704716276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4f+o92tEB3v2RUgca0yqpC7hg13LWTPJlWiXsQsERzs=; b=aRGdpYwKtMEVTGtm5fLnYrB7BitJptLCqP5n8GqYGY6gl2PD5/orKEC0Bzbf7xLenyRvl0 PYO9SgHjaA/V/3ssWt1qtsL00wvrdRyQ8x7nfRmjk9yDbFg28VQczUIHwQUNwrItW8WnhV 0jQ3qkewCP/29cm5DbpL89sstxYpUlHFDgB8uAeQbuDiKVwU3GrkbI/I2fbeIc9LmYg8CP yQDAb30HL0DJNlY5bdBvskrO/IFnehPmiaz8+Kz7IDvaoRkSnhO22/sgQAK8EkibGOUHhQ SumDI5YD2jD/fm4cBsGhy29gBNlMrc7VQCRTKH31S9ShgkKZaYLqRINKKd04bA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1704716276; a=rsa-sha256; cv=none; b=Q0TVicG1sOkgTZLuqi7BAphYRC0n0sH06mZKKgmdqWe3d2bPFL7WqhnCRx8eqqDJMZr4cV whdPh0gtu346vG8kkTivL4ShGNdk2dg3I//kzrP1oNxPbacd8ogxeQXrMtdptJyDfA0HRj O5PcOrnrJH+4SFBLbCtGKCeUf1i+WvAfVIvSHdA0kJnLhYjnO/2p/w9ygR4mXo2Sba9ahY 7X6jfJTnCdIanyaBf6AcDsV9GPWImi3RRbjTPvDxGHomdY95lhU8eEjky07b4yD2wSwkKs PjEFB/9tZdGM2YY0D1Yabpp7dGwaOsZtb1cbANDbu9DP8LYUZb0ka3W6awEprg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4T7tPJ12p0z16Mm; Mon, 8 Jan 2024 12:17:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 408CHuJf082597; Mon, 8 Jan 2024 12:17:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 408CHuSa082594; Mon, 8 Jan 2024 12:17:56 GMT (envelope-from git) Date: Mon, 8 Jan 2024 12:17:56 GMT Message-Id: <202401081217.408CHuSa082594@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Gleb Popov Subject: git: e94d07c58064 - main - security/tpm2-pkcs11: New port List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: arrowd X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e94d07c580641ab63b7103ab92ded89042941346 Auto-Submitted: auto-generated The branch main has been updated by arrowd: URL: https://cgit.FreeBSD.org/ports/commit/?id=e94d07c580641ab63b7103ab92ded89042941346 commit e94d07c580641ab63b7103ab92ded89042941346 Author: Gleb Popov AuthorDate: 2024-01-07 19:12:42 +0000 Commit: Gleb Popov CommitDate: 2024-01-08 12:17:39 +0000 security/tpm2-pkcs11: New port Sponsored by: Serenity Cybersecurity, LLC --- security/Makefile | 1 + security/tpm2-pkcs11/Makefile | 29 ++++++++++++++++++++++++ security/tpm2-pkcs11/distinfo | 3 +++ security/tpm2-pkcs11/files/patch-src_lib_db.c | 11 +++++++++ security/tpm2-pkcs11/files/patch-src_lib_twist.c | 10 ++++++++ security/tpm2-pkcs11/pkg-descr | 3 +++ security/tpm2-pkcs11/pkg-plist | 4 ++++ 7 files changed, 61 insertions(+) diff --git a/security/Makefile b/security/Makefile index 24e5ef2f8ead..ceb39475fa1b 100644 --- a/security/Makefile +++ b/security/Makefile @@ -1327,6 +1327,7 @@ SUBDIR += tpm-quote-tools SUBDIR += tpm-tools SUBDIR += tpm2-abrmd + SUBDIR += tpm2-pkcs11 SUBDIR += tpm2-tools SUBDIR += tpm2-tss SUBDIR += transcrypt diff --git a/security/tpm2-pkcs11/Makefile b/security/tpm2-pkcs11/Makefile new file mode 100644 index 000000000000..56d347a40460 --- /dev/null +++ b/security/tpm2-pkcs11/Makefile @@ -0,0 +1,29 @@ +PORTNAME= tpm2-pkcs11 +PORTVERSION= 1.9.0 +CATEGORIES= security +MASTER_SITES= https://github.com/tpm2-software/tpm2-pkcs11/releases/download/${PORTVERSION}/ + +MAINTAINER= arrowd@FreeBSD.org +COMMENT= PKCS\#11 interface for TPM2 hardware +WWW= https://tpm2-software.github.io/software/ + +LICENSE= BSD2CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE + +LIB_DEPENDS= libyaml.so:textproc/libyaml \ + libtss2-esys.so:security/tpm2-tss + +USES= libtool pkgconfig sqlite:3 ssl + +GNU_CONFIGURE= yes +INSTALL_TARGET= install-strip +TEST_TARGET= check-TESTS + +OPTIONS_DEFINE= TEST + +TEST_USES= python:3.9+ +TEST_CONFIGURE_ENABLE= ptool-checks unit +TEST_LIB_DEPENDS= libcmocka.so:sysutils/cmocka +TEST_RUN_DEPENDS= dbus-run-session:devel/dbus + +.include diff --git a/security/tpm2-pkcs11/distinfo b/security/tpm2-pkcs11/distinfo new file mode 100644 index 000000000000..1ca135b2ffc3 --- /dev/null +++ b/security/tpm2-pkcs11/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1704652212 +SHA256 (tpm2-pkcs11-1.9.0.tar.gz) = 35bf06c30cfa76fc0eba2c5f503cf7dd0d34a66afb2d292fee896b90362f633b +SIZE (tpm2-pkcs11-1.9.0.tar.gz) = 1396590 diff --git a/security/tpm2-pkcs11/files/patch-src_lib_db.c b/security/tpm2-pkcs11/files/patch-src_lib_db.c new file mode 100644 index 000000000000..1dafaa2e68ba --- /dev/null +++ b/security/tpm2-pkcs11/files/patch-src_lib_db.c @@ -0,0 +1,11 @@ +--- src/lib/db.c.orig 2023-01-20 15:32:09 UTC ++++ src/lib/db.c +@@ -12,8 +12,6 @@ + #include + #include + +-#include +- + #include + #include + #include diff --git a/security/tpm2-pkcs11/files/patch-src_lib_twist.c b/security/tpm2-pkcs11/files/patch-src_lib_twist.c new file mode 100644 index 000000000000..382fc6c85f60 --- /dev/null +++ b/security/tpm2-pkcs11/files/patch-src_lib_twist.c @@ -0,0 +1,10 @@ +--- src/lib/twist.c.orig 2021-09-29 17:04:30 UTC ++++ src/lib/twist.c +@@ -2,7 +2,6 @@ + + #include + +-#include + #include + #include + #include diff --git a/security/tpm2-pkcs11/pkg-descr b/security/tpm2-pkcs11/pkg-descr new file mode 100644 index 000000000000..e8e4f820f83d --- /dev/null +++ b/security/tpm2-pkcs11/pkg-descr @@ -0,0 +1,3 @@ +PKCS #11 is a Public-Key Cryptography Standard that defines a standard method to +access cryptographic services from tokens/devices. This package allows to use +a TPM2 device as the cryptographic token. diff --git a/security/tpm2-pkcs11/pkg-plist b/security/tpm2-pkcs11/pkg-plist new file mode 100644 index 000000000000..102440d169b2 --- /dev/null +++ b/security/tpm2-pkcs11/pkg-plist @@ -0,0 +1,4 @@ +lib/libtpm2_pkcs11.so +lib/libtpm2_pkcs11.so.0 +lib/libtpm2_pkcs11.so.0.0.0 +libdata/pkgconfig/tpm2-pkcs11.pc