Skip to contentSkip to conversation

meta-hardening/binutils: harden installation permissions

PATCH New Marta Rybczynska 1 participant 1 message Aug 25, 2021

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 meta-hardening/binutils: harden installation permissions

Compilers and related utils are better restricted on production platforms. Change permissions of all installed binutils tools to remove access from users outside of the root group.

This also demonstrates how to restrict file permissions in a hardened distribution.

---
 meta-hardening/recipes-devtools/binutils/binutils_%.bbappend | 3 +++
 1 file changed, 3 insertions(+)
 create mode 100644 meta-hardening/recipes-devtools/binutils/binutils_%.bbappend
meta-hardening/recipes-devtools/binutils/binutils_%.bbappend new file +3 -0
new file mode 100644
index 0000000..3eb3ad0
@@ -0,0 +1,3 @@
+do_install_append_class-target () {
+    chmod o-rx ${D}${prefix}/${TARGET_SYS}/bin/*
+}
Signature · 1 line
2.30.2