Commit Graph

79 Commits

Author SHA1 Message Date
Marta Rybczynska
aa7213378a packagegroup-core-security: unify conditional adding of packages on RISCV
The package choice was using TUNE_FEATURES that doesn't work anymore
with multiple sub-architectures of RISCV. Instead use the overrides
and make sure to take into account also qemu versions.

Only riscv32/riscv64 does not work, fail on RDEPEND for qemu targets.

Signed-off-by: Marta Rybczynska <marta.rybczynska@ygreky.com>
2025-07-23 18:45:56 +02:00
Armin Kuster
a9c3a4fdfd packagegroup-core-security: drop firejail for musl
appears to be a known issue:
https://bugs.gentoo.org/937374

Signed-off-by: Armin Kuster <akuster808@gmail.com>
2025-01-06 20:01:40 -05:00
Yi Zhao
c9585ebfe8 dm-verity-image-initramfs: drop lvm2-udevrules
Drop lvm2-udevrules as it has been removed in meta-openembedded
commit[1].

[1] https://git.openembedded.org/meta-openembedded/commit/?h=master&id=c37c867e1adddd6fa39cf3f3d4c6688ea6dc825a

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2024-11-24 20:19:50 -05:00
Changqing Li
ceb47a8a39 recipes: WORKDIR -> UNPACKDIR transition
* WORKDIR -> UNPACKDIR transition
* Switch away from S = WORKDIR

Signed-off-by: Changqing Li <changqing.li@windriver.com>
[Fixed up the smack changes due to prior patch]
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2024-06-17 08:25:25 -04:00
Marta Rybczynska
3a88379610 packagegroup-core-security: update libseccomp dependencies
libseccomp requires DISTRO_FEATURE seccomp enabled. This one
is automatically removed for riscv, so we do not need to add
an additional condition.

This change is necessary for cve-check on world with meta-security

Signed-off-by: Marta Rybczynska <marta.rybczynska@syslinbit.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2024-05-08 22:03:13 -04:00
Kevin Hao
40ddb9e5ed dm-verity-image-initramfs: Set IMAGE_NAME_SUFFIX to empty
According to the Yocto reference manual [1], the IMAGE_NAME_SUFFIX should
be set to empty for the initramfs image. Otherwise, we may incur a build
error like following due to the initrd check in live-vm-common.bbclass:
  ERROR: core-image-minimal-1.0-r0 do_bootimg: build-test/tmp/deploy/images/genericx86-64/dm-verity-image-initramfs-genericx86-64.cpio.gz is invalid. initrd image creation failed.
  ERROR: core-image-minimal-1.0-r0 do_bootimg: ExecutionError('build-test/tmp/work/genericx86_64-poky-linux/core-image-minimal/1.0/temp/run.build_hddimg.1961965', 1, None, None)
  ERROR: Logfile of failure stored in: build-test/tmp/work/genericx86_64-poky-linux/core-image-minimal/1.0/temp/log.do_bootimg.1961965
  ERROR: Task (poky/meta/recipes-core/images/core-image-minimal.bb:do_bootimg) failed with exit code '1'

[1] https://docs.yoctoproject.org/ref-manual/variables.html#term-IMAGE_NAME_SUFFIX

Signed-off-by: Kevin Hao <kexin.hao@windriver.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2024-03-27 12:36:58 -04:00
Wurm, Stephan
a94674c5bc dm-verity-image-initramfs: Allow compressed image types
Using <DM_VERITY_IMAGE_TYPE> in the depends variable does not work for
compressed image types like squashfs-zst, as the resulting task
dependency still contains the incompatible dash. Replacing the dash by
an underscore resolves this issue.

Signed-off-by: Stephan Wurm <stephan.wurm@a-eberle.de>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2023-08-06 11:31:18 -04:00
Armin Kuster
e4318a3c5a packagegroup-core-security: only include firejail x86-64 and arch64
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2023-07-31 06:18:52 -04:00
Armin Kuster
cfe7335568 qemu: move qemu setting to image and out of layer.conf
I suspect its better form to have these in the image definition.

Signed-off-by: Armin Kuster <akuster808@gmail.com>
2023-07-31 06:18:52 -04:00
Armin Kuster
515dd792ba packagegroup-core-security: add os-release
Exclude openscap and scap-security-guide if musl

Fix RDEPENDS list to include compliance packages.

Signed-off-by: Armin Kuster <akuster808@gmail.com>
2023-06-25 15:05:28 -04:00
Paul Gortmaker
521e7b040a dm-verity: hook separate hash into initramfs framework
The prior commits create the separate hash so now it is time to update
the initramfs framework so that veritysetup, which is responsible for
binding the data and hash, is aware of when separate hash is in use,
and can react accordingly.

The added code follows the existing appended hash code style, but is
considerably smaller because it doesn't have the large case statement
that supports all possible identification schemes (label, UUID, ...).

With the root hash split in two to create the respective partition
UUIDs, we know exactly how to identify it, and the UUIDs used.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2023-06-25 15:05:28 -04:00
Armin Kuster
6ae25c7673 packagegroup-core-security: add compliance pkg group
Signed-off-by: Armin Kuster <akuster808@gmail.com>

---
v2]
Missed to include trailing \
2023-06-20 11:07:20 -04:00
Kevin Hao
c50757b2f1 dmverity: Suppress the realpath errors
If we use a non PARTUUID root parameter, we would always get a error
like below:
  realpath: /dev/disk/by-partuuid//dev/mmcblk0p2: No such file or directory

This seems pretty confusion and it also seems no need to emit this kind
of error when we are waiting for the root device. So suppress all the
realpath errors.

Signed-off-by: Kevin Hao <kexin.hao@windriver.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2023-06-11 10:40:33 -04:00
Armin Kuster
4ed311eaf7 packagegroup-core-security: refactor the inclusion of krill
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2023-03-22 08:02:50 -04:00
John Edward Broadbent
571af37e9c meta-security: Add recipe for Glome
Generic Low Overhead Message Exchange (GLOME) is a protocol providing
secure authentication and authorization for low dependency environments.

Signed-off-by: John Edward Broadbent <jebr@google.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-08-12 08:32:51 -07:00
Armin Kuster
5f530ba5ab packagegroup-core-security: add pkg to grp
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-08-12 08:32:51 -07:00
Armin Kuster
c352530c13 packagegroup-core-security: add space for appends
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-08-06 08:55:49 -07:00
Armin Kuster
2a2d650ee0 packagegroup-core-security: remove krill for some archs
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-08-02 13:45:26 -07:00
Armin Kuster
d8d3824d2d packagegroup-core-security: add chipsec pkg to grp
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-08-02 13:45:26 -07:00
Armin Kuster
c48c6e5881 packagegroup-core-security: add krill to pkg grps
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-08-02 13:45:26 -07:00
Armin Kuster
ac0a4ea0f8 packagegroup-core-security.bb: add bubblewrap to pkg grp
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-07-30 14:11:27 -07:00
Armin Kuster
f453866cf6 security-build-image: add lkrg-module to build image
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-06-23 18:47:59 -07:00
Armin Kuster
a68a46ded9 packagegroup-core-security: skip mips firejail
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-06-23 18:47:59 -07:00
Armin Kuster
123c59c313 security-test-image: add firejail and aide test suites
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-06-23 18:47:59 -07:00
Armin Kuster
6cdb369591 packagegroup-core-security: add firejail
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-06-23 18:47:59 -07:00
Armin Kuster
6c77d06b84 security-test-image: auto include layers if present.
This is to simplify tesing to build one image and include pkgs depending on the
layers included in the BBLAYERS.

Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-06-18 06:48:22 -07:00
Armin Kuster
db2ebfc0d3 packagegroup-core-security: drop sssd
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-06-18 06:48:22 -07:00
Armin Kuster
8c6fe006a1 packagegroup-core-security: don't include aprwatch for musl
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-06-07 16:58:24 -07:00
Armin Kuster
5bdb7a35c1 packagegroup-core-security: drop arpwatch for riscv from pkg grp
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-06-07 16:58:24 -07:00
Armin Kuster
982ff6fb97 packagegroup-core-security: add arpwatch and chkrootkit to pkg grp
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-06-07 16:58:24 -07:00
Armin Kuster
bc59937b54 packagegroup-core-security.bb: fix suricata inclusion
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-05-14 10:51:32 -07:00
Armin Kuster
55839bcd20 packagegroup-core-security: remove pkgs
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2022-05-14 10:51:32 -07:00
Armin Kuster
e740a30c10 libest: does not build with openssl 3.x
blacklist for now. Remove from pkg grp

Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-12-25 11:29:31 -08:00
Armin Kuster
e5e54135da opendnssec: blacklist do to ldns being blacklisted
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-10-24 19:54:00 -07:00
Christer Fletcher
650e6d6d4b dmverity: Make use of DATA_BLOCK_SIZE variable in initrdscript.
DATA_BLOCK_SIZE variable was set in dm-verity-img.bbclass at build
time but the initrdscript was not updated to pass the DATA_BLOCK_SIZE
to the veritysetup. Now the functionality is complete.

Signed-off-by: Paulo Neves <paulo.neves1@inter.ikea.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-09-28 16:18:41 -07:00
Armin Kuster
c885d399cd packagegroup-core-security.bb: only include suricat-ptest if rust is included
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-08-01 08:47:08 -07:00
Armin Kuster
11a67b861a meta-security: Convert to new override syntax
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-08-01 08:47:08 -07:00
Armin Kuster
f447658731 packagegroup-core-security.bb: fix suricat-ptest inclusion
drop libseccomp ptest

Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-07-28 18:21:25 -07:00
Armin Kuster
be53d1a467 initramfs-framework: rename files dir
Fixes:
ERROR: initramfs-framework-1.0-r4 do_fetch: Fetcher failure for URL: 'file://dmverity'. Unable to fetch URL from any source.

Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-06-29 09:31:13 -07:00
Armin Kuster
8f313d951c packagegroup-core-security: add sshguard
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-06-29 09:31:13 -07:00
Armin Kuster
54186fc738 initramfs-framework: fix typo in conditional
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-06-29 09:31:13 -07:00
Armin Kuster
0c26950b0d packagegroup-core-security: drop python3-scapy
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-06-05 19:25:24 +00:00
Armin Kuster
f40fdc7e6d initramfs-framework: fix YCL issue.
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-06-05 19:25:24 +00:00
Armin Kuster
a1d5476acc busybox: drop as libsecomp is in core
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-06-05 19:25:23 +00:00
Armin Kuster
e1f0699492 packagegroup-core-security: exclude ossec-hids from musl
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-06-05 19:25:17 +00:00
Armin Kuster
ab239f1497 packagegroup-core-security: add clamav-daemon
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-05-16 13:23:55 -07:00
Armin Kuster
31e5b3e08f packagegroup-core-security: add aide and ossec
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-05-16 13:23:55 -07:00
Armin Kuster
06101dd3da packagegroup-core-security: fix typo for mips
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-05-16 13:23:55 -07:00
Armin Kuster
7db47965a2 tripwire: Blacklist pkg, upstream seems abandond
Last update was 2018. Does not build with gcc11.
There are other actively maintained IDS options.

Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-05-16 13:23:55 -07:00
Armin Kuster
881d441f71 packagegroup-core-security: exclude apparmor in mips64
Signed-off-by: Armin Kuster <akuster808@gmail.com>
2021-04-19 06:56:18 -07:00