[yocto] [meta-security][PATCH] tpm2.0-tss: install resourcemgr service

Patrick Ohly patrick.ohly at intel.com
Fri Mar 24 02:28:37 PDT 2017


On Thu, 2017-03-23 at 15:26 +0100, Benjamin Gaignard wrote:
> +diff --git a/contrib/resourcemgr.service b/contrib/resourcemgr.service
> +index 7f23739..e5b0900 100644
> +--- a/contrib/resourcemgr.service
> ++++ b/contrib/resourcemgr.service
> +@@ -3,7 +3,7 @@ Description=TPM2 resource manager & access broker
> + Documentation=http://www.github.com/01org/TPM2.0-TSS
> + 
> + [Service]
> +-ExecStart=/usr/local/sbin/resourcemgr
> ++ExecStart=/usr/sbin/resourcemgr
> + StandardOutput=null
> + User=tss
> + Group=tss
> +-- 
> +1.9.1

I think it would be better to patch the actual ${sbindir} into the
resourcemgr.service file, instead of assuming that ${sbindir}
= /usr/sbin and using a static patch.

Something like this:

do_patch[postfuncs] += "fix_systemd_unit"
fix_systemd_unit () {
    sed -i -e 's;^ExecStart=.*/resourcemgr;ExecStart=${sbindir}/resourcemgr;' ${S}/contrib/resourcemgr.service
}

Just my 2 cents.

-- 
Best Regards, Patrick Ohly

The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.






More information about the yocto mailing list