diff --git a/harden_osmo-hnbgw.service.patch b/harden_osmo-hnbgw.service.patch new file mode 100644 index 0000000..d208bd2 --- /dev/null +++ b/harden_osmo-hnbgw.service.patch @@ -0,0 +1,22 @@ +Index: osmo-iuh-0.7.0/contrib/systemd/osmo-hnbgw.service +=================================================================== +--- osmo-iuh-0.7.0.orig/contrib/systemd/osmo-hnbgw.service ++++ osmo-iuh-0.7.0/contrib/systemd/osmo-hnbgw.service +@@ -2,6 +2,17 @@ + Description=Osmocom Home Nodeb Gateway (OsmoHNBGW) + + [Service] ++# added automatically, for details please see ++# https://en.opensuse.org/openSUSE:Security_Features#Systemd_hardening_effort ++ProtectSystem=full ++ProtectHome=true ++ProtectHostname=true ++ProtectKernelTunables=true ++ProtectKernelModules=true ++ProtectKernelLogs=true ++ProtectControlGroups=true ++RestrictRealtime=true ++# end of automatic additions + Type=simple + Restart=always + ExecStart=/usr/bin/osmo-hnbgw -c /etc/osmocom/osmo-hnbgw.cfg diff --git a/osmo-iuh.changes b/osmo-iuh.changes index 4d4649b..4aeff2c 100644 --- a/osmo-iuh.changes +++ b/osmo-iuh.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Oct 13 13:53:31 UTC 2021 - Johannes Segitz + +- Added hardening to systemd service(s) (bsc#1181400). Added patch(es): + * harden_osmo-hnbgw.service.patch + ------------------------------------------------------------------- Sun Mar 14 21:07:14 UTC 2021 - Jan Engelhardt diff --git a/osmo-iuh.spec b/osmo-iuh.spec index 3b05075..6f330e5 100644 --- a/osmo-iuh.spec +++ b/osmo-iuh.spec @@ -26,6 +26,7 @@ Group: Hardware/Mobile URL: https://osmocom.org/projects/osmohnbgw/wiki Source: https://github.com/osmocom/osmo-iuh/archive/%version.tar.gz +Patch0: harden_osmo-hnbgw.service.patch BuildRequires: automake >= 1.9 BuildRequires: libtool >= 2 BuildRequires: lksctp-tools-devel