All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrea Adami <andrea.adami@gmail.com>
To: Christopher Larson <kergoth@gmail.com>
Cc: openembedded-core <openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH 1/3] update_gio_module_cache: fix host user contamination
Date: Wed, 29 Mar 2017 23:08:00 +0200	[thread overview]
Message-ID: <CAAQYJAsVvf+=jvrX0NEnypsEZDJkfFzZVbbri+-DW82o6oeSxw@mail.gmail.com> (raw)
In-Reply-To: <CABcZAN=vQzdwxd6F=nGBq0TWhOjx8kw0_MZfPpN82V=pbntF5g@mail.gmail.com>

On Wed, Mar 29, 2017 at 10:40 PM, Christopher Larson <kergoth@gmail.com> wrote:
>
> On Wed, Mar 29, 2017 at 1:33 PM, Andrea Adami <andrea.adami@gmail.com>
> wrote:
>>
>> On Tue, Mar 28, 2017 at 6:14 PM, Christopher Larson <kergoth@gmail.com>
>> wrote:
>> > From: Abdur Rehman <abdur_rehman@mentor.com>
>> >
>> > update_gio_module_cache intercept creates file:
>> > $D${libdir}/gio/modules/giomodule.cache
>> >
>> > Change ownership of this file to root:root to avoid user contamination
>> > by host.
>> >
>> > Signed-off-by: Abdur Rehman <abdur_rehman@mentor.com>
>> > Signed-off-by: Christopher Larson <chris_larson@mentor.com>
>> > ---
>> >  scripts/postinst-intercepts/update_gio_module_cache | 2 ++
>> >  1 file changed, 2 insertions(+)
>> >
>> > diff --git a/scripts/postinst-intercepts/update_gio_module_cache
>> > b/scripts/postinst-intercepts/update_gio_module_cache
>> > index fe468092cf..92092f2144 100644
>> > --- a/scripts/postinst-intercepts/update_gio_module_cache
>> > +++ b/scripts/postinst-intercepts/update_gio_module_cache
>> > @@ -5,3 +5,5 @@ set -e
>> >  PSEUDO_UNLOAD=1 qemuwrapper -L $D -E
>> > LD_LIBRARY_PATH=$D${libdir}:$D${base_libdir} \
>> >          $D${libexecdir}/${binprefix}gio-querymodules
>> > $D${libdir}/gio/modules/
>> >
>> > +chown root:root $D${libdir}/gio/modules/giomodule.cache
>> > +
>> > --
>> > 2.11.1
>> >
>> > --
>> > _______________________________________________
>> > Openembedded-core mailing list
>> > Openembedded-core@lists.openembedded.org
>> > http://lists.openembedded.org/mailman/listinfo/openembedded-core
>>
>>
>> Hello,
>> There must be something wrong with this patch.
>> After fresh pull of an hour ago I git:
>>
>> andrea@ThinkPad-T520:/oe/oe-core/build$ bitbake core-image-base
>> Loading cache: 100% |############################################| Time:
>> 0:00:00
>> Loaded 2095 entries from dependency cache.
>> NOTE: Resolving any missing task queue dependencies
>>
>> Build Configuration:
>> BB_VERSION        = "1.33.2"
>> BUILD_SYS         = "x86_64-linux"
>> NATIVELSBSTRING   = "ubuntu-16.04"
>> TARGET_SYS        = "arm-oe-linux-gnueabi"
>> MACHINE           = "c7x0"
>> DISTRO            = "nodistro"
>> DISTRO_VERSION    = "nodistro.0"
>> TUNE_FEATURES     = "arm armv5 thumb dsp"
>> TARGET_FPU        = "soft"
>> meta              = "master:c187326afcf1e9d781c1bd0923e1362a6f50f613"
>> meta-handheld     = "master:f88f5bc546ec18de232a91dc1c8185ad242c45f7"
>> meta-oe
>> meta-initramfs    = "master:225e64d95bc41077782815f3dceb6f2d1a42b167"
>>
>> Initialising tasks: 100% |#######################################| Time:
>> 0:00:08
>> NOTE: Executing SetScene Tasks
>> NOTE: Executing RunQueue Tasks
>> WARNING: core-image-base-1.0-r0 do_rootfs: The postinstall intercept
>> hook 'update_gio_module_cache' failed (exit code: 1)! See log for
>> details! (Output: b'')
>> WARNING: core-image-base-1.0-r0 do_rootfs: The postinstalls for the
>> following packages will be postponed for first boot: libglib-2.0-0
>> NOTE: Tasks Summary: Attempted 3440 tasks of which 3427 didn't need to
>> be rerun and all succeeded.
>
>
> Odd, we’ve been running with this applied for ages. Is there anything useful
> in do_rootfs? I’ll attempt to repro here. Thanks, and sorry for the hassle.
> --

There is just a laconical message:

NOTE: Running intercept scripts:
NOTE: > Executing update_gio_module_cache intercept ...
chown: cannot access
'/tmp/build/tmp-glibc/work/c7x0-oe-linux-gnueabi/core-image-base/1.0-r0/rootfs/usr/lib/gio/modules/giomodule.cache':
No such file or directory

Here the permissions:
andrea@ThinkPad-T520:/tmp/build/tmp-glibc/work/c7x0-oe-linux-gnueabi/core-image-base/1.0-r0/rootfs/usr/lib/gio$
ls -al
total 0
drwxr-xr-x 3 andrea andrea   60 mar 29 21:33 .
drwxr-xr-x 6 andrea andrea 1660 mar 29 22:51 ..
drwxr-xr-x 2 andrea andrea   40 mar 29 21:33 modules

Cheers
Andrea

> Christopher Larson
> kergoth at gmail dot com
> Founder - BitBake, OpenEmbedded, OpenZaurus
> Senior Software Engineer, Mentor Graphics


  reply	other threads:[~2017-03-29 21:07 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-28 16:14 [PATCH 0/3] A few misc fixes Mentor is carrying Christopher Larson
2017-03-28 16:14 ` [PATCH 1/3] update_gio_module_cache: fix host user contamination Christopher Larson
2017-03-29 20:33   ` Andrea Adami
2017-03-29 20:40     ` Christopher Larson
2017-03-29 21:08       ` Andrea Adami [this message]
2017-03-30  8:54         ` Jussi Kukkonen
2017-03-29 23:54       ` Peter Kjellerstedt
2017-03-30  8:57         ` Richard Purdie
2017-03-30 11:46         ` Patrick Ohly
2017-03-30  9:27   ` Alexander Kanavin
2017-03-28 16:14 ` [PATCH 2/3] sysroot-relativelinks: also consider links to dirs on the host Christopher Larson
2017-03-28 16:14 ` [PATCH 3/3] systemd-boot: write startup.nsh Christopher Larson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAAQYJAsVvf+=jvrX0NEnypsEZDJkfFzZVbbri+-DW82o6oeSxw@mail.gmail.com' \
    --to=andrea.adami@gmail.com \
    --cc=kergoth@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.