71 Commits

Author SHA1 Message Date
Yi Zhao fea6a37625 recipes: update SRC_URI branch and protocols
Update SRC_URIs using git to include branch=master if no branch is set
and also to use protocol=https for github urls.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-11-15 09:56:02 +08:00
Yi Zhao 8226df83a6 tpm2-tools: upgrade 4.1.3 -> 4.3.2
* Drop backported CVE patch.
* License-Update: Add Copyrights and move it to doc directory.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-11-12 16:52:32 +08:00
Yi Zhao 1d1bd5934b tpm2-abrmd: upgrade 2.3.2 -> 2.3.3
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-11-12 16:52:32 +08:00
Yi Zhao d3a025a3d5 tpm2-tss: backport fixes for openssl 3.0
Backport 3 patches from master branch for openssl 3.0:
https://github.com/tpm2-software/tpm2-tss/commit/73d25d6834ad362f9a9a907cb78452deaa336ec0
https://github.com/tpm2-software/tpm2-tss/commit/362fda1daa398da2944e76013c215500761d46a5
https://github.com/tpm2-software/tpm2-tss/commit/e5bb5fb9f070c619415160f8889c372b769431b8

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-11-12 16:52:32 +08:00
Yi Zhao 59a7c40fe7 tpm2-tss: upgrade 2.3.3 -> 2.4.6
Add PACKAGECONFIG[fapi] to enable/disable FAPI.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-11-12 16:52:32 +08:00
Yi Zhao 4caca5b780 tpm2-tools: fix build with openssl 3.0
Backport a patch to disable '-Werror' to fix build error until upstream
addresses openssl 3.0 compatibility issue.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-10-21 15:57:54 +08:00
Yi Zhao 9f03a89db8 layer.conf: add honister to LAYERSERIES_COMPAT
Drop other releases since they are not compatible anymore.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-08-09 18:51:13 +08:00
Yi Zhao 4042043742 meta-secure-core: Convert to new override syntax
Converting the metadata to use ":" as the override character instead of "_".

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-08-09 18:51:13 +08:00
Yi Zhao 0e8603b1ea tpm2-tools: fix CVE-2021-3565
CVE-2021-3565:
A flaw was found in tpm2-tools in versions before 5.1.1 and before
4.3.2. tpm2_import used a fixed AES key for the inner wrapper,
potentially allowing a MITM attacker to unwrap the inner portion and
reveal the key being imported. The highest threat from this
vulnerability is to data confidentiality.

Reference:
https://nvd.nist.gov/vuln/detail/CVE-2021-3565

Patch from:
https://github.com/tpm2-software/tpm2-tools/commit/c069e4f179d5e6653a84fb236816c375dca82515

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-07-07 14:26:45 +08:00
Yi Zhao 6cbe3df2a2 layer.conf: add hardknott to LAYERSERIES_COMPAT
Remove other releases since they are not compatible anymore.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-04-21 12:57:22 +08:00
Yi Zhao 477e4a812b meta-tpm2/conf/layer.conf: remove meta-python2 from LAYERDEPENDS
Get rid of meta-python2 dependency because python2 is EOL.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-03-03 14:43:31 +08:00
Yi Zhao bb0597dddb python-beautifulsoup4: remove recipe
Remove the recipe because no one depends on it anymore.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-03-03 14:43:31 +08:00
Yi Zhao 1eeb4a31e3 tpm2simulator-native: remove recipe
Remove the recipe because it is unmaintained and its dependency python2
is EOL. Users can use ibmswtpm2 in meta-security as a replacement.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-03-03 14:43:31 +08:00
Yi Zhao 032e3b7740 tpm2simulator-native: fix native inheritance order
Classes native/nativesdk must be inherited last to prevent unexpected
behaviour.

Fixes QA warning:
QA Issue: tpm2simulator-native: native/nativesdk class is not inherited
last, this can result in unexpected behaviour. Classes inherited after
native/nativesdk: cmake.bbclass lib_package.bbclass python-dir.bbclass
pythonnative.bbclass [native-last]

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2021-02-04 18:07:53 +08:00
Bartłomiej Burdukiewicz 50a847007d conf/layer.conf: Add gatesgarth to LAYERSERIES_COMPAT
Signed-off-by: Bartłomiej Burdukiewicz <bartlomiej.burdukiewicz@gmail.com>
2020-12-09 09:17:12 +08:00
Mingli Yu 6c64d71334 tpm2-abrmd: Remove obsolete setting regarding the Standard Output
The Standard output type "syslog" is obsolete, causing a warning since systemd
version 246 [1].

Please consider using "journal" or "journal+console"

[1] https://github.com/systemd/systemd/blob/master/NEWS#L202

Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
2020-09-23 12:57:44 +08:00
Yi Zhao 960cffb107 tpm2-tools: upgrade 4.1.1 -> 4.1.3
* License-Update: BSD -> BSD-3-Clause
* Add a patch to switch to python3 in test scripts

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2020-07-22 17:30:26 +08:00
Yi Zhao 6830825188 tpm2-tss: upgrade 2.3.2 -> 2.3.3
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2020-07-22 17:30:26 +08:00
Yi Zhao d560bafc49 tpm2-abrmd: upgrade 2.3.0 -> 2.3.2
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2020-07-22 17:30:26 +08:00
Yi Zhao 3801a7e716 tpm2-abrmd: rdepends on libtss2-tcti-device and libtss2-tcti-mssim
The tpm2-abrmd daemon needs TCTI library for TPM2 device or simulator.
But the libtss2-tcti-device and libtss2-tcti-mssim packages are not
installed by default which causes the tpm2-abrmd daemon startup failure:

systemd[1]: Starting TPM2 Access Broker and Resource Management Daemon...
tpm2-abrmd[459]: tcti_conf before: "device:/dev/tpm0"
tpm2-abrmd[459]: tcti_conf after: "device:/dev/tpm0"
tpm2-abrmd[459]: ERROR:tcti:../tpm2-tss-2.3.2/src/tss2-tcti/tctildr.c:418:Tss2_TctiLdr_Initialize_Ex() Failed to instantiate TCTI
tpm2-abrmd[459]: init_thread_func: failed to create TCTI with conf "device:/dev/tpm0"
tpm2-abrmd[459]: g_bus_unown_name: assertion 'owner_id > 0' failed

Add libtss2-tcti-device and libtss2-tcti-mssim to runtime dependencies.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2020-07-15 16:49:12 +08:00
Changqing Li c61b8157fb tpm2-tss: support usrmerge
fix do_package_qa error:
ERROR: QA Issue: tpm2-tss package is not obeying usrmerge distro feature. /lib should be relocated to /usr. [usrmerge]

Signed-off-by: Changqing Li <changqing.li@windriver.com>
2020-07-02 22:16:43 +08:00
richard 3590e302df update tpm2-tools_3.2.1 -> tpm2-tools_4.1.1.bb, tpm2-abrmd_2.0.3 -> tpm2-abrmd_2.3.0, tpm2-tss_2.2.3.bb -> tpm2-tss_2.3.2.bb 2020-06-27 19:01:35 +08:00
Christophe Priouzeau ac1ec689f2 conf/layer.conf: Add dunfell to LAYERSERIES_COMPAT
Signed-off-by: Christophe Priouzeau <christophe.priouzeau@st.com>
2020-05-27 08:22:24 +08:00
Yi Zhao f2d06cda8d meta-tpm2: add dependency on meta-python2
Fixes:
ERROR: ParseError at
/buildarea/poky/meta-secure-core/meta-tpm2/recipes-devtools/python/python-beautifulsoup4_4.4.1.bb:19:
Could not inherit file classes/setuptools.bbclass

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2020-03-19 10:47:24 +08:00
Yi Zhao 6faa083706 tpm2-tools: only support python3 in test scripts
The python2 is removed from oe-core and there is no python symblic link
by default which will cause an error when running test scripts:

$ ./test_tpm2_activecredential.sh: line 66: python: command not found

So drop python2 support and only keep python3.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2020-03-13 20:29:08 +08:00
Yi Zhao b0d0273ae2 tpm2-tools: fix yaml.load warning in test scripts
The yaml.load(f) is deprecated since pyyaml 5.1.
Use yaml.load(f, Loader=yaml.BaseLoader) instead of it.
See https://github.com/yaml/pyyaml/wiki/PyYAML-yaml.load(input)-Deprecation

Fixes warning:
YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated,
as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2020-03-13 20:29:08 +08:00
Yi Zhao 7db0fc79df tpm2simulator-native: update to latest git revision
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2020-03-10 10:22:02 +08:00
Yi Zhao 1989109180 tpm2-tools: upgrade 3.2.0 -> 3.2.1
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2020-03-10 10:22:02 +08:00
muvarov e3678e964c conf/layer.conf: Add zeus to LAYERSERIES_COMPAT (#121)
Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2019-11-01 08:39:17 +08:00
Dmitry Eremin-Solenikov 99ec1bedbb meta-tpm2: tpm2-tools: update to version 3.2.0
Signed-off-by: Dmitry Eremin-Solenikov <dmitry_eremin-solenikov@mentor.com>
2019-09-04 12:01:45 +03:00
Dmitry Eremin-Solenikov fe4f5b1122 meta-tpm2: tpm2-tss: update to version 2.2.3
Signed-off-by: Dmitry Eremin-Solenikov <dmitry_eremin-solenikov@mentor.com>
2019-09-04 12:01:45 +03:00
Yi Zhao 8d1b7c2a29 meta-secure-core: add linux-yocto-dev bbappend
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2019-08-13 20:53:14 +08:00
Yi Zhao b0a4ae0fe3 linux-yocto: upgrade bbappend from 4.% to 5.%
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2019-08-13 20:53:14 +08:00
Mingli Yu a32ad2f61d tpm2-abrmd: fix do_compile error
After commit [5ef547b autoconf-archive: update to 2019.01.06]
applied in oe-core, there comes below error
when build tpm2-abrmd:
| NOTE: make -j 48
| Makefile:4381: *** missing separator.  Stop.

So backport a patch from tpm2-abrmd upstream to fix
this failure.

Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
2019-07-24 12:07:13 +08:00
Mingli Yu 075c5e687e tpm2-tss: fix do_compile error
After commit [5ef547b autoconf-archive: update to 2019.01.06]
applied in oe-core, there comes below error
when build tpm2-tss:
| NOTE: make -j 48
| Makefile:14636: *** missing separator.  Stop.

So backport a patch from tpm2-tss upstream to fix
this failure.

Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
2019-07-23 17:59:57 +08:00
Yi Zhao a2688eb342 conf/layer.conf: Add warrior to LAYERSERIES_COMPAT
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
2019-04-23 15:43:10 +08:00
Luca Boccassi 8dc5057161 Bump tpm2-abrmd from 2.0.1 to 2.0.3 to fix build with musl
Several bug fixes were merged in 2.0.1 and 2.0.3, including the
following PRs that fix building tpm2-abrmd with the musl C library:

https://github.com/tpm2-software/tpm2-abrmd/pull/502
https://github.com/tpm2-software/tpm2-abrmd/pull/503

Signed-off-by: Luca Boccassi <luca.boccassi@microsoft.com>
2019-02-26 22:00:05 +08:00
Hongxu Jia c1a543fc99 layer.conf: update LAYERSERIES_COMPAT sumo' -> thud'
Since `9ec5a8a layer.conf: Drop sumo from LAYERSERIES_CORENAMES' and
`9867924 layer.conf: Add thud to LAYERSERIES_CORENAMES' applied in oe-core,
update LAYERSERIES_COMPAT `sumo' -> `thud'

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
2018-10-08 14:47:47 +08:00
Jia Zhang 139a9b656d Clean up the stuffs for stable branches
The following commits are reverted by the way:

- seloader: Fix building for rocko (bc6bbe2)
- meta-integrity: rpm: Add back in required patches for rocko (5fa9c85)

Because they are only applicable to rocko.

Signed-off-by: Jia Zhang <zhang.jia@linux.alibaba.com>
2018-09-20 21:21:37 -04:00
Trevor Woerner c2e3fe9168 tpm2: move configure option
The --with-udevrulesdir configure option has been moved from tpm2-abrmd to
tpm2-tss in the code, therefore move its associated EXTRA_OECONF to suit.

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
2018-08-03 10:49:00 +08:00
Trevor Woerner dc173c7a8d tpm2: update release recipes
tpm2-tss: 1.4.0 -> 2.0.0
tpm2-abrmd: 1.3.1 -> 2.0.1
tpm2-tools: 3.0.4 -> 3.1.1

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
2018-08-03 10:49:00 +08:00
Tom Rini cd40815e69 layer.conf: Mark as compatible with rocko
As we also work with the 'rocko' release list that in our
LAYERSERIES_COMPAT.

Signed-off-by: Tom Rini <trini@konsulko.com>
2018-07-25 20:41:35 +08:00
Trevor Woerner 089dd7e811 tpm2 git AUTOREV fix for BB_NO_NETWORK
Bitbake will try an ls-remote for any recipe whose SRCREV is AUTOREV,
even if that recipe will not ultimately be used for a particular build.
Therefore if the user specifies 'BB_NO_NETWORK = "1"', the _git versions of
the tpm2 recipes will cause the build to fail even if the _git versions are
not going to be built (which they won't be by default on account of their
DEFAULT_PREFERENCE being set to "-1").

This fix follows the same pattern as
https://github.com/sbabic/meta-swupdate/commit/721fcc89c53debcd6582bd1aa972f75297cf12e9

With this fix, the user can disable networking and successfully build the
non-_git versions of the tpm2 recipes. If the user wants to build the _git
versions, networking must be enabled. The build is expected to fail if the
user asks for the _git versions, but disables networking.

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
2018-07-10 09:30:16 +08:00
Trevor Woerner ce1bb2fa28 Revert "tpm2-abrmd: move tpm2-abrmd.default to tpm2-abrmd.inc"
This reverts commit 0bb383b60a.
2018-06-26 09:58:27 +08:00
Jia Zhang 5497078ef4 tpm2-tools: refresh the dlopen patch for 3.0.4
The latest git version has updated to use dl interface to load
the library of tpm2-abrmd, instead of linking it on compilation.

Signed-off-by: Jia Zhang <zhang.jia@linux.alibaba.com>
2018-06-16 05:33:13 -04:00
Jia Zhang 0bb383b60a tpm2-abrmd: move tpm2-abrmd.default to tpm2-abrmd.inc
Use separate directories to store tpm2-abrmd.default for stable
and git version.

Signed-off-by: Jia Zhang <zhang.jia@linux.alibaba.com>
2018-06-16 05:12:46 -04:00
Jia Zhang 60be51b4ee tpm2-abrmd: code style cleanup
Signed-off-by: Jia Zhang <zhang.jia@linux.alibaba.com>
2018-06-16 04:41:05 -04:00
Jia Zhang 62638c5a24 tpm2-abrmd: Fix missing tpm2-abrmd.service
The default value of --with-systemdsystemunitdir with the prefix
"/usr" cannot be used to search tpm2-abrmd.service. In order to
fix this issue, explicitly set --with-systemdsystemunitdir as
before. In addition, place .perset to the dedicated system-preset
directory.

Signed-off-by: Jia Zhang <zhang.jia@linux.alibaba.com>
2018-06-16 04:35:55 -04:00
Jia Zhang 23d074cba7 tpm2-tss: code style cleanup
Replace tab with four spaces.

Signed-off-by: Jia Zhang <zhang.jia@linux.alibaba.com>
2018-06-16 04:09:39 -04:00
Trevor Woerner de08228a0d tpm2-abrmd: update daemon cmdline options
In the latest git version of abrmd:
	- the following option has been renamed:
		--max-transient-objects -> --max-transients

	- the following option has been removed:
		--fail-on-loaded-trans

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
2018-06-15 13:01:25 +08:00